commit 09ae0dd3fee0c42fcb06fba6b31605e7a7117c63 Author: Benjamin Toby Date: Tue Nov 5 12:12:42 2024 +0100 First Commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..0a51e10 --- /dev/null +++ b/.gitignore @@ -0,0 +1,141 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +lerna-debug.log* + +# Diagnostic reports (https://nodejs.org/api/report.html) +report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json + +# Runtime data +pids +*.pid +*.seed +*.pid.lock + +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov + +# Coverage directory used by tools like istanbul +coverage +*.lcov + +# nyc test coverage +.nyc_output + +# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# Bower dependency directory (https://bower.io/) +bower_components + +# node-waf configuration +.lock-wscript + +# Compiled binary addons (https://nodejs.org/api/addons.html) +build/Release + +# Dependency directories +node_modules/ +jspm_packages/ + +# TypeScript v1 declaration files +typings/ + +# TypeScript cache +*.tsbuildinfo + +# Optional npm cache directory +.npm + +# Optional eslint cache +.eslintcache + +# Microbundle cache +.rpt2_cache/ +.rts2_cache_cjs/ +.rts2_cache_es/ +.rts2_cache_umd/ + +# Optional REPL history +.node_repl_history + +# Output of 'npm pack' +*.tgz + +# Yarn Integrity file +.yarn-integrity + +# dotenv environment variables file +.env + +# parcel-bundler cache (https://parceljs.org/) +.cache + +# Next.js build output +.next + +# Nuxt.js build / generate output +.nuxt + +dist/dev +dist/build.js +dist/kill* + +# Gatsby files +.cache/ +# Comment in the public line in if your project uses Gatsby and *not* Next.js +# https://nextjs.org/blog/next-9-1#public-directory-support +# public + +# vuepress build output +.vuepress/dist + +# Serverless directories +.serverless/ + +# FuseBox cache +.fusebox/ + +# DynamoDB Local files +.dynamodb/ + +# TernJS port file +.tern-port + +# Other folders +/dsql-app/node_shell +dump/ +/dsql-app/webhook-server +/dsql-app/cache +/dsql-app/websocket +apiKeys +/dsql-app/jsonData/dbSchemas/users +/dsql-app/public/tinymce/ +/dsql-app/public/images/user-images +/dsql-app/public/images/user_images/* +tmpDbFile.sql +/dsql-app/package-lock.json +/dsql-app/.dist + +# logs +.tmp + +# SHell scrips +.sh + +/dsql-app/test + +*flight.sh +REDEPLOY +*client-cert.pem +*client-key.pem + +/dsql-data/* +!/dsql-data/static-config +!/dsql-data/db-config + +new-user.json +update-user.json diff --git a/dsql-app/.dockerignore b/dsql-app/.dockerignore new file mode 100644 index 0000000..edb3d0f --- /dev/null +++ b/dsql-app/.dockerignore @@ -0,0 +1,3 @@ +jsonData/dbSchemas/users +.git +node_modules diff --git a/dsql-app/.local_dist/BUILD_ID b/dsql-app/.local_dist/BUILD_ID new file mode 100644 index 0000000..7994359 --- /dev/null +++ b/dsql-app/.local_dist/BUILD_ID @@ -0,0 +1 @@ +vsppBJBDbOVrlLfYIAYwv \ No newline at end of file diff --git a/dsql-app/.local_dist/build-manifest.json b/dsql-app/.local_dist/build-manifest.json new file mode 100644 index 0000000..ec94b2c --- /dev/null +++ b/dsql-app/.local_dist/build-manifest.json @@ -0,0 +1,629 @@ +{ + "polyfillFiles": [ + "static/chunks/polyfills-c67a75d1b6f99dc8.js" + ], + "devFiles": [], + "ampDevFiles": [], + "lowPriorityFiles": [ + "static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js", + "static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" + ], + "rootMainFiles": [], + "pages": { + "/": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/3935-eea593fa60dfd620.js", + "static/css/65efe10b506f9812.css", + "static/chunks/pages/index-c2ab88c2111475dd.js" + ], + "/404": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/404-d04d8d42f75218d9.js" + ], + "/500": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/500-7db225cc6b4dea2c.js" + ], + "/_app": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/css/c83c1473ba7928cd.css", + "static/chunks/pages/_app-881c4f419bb13dab.js" + ], + "/_error": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/_error-f2496e8b9fdedb89.js" + ], + "/about": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/3935-eea593fa60dfd620.js", + "static/chunks/pages/about-76deaa37497c062c.js" + ], + "/admin": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/3181-e628e642754b0f35.js", + "static/chunks/5667-9e7b94f8ce529764.js", + "static/chunks/pages/admin-81e2733c0d783481.js" + ], + "/admin/[user_id]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/3181-e628e642754b0f35.js", + "static/chunks/5667-9e7b94f8ce529764.js", + "static/chunks/pages/admin/[user_id]-e36cc5d13c2aa929.js" + ], + "/admin/[user_id]/api-keys": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/pages/admin/[user_id]/api-keys-ad926df40536b287.js" + ], + "/admin/[user_id]/connect": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/pages/admin/[user_id]/connect-8973f4ea35b17adf.js" + ], + "/admin/[user_id]/databases": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/3181-e628e642754b0f35.js", + "static/chunks/pages/admin/[user_id]/databases-2ede91ae9bfe108a.js" + ], + "/admin/[user_id]/databases/[single]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/pages/admin/[user_id]/databases/[single]-35266a148b439139.js" + ], + "/admin/[user_id]/databases/[single]/connect": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/connect-6fe32fdcf255139c.js" + ], + "/admin/[user_id]/databases/[single]/edit-database": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/8887-5917115e54cd417b.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/edit-database-a60b50dd21c29ae2.js" + ], + "/admin/[user_id]/databases/[single]/schema": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/8473-1a1faf3d4d34beef.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/8887-5917115e54cd417b.js", + "static/chunks/7200-4c384098300f07db.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/schema-7b76b5c228e273d4.js" + ], + "/admin/[user_id]/databases/[single]/shell": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/3795-b7a314b891092ea4.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/shell-cb2910aa3bd12a22.js" + ], + "/admin/[user_id]/databases/[single]/tables": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables-512e452212994e35.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/94726e6d-f5320de901b4c44f.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/9572-f67b1194a0e6ae72.js", + "static/chunks/1502-965711da5f99a5c8.js", + "static/chunks/8446-a36a685092b53a06.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/4893-e30c16360c86c67d.js", + "static/chunks/9788-84477f8e20625988.js", + "static/chunks/9035-b11038b244e852f0.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]-0d9a8a82c8b584d3.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/94726e6d-f5320de901b4c44f.js", + "static/chunks/9572-f67b1194a0e6ae72.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/4893-e30c16360c86c67d.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table-4d03eae9a64fe6a7.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/1502-965711da5f99a5c8.js", + "static/chunks/8446-a36a685092b53a06.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9788-84477f8e20625988.js", + "static/chunks/9035-b11038b244e852f0.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries-3a14a471d2dc7b00.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/1502-965711da5f99a5c8.js", + "static/chunks/8446-a36a685092b53a06.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9788-84477f8e20625988.js", + "static/chunks/9035-b11038b244e852f0.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]-a15e553c68e1ca23.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/1502-965711da5f99a5c8.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9788-84477f8e20625988.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry-0ecd226005afec57.js" + ], + "/admin/[user_id]/databases/[single]/tables/[single_table]/fields": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/94726e6d-f5320de901b4c44f.js", + "static/chunks/9572-f67b1194a0e6ae72.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/4893-e30c16360c86c67d.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields-ab993bc50ce1e800.js" + ], + "/admin/[user_id]/databases/[single]/tables/add-table": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/94726e6d-f5320de901b4c44f.js", + "static/chunks/9572-f67b1194a0e6ae72.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/4893-e30c16360c86c67d.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/tables/add-table-09cebcb0b429f6de.js" + ], + "/admin/[user_id]/databases/[single]/users": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/8264-5901ddfeb3cb03ce.js", + "static/chunks/5949-b1c68b62cd5dbfee.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/users-0afdf841aae9f757.js" + ], + "/admin/[user_id]/databases/[single]/users/[user]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/2870-8e302171aed920f8.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]-f7cdffc0b0c094c6.js" + ], + "/admin/[user_id]/databases/[single]/users/[user]/change-password": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]/change-password-21db218c89054e75.js" + ], + "/admin/[user_id]/databases/[single]/users/add-social-logins": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/2870-8e302171aed920f8.js", + "static/chunks/9719-14cc8b76a1deed3c.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/users/add-social-logins-3e4d353e902f53ae.js" + ], + "/admin/[user_id]/databases/[single]/users/add-user": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/2870-8e302171aed920f8.js", + "static/chunks/9719-14cc8b76a1deed3c.js", + "static/chunks/pages/admin/[user_id]/databases/[single]/users/add-user-36cc73c2fdadfc25.js" + ], + "/admin/[user_id]/databases/add-database": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/8887-5917115e54cd417b.js", + "static/chunks/pages/admin/[user_id]/databases/add-database-e3a5509e700b0e80.js" + ], + "/admin/[user_id]/media": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/4156-a7c42d729046e9bc.js", + "static/chunks/pages/admin/[user_id]/media-922d349166d14d18.js" + ], + "/admin/[user_id]/media/[...folder]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/4156-a7c42d729046e9bc.js", + "static/chunks/pages/admin/[user_id]/media/[...folder]-773d7108b2688df4.js" + ], + "/admin/[user_id]/schema": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/8473-1a1faf3d4d34beef.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/194-da10d06ed5c55a8f.js", + "static/chunks/7200-4c384098300f07db.js", + "static/chunks/pages/admin/[user_id]/schema-d264203c84a34e72.js" + ], + "/admin/[user_id]/settings": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/9967-c027b915261dae19.js", + "static/chunks/3181-e628e642754b0f35.js", + "static/chunks/8374-f28680e628b18bd5.js", + "static/chunks/5667-9e7b94f8ce529764.js", + "static/chunks/5114-a70f18877cc7f8bc.js", + "static/chunks/pages/admin/[user_id]/settings-7a69db8bd70bed09.js" + ], + "/admin/[user_id]/users": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/5949-b1c68b62cd5dbfee.js", + "static/chunks/pages/admin/[user_id]/users-8b4f68a1fd38c9b3.js" + ], + "/admin/[user_id]/users/add-user": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/pages/admin/[user_id]/users/add-user-c50fb941e687320a.js" + ], + "/admin/[user_id]/users/databases": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/5949-b1c68b62cd5dbfee.js", + "static/chunks/pages/admin/[user_id]/users/databases-ee8daf5a492656f7.js" + ], + "/admin/[user_id]/users/databases/[database]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/5949-b1c68b62cd5dbfee.js", + "static/chunks/pages/admin/[user_id]/users/databases/[database]-28052313a8523fc1.js" + ], + "/admin/[user_id]/users/databases/[database]/[user]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/9365-101d5c9d637cef9a.js", + "static/chunks/2870-8e302171aed920f8.js", + "static/chunks/pages/admin/[user_id]/users/databases/[database]/[user]-1922bb43b40f7cbb.js" + ], + "/blog": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/blog-be6db5dd2389f8c4.js" + ], + "/contact": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/contact-513427eea0db408d.js" + ], + "/create-account": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/8374-f28680e628b18bd5.js", + "static/chunks/5114-a70f18877cc7f8bc.js", + "static/chunks/pages/create-account-c97da041b7809649.js" + ], + "/docs": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/docs-de42203d30b1880d.js" + ], + "/docs/[page]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/docs/[page]-3602862f9a9542f8.js" + ], + "/docs/[page]/[sub-page]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/docs/[page]/[sub-page]-b3641ae1942e2312.js" + ], + "/email-verification": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/email-verification-2643dd10f1b54d59.js" + ], + "/login": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/8374-f28680e628b18bd5.js", + "static/chunks/pages/login-5453e8ec28f13db7.js" + ], + "/logout": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/logout-043abd512c88b3d5.js" + ], + "/pricing": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/pricing-e193043fd895ccd5.js" + ], + "/privacy": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/privacy-6a6371ab4eda9c15.js" + ], + "/redirect": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/redirect-f189e8f0d6ae1482.js" + ], + "/reset-password": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/29107295-4a69275373f23f88.js", + "static/chunks/pages/reset-password-a754110c3b3e20fb.js" + ], + "/send-password-reset-link": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/send-password-reset-link-62def12808387ec7.js" + ], + "/su": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/3695-c03f5685e1b79345.js", + "static/chunks/pages/su-0929bdda8a625d2f.js" + ], + "/su/backups": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/pages/su/backups-4a9e96c30acc4626.js" + ], + "/su/console": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/ed150ef9-713e0b995a8779c6.js", + "static/chunks/493-ec86d71e0fece010.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/css/85fa6dafca566008.css", + "static/chunks/pages/su/console-46c6d0d0303e04b9.js" + ], + "/su/docs": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/5622-0b01b71a2de3acf8.js", + "static/chunks/pages/su/docs-b48cfe163578ba42.js" + ], + "/su/docs/create-page": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/2452-ed265b549204d978.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/2378-3a97fbefe0f48bac.js", + "static/chunks/pages/su/docs/create-page-9be0d237216b00cd.js" + ], + "/su/docs/edit-page": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/2452-ed265b549204d978.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/2378-3a97fbefe0f48bac.js", + "static/chunks/pages/su/docs/edit-page-4892c3a874c645b3.js" + ], + "/su/docs/pages": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/5622-0b01b71a2de3acf8.js", + "static/chunks/pages/su/docs/pages-5eee4e47bc092505.js" + ], + "/su/docs/pages/[id]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/1179-5a248a7a76a74928.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/2452-ed265b549204d978.js", + "static/chunks/7901-841b99c96481dd31.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/2378-3a97fbefe0f48bac.js", + "static/chunks/pages/su/docs/pages/[id]-abedeaddb98ac372.js" + ], + "/su/envar": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/pages/su/envar-42f3065b06c71be8.js" + ], + "/su/error-logs": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/3695-c03f5685e1b79345.js", + "static/chunks/pages/su/error-logs-5c9265bc2ac8176f.js" + ], + "/su/login": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/su/login-522c70b6952cc65b.js" + ], + "/su/users": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/pages/su/users-464900047fbc0228.js" + ], + "/su/users/[single]": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/4185-b4c9a571bd713be6.js", + "static/chunks/8473-1a1faf3d4d34beef.js", + "static/chunks/3795-b7a314b891092ea4.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/pages/su/users/[single]-65b1051395f52052.js" + ], + "/su/users/new": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/5313-e7700a25826b1c4d.js", + "static/chunks/pages/su/users/new-6cf4001cfdd2ec66.js" + ], + "/terms": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/terms-da8c5b5b6b17b132.js" + ], + "/unsubscribe": [ + "static/chunks/webpack-309fbebe2073f18c.js", + "static/chunks/framework-4ed89e9640adfb9e.js", + "static/chunks/main-fd9fe2eccf11c307.js", + "static/chunks/pages/unsubscribe-b9517fbaaacff29b.js" + ] + }, + "ampFirstPages": [] +} \ No newline at end of file diff --git a/dsql-app/.local_dist/cache/config.json b/dsql-app/.local_dist/cache/config.json new file mode 100644 index 0000000..9d1b5d9 --- /dev/null +++ b/dsql-app/.local_dist/cache/config.json @@ -0,0 +1,7 @@ +{ + "telemetry": { + "notifiedAt": "1730731713743", + "anonymousId": "ea369d7f933d2d9fe75cda12feeac792a2b65ee0f3d9ef16d88da00403f387b5", + "salt": "79cdffc555380403b2af7e5f967075d9" + } +} \ No newline at end of file diff --git a/dsql-app/.local_dist/cache/next-server.js.nft.json b/dsql-app/.local_dist/cache/next-server.js.nft.json new file mode 100644 index 0000000..3d259be --- /dev/null +++ b/dsql-app/.local_dist/cache/next-server.js.nft.json @@ -0,0 +1 @@ +{"version":1,"cacheKey":"49b529bea4713512a09532b4f519b1a5ac659b73ea8218a762554b81c1daddea","files":["../node_modules/next/dist/server/next-server.js","../node_modules/next/package.json","../node_modules/next/dist/server/node-polyfill-fetch.js","../node_modules/next/dist/server/node-polyfill-web-streams.js","../node_modules/next/dist/server/request-meta.js","../node_modules/next/dist/server/server-route-utils.js","../node_modules/next/dist/server/serve-static.js","../node_modules/next/dist/server/render.js","../node_modules/next/dist/server/app-render.js","../node_modules/next/dist/server/base-server.js","../node_modules/next/dist/server/require.js","../node_modules/next/dist/server/load-components.js","../node_modules/next/dist/server/body-streams.js","../node_modules/next/dist/server/utils.js","../node_modules/next/dist/server/image-optimizer.js","../node_modules/next/dist/server/lib/recursive-readdir-sync.js","../node_modules/next/dist/server/base-http/node.js","../node_modules/next/dist/server/api-utils/node.js","../node_modules/next/dist/lib/is-error.js","../node_modules/next/dist/server/web/utils.js","../node_modules/next/dist/shared/lib/utils.js","../node_modules/next/dist/shared/lib/constants.js","../node_modules/next/dist/shared/lib/router/utils/path-match.js","../node_modules/next/dist/shared/lib/router/utils/get-route-from-asset-path.js","../node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js","../node_modules/next/dist/shared/lib/router/utils/parse-url.js","../node_modules/next/dist/build/output/log.js","../node_modules/next/dist/build/webpack/require-hook.js","../node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js","../node_modules/next/dist/shared/lib/page-path/normalize-page-path.js","../node_modules/next/dist/shared/lib/router/utils/relativize-url.js","../node_modules/next/dist/shared/lib/router/utils/prepare-destination.js","../node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js","../node_modules/next/dist/shared/lib/router/utils/route-matcher.js","../node_modules/next/dist/shared/lib/router/utils/middleware-route-matcher.js","../node_modules/next/dist/shared/lib/router/utils/querystring.js","../node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js","../node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js","../node_modules/next/dist/build/webpack/loaders/next-serverless-loader/utils.js","../node_modules/next/dist/shared/lib/router/utils/route-regex.js","../node_modules/next/dist/shared/lib/router/utils/app-paths.js","../node_modules/next/dist/server/send-payload/index.js","../node_modules/next/dist/server/api-utils/index.js","../node_modules/next/dist/server/response-cache/index.js","../node_modules/next/dist/server/web/sandbox/index.js","../node_modules/next/dist/server/lib/incremental-cache/index.js","../node_modules/next/dist/shared/lib/router/utils/index.js","../node_modules/next/dist/lib/redirect-status.js","../node_modules/next/dist/lib/constants.js","../node_modules/next/dist/lib/is-serializable-props.js","../node_modules/next/dist/shared/lib/amp-mode.js","../node_modules/next/dist/shared/lib/amp-context.js","../node_modules/next/dist/shared/lib/head.js","../node_modules/next/dist/shared/lib/head-manager-context.js","../node_modules/next/dist/shared/lib/loadable.js","../node_modules/next/dist/shared/lib/loadable-context.js","../node_modules/next/dist/shared/lib/router-context.js","../node_modules/next/dist/shared/lib/router/utils/is-dynamic.js","../node_modules/next/dist/shared/lib/html-context.js","../node_modules/next/dist/server/render-result.js","../node_modules/next/dist/server/node-web-streams-helper.js","../node_modules/next/dist/shared/lib/image-config-context.js","../node_modules/next/dist/server/internal-utils.js","../node_modules/next/dist/server/post-process.js","../node_modules/next/dist/server/htmlescape.js","../node_modules/next/dist/shared/lib/flush-effects.js","../node_modules/next/dist/lib/interop-default.js","../node_modules/next/dist/server/lib/mock-request.js","../node_modules/next/dist/shared/lib/match-remote-pattern.js","../node_modules/next/dist/shared/lib/image-blur-svg.js","../node_modules/next/dist/shared/lib/is-plain-object.js","../node_modules/next/dist/server/lib/squoosh/main.js","../node_modules/next/dist/server/base-http/index.js","../node_modules/next/dist/server/crypto-utils.js","../node_modules/next/dist/server/lib/etag.js","../node_modules/next/dist/client/components/match-segments.js","../node_modules/next/dist/client/components/hooks-server-context.js","../node_modules/next/dist/client/components/hooks-server.js","../node_modules/next/dist/lib/chalk.js","../node_modules/next/dist/shared/lib/runtime-config.js","../node_modules/next/dist/server/router.js","../node_modules/next/dist/server/send-payload/revalidate-headers.js","../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../node_modules/next/dist/shared/lib/router/utils/escape-path-delimiters.js","../node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js","../node_modules/next/dist/shared/lib/i18n/get-locale-redirect.js","../node_modules/next/dist/shared/lib/get-hostname.js","../node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js","../node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js","../node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js","../node_modules/next/dist/shared/lib/escape-regexp.js","../node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js","../node_modules/next/dist/server/accept-header.js","../node_modules/next/dist/shared/lib/i18n/detect-locale-cookie.js","../node_modules/next/dist/server/response-cache/types.js","../node_modules/next/dist/server/web/sandbox/sandbox.js","../node_modules/next/dist/server/web/sandbox/context.js","../node_modules/next/dist/server/lib/incremental-cache/file-system-cache.js","../node_modules/next/dist/lib/non-nullable.js","../node_modules/next/dist/server/optimize-amp.js","../node_modules/next/dist/server/font-utils.js","../node_modules/next/dist/shared/lib/isomorphic/path.js","../node_modules/next/dist/shared/lib/router/utils/sorted-routes.js","../node_modules/next/dist/shared/lib/side-effect.js","../node_modules/next/dist/shared/lib/image-config.js","../node_modules/next/dist/compiled/react-server-dom-webpack/writer.browser.server.js","../node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js","../node_modules/next/dist/compiled/react-server-dom-webpack/package.json","../node_modules/next/dist/lib/web/chalk.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/streams.js","../node_modules/next/dist/shared/lib/router/utils/format-url.js","../node_modules/styled-jsx/style.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/package.json","../node_modules/next/dist/compiled/@next/react-dev-overlay/dist/middleware.js","../node_modules/next/dist/server/google-font-metrics.json","../node_modules/styled-jsx/package.json","../node_modules/next/dist/shared/lib/router/utils/parse-path.js","../node_modules/react-dom/package.json","../node_modules/react-dom/server.browser.js","../node_modules/next/dist/compiled/react-server-dom-webpack/index.js","../node_modules/next/dist/compiled/node-fetch/package.json","../node_modules/next/dist/compiled/node-fetch/index.js","../node_modules/next/dist/compiled/compression/package.json","../node_modules/next/dist/compiled/compression/index.js","../node_modules/next/dist/compiled/http-proxy/package.json","../node_modules/next/dist/compiled/http-proxy/index.js","../node_modules/next/dist/compiled/send/package.json","../node_modules/next/dist/compiled/send/index.js","../node_modules/react/package.json","../node_modules/react/index.js","../node_modules/next/dist/compiled/strip-ansi/package.json","../node_modules/next/dist/compiled/strip-ansi/index.js","../node_modules/react-dom/server.node.js","../node_modules/next/dist/compiled/@next/react-dev-overlay/package.json","../node_modules/next/dist/compiled/react-is/package.json","../node_modules/next/dist/compiled/react-is/index.js","../node_modules/react-dom/server.js","../node_modules/@next/env/package.json","../node_modules/@next/env/dist/index.js","../node_modules/next/dist/compiled/get-orientation/package.json","../node_modules/next/dist/compiled/get-orientation/index.js","../node_modules/next/dist/compiled/image-size/package.json","../node_modules/next/dist/compiled/image-size/index.js","../node_modules/next/dist/compiled/is-animated/package.json","../node_modules/next/dist/compiled/is-animated/index.js","../node_modules/next/dist/compiled/content-disposition/package.json","../node_modules/next/dist/compiled/content-disposition/index.js","../node_modules/next/dist/compiled/chalk/package.json","../node_modules/next/dist/compiled/chalk/index.js","../node_modules/next/dist/lib/pick.js","../node_modules/next/dist/server/web/sandbox/fetch-inline-assets.js","../node_modules/styled-jsx/index.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-writer.browser.production.min.server.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-writer.browser.development.server.js","../node_modules/next/dist/compiled/@hapi/accept/package.json","../node_modules/next/dist/compiled/@hapi/accept/index.js","../node_modules/sharp/package.json","../node_modules/sharp/lib/index.js","../node_modules/next/dist/compiled/bytes/package.json","../node_modules/next/dist/compiled/bytes/index.js","../node_modules/next/dist/compiled/jsonwebtoken/package.json","../node_modules/next/dist/compiled/jsonwebtoken/index.js","../node_modules/next/dist/compiled/content-type/package.json","../node_modules/next/dist/compiled/content-type/index.js","../node_modules/next/dist/compiled/raw-body/package.json","../node_modules/next/dist/compiled/raw-body/index.js","../node_modules/next/dist/compiled/cookie/package.json","../node_modules/next/dist/compiled/cookie/index.js","../node_modules/@swc/helpers/lib/_async_to_generator.js","../node_modules/@swc/helpers/lib/_extends.js","../node_modules/@swc/helpers/lib/_interop_require_default.js","../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack.production.min.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack.development.js","../node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js","../node_modules/next/dist/shared/lib/router/utils/add-locale.js","../node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js","../node_modules/react-dom/cjs/react-dom-server-legacy.browser.production.min.js","../node_modules/react-dom/cjs/react-dom-server.browser.production.min.js","../node_modules/react-dom/cjs/react-dom-server.browser.development.js","../node_modules/react-dom/cjs/react-dom-server-legacy.browser.development.js","../node_modules/react-dom/cjs/react-dom-server.node.production.min.js","../node_modules/react-dom/cjs/react-dom-server-legacy.node.production.min.js","../node_modules/react-dom/cjs/react-dom-server-legacy.node.development.js","../node_modules/react-dom/cjs/react-dom-server.node.development.js","../node_modules/@swc/helpers/package.json","../node_modules/next/dist/compiled/path-to-regexp/index.js","../node_modules/next/dist/compiled/fresh/package.json","../node_modules/next/dist/compiled/fresh/index.js","../node_modules/react/cjs/react.production.min.js","../node_modules/react/cjs/react.development.js","../node_modules/next/dist/compiled/react-is/cjs/react-is.production.min.js","../node_modules/next/dist/compiled/react-is/cjs/react-is.development.js","../node_modules/next/dist/compiled/node-html-parser/package.json","../node_modules/next/dist/compiled/node-html-parser/index.js","../node_modules/sharp/lib/constructor.js","../node_modules/sharp/lib/input.js","../node_modules/sharp/lib/resize.js","../node_modules/sharp/lib/composite.js","../node_modules/sharp/lib/operation.js","../node_modules/sharp/lib/channel.js","../node_modules/sharp/lib/colour.js","../node_modules/sharp/lib/utility.js","../node_modules/sharp/lib/output.js","../node_modules/next/dist/compiled/micromatch/package.json","../node_modules/next/dist/compiled/micromatch/index.js","../node_modules/styled-jsx/dist/index/index.js","../node_modules/use-sync-external-store/shim/index.js","../node_modules/next/dist/compiled/jest-worker/package.json","../node_modules/next/dist/compiled/jest-worker/index.js","../node_modules/use-sync-external-store/package.json","../node_modules/sharp/lib/is.js","../node_modules/sharp/lib/sharp.js","../node_modules/sharp/lib/libvips.js","../node_modules/next/dist/compiled/edge-runtime/package.json","../node_modules/next/dist/compiled/edge-runtime/index.js","../node_modules/next/dist/compiled/lru-cache/package.json","../node_modules/next/dist/compiled/lru-cache/index.js","../node_modules/next/dist/compiled/path-browserify/package.json","../node_modules/next/dist/compiled/path-browserify/index.js","../node_modules/next/dist/compiled/debug/package.json","../node_modules/next/dist/compiled/debug/index.js","../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js","../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js","../node_modules/next/dist/compiled/semver/package.json","../node_modules/next/dist/compiled/semver/index.js","../node_modules/sharp/node_modules/semver/functions/coerce.js","../node_modules/sharp/node_modules/semver/functions/gte.js","../node_modules/sharp/node_modules/semver/functions/satisfies.js","../node_modules/sharp/node_modules/semver/package.json","../node_modules/color/index.js","../node_modules/detect-libc/package.json","../node_modules/detect-libc/lib/detect-libc.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/console.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/encoding.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/abort-controller.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/fetch.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/blob.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/cache.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/crypto.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/events.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/url.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/structured-clone.js","../node_modules/color/package.json","../node_modules/sharp/node_modules/semver/functions/compare.js","../node_modules/sharp/node_modules/semver/functions/parse.js","../node_modules/sharp/node_modules/semver/classes/semver.js","../node_modules/sharp/node_modules/semver/internal/re.js","../node_modules/sharp/node_modules/semver/classes/range.js","../node_modules/detect-libc/lib/process.js","../node_modules/detect-libc/lib/filesystem.js","../node_modules/sharp/node_modules/semver/internal/debug.js","../node_modules/sharp/node_modules/semver/internal/constants.js","../node_modules/sharp/node_modules/semver/internal/parse-options.js","../node_modules/sharp/node_modules/semver/internal/identifiers.js","../node_modules/sharp/node_modules/semver/classes/comparator.js","../node_modules/color/node_modules/color-convert/index.js","../node_modules/color/node_modules/color-convert/package.json","../node_modules/sharp/node_modules/semver/functions/cmp.js","../node_modules/color-string/index.js","../node_modules/color/node_modules/color-convert/route.js","../node_modules/color/node_modules/color-convert/conversions.js","../node_modules/color-string/package.json","../node_modules/sharp/node_modules/semver/functions/eq.js","../node_modules/sharp/node_modules/semver/functions/neq.js","../node_modules/sharp/node_modules/semver/functions/gt.js","../node_modules/sharp/node_modules/semver/functions/lt.js","../node_modules/sharp/node_modules/semver/functions/lte.js","../node_modules/lru-cache/package.json","../node_modules/lru-cache/index.js","../node_modules/color/node_modules/color-name/package.json","../node_modules/color/node_modules/color-name/index.js","../node_modules/color-name/package.json","../node_modules/color-name/index.js","../node_modules/simple-swizzle/index.js","../node_modules/simple-swizzle/package.json","../node_modules/yallist/package.json","../node_modules/yallist/yallist.js","../node_modules/yallist/iterator.js","../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../node_modules/simple-swizzle/node_modules/is-arrayish/package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/cache/webpack/client-development-fallback/0.pack b/dsql-app/.local_dist/cache/webpack/client-development-fallback/0.pack new file mode 100644 index 0000000..2c59ad5 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development-fallback/0.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development-fallback/index.pack b/dsql-app/.local_dist/cache/webpack/client-development-fallback/index.pack new file mode 100644 index 0000000..a94f5dd Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development-fallback/index.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/0.pack b/dsql-app/.local_dist/cache/webpack/client-development/0.pack new file mode 100644 index 0000000..fa4c57d Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/0.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/1.pack b/dsql-app/.local_dist/cache/webpack/client-development/1.pack new file mode 100644 index 0000000..232f205 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/1.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/10.pack b/dsql-app/.local_dist/cache/webpack/client-development/10.pack new file mode 100644 index 0000000..45daf51 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/10.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/11.pack b/dsql-app/.local_dist/cache/webpack/client-development/11.pack new file mode 100644 index 0000000..f85ddab Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/11.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/12.pack b/dsql-app/.local_dist/cache/webpack/client-development/12.pack new file mode 100644 index 0000000..7b13cc5 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/12.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/13.pack b/dsql-app/.local_dist/cache/webpack/client-development/13.pack new file mode 100644 index 0000000..14b5853 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/13.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/14.pack b/dsql-app/.local_dist/cache/webpack/client-development/14.pack new file mode 100644 index 0000000..ead7da1 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/14.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/15.pack b/dsql-app/.local_dist/cache/webpack/client-development/15.pack new file mode 100644 index 0000000..2508a23 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/15.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/16.pack b/dsql-app/.local_dist/cache/webpack/client-development/16.pack new file mode 100644 index 0000000..d733f2d Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/16.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/17.pack b/dsql-app/.local_dist/cache/webpack/client-development/17.pack new file mode 100644 index 0000000..ea6cb91 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/17.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/18.pack b/dsql-app/.local_dist/cache/webpack/client-development/18.pack new file mode 100644 index 0000000..b82b11a Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/18.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/19.pack b/dsql-app/.local_dist/cache/webpack/client-development/19.pack new file mode 100644 index 0000000..4558070 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/19.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/2.pack b/dsql-app/.local_dist/cache/webpack/client-development/2.pack new file mode 100644 index 0000000..398fa2d Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/2.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/20.pack b/dsql-app/.local_dist/cache/webpack/client-development/20.pack new file mode 100644 index 0000000..547816e Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/20.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/21.pack b/dsql-app/.local_dist/cache/webpack/client-development/21.pack new file mode 100644 index 0000000..d8fd6e2 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/21.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/3.pack b/dsql-app/.local_dist/cache/webpack/client-development/3.pack new file mode 100644 index 0000000..2554473 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/3.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/4.pack b/dsql-app/.local_dist/cache/webpack/client-development/4.pack new file mode 100644 index 0000000..999c2c4 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/4.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/5.pack b/dsql-app/.local_dist/cache/webpack/client-development/5.pack new file mode 100644 index 0000000..11f45cf Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/5.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/6.pack b/dsql-app/.local_dist/cache/webpack/client-development/6.pack new file mode 100644 index 0000000..e4fb17c Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/6.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/7.pack b/dsql-app/.local_dist/cache/webpack/client-development/7.pack new file mode 100644 index 0000000..2ff1a59 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/7.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/8.pack b/dsql-app/.local_dist/cache/webpack/client-development/8.pack new file mode 100644 index 0000000..3a6f8a3 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/8.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/9.pack b/dsql-app/.local_dist/cache/webpack/client-development/9.pack new file mode 100644 index 0000000..611d7a9 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/9.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/index.pack b/dsql-app/.local_dist/cache/webpack/client-development/index.pack new file mode 100644 index 0000000..90f7008 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/index.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-development/index.pack.old b/dsql-app/.local_dist/cache/webpack/client-development/index.pack.old new file mode 100644 index 0000000..64c8ddb Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-development/index.pack.old differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/0.pack b/dsql-app/.local_dist/cache/webpack/client-production/0.pack new file mode 100644 index 0000000..975574c Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/0.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/1.pack b/dsql-app/.local_dist/cache/webpack/client-production/1.pack new file mode 100644 index 0000000..f6a2242 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/1.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/2.pack b/dsql-app/.local_dist/cache/webpack/client-production/2.pack new file mode 100644 index 0000000..e551cdd Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/2.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/3.pack b/dsql-app/.local_dist/cache/webpack/client-production/3.pack new file mode 100644 index 0000000..457d295 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/3.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/4.pack b/dsql-app/.local_dist/cache/webpack/client-production/4.pack new file mode 100644 index 0000000..3b61f5b Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/4.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/5.pack b/dsql-app/.local_dist/cache/webpack/client-production/5.pack new file mode 100644 index 0000000..0eb8546 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/5.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/6.pack b/dsql-app/.local_dist/cache/webpack/client-production/6.pack new file mode 100644 index 0000000..c464ea9 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/6.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/7.pack b/dsql-app/.local_dist/cache/webpack/client-production/7.pack new file mode 100644 index 0000000..a78ff2f Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/7.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/index.pack b/dsql-app/.local_dist/cache/webpack/client-production/index.pack new file mode 100644 index 0000000..85b38a4 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/index.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/client-production/index.pack.old b/dsql-app/.local_dist/cache/webpack/client-production/index.pack.old new file mode 100644 index 0000000..0c485da Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/client-production/index.pack.old differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/0.pack b/dsql-app/.local_dist/cache/webpack/server-development/0.pack new file mode 100644 index 0000000..3786be9 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/0.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/1.pack b/dsql-app/.local_dist/cache/webpack/server-development/1.pack new file mode 100644 index 0000000..f46a7de Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/1.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/10.pack b/dsql-app/.local_dist/cache/webpack/server-development/10.pack new file mode 100644 index 0000000..e5ff827 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/10.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/11.pack b/dsql-app/.local_dist/cache/webpack/server-development/11.pack new file mode 100644 index 0000000..3eb1d57 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/11.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/12.pack b/dsql-app/.local_dist/cache/webpack/server-development/12.pack new file mode 100644 index 0000000..e332e96 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/12.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/13.pack b/dsql-app/.local_dist/cache/webpack/server-development/13.pack new file mode 100644 index 0000000..48e8754 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/13.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/14.pack b/dsql-app/.local_dist/cache/webpack/server-development/14.pack new file mode 100644 index 0000000..7081a11 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/14.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/15.pack b/dsql-app/.local_dist/cache/webpack/server-development/15.pack new file mode 100644 index 0000000..2de7e2c Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/15.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/16.pack b/dsql-app/.local_dist/cache/webpack/server-development/16.pack new file mode 100644 index 0000000..dad47c0 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/16.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/17.pack b/dsql-app/.local_dist/cache/webpack/server-development/17.pack new file mode 100644 index 0000000..d9ad82f Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/17.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/18.pack b/dsql-app/.local_dist/cache/webpack/server-development/18.pack new file mode 100644 index 0000000..64794e9 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/18.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/19.pack b/dsql-app/.local_dist/cache/webpack/server-development/19.pack new file mode 100644 index 0000000..bfa1bf0 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/19.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/2.pack b/dsql-app/.local_dist/cache/webpack/server-development/2.pack new file mode 100644 index 0000000..7333336 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/2.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/20.pack b/dsql-app/.local_dist/cache/webpack/server-development/20.pack new file mode 100644 index 0000000..8cc2af0 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/20.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/21.pack b/dsql-app/.local_dist/cache/webpack/server-development/21.pack new file mode 100644 index 0000000..414c97c Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/21.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/22.pack b/dsql-app/.local_dist/cache/webpack/server-development/22.pack new file mode 100644 index 0000000..7e02b4c Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/22.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/23.pack b/dsql-app/.local_dist/cache/webpack/server-development/23.pack new file mode 100644 index 0000000..5917539 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/23.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/24.pack b/dsql-app/.local_dist/cache/webpack/server-development/24.pack new file mode 100644 index 0000000..332f836 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/24.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/25.pack b/dsql-app/.local_dist/cache/webpack/server-development/25.pack new file mode 100644 index 0000000..0095eb2 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/25.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/26.pack b/dsql-app/.local_dist/cache/webpack/server-development/26.pack new file mode 100644 index 0000000..12c6535 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/26.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/27.pack b/dsql-app/.local_dist/cache/webpack/server-development/27.pack new file mode 100644 index 0000000..c8e2ead Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/27.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/3.pack b/dsql-app/.local_dist/cache/webpack/server-development/3.pack new file mode 100644 index 0000000..742cf69 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/3.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/4.pack b/dsql-app/.local_dist/cache/webpack/server-development/4.pack new file mode 100644 index 0000000..6909a27 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/4.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/5.pack b/dsql-app/.local_dist/cache/webpack/server-development/5.pack new file mode 100644 index 0000000..97d1379 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/5.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/6.pack b/dsql-app/.local_dist/cache/webpack/server-development/6.pack new file mode 100644 index 0000000..a55df1d Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/6.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/7.pack b/dsql-app/.local_dist/cache/webpack/server-development/7.pack new file mode 100644 index 0000000..dbfd899 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/7.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/8.pack b/dsql-app/.local_dist/cache/webpack/server-development/8.pack new file mode 100644 index 0000000..99a4253 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/8.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/9.pack b/dsql-app/.local_dist/cache/webpack/server-development/9.pack new file mode 100644 index 0000000..26a4cc0 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/9.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/index.pack b/dsql-app/.local_dist/cache/webpack/server-development/index.pack new file mode 100644 index 0000000..3474c40 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/index.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-development/index.pack.old b/dsql-app/.local_dist/cache/webpack/server-development/index.pack.old new file mode 100644 index 0000000..f32588d Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-development/index.pack.old differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/0.pack b/dsql-app/.local_dist/cache/webpack/server-production/0.pack new file mode 100644 index 0000000..a0ee400 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/0.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/1.pack b/dsql-app/.local_dist/cache/webpack/server-production/1.pack new file mode 100644 index 0000000..ef5a5ad Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/1.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/2.pack b/dsql-app/.local_dist/cache/webpack/server-production/2.pack new file mode 100644 index 0000000..e8dde16 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/2.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/3.pack b/dsql-app/.local_dist/cache/webpack/server-production/3.pack new file mode 100644 index 0000000..fed3313 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/3.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/4.pack b/dsql-app/.local_dist/cache/webpack/server-production/4.pack new file mode 100644 index 0000000..224de56 Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/4.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/5.pack b/dsql-app/.local_dist/cache/webpack/server-production/5.pack new file mode 100644 index 0000000..b2d789a Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/5.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/6.pack b/dsql-app/.local_dist/cache/webpack/server-production/6.pack new file mode 100644 index 0000000..fbcb8ad Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/6.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/7.pack b/dsql-app/.local_dist/cache/webpack/server-production/7.pack new file mode 100644 index 0000000..030216f Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/7.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/index.pack b/dsql-app/.local_dist/cache/webpack/server-production/index.pack new file mode 100644 index 0000000..dafecfb Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/index.pack differ diff --git a/dsql-app/.local_dist/cache/webpack/server-production/index.pack.old b/dsql-app/.local_dist/cache/webpack/server-production/index.pack.old new file mode 100644 index 0000000..2b1f56b Binary files /dev/null and b/dsql-app/.local_dist/cache/webpack/server-production/index.pack.old differ diff --git a/dsql-app/.local_dist/export-marker.json b/dsql-app/.local_dist/export-marker.json new file mode 100644 index 0000000..07328d6 --- /dev/null +++ b/dsql-app/.local_dist/export-marker.json @@ -0,0 +1 @@ +{"version":1,"hasExportPathMap":false,"exportTrailingSlash":false,"isNextImageImported":false} \ No newline at end of file diff --git a/dsql-app/.local_dist/images-manifest.json b/dsql-app/.local_dist/images-manifest.json new file mode 100644 index 0000000..a611415 --- /dev/null +++ b/dsql-app/.local_dist/images-manifest.json @@ -0,0 +1 @@ +{"version":1,"images":{"deviceSizes":[640,750,828,1080,1200,1920,2048,3840],"imageSizes":[16,32,48,64,96,128,256,384],"path":"/_next/image","loader":"default","domains":[],"disableStaticImages":false,"minimumCacheTTL":60,"formats":["image/webp"],"dangerouslyAllowSVG":false,"contentSecurityPolicy":"script-src 'none'; frame-src 'none'; sandbox;","remotePatterns":[],"unoptimized":false,"sizes":[640,750,828,1080,1200,1920,2048,3840,16,32,48,64,96,128,256,384]}} \ No newline at end of file diff --git a/dsql-app/.local_dist/next-server.js.nft.json b/dsql-app/.local_dist/next-server.js.nft.json new file mode 100644 index 0000000..3d259be --- /dev/null +++ b/dsql-app/.local_dist/next-server.js.nft.json @@ -0,0 +1 @@ +{"version":1,"cacheKey":"49b529bea4713512a09532b4f519b1a5ac659b73ea8218a762554b81c1daddea","files":["../node_modules/next/dist/server/next-server.js","../node_modules/next/package.json","../node_modules/next/dist/server/node-polyfill-fetch.js","../node_modules/next/dist/server/node-polyfill-web-streams.js","../node_modules/next/dist/server/request-meta.js","../node_modules/next/dist/server/server-route-utils.js","../node_modules/next/dist/server/serve-static.js","../node_modules/next/dist/server/render.js","../node_modules/next/dist/server/app-render.js","../node_modules/next/dist/server/base-server.js","../node_modules/next/dist/server/require.js","../node_modules/next/dist/server/load-components.js","../node_modules/next/dist/server/body-streams.js","../node_modules/next/dist/server/utils.js","../node_modules/next/dist/server/image-optimizer.js","../node_modules/next/dist/server/lib/recursive-readdir-sync.js","../node_modules/next/dist/server/base-http/node.js","../node_modules/next/dist/server/api-utils/node.js","../node_modules/next/dist/lib/is-error.js","../node_modules/next/dist/server/web/utils.js","../node_modules/next/dist/shared/lib/utils.js","../node_modules/next/dist/shared/lib/constants.js","../node_modules/next/dist/shared/lib/router/utils/path-match.js","../node_modules/next/dist/shared/lib/router/utils/get-route-from-asset-path.js","../node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js","../node_modules/next/dist/shared/lib/router/utils/parse-url.js","../node_modules/next/dist/build/output/log.js","../node_modules/next/dist/build/webpack/require-hook.js","../node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js","../node_modules/next/dist/shared/lib/page-path/normalize-page-path.js","../node_modules/next/dist/shared/lib/router/utils/relativize-url.js","../node_modules/next/dist/shared/lib/router/utils/prepare-destination.js","../node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js","../node_modules/next/dist/shared/lib/router/utils/route-matcher.js","../node_modules/next/dist/shared/lib/router/utils/middleware-route-matcher.js","../node_modules/next/dist/shared/lib/router/utils/querystring.js","../node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js","../node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js","../node_modules/next/dist/build/webpack/loaders/next-serverless-loader/utils.js","../node_modules/next/dist/shared/lib/router/utils/route-regex.js","../node_modules/next/dist/shared/lib/router/utils/app-paths.js","../node_modules/next/dist/server/send-payload/index.js","../node_modules/next/dist/server/api-utils/index.js","../node_modules/next/dist/server/response-cache/index.js","../node_modules/next/dist/server/web/sandbox/index.js","../node_modules/next/dist/server/lib/incremental-cache/index.js","../node_modules/next/dist/shared/lib/router/utils/index.js","../node_modules/next/dist/lib/redirect-status.js","../node_modules/next/dist/lib/constants.js","../node_modules/next/dist/lib/is-serializable-props.js","../node_modules/next/dist/shared/lib/amp-mode.js","../node_modules/next/dist/shared/lib/amp-context.js","../node_modules/next/dist/shared/lib/head.js","../node_modules/next/dist/shared/lib/head-manager-context.js","../node_modules/next/dist/shared/lib/loadable.js","../node_modules/next/dist/shared/lib/loadable-context.js","../node_modules/next/dist/shared/lib/router-context.js","../node_modules/next/dist/shared/lib/router/utils/is-dynamic.js","../node_modules/next/dist/shared/lib/html-context.js","../node_modules/next/dist/server/render-result.js","../node_modules/next/dist/server/node-web-streams-helper.js","../node_modules/next/dist/shared/lib/image-config-context.js","../node_modules/next/dist/server/internal-utils.js","../node_modules/next/dist/server/post-process.js","../node_modules/next/dist/server/htmlescape.js","../node_modules/next/dist/shared/lib/flush-effects.js","../node_modules/next/dist/lib/interop-default.js","../node_modules/next/dist/server/lib/mock-request.js","../node_modules/next/dist/shared/lib/match-remote-pattern.js","../node_modules/next/dist/shared/lib/image-blur-svg.js","../node_modules/next/dist/shared/lib/is-plain-object.js","../node_modules/next/dist/server/lib/squoosh/main.js","../node_modules/next/dist/server/base-http/index.js","../node_modules/next/dist/server/crypto-utils.js","../node_modules/next/dist/server/lib/etag.js","../node_modules/next/dist/client/components/match-segments.js","../node_modules/next/dist/client/components/hooks-server-context.js","../node_modules/next/dist/client/components/hooks-server.js","../node_modules/next/dist/lib/chalk.js","../node_modules/next/dist/shared/lib/runtime-config.js","../node_modules/next/dist/server/router.js","../node_modules/next/dist/server/send-payload/revalidate-headers.js","../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../node_modules/next/dist/shared/lib/router/utils/escape-path-delimiters.js","../node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js","../node_modules/next/dist/shared/lib/i18n/get-locale-redirect.js","../node_modules/next/dist/shared/lib/get-hostname.js","../node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js","../node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js","../node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js","../node_modules/next/dist/shared/lib/escape-regexp.js","../node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js","../node_modules/next/dist/server/accept-header.js","../node_modules/next/dist/shared/lib/i18n/detect-locale-cookie.js","../node_modules/next/dist/server/response-cache/types.js","../node_modules/next/dist/server/web/sandbox/sandbox.js","../node_modules/next/dist/server/web/sandbox/context.js","../node_modules/next/dist/server/lib/incremental-cache/file-system-cache.js","../node_modules/next/dist/lib/non-nullable.js","../node_modules/next/dist/server/optimize-amp.js","../node_modules/next/dist/server/font-utils.js","../node_modules/next/dist/shared/lib/isomorphic/path.js","../node_modules/next/dist/shared/lib/router/utils/sorted-routes.js","../node_modules/next/dist/shared/lib/side-effect.js","../node_modules/next/dist/shared/lib/image-config.js","../node_modules/next/dist/compiled/react-server-dom-webpack/writer.browser.server.js","../node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js","../node_modules/next/dist/compiled/react-server-dom-webpack/package.json","../node_modules/next/dist/lib/web/chalk.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/streams.js","../node_modules/next/dist/shared/lib/router/utils/format-url.js","../node_modules/styled-jsx/style.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/package.json","../node_modules/next/dist/compiled/@next/react-dev-overlay/dist/middleware.js","../node_modules/next/dist/server/google-font-metrics.json","../node_modules/styled-jsx/package.json","../node_modules/next/dist/shared/lib/router/utils/parse-path.js","../node_modules/react-dom/package.json","../node_modules/react-dom/server.browser.js","../node_modules/next/dist/compiled/react-server-dom-webpack/index.js","../node_modules/next/dist/compiled/node-fetch/package.json","../node_modules/next/dist/compiled/node-fetch/index.js","../node_modules/next/dist/compiled/compression/package.json","../node_modules/next/dist/compiled/compression/index.js","../node_modules/next/dist/compiled/http-proxy/package.json","../node_modules/next/dist/compiled/http-proxy/index.js","../node_modules/next/dist/compiled/send/package.json","../node_modules/next/dist/compiled/send/index.js","../node_modules/react/package.json","../node_modules/react/index.js","../node_modules/next/dist/compiled/strip-ansi/package.json","../node_modules/next/dist/compiled/strip-ansi/index.js","../node_modules/react-dom/server.node.js","../node_modules/next/dist/compiled/@next/react-dev-overlay/package.json","../node_modules/next/dist/compiled/react-is/package.json","../node_modules/next/dist/compiled/react-is/index.js","../node_modules/react-dom/server.js","../node_modules/@next/env/package.json","../node_modules/@next/env/dist/index.js","../node_modules/next/dist/compiled/get-orientation/package.json","../node_modules/next/dist/compiled/get-orientation/index.js","../node_modules/next/dist/compiled/image-size/package.json","../node_modules/next/dist/compiled/image-size/index.js","../node_modules/next/dist/compiled/is-animated/package.json","../node_modules/next/dist/compiled/is-animated/index.js","../node_modules/next/dist/compiled/content-disposition/package.json","../node_modules/next/dist/compiled/content-disposition/index.js","../node_modules/next/dist/compiled/chalk/package.json","../node_modules/next/dist/compiled/chalk/index.js","../node_modules/next/dist/lib/pick.js","../node_modules/next/dist/server/web/sandbox/fetch-inline-assets.js","../node_modules/styled-jsx/index.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-writer.browser.production.min.server.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-writer.browser.development.server.js","../node_modules/next/dist/compiled/@hapi/accept/package.json","../node_modules/next/dist/compiled/@hapi/accept/index.js","../node_modules/sharp/package.json","../node_modules/sharp/lib/index.js","../node_modules/next/dist/compiled/bytes/package.json","../node_modules/next/dist/compiled/bytes/index.js","../node_modules/next/dist/compiled/jsonwebtoken/package.json","../node_modules/next/dist/compiled/jsonwebtoken/index.js","../node_modules/next/dist/compiled/content-type/package.json","../node_modules/next/dist/compiled/content-type/index.js","../node_modules/next/dist/compiled/raw-body/package.json","../node_modules/next/dist/compiled/raw-body/index.js","../node_modules/next/dist/compiled/cookie/package.json","../node_modules/next/dist/compiled/cookie/index.js","../node_modules/@swc/helpers/lib/_async_to_generator.js","../node_modules/@swc/helpers/lib/_extends.js","../node_modules/@swc/helpers/lib/_interop_require_default.js","../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack.production.min.js","../node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack.development.js","../node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js","../node_modules/next/dist/shared/lib/router/utils/add-locale.js","../node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js","../node_modules/react-dom/cjs/react-dom-server-legacy.browser.production.min.js","../node_modules/react-dom/cjs/react-dom-server.browser.production.min.js","../node_modules/react-dom/cjs/react-dom-server.browser.development.js","../node_modules/react-dom/cjs/react-dom-server-legacy.browser.development.js","../node_modules/react-dom/cjs/react-dom-server.node.production.min.js","../node_modules/react-dom/cjs/react-dom-server-legacy.node.production.min.js","../node_modules/react-dom/cjs/react-dom-server-legacy.node.development.js","../node_modules/react-dom/cjs/react-dom-server.node.development.js","../node_modules/@swc/helpers/package.json","../node_modules/next/dist/compiled/path-to-regexp/index.js","../node_modules/next/dist/compiled/fresh/package.json","../node_modules/next/dist/compiled/fresh/index.js","../node_modules/react/cjs/react.production.min.js","../node_modules/react/cjs/react.development.js","../node_modules/next/dist/compiled/react-is/cjs/react-is.production.min.js","../node_modules/next/dist/compiled/react-is/cjs/react-is.development.js","../node_modules/next/dist/compiled/node-html-parser/package.json","../node_modules/next/dist/compiled/node-html-parser/index.js","../node_modules/sharp/lib/constructor.js","../node_modules/sharp/lib/input.js","../node_modules/sharp/lib/resize.js","../node_modules/sharp/lib/composite.js","../node_modules/sharp/lib/operation.js","../node_modules/sharp/lib/channel.js","../node_modules/sharp/lib/colour.js","../node_modules/sharp/lib/utility.js","../node_modules/sharp/lib/output.js","../node_modules/next/dist/compiled/micromatch/package.json","../node_modules/next/dist/compiled/micromatch/index.js","../node_modules/styled-jsx/dist/index/index.js","../node_modules/use-sync-external-store/shim/index.js","../node_modules/next/dist/compiled/jest-worker/package.json","../node_modules/next/dist/compiled/jest-worker/index.js","../node_modules/use-sync-external-store/package.json","../node_modules/sharp/lib/is.js","../node_modules/sharp/lib/sharp.js","../node_modules/sharp/lib/libvips.js","../node_modules/next/dist/compiled/edge-runtime/package.json","../node_modules/next/dist/compiled/edge-runtime/index.js","../node_modules/next/dist/compiled/lru-cache/package.json","../node_modules/next/dist/compiled/lru-cache/index.js","../node_modules/next/dist/compiled/path-browserify/package.json","../node_modules/next/dist/compiled/path-browserify/index.js","../node_modules/next/dist/compiled/debug/package.json","../node_modules/next/dist/compiled/debug/index.js","../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.min.js","../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js","../node_modules/next/dist/compiled/semver/package.json","../node_modules/next/dist/compiled/semver/index.js","../node_modules/sharp/node_modules/semver/functions/coerce.js","../node_modules/sharp/node_modules/semver/functions/gte.js","../node_modules/sharp/node_modules/semver/functions/satisfies.js","../node_modules/sharp/node_modules/semver/package.json","../node_modules/color/index.js","../node_modules/detect-libc/package.json","../node_modules/detect-libc/lib/detect-libc.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/console.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/encoding.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/abort-controller.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/fetch.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/blob.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/cache.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/crypto.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/events.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/url.js","../node_modules/next/dist/compiled/@edge-runtime/primitives/structured-clone.js","../node_modules/color/package.json","../node_modules/sharp/node_modules/semver/functions/compare.js","../node_modules/sharp/node_modules/semver/functions/parse.js","../node_modules/sharp/node_modules/semver/classes/semver.js","../node_modules/sharp/node_modules/semver/internal/re.js","../node_modules/sharp/node_modules/semver/classes/range.js","../node_modules/detect-libc/lib/process.js","../node_modules/detect-libc/lib/filesystem.js","../node_modules/sharp/node_modules/semver/internal/debug.js","../node_modules/sharp/node_modules/semver/internal/constants.js","../node_modules/sharp/node_modules/semver/internal/parse-options.js","../node_modules/sharp/node_modules/semver/internal/identifiers.js","../node_modules/sharp/node_modules/semver/classes/comparator.js","../node_modules/color/node_modules/color-convert/index.js","../node_modules/color/node_modules/color-convert/package.json","../node_modules/sharp/node_modules/semver/functions/cmp.js","../node_modules/color-string/index.js","../node_modules/color/node_modules/color-convert/route.js","../node_modules/color/node_modules/color-convert/conversions.js","../node_modules/color-string/package.json","../node_modules/sharp/node_modules/semver/functions/eq.js","../node_modules/sharp/node_modules/semver/functions/neq.js","../node_modules/sharp/node_modules/semver/functions/gt.js","../node_modules/sharp/node_modules/semver/functions/lt.js","../node_modules/sharp/node_modules/semver/functions/lte.js","../node_modules/lru-cache/package.json","../node_modules/lru-cache/index.js","../node_modules/color/node_modules/color-name/package.json","../node_modules/color/node_modules/color-name/index.js","../node_modules/color-name/package.json","../node_modules/color-name/index.js","../node_modules/simple-swizzle/index.js","../node_modules/simple-swizzle/package.json","../node_modules/yallist/package.json","../node_modules/yallist/yallist.js","../node_modules/yallist/iterator.js","../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../node_modules/simple-swizzle/node_modules/is-arrayish/package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/package.json b/dsql-app/.local_dist/package.json new file mode 100644 index 0000000..7156107 --- /dev/null +++ b/dsql-app/.local_dist/package.json @@ -0,0 +1 @@ +{"type": "commonjs"} \ No newline at end of file diff --git a/dsql-app/.local_dist/prerender-manifest.json b/dsql-app/.local_dist/prerender-manifest.json new file mode 100644 index 0000000..fdbf29d --- /dev/null +++ b/dsql-app/.local_dist/prerender-manifest.json @@ -0,0 +1 @@ +{"version":3,"routes":{"/docs/gui-reference/getting-started":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/gui-reference/getting-started.json"},"/docs/gui-reference/upload-media":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/gui-reference/upload-media.json"},"/docs/api-reference/get":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/api-reference/get.json"},"/docs/api-reference/post":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/api-reference/post.json"},"/docs/database-reference/data-types":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/database-reference/data-types.json"},"/docs/database-reference/querying-data":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]/[sub-page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/database-reference/querying-data.json"},"/docs/quick-start":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/quick-start.json"},"/docs/gui-reference":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/gui-reference.json"},"/docs/api-reference":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/api-reference.json"},"/docs/getting-started":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/getting-started.json"},"/docs/database-reference":{"initialRevalidateSeconds":false,"srcRoute":"/docs/[page]","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/database-reference.json"}},"dynamicRoutes":{"/docs/[page]/[sub-page]":{"routeRegex":"^/docs/([^/]+?)/([^/]+?)(?:/)?$","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/[page]/[sub-page].json","fallback":false,"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/([^/]+?)/([^/]+?)\\.json$"},"/docs/[page]":{"routeRegex":"^/docs/([^/]+?)(?:/)?$","dataRoute":"/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/[page].json","fallback":false,"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/([^/]+?)\\.json$"}},"notFoundRoutes":[],"preview":{"previewModeId":"9c59e033bcb45d11654ebd76b3799dc6","previewModeSigningKey":"29052237ee0b07d7aadc4b19d504ad089f772e7bf8b39bd18c4179b9179c0dac","previewModeEncryptionKey":"15c7d14816ae70c1971507cab9f741ec628262d518f4ddb4fc6bab3ce74d18d5"}} \ No newline at end of file diff --git a/dsql-app/.local_dist/react-loadable-manifest.json b/dsql-app/.local_dist/react-loadable-manifest.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/dsql-app/.local_dist/react-loadable-manifest.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/dsql-app/.local_dist/required-server-files.json b/dsql-app/.local_dist/required-server-files.json new file mode 100644 index 0000000..f1865be --- /dev/null +++ b/dsql-app/.local_dist/required-server-files.json @@ -0,0 +1 @@ +{"version":1,"config":{"env":{},"webpack":null,"webpackDevMiddleware":null,"eslint":{"ignoreDuringBuilds":true},"typescript":{"ignoreBuildErrors":true,"tsconfigPath":"tsconfig.json"},"distDir":".local_dist","cleanDistDir":true,"assetPrefix":"","configOrigin":"next.config.js","useFileSystemPublicRoutes":true,"generateEtags":true,"pageExtensions":["tsx","ts","jsx","js"],"target":"server","poweredByHeader":true,"compress":true,"analyticsId":"","images":{"deviceSizes":[640,750,828,1080,1200,1920,2048,3840],"imageSizes":[16,32,48,64,96,128,256,384],"path":"/_next/image","loader":"default","domains":[],"disableStaticImages":false,"minimumCacheTTL":60,"formats":["image/webp"],"dangerouslyAllowSVG":false,"contentSecurityPolicy":"script-src 'none'; frame-src 'none'; sandbox;","remotePatterns":[],"unoptimized":false},"devIndicators":{"buildActivity":true,"buildActivityPosition":"bottom-right"},"onDemandEntries":{"maxInactiveAge":15000,"pagesBufferLength":2},"amp":{"canonicalBase":""},"basePath":"","sassOptions":{},"trailingSlash":false,"i18n":null,"productionBrowserSourceMaps":false,"optimizeFonts":true,"excludeDefaultMomentLocales":true,"serverRuntimeConfig":{},"publicRuntimeConfig":{},"reactStrictMode":true,"httpAgentOptions":{"keepAlive":true},"outputFileTracing":true,"staticPageGenerationTimeout":60,"swcMinify":false,"experimental":{"optimisticClientCache":true,"manualClientBasePath":false,"legacyBrowsers":true,"browsersListForSwc":false,"newNextLinkBehavior":false,"cpus":15,"sharedPool":true,"profiling":false,"isrFlushToDisk":true,"workerThreads":false,"pageEnv":false,"optimizeCss":false,"nextScriptWorkers":false,"scrollRestoration":false,"externalDir":false,"disableOptimizedLoading":false,"gzipSize":true,"swcFileReading":true,"craCompat":false,"esmExternals":true,"appDir":false,"isrMemoryCacheSize":52428800,"serverComponents":false,"fullySpecified":false,"outputFileTracingRoot":"","swcTraceProfiling":false,"forceSwcTransforms":false,"largePageDataBytes":128000,"adjustFontFallbacks":false,"trustHostHeader":false},"configFileName":"next.config.js"},"appDir":"/app","files":[".local_dist/routes-manifest.json",".local_dist/server/pages-manifest.json",".local_dist/build-manifest.json",".local_dist/prerender-manifest.json",".local_dist/server/middleware-manifest.json",".local_dist/react-loadable-manifest.json",".local_dist/server/font-manifest.json",".local_dist/BUILD_ID"],"ignore":["node_modules/next/dist/compiled/@ampproject/toolbox-optimizer/**/*"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/routes-manifest.json b/dsql-app/.local_dist/routes-manifest.json new file mode 100644 index 0000000..c3ad87a --- /dev/null +++ b/dsql-app/.local_dist/routes-manifest.json @@ -0,0 +1 @@ +{"version":3,"pages404":true,"basePath":"","redirects":[{"source":"/:path+/","destination":"/:path+","internal":true,"statusCode":308,"regex":"^(?:/((?:[^/]+?)(?:/(?:[^/]+?))*))/$"}],"headers":[],"dynamicRoutes":[{"page":"/admin/[user_id]","regex":"^/admin/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/api-keys","regex":"^/admin/([^/]+?)/api\\-keys(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/api\\-keys(?:/)?$"},{"page":"/admin/[user_id]/connect","regex":"^/admin/([^/]+?)/connect(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/connect(?:/)?$"},{"page":"/admin/[user_id]/databases","regex":"^/admin/([^/]+?)/databases(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/databases(?:/)?$"},{"page":"/admin/[user_id]/databases/add-database","regex":"^/admin/([^/]+?)/databases/add\\-database(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/databases/add\\-database(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]","regex":"^/admin/([^/]+?)/databases/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/connect","regex":"^/admin/([^/]+?)/databases/([^/]+?)/connect(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/connect(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/edit-database","regex":"^/admin/([^/]+?)/databases/([^/]+?)/edit\\-database(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/edit\\-database(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/schema","regex":"^/admin/([^/]+?)/databases/([^/]+?)/schema(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/schema(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/shell","regex":"^/admin/([^/]+?)/databases/([^/]+?)/shell(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/shell(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/add-table","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/add\\-table(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/add\\-table(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/edit\\-table(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/edit\\-table(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries/add\\-entry(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries/add\\-entry(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table","single_entry":"single_entry"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/fields","regex":"^/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/fields(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/fields(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/users","regex":"^/admin/([^/]+?)/databases/([^/]+?)/users(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/users(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/users/add-social-logins","regex":"^/admin/([^/]+?)/databases/([^/]+?)/users/add\\-social\\-logins(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/users/add\\-social\\-logins(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/users/add-user","regex":"^/admin/([^/]+?)/databases/([^/]+?)/users/add\\-user(?:/)?$","routeKeys":{"user_id":"user_id","single":"single"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/users/add\\-user(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/users/[user]","regex":"^/admin/([^/]+?)/databases/([^/]+?)/users/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","user":"user"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/users/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/databases/[single]/users/[user]/change-password","regex":"^/admin/([^/]+?)/databases/([^/]+?)/users/([^/]+?)/change\\-password(?:/)?$","routeKeys":{"user_id":"user_id","single":"single","user":"user"},"namedRegex":"^/admin/(?[^/]+?)/databases/(?[^/]+?)/users/(?[^/]+?)/change\\-password(?:/)?$"},{"page":"/admin/[user_id]/media","regex":"^/admin/([^/]+?)/media(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/media(?:/)?$"},{"page":"/admin/[user_id]/media/[...folder]","regex":"^/admin/([^/]+?)/media/(.+?)(?:/)?$","routeKeys":{"user_id":"user_id","folder":"folder"},"namedRegex":"^/admin/(?[^/]+?)/media/(?.+?)(?:/)?$"},{"page":"/admin/[user_id]/schema","regex":"^/admin/([^/]+?)/schema(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/schema(?:/)?$"},{"page":"/admin/[user_id]/settings","regex":"^/admin/([^/]+?)/settings(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/settings(?:/)?$"},{"page":"/admin/[user_id]/users","regex":"^/admin/([^/]+?)/users(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/users(?:/)?$"},{"page":"/admin/[user_id]/users/add-user","regex":"^/admin/([^/]+?)/users/add\\-user(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/users/add\\-user(?:/)?$"},{"page":"/admin/[user_id]/users/databases","regex":"^/admin/([^/]+?)/users/databases(?:/)?$","routeKeys":{"user_id":"user_id"},"namedRegex":"^/admin/(?[^/]+?)/users/databases(?:/)?$"},{"page":"/admin/[user_id]/users/databases/[database]","regex":"^/admin/([^/]+?)/users/databases/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","database":"database"},"namedRegex":"^/admin/(?[^/]+?)/users/databases/(?[^/]+?)(?:/)?$"},{"page":"/admin/[user_id]/users/databases/[database]/[user]","regex":"^/admin/([^/]+?)/users/databases/([^/]+?)/([^/]+?)(?:/)?$","routeKeys":{"user_id":"user_id","database":"database","user":"user"},"namedRegex":"^/admin/(?[^/]+?)/users/databases/(?[^/]+?)/(?[^/]+?)(?:/)?$"},{"page":"/api/admin/docs/[action]","regex":"^/api/admin/docs/([^/]+?)(?:/)?$","routeKeys":{"action":"action"},"namedRegex":"^/api/admin/docs/(?[^/]+?)(?:/)?$"},{"page":"/api/stream/[path]","regex":"^/api/stream/([^/]+?)(?:/)?$","routeKeys":{"path":"path"},"namedRegex":"^/api/stream/(?[^/]+?)(?:/)?$"},{"page":"/docs/[page]","regex":"^/docs/([^/]+?)(?:/)?$","routeKeys":{"page":"page"},"namedRegex":"^/docs/(?[^/]+?)(?:/)?$"},{"page":"/docs/[page]/[sub-page]","regex":"^/docs/([^/]+?)/([^/]+?)(?:/)?$","routeKeys":{"page":"page","subpage":"sub-page"},"namedRegex":"^/docs/(?[^/]+?)/(?[^/]+?)(?:/)?$"},{"page":"/su/docs/pages/[id]","regex":"^/su/docs/pages/([^/]+?)(?:/)?$","routeKeys":{"id":"id"},"namedRegex":"^/su/docs/pages/(?[^/]+?)(?:/)?$"},{"page":"/su/users/[single]","regex":"^/su/users/([^/]+?)(?:/)?$","routeKeys":{"single":"single"},"namedRegex":"^/su/users/(?[^/]+?)(?:/)?$"}],"staticRoutes":[{"page":"/","regex":"^/(?:/)?$","routeKeys":{},"namedRegex":"^/(?:/)?$"},{"page":"/404","regex":"^/404(?:/)?$","routeKeys":{},"namedRegex":"^/404(?:/)?$"},{"page":"/500","regex":"^/500(?:/)?$","routeKeys":{},"namedRegex":"^/500(?:/)?$"},{"page":"/about","regex":"^/about(?:/)?$","routeKeys":{},"namedRegex":"^/about(?:/)?$"},{"page":"/admin","regex":"^/admin(?:/)?$","routeKeys":{},"namedRegex":"^/admin(?:/)?$"},{"page":"/blog","regex":"^/blog(?:/)?$","routeKeys":{},"namedRegex":"^/blog(?:/)?$"},{"page":"/contact","regex":"^/contact(?:/)?$","routeKeys":{},"namedRegex":"^/contact(?:/)?$"},{"page":"/create-account","regex":"^/create\\-account(?:/)?$","routeKeys":{},"namedRegex":"^/create\\-account(?:/)?$"},{"page":"/docs","regex":"^/docs(?:/)?$","routeKeys":{},"namedRegex":"^/docs(?:/)?$"},{"page":"/email-verification","regex":"^/email\\-verification(?:/)?$","routeKeys":{},"namedRegex":"^/email\\-verification(?:/)?$"},{"page":"/login","regex":"^/login(?:/)?$","routeKeys":{},"namedRegex":"^/login(?:/)?$"},{"page":"/logout","regex":"^/logout(?:/)?$","routeKeys":{},"namedRegex":"^/logout(?:/)?$"},{"page":"/pricing","regex":"^/pricing(?:/)?$","routeKeys":{},"namedRegex":"^/pricing(?:/)?$"},{"page":"/privacy","regex":"^/privacy(?:/)?$","routeKeys":{},"namedRegex":"^/privacy(?:/)?$"},{"page":"/redirect","regex":"^/redirect(?:/)?$","routeKeys":{},"namedRegex":"^/redirect(?:/)?$"},{"page":"/reset-password","regex":"^/reset\\-password(?:/)?$","routeKeys":{},"namedRegex":"^/reset\\-password(?:/)?$"},{"page":"/send-password-reset-link","regex":"^/send\\-password\\-reset\\-link(?:/)?$","routeKeys":{},"namedRegex":"^/send\\-password\\-reset\\-link(?:/)?$"},{"page":"/su","regex":"^/su(?:/)?$","routeKeys":{},"namedRegex":"^/su(?:/)?$"},{"page":"/su/backups","regex":"^/su/backups(?:/)?$","routeKeys":{},"namedRegex":"^/su/backups(?:/)?$"},{"page":"/su/console","regex":"^/su/console(?:/)?$","routeKeys":{},"namedRegex":"^/su/console(?:/)?$"},{"page":"/su/docs","regex":"^/su/docs(?:/)?$","routeKeys":{},"namedRegex":"^/su/docs(?:/)?$"},{"page":"/su/docs/create-page","regex":"^/su/docs/create\\-page(?:/)?$","routeKeys":{},"namedRegex":"^/su/docs/create\\-page(?:/)?$"},{"page":"/su/docs/edit-page","regex":"^/su/docs/edit\\-page(?:/)?$","routeKeys":{},"namedRegex":"^/su/docs/edit\\-page(?:/)?$"},{"page":"/su/docs/pages","regex":"^/su/docs/pages(?:/)?$","routeKeys":{},"namedRegex":"^/su/docs/pages(?:/)?$"},{"page":"/su/envar","regex":"^/su/envar(?:/)?$","routeKeys":{},"namedRegex":"^/su/envar(?:/)?$"},{"page":"/su/error-logs","regex":"^/su/error\\-logs(?:/)?$","routeKeys":{},"namedRegex":"^/su/error\\-logs(?:/)?$"},{"page":"/su/login","regex":"^/su/login(?:/)?$","routeKeys":{},"namedRegex":"^/su/login(?:/)?$"},{"page":"/su/users","regex":"^/su/users(?:/)?$","routeKeys":{},"namedRegex":"^/su/users(?:/)?$"},{"page":"/su/users/new","regex":"^/su/users/new(?:/)?$","routeKeys":{},"namedRegex":"^/su/users/new(?:/)?$"},{"page":"/terms","regex":"^/terms(?:/)?$","routeKeys":{},"namedRegex":"^/terms(?:/)?$"},{"page":"/unsubscribe","regex":"^/unsubscribe(?:/)?$","routeKeys":{},"namedRegex":"^/unsubscribe(?:/)?$"}],"dataRoutes":[{"page":"/admin","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin.json$"},{"page":"/admin/[user_id]","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/api-keys","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/api\\-keys\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/api\\-keys\\.json$"},{"page":"/admin/[user_id]/connect","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/connect\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/connect\\.json$"},{"page":"/admin/[user_id]/databases","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases\\.json$"},{"page":"/admin/[user_id]/databases/add-database","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/add\\-database\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/add\\-database\\.json$"},{"page":"/admin/[user_id]/databases/[single]","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/databases/[single]/connect","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/connect\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/connect\\.json$"},{"page":"/admin/[user_id]/databases/[single]/edit-database","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/edit\\-database\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/edit\\-database\\.json$"},{"page":"/admin/[user_id]/databases/[single]/schema","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/schema\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/schema\\.json$"},{"page":"/admin/[user_id]/databases/[single]/shell","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/shell\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/shell\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/add-table","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/add\\-table\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/add\\-table\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/edit\\-table\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/edit\\-table\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries/add\\-entry\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries/add\\-entry\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table","single_entry":"single_entry"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/entries/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/entries/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/databases/[single]/tables/[single_table]/fields","routeKeys":{"user_id":"user_id","single":"single","single_table":"single_table"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/tables/([^/]+?)/fields\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/tables/(?[^/]+?)/fields\\.json$"},{"page":"/admin/[user_id]/databases/[single]/users","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/users\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/users\\.json$"},{"page":"/admin/[user_id]/databases/[single]/users/add-social-logins","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/users/add\\-social\\-logins\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/users/add\\-social\\-logins\\.json$"},{"page":"/admin/[user_id]/databases/[single]/users/add-user","routeKeys":{"user_id":"user_id","single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/users/add\\-user\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/users/add\\-user\\.json$"},{"page":"/admin/[user_id]/databases/[single]/users/[user]","routeKeys":{"user_id":"user_id","single":"single","user":"user"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/users/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/users/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/databases/[single]/users/[user]/change-password","routeKeys":{"user_id":"user_id","single":"single","user":"user"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/databases/([^/]+?)/users/([^/]+?)/change\\-password\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/databases/(?[^/]+?)/users/(?[^/]+?)/change\\-password\\.json$"},{"page":"/admin/[user_id]/media","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/media\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/media\\.json$"},{"page":"/admin/[user_id]/media/[...folder]","routeKeys":{"user_id":"user_id","folder":"folder"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/media/(.+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/media/(?.+?)\\.json$"},{"page":"/admin/[user_id]/schema","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/schema\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/schema\\.json$"},{"page":"/admin/[user_id]/settings","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/settings\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/settings\\.json$"},{"page":"/admin/[user_id]/users","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/users\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/users\\.json$"},{"page":"/admin/[user_id]/users/add-user","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/users/add\\-user\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/users/add\\-user\\.json$"},{"page":"/admin/[user_id]/users/databases","routeKeys":{"user_id":"user_id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/users/databases\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/users/databases\\.json$"},{"page":"/admin/[user_id]/users/databases/[database]","routeKeys":{"user_id":"user_id","database":"database"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/users/databases/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/users/databases/(?[^/]+?)\\.json$"},{"page":"/admin/[user_id]/users/databases/[database]/[user]","routeKeys":{"user_id":"user_id","database":"database","user":"user"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/([^/]+?)/users/databases/([^/]+?)/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/admin/(?[^/]+?)/users/databases/(?[^/]+?)/(?[^/]+?)\\.json$"},{"page":"/create-account","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/create-account.json$"},{"page":"/docs","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs.json$"},{"page":"/docs/[page]","routeKeys":{"page":"page"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/(?[^/]+?)\\.json$"},{"page":"/docs/[page]/[sub-page]","routeKeys":{"page":"page","subpage":"sub-page"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/([^/]+?)/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/docs/(?[^/]+?)/(?[^/]+?)\\.json$"},{"page":"/email-verification","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/email-verification.json$"},{"page":"/login","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/login.json$"},{"page":"/logout","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/logout.json$"},{"page":"/reset-password","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/reset-password.json$"},{"page":"/send-password-reset-link","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/send-password-reset-link.json$"},{"page":"/su","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su.json$"},{"page":"/su/backups","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/backups.json$"},{"page":"/su/console","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/console.json$"},{"page":"/su/docs","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs.json$"},{"page":"/su/docs/create-page","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs/create-page.json$"},{"page":"/su/docs/edit-page","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs/edit-page.json$"},{"page":"/su/docs/pages","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs/pages.json$"},{"page":"/su/docs/pages/[id]","routeKeys":{"id":"id"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs/pages/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/docs/pages/(?[^/]+?)\\.json$"},{"page":"/su/envar","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/envar.json$"},{"page":"/su/error-logs","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/error-logs.json$"},{"page":"/su/login","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/login.json$"},{"page":"/su/users","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/users.json$"},{"page":"/su/users/new","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/users/new.json$"},{"page":"/su/users/[single]","routeKeys":{"single":"single"},"dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/users/([^/]+?)\\.json$","namedDataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/su/users/(?[^/]+?)\\.json$"},{"page":"/unsubscribe","dataRouteRegex":"^/_next/data/vsppBJBDbOVrlLfYIAYwv/unsubscribe.json$"}],"rewrites":[]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1007.js b/dsql-app/.local_dist/server/chunks/1007.js new file mode 100644 index 0000000..de36e5e --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1007.js @@ -0,0 +1,39 @@ +"use strict"; +exports.id = 1007; +exports.ids = [1007]; +exports.modules = { + +/***/ 1007: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const decrypt = __webpack_require__(5425); +/** @type {import("@/package-shared/types").CheckApiCredentialsFn} */ const grabApiCred = ({ key , database , table })=>{ + try { + const allowedKeysPath = process.env.DSQL_API_KEYS_PATH; + if (!allowedKeysPath) throw new Error("process.env.DSQL_API_KEYS_PATH variable not found"); + const ApiJSON = decrypt(key); + /** @type {import("@/package-shared/types").ApiKeyObject} */ const ApiObject = JSON.parse(ApiJSON || ""); + const isApiKeyValid = fs.existsSync(`${allowedKeysPath}/${ApiObject.sign}`); + if (!isApiKeyValid) return null; + if (!ApiObject.target_database) return ApiObject; + if (!database && ApiObject.target_database) return null; + const isDatabaseAllowed = ApiObject.target_database?.split(",").includes(String(database)); + if (isDatabaseAllowed && !ApiObject.target_table) return ApiObject; + if (isDatabaseAllowed && !table && ApiObject.target_table) return null; + const isTableAllowed = ApiObject.target_table?.split(",").includes(String(table)); + if (isTableAllowed) return ApiObject; + return null; + } catch (error) { + return null; + } +}; +module.exports = grabApiCred; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1206.js b/dsql-app/.local_dist/server/chunks/1206.js new file mode 100644 index 0000000..3f28cf3 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1206.js @@ -0,0 +1,182 @@ +"use strict"; +exports.id = 1206; +exports.ids = [1206]; +exports.modules = { + +/***/ 7410: +/***/ ((module) => { + +// @ts-check +/** + * Regular expression to match default fields + * + * @description Regular expression to match default fields + */ +const defaultFieldsRegexp = /^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = defaultFieldsRegexp; + + +/***/ }), + +/***/ 7432: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const decrypt = __webpack_require__(5304); +const defaultFieldsRegexp = __webpack_require__(7410); +/** + * Parse Database results + * ============================================================================== + * @description this function takes a database results array gotten from a DB handler + * function, decrypts encrypted fields, and returns an updated array with no encrypted + * fields + * + * @param {object} params - Single object params + * @param {any[]} params.unparsedResults - Array of data objects containing Fields(keys) + * and corresponding values of the fields(values) + * @param {import("../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @returns {Promise} + */ module.exports = async function parseDbResults({ unparsedResults , tableSchema , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ let parsedResults = []; + try { + /** + * Declare variables + * + * @description Declare "results" variable + */ for(let pr = 0; pr < unparsedResults.length; pr++){ + let result = unparsedResults[pr]; + let resultFieldNames = Object.keys(result); + for(let i = 0; i < resultFieldNames.length; i++){ + const resultFieldName = resultFieldNames[i]; + let resultFieldSchema = tableSchema?.fields[i]; + if (resultFieldName?.match(defaultFieldsRegexp)) { + continue; + } + let value = result[resultFieldName]; + if (typeof value !== "number" && !value) { + continue; + } + if (resultFieldSchema?.encrypted) { + if (value?.match(/./)) { + result[resultFieldName] = decrypt(value); + } + } + } + parsedResults.push(result); + } + /** + * Declare variables + * + * @description Declare "results" variable + */ return parsedResults; + } catch (/** @type {any} */ error) { + console.log("ERROR in parseDbResults Function =>", error.message); + return unparsedResults; + } +}; + + +/***/ }), + +/***/ 1206: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const parseDbResults = __webpack_require__(7432); +const serverError = __webpack_require__(7023); +const DB_HANDLER = __webpack_require__(9395); +const DSQL_USER_DB_HANDLER = __webpack_require__(8682); +/** + * DB handler for specific database + * ============================================================================== + * @async + * @param {object} params - Single object params + * @param {string} params.queryString - SQL string + * @param {*[]} [params.queryValuesArray] - Values Array + * @param {string} [params.database] - Database name + * @param {import("../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @returns {Promise} + */ module.exports = async function varDatabaseDbHandler({ queryString , queryValuesArray , database , tableSchema , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ const isMaster = database?.match(/^datasquirel$/) ? true : false; + /** @type {any} */ const FINAL_DB_HANDLER = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + if (queryString && queryValuesArray && Array.isArray(queryValuesArray) && queryValuesArray[0]) { + results = isMaster ? await FINAL_DB_HANDLER(queryString, queryValuesArray) : await FINAL_DB_HANDLER({ + paradigm: "Full Access", + database, + queryString, + queryValues: queryValuesArray + }); + } else { + results = isMaster ? await FINAL_DB_HANDLER(queryString) : await FINAL_DB_HANDLER({ + paradigm: "Full Access", + database, + queryString + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "varDatabaseDbHandler/lines-29-32", + message: error.message + }); + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results && tableSchema) { + try { + const unparsedResults = results; + const parsedResults = await parseDbResults({ + unparsedResults: unparsedResults, + tableSchema: tableSchema + }); + return parsedResults; + } catch (/** @type {any} */ error1) { + console.log("\x1b[31mvarDatabaseDbHandler ERROR\x1b[0m =>", database, error1); + serverError({ + component: "varDatabaseDbHandler/lines-52-53", + message: error1.message + }); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else if (results) { + return results; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1311.js b/dsql-app/.local_dist/server/chunks/1311.js new file mode 100644 index 0000000..c253e4a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1311.js @@ -0,0 +1,99 @@ +"use strict"; +exports.id = 1311; +exports.ids = [1311]; +exports.modules = { + +/***/ 1311: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const parseDbResults = __webpack_require__(8326); +const serverError = __webpack_require__(3017); +const DB_HANDLER = __webpack_require__(2224); +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** + * DB handler for specific database + * ============================================================================== + * @async + * @param {object} params - Single object params + * @param {string} params.queryString - SQL string + * @param {*[]} [params.queryValuesArray] - Values Array + * @param {string} [params.database] - Database name + * @param {import("../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @returns {Promise} + */ module.exports = async function varDatabaseDbHandler({ queryString , queryValuesArray , database , tableSchema , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ const isMaster = database?.match(/^datasquirel$/) ? true : false; + /** @type {any} */ const FINAL_DB_HANDLER = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + if (queryString && queryValuesArray && Array.isArray(queryValuesArray) && queryValuesArray[0]) { + results = isMaster ? await FINAL_DB_HANDLER(queryString, queryValuesArray) : await FINAL_DB_HANDLER({ + paradigm: "Full Access", + database, + queryString, + queryValues: queryValuesArray + }); + } else { + results = isMaster ? await FINAL_DB_HANDLER(queryString) : await FINAL_DB_HANDLER({ + paradigm: "Full Access", + database, + queryString + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "varDatabaseDbHandler/lines-29-32", + message: error.message + }); + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results && tableSchema) { + try { + const unparsedResults = results; + const parsedResults = await parseDbResults({ + unparsedResults: unparsedResults, + tableSchema: tableSchema + }); + return parsedResults; + } catch (/** @type {any} */ error1) { + console.log("\x1b[31mvarDatabaseDbHandler ERROR\x1b[0m =>", database, error1); + serverError({ + component: "varDatabaseDbHandler/lines-52-53", + message: error1.message + }); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else if (results) { + return results; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1336.js b/dsql-app/.local_dist/server/chunks/1336.js new file mode 100644 index 0000000..a2aea45 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1336.js @@ -0,0 +1,158 @@ +"use strict"; +exports.id = 1336; +exports.ids = [1336]; +exports.modules = { + +/***/ 1336: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UserCard) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").UserType} props.userObject + * @param {boolean} [props.userPage] + */ function UserCard({ userObject , userPage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userTitles = Object.keys(userObject); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const [refresh, setRefresh] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + const [collapsed, setCollapsed] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(userPage ? false : true); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card col green w-full overflow-hidden" + (collapsed ? userPage ? " h-[100px]" : " h-[85px]" : " "), + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "items-center w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: userObject["image_thumbnail"], + alt: "", + className: "rounded-full object-cover" + (userPage ? " w-16 h-16" : " w-12 h-12") + }), + !userPage && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h3", { + className: "m-0 text-xl", + children: [ + userObject["first_name"], + " ", + userObject["last_name"], + " " + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "ml-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray small-text", + onClick: (e)=>{ + if (collapsed) { + setCollapsed(false); + } else { + setCollapsed(true); + } + }, + children: collapsed ? "More Details" : "Collapse" + }), + !userPage && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/su/users/${userObject.id}`, + className: "button outlined gray small-text", + children: "View User" + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "card no-hover col w-full light-gray-bg", + children: userTitles.map((userTitle, utIndex)=>{ + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + style: { + wordBreak: "break-all" + }, + children: [ + userTitle, + ":", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: // @ts-ignore + userObject[userTitle] + }) + ] + }) + }), + utIndex < userTitles.length - 1 && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", {}) + ] + }, utIndex + 1); + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray small-text w-full", + onClick: (e)=>{ + setCollapsed(true); + }, + children: "Collapse" + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1352.js b/dsql-app/.local_dist/server/chunks/1352.js new file mode 100644 index 0000000..6fb3b1d --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1352.js @@ -0,0 +1,99 @@ +"use strict"; +exports.id = 1352; +exports.ids = [1352]; +exports.modules = { + +/***/ 1352: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const http = __webpack_require__(3685); +const decrypt = __webpack_require__(5425); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} grabDelegatedUserFromCookieReturn + * @property {number} dbUserId + * @property {number} [dbUserId] + * @property {number} [rootUserId] + * @property {string} [rootUserName] + * @property {string} [rootUserEmail] + * @property {string} [rootUserImage] + * @property {string} [databaseFullName] + * @property {string} [databaseSlug] + * @property {string[]} [allowedTables] + * @property {string} [priviledges] + * @property {string} [database] + * @property {boolean} [delegated] + */ /** + * @param {object} params - user id + * @param {import("next").NextApiRequest | http.IncomingMessage & { cookies: Partial<{ [key: string]: string; }>}} params.request - HTTPS request object + * @param {string | string[]} params.databaseSlug - Database name slug + * @param {{ id: number, first_name: string, last_name: string }} params.user + * @param {any} params.query - query params + * + * @returns {Promise} new user auth object payload + */ module.exports = async function grabDelegatedUserFromCookie({ request , databaseSlug , user , query , }) { + try { + /** + * Fetch user + * + * @description Fetch user from db + */ let dbUserId = user.id; + let delegatedUserObject = null; + if (!query?.delegated) return { + dbUserId + }; + const rootUserId = query.dbUserId; + const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${rootUserId}_${databaseSlug}`; + const tokenName = `${process.env.DSQL_USER_DELEGATED_DB_COOKIE_PREFIX}${dbFullName}`; + try { + if (!request.cookies?.[tokenName]) throw new Error("Cookie not present"); + // @ts-ignore + const decryptedToken = decrypt(request.cookies[tokenName]); + if (!decryptedToken) throw new Error("Invalid Token"); + delegatedUserObject = JSON.parse(decryptedToken); + if (delegatedUserObject.databaseSlug === databaseSlug) { + dbUserId = delegatedUserObject.rootUserId; + return { + dbUserId: dbUserId, + rootUserId: delegatedUserObject.rootUserId, + rootUserName: delegatedUserObject.rootUserName, + rootUserEmail: delegatedUserObject.rootUserEmail, + rootUserImage: delegatedUserObject.rootUserImage, + databaseFullName: delegatedUserObject.databaseFullName, + databaseSlug: delegatedUserObject.databaseSlug, + allowedTables: delegatedUserObject.allowedTables, + priviledges: delegatedUserObject.priviledges, + database: delegatedUserObject.databaseSlug, + delegated: true + }; + } + } catch (error) { + // serverError({ + // component: "grabDelegatedUserFromCookie", + // message: error.message, + // user: user, + // }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return { + dbUserId + }; + } catch (error1) { + return null; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1500.js b/dsql-app/.local_dist/server/chunks/1500.js new file mode 100644 index 0000000..ea70001 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1500.js @@ -0,0 +1,124 @@ +"use strict"; +exports.id = 1500; +exports.ids = [1500]; +exports.modules = { + +/***/ 5012: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DeleteDatabaseConfirmationPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6729); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {DSQL_MYSQL_user_databases_Type | undefined} props.targetDatabase + */ function DeleteDatabaseConfirmationPopup({ targetDatabase }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "delete-database-confirmation", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0", + children: [ + "Delete '", + targetDatabase?.db_name ? targetDatabase.db_name : "This Database", + "' database?" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + if (!targetDatabase) { + alert("No Target Database Selected!"); + return; + } + setLoading(true); + if (window.confirm(`Note that you will loose all data in this database. Continue?`)) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/deleteUserDatabase", { + method: "post", + body: targetDatabase + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }); + } else { + setLoading(false); + } + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Yes" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Cancel" + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1503.js b/dsql-app/.local_dist/server/chunks/1503.js new file mode 100644 index 0000000..8563ea8 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1503.js @@ -0,0 +1,37 @@ +"use strict"; +exports.id = 1503; +exports.ids = [1503]; +exports.modules = { + +/***/ 1503: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { IncomingMessage } = __webpack_require__(3685); +const decrypt = __webpack_require__(5304); +/** + * @async + * @param {import("next").NextApiRequest | IncomingMessage & { cookies: Partial<{ [key: string]: string; }>} } req - https request object + * + * @returns {Promise<({ email: string, password: string, authKey: string, logged_in_status: boolean, date: number } | null)>} + */ module.exports = async function(req) { + /** ********************* Check for existence of required cookie */ if (!req.cookies?.datasquirelSuAdminUserAuthKey) { + return null; + } + /** ********************* Grab the payload */ let userPayload = decrypt(req.cookies.datasquirelSuAdminUserAuthKey); + /** ********************* Return if no payload */ if (!userPayload) return null; + /** ********************* Parse the payload */ let userObject = JSON.parse(userPayload); + if (userObject.password !== process.env.DSQL_USER_KEY) return null; + if (userObject.authKey !== process.env.DSQL_SPECIAL_KEY) return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* return user object */ return userObject; +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1674.js b/dsql-app/.local_dist/server/chunks/1674.js new file mode 100644 index 0000000..ff4a81b --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1674.js @@ -0,0 +1,122 @@ +"use strict"; +exports.id = 1674; +exports.ids = [1674]; +exports.modules = { + +/***/ 1674: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DeleteTableConfirmationPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_Breadcrumbs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(424); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5472); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def | null} [props.targetTable] + */ function DeleteTableConfirmationPopup({ targetTable , database , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .ZP, { + title: "delete-table-confirmation", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0", + children: [ + "Delete '", + targetTable?.table_name ? targetTable.table_name : "This Database", + "' Table?" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/deleteUserTable", { + method: "post", + body: { + database: database, + table: targetTable + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Yes" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Cancel" + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1781.js b/dsql-app/.local_dist/server/chunks/1781.js new file mode 100644 index 0000000..d834e59 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1781.js @@ -0,0 +1,46 @@ +"use strict"; +exports.id = 1781; +exports.ids = [1781]; +exports.modules = { + +/***/ 1781: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ BackButton) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ArrowBackIosRounded__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3257); +/* harmony import */ var _mui_icons_material_ArrowBackIosRounded__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ArrowBackIosRounded__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + */ function BackButton() { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full", + onClick: (e)=>{ + window.history.back(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_ArrowBackIosRounded__WEBPACK_IMPORTED_MODULE_2___default()), { + color: "inherit", + className: "opacity-50 text-black", + fontSize: "small" + }) + }); +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/1926.js b/dsql-app/.local_dist/server/chunks/1926.js new file mode 100644 index 0000000..500b9b1 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/1926.js @@ -0,0 +1,309 @@ +"use strict"; +exports.id = 1926; +exports.ids = [1926]; +exports.modules = { + +/***/ 1926: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DbCreateDbUserForm) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6729); +/* harmony import */ var _general_FormAlertBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7037); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _form_FormInput__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7901); +/* harmony import */ var _UserImage__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2733); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// + + + + + +//////////////////////////////////////// +/** @type {any} */ let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.targetDb + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} [props.database] + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {any} props.userImage + * @param {React.Dispatch>} props.setUserImage + */ function DbCreateDbUserForm({ targetDb , database , user , userImage , setUserImage , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ alert: string | null, setAlert: React.Dispatch> ]} */ // @ts-ignore + const [alert, setAlert] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + alert && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_FormAlertBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + message: alert + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600 mt-4", + children: "User information" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "First Name", + inputType: "text", + name: "first_name", + autoComplete: "given-name", + onInputHandler: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + }, + required: true + }) + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "last_name", + children: "Last Name" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "last_name", + id: "last_name", + placeholder: "Last Name", + autoComplete: "family-name", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "username", + children: "Username" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "username", + id: "username", + placeholder: "Username", + autoComplete: "username", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z)(`/api/checkDuplicateData?type=username&value=${inputEl.value}&tableName=users&dbFullName=${targetDb}`).then((res)=>{ + // console.log(res); + if (res?.result) { + setAlert("Username Already Exists"); + inputEl.classList.add("warning"); + } else { + setAlert(null); + inputEl.classList.remove("warning"); + } + }); + }, 300); + } + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "email_address", + children: "Email Address" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "email", + name: "email_address", + id: "email_address", + placeholder: "Email Address", + autoComplete: "email", + onInput: (e)=>{ + window.clearTimeout(timeout); + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + timeout = setTimeout(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z)(`/api/checkDuplicateData?type=email&value=${inputEl.value}&tableName=users&dbFullName=${targetDb}`).then((res)=>{ + // console.log(res); + if (res?.result) { + setAlert("Email Already Exists"); + inputEl.classList.add("warning"); + } else { + setAlert(null); + inputEl.classList.remove("warning"); + } + }); + }, 300); + }, + required: true + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "Phone Number", + inputType: "text", + name: "phone", + autoComplete: "tel" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "Address", + name: "address", + autoComplete: "address" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-wrap xl:flex-nowrap", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "City", + name: "city", + autoComplete: "city" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "State", + name: "state", + autoComplete: "state" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "Country", + name: "country", + autoComplete: "country" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormInput__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + title: "Zip Code", + name: "zip_code", + autoComplete: "zip_code" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "password", + children: "Password" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "password", + id: "password", + placeholder: "Password", + required: true + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "confirm_password", + children: "Confirm Password" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "confirm_password", + id: "confirm_password", + placeholder: "Confirm Password", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let passwordInput = inputEl.closest("form")?.["password"].value; + let passwordRepeatInput = inputEl.value; + if (passwordInput === passwordRepeatInput) { + inputEl.classList.remove("warning"); + } else { + inputEl.classList.add("warning"); + } + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "paper", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600", + children: "User Image" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_UserImage__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + userImage: userImage, + setUserImage: setUserImage, + className: "w-full" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2163.js b/dsql-app/.local_dist/server/chunks/2163.js new file mode 100644 index 0000000..b184309 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2163.js @@ -0,0 +1,53 @@ +"use strict"; +exports.id = 2163; +exports.ids = [2163]; +exports.modules = { + +/***/ 2163: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +// const handleNodemailer = require("./handleNodemailer"); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * user?: { id?: number | string, first_name?: string, last_name?: string, email?: string } & *, + * message: string, + * component?: string, + * noMail?: boolean, + * }} params - user id + * + * @returns {Promise} + */ module.exports = async function serverError({ user , message , component , noMail , }) { + const log = `🚀 SERVER ERROR ===========================\nUser Id: ${user?.id}\nUser Name: ${user?.first_name} ${user?.last_name}\nUser Email: ${user?.email}\nError Message: ${message}\nComponent: ${component}\nDate: ${Date()}\n========================================`; + if (!fs.existsSync(`./.tmp/error.log`)) { + fs.writeFileSync(`./.tmp/error.log`, "", "utf-8"); + } + const initialText = fs.readFileSync(`./.tmp/error.log`, "utf-8"); + fs.writeFileSync(`./.tmp/error.log`, log); + fs.appendFileSync(`./.tmp/error.log`, `\n\n\n\n\n${initialText}`); +// if (process.env.NODE_ENV?.match(/production/) && !noMail) { +// handleNodemailer({ +// to: "benoti.san@gmail.com", +// subject: "SERVER Error in Datasquirel Application", +// text: "An Error occured in Datasquirel Application Server Side", +// html: log, +// }); +// } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2186.js b/dsql-app/.local_dist/server/chunks/2186.js new file mode 100644 index 0000000..04575c4 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2186.js @@ -0,0 +1,51 @@ +"use strict"; +exports.id = 2186; +exports.ids = [2186]; +exports.modules = { + +/***/ 2186: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormSuccessBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props + * @param {string} props.message - Message + * @param {string} [props.className] - Additional Class Names + */ function FormSuccessBlock({ message , className }) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "info green" + (className ? " " + className : ""), + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/checkmark.svg", + alt: "Warning Image Icon", + width: 22, + className: "-my-2" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: message + }) + ] + }); +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2224.js b/dsql-app/.local_dist/server/chunks/2224.js new file mode 100644 index 0000000..21d3f6e --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2224.js @@ -0,0 +1,55 @@ +"use strict"; +exports.id = 2224; +exports.ids = [2224]; +exports.modules = { + +/***/ 2224: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +const MASTER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + database: process.env.DSQL_DB_NAME, + port: process.env.DB_PORT ? Number(process.env.DB_PORT) : undefined, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {string} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ // @ts-ignore +async function DB_HANDLER(...args) { + try { + const results = await MASTER.query(...args); + /** ********************* Clean up */ await MASTER.end(); + return JSON.parse(JSON.stringify(results)); + } catch (/** @type {any} */ error) { + console.log("DB Error =>", error); + return { + success: false, + error: error.message + }; + } +} +module.exports = DB_HANDLER; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2317.js b/dsql-app/.local_dist/server/chunks/2317.js new file mode 100644 index 0000000..a7ef3ed --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2317.js @@ -0,0 +1,53 @@ +"use strict"; +exports.id = 2317; +exports.ids = [2317]; +exports.modules = { + +/***/ 2317: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +// const handleNodemailer = require("./handleNodemailer"); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * user?: { id?: number | string, first_name?: string, last_name?: string, email?: string } & *, + * message: string, + * component?: string, + * noMail?: boolean, + * }} params - user id + * + * @returns {Promise} + */ module.exports = async function serverError({ user , message , component , noMail , }) { + const log = `🚀 SERVER ERROR ===========================\nUser Id: ${user?.id}\nUser Name: ${user?.first_name} ${user?.last_name}\nUser Email: ${user?.email}\nError Message: ${message}\nComponent: ${component}\nDate: ${Date()}\n========================================`; + if (!fs.existsSync(`./.tmp/error.log`)) { + fs.writeFileSync(`./.tmp/error.log`, "", "utf-8"); + } + const initialText = fs.readFileSync(`./.tmp/error.log`, "utf-8"); + fs.writeFileSync(`./.tmp/error.log`, log); + fs.appendFileSync(`./.tmp/error.log`, `\n\n\n\n\n${initialText}`); +// if (process.env.NODE_ENV?.match(/production/) && !noMail) { +// handleNodemailer({ +// to: "benoti.san@gmail.com", +// subject: "SERVER Error in Datasquirel Application", +// text: "An Error occured in Datasquirel Application Server Side", +// html: log, +// }); +// } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2348.js b/dsql-app/.local_dist/server/chunks/2348.js new file mode 100644 index 0000000..457ac97 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2348.js @@ -0,0 +1,118 @@ +"use strict"; +exports.id = 2348; +exports.ids = [2348]; +exports.modules = { + +/***/ 2348: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormRadios) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {{ + * title: string, + * payload: string | boolean, + * default?: boolean, + * jsx?: React.ReactNode, + * onChangeHandler?: (e: any) => void, + * }[]} props.radioValues - array of objects + * @param {string} props.name - form radios collective name + * @param {(e: any) => void} [props.onChangeHandler] - when radios change + * @param {React.Dispatch>} [props.setAlert] - set an external alert dispatch + * @param {boolean} [props.flexRow] - if the radio and label are stacked on each other or side-by-side + * @param {string} [props.labelColor] - Label color using tailwind syntax + * @param {boolean} [props.baseText] - Font size regular + * @param {boolean} [props.smallText] - Font size smaller + * @param {string} [props.className] - Additional class names for the wrapper + */ function FormRadios({ radioValues , name , onChangeHandler , setAlert , flexRow , labelColor , baseText , smallText , className , }) { + try { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex items-start gap-4 flex-wrap " + (flexRow ? "" : " flex-col ") + (className ? className : ""), + children: radioValues.map((value, index)=>{ + const { payload , title , jsx } = value; + const radioPayload = payload === false ? payload : payload ? payload : title ? title : null; + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + className: "m-0" + (baseText ? " w-5 h-5" : smallText ? " w-4 h-4" : " w-6 h-6"), + type: "radio", + defaultChecked: value.default ? true : false, + name: name, + id: name + "_" + radioPayload, + onChange: (e)=>{ + if (setAlert) setAlert(null); + if (value.onChangeHandler) { + value.onChangeHandler(e); + } else if (onChangeHandler) { + onChangeHandler(e); + } + }, + value: typeof radioPayload == "string" ? radioPayload : undefined + }), + jsx ? jsx : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: name + "_" + radioPayload, + className: "text-lg m-0 " + (labelColor ? labelColor : "text-slate-800") + (baseText ? " text-base" : smallText ? " text-sm" : " text-lg"), + children: title + }) + ] + }, index + 1); + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log("ERROR in FormRadio =>", error); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: "Form Radio Error" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2378.js b/dsql-app/.local_dist/server/chunks/2378.js new file mode 100644 index 0000000..962983b --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2378.js @@ -0,0 +1,1495 @@ +"use strict"; +exports.id = 2378; +exports.ids = [2378]; +exports.modules = { + +/***/ 2378: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ CreatePageContent) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./components/form/FormInput.jsx + 2 modules +var FormInput = __webpack_require__(7901); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@tinymce/tinymce-react" +var tinymce_react_ = __webpack_require__(6451); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: external "@mui/icons-material/ViewTimelineTwoTone" +var ViewTimelineTwoTone_ = __webpack_require__(5139); +var ViewTimelineTwoTone_default = /*#__PURE__*/__webpack_require__.n(ViewTimelineTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/StyleTwoTone" +var StyleTwoTone_ = __webpack_require__(723); +var StyleTwoTone_default = /*#__PURE__*/__webpack_require__.n(StyleTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DifferenceTwoTone" +var DifferenceTwoTone_ = __webpack_require__(930); +var DifferenceTwoTone_default = /*#__PURE__*/__webpack_require__.n(DifferenceTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/Close" +var Close_ = __webpack_require__(4173); +var Close_default = /*#__PURE__*/__webpack_require__.n(Close_); +// EXTERNAL MODULE: external "@mui/material" +var material_ = __webpack_require__(5692); +;// CONCATENATED MODULE: ./components/su/components/RichText/ElementStyleModalContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {HTMLElement|null} props.targetElement + * @param {React.Dispatch>} props.setOpenStyleModal + */ function ElementStyleModalContent({ targetElement , setOpenStyleModal , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!targetElement) { + return null; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-stretch p-6 max-w-lg", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xl", + children: "Element Style" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-10 h-10 plain-text", + onClick: ()=>{ + setOpenStyleModal(false); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((Close_default()), {}) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-stretch p-2 bg-slate-100 rounded add-css-block", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "CSS key" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "CSS Value", + onKeyDownCapture: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (e.key?.match(/enter/i)) { + const firstChild = inputEl.closest(".add-css-block")?.children[0]; + const secondChild = inputEl.closest(".add-css-block")?.children[1]; + // @ts-ignore + const key = firstChild?.value; + // @ts-ignore + const value = secondChild?.value; + if (!key?.match(/./) || !value?.match(/./)) return; + targetElement.style[key] = value; + } + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + /** @type {HTMLButtonElement} */ // @ts-ignore + const buttonEl = e.target; + const firstChild = buttonEl.closest(".add-css-block")?.children[0]; + const secondChild = buttonEl.closest(".add-css-block")?.children[1]; + // @ts-ignore + const key = firstChild?.value; + // @ts-ignore + const value = secondChild?.value; + if (!key?.match(/./) || !value?.match(/./)) return; + targetElement.style[key] = value; + }, + children: "Add" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + const active = targetElement.removeAttribute("style"); + }, + className: "secondary grow", + children: "Reset" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.display = "flex"; + targetElement.style.alignItems = "center"; + targetElement.style.gap = "10px"; + }, + className: "outlined black grow", + children: "Flex" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.backgroundColor = "rgb(241 245 249)"; + }, + className: "outlined black grow", + children: "BG-Slate-100" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.backgroundColor = "#F6F4F8"; + }, + className: "outlined black grow", + children: "BG-Main-light" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.padding = "10px"; + }, + className: "outlined black grow", + children: "Padding-10px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.padding = "10px 20px"; + }, + className: "outlined black grow", + children: "Padding-10px-20px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.borderRadius = "5px"; + }, + className: "outlined black grow", + children: "Border-Radius-5px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.border = "1px solid rgb(241 245 249)"; + }, + className: "outlined black grow", + children: "Border-Slate-100" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.border = "1px solid rgb(226 232 240)"; + }, + className: "outlined black grow", + children: "Border-Slate-200" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + targetElement.style.border = "1px solid rgb(203 213 225)"; + }, + className: "outlined black grow", + children: "Border-Slate-300" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-xl mt-4", + children: "Add class Name" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-stretch p-2 bg-slate-100 rounded add-class-name-block", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "Class Name", + onKeyDownCapture: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const firstChild = inputEl.closest(".add-class-name-block")?.children[0]; + if (e.key?.match(/enter/i)) { + // @ts-ignore + const className = firstChild?.value; + if (!className?.match(/./)) return; + targetElement.classList.add(className); + } + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + /** @type {HTMLButtonElement} */ // @ts-ignore + const buttonEl = e.target; + const firstChild = buttonEl.closest(".add-class-name-block")?.children[0]; + // @ts-ignore + const className = firstChild?.value; + if (!className?.match(/./)) return; + targetElement.classList.add(className); + }, + children: "Add" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + /** @type {HTMLButtonElement} */ // @ts-ignore + const buttonEl = e.target; + const firstChild = buttonEl.closest(".add-class-name-block")?.children[0]; + // @ts-ignore + const className = firstChild?.value; + if (!className?.match(/./)) return; + targetElement.classList.remove(className); + }, + className: "outlined", + children: "Remove" + }) + ] + }), + targetElement?.nodeName?.match(/^a$/i) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-xl mt-4", + children: "Add URL" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-stretch p-2 bg-slate-100 rounded href-block", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "Class Name", + onKeyDownCapture: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const firstChild = inputEl.closest(".href-block")?.children[0]; + if (e.key?.match(/enter/i)) { + // @ts-ignore + const url = firstChild?.value; + if (!url?.match(/./)) return; + // @ts-ignore + targetElement.href = url; + } + }, + // @ts-ignore + defaultValue: targetElement?.href + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const buttonEl = e.target; + const firstChild = buttonEl.closest(".href-block")?.children[0]; + // @ts-ignore + const url = firstChild?.value; + if (!url?.match(/./)) return; + // @ts-ignore + targetElement.href = url; + }, + children: "Add" + }) + ] + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/components/RichText/fns.js +// @ts-check +/** + * Imports: Handle imports + */ /** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} params.targetElement + * @param {React.Dispatch>} params.setTargetElement + */ function duplicateNode({ editor , targetElement , setTargetElement }) { + /** + * Initialize variables + */ const editorWindow = editor.getWin(); + // const currentSelectionTextNode = editorWindow.getSelection(); + // const currentSelectionTextNode = targetElement; + if (!targetElement) return; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ // const TARGET_ELEMENT = currentSelectionTextNode.anchorNode.parentElement; + // const TARGET_ELEMENT = targetElement; + /** @type {HTMLElement} */ // @ts-ignore + const newNode = targetElement.cloneNode(true); + if (newNode.nodeName.match(/html|document|body/i)) return; + targetElement.insertAdjacentElement("afterend", newNode); + targetElement.classList.remove("target-node"); + setTargetElement(newNode); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} params.targetElement + * @param {React.Dispatch>} params.setTargetElement + */ function selectParent({ editor , targetElement , setTargetElement }) { + /** + * Initialize variables + */ const editorWindow = editor.getWin(); + // const currentNode = editorWindow.getSelection()?.anchorNode.parentElement; + const currentNode = targetElement; + if (!currentNode) return; + if (currentNode.nodeName.match(/html|document|body/i)) { + return; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ /** @type {HTMLElement | null} */ // @ts-ignore + let parentNode = currentNode.parentElement; + if (!parentNode) { + setTargetElement(currentNode); + targetNode({ + editor: editor, + node: currentNode, + setTargetElement + }); + } + if (parentNode?.nodeName.match(/html|document|body/i)) { + setTargetElement(currentNode); + targetNode({ + editor: editor, + node: currentNode, + setTargetElement + }); + } else if (parentNode) { + setTargetElement(parentNode); + targetNode({ + editor: editor, + node: parentNode, + setTargetElement + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} params.targetElement + * @param {React.Dispatch>} params.setTargetElement + */ function selectChild({ editor , targetElement , setTargetElement }) { + /** + * Initialize variables + */ const editorWindow = editor.getWin(); + // const currentNode = editorWindow.getSelection()?.anchorNode.parentElement; + const currentNode = targetElement; + if (!currentNode) return; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ /** @type {HTMLElement | null} */ // @ts-ignore + const childNode = currentNode.children[0]; + if (!childNode) { + setTargetElement(currentNode); + targetNode({ + editor: editor, + node: currentNode, + setTargetElement + }); + } else { + setTargetElement(childNode); + targetNode({ + editor: editor, + node: childNode, + setTargetElement + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {HTMLElement|null} params.targetElement + * @param {boolean} [params.back] + */ function moveElement({ targetElement , back }) { + /** + * Initialize variables + */ if (!targetElement) return; + const next = targetElement.nextElementSibling; + const prev = targetElement.previousElementSibling; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ if (!back && next) { + next.after(targetElement); + } else if (back && prev) { + prev.before(targetElement); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} params.targetElement + * @param {React.Dispatch>} params.setTargetElement + */ function selectNext({ editor , targetElement , setTargetElement }) { + /** + * Initialize variables + */ const currentNode = targetElement; + if (!currentNode) return; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ /** @type {HTMLElement | null} */ // @ts-ignore + const nextNode = currentNode.nextElementSibling; + if (!nextNode) { + setTargetElement(currentNode); + targetNode({ + editor: editor, + node: currentNode, + setTargetElement + }); + } else { + setTargetElement(nextNode); + targetNode({ + editor: editor, + node: nextNode, + setTargetElement + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} params.targetElement + * @param {React.Dispatch>} params.setTargetElement + */ function selectPrevious({ editor , targetElement , setTargetElement }) { + /** + * Initialize variables + */ const currentNode = targetElement; + if (!currentNode) return; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ /** @type {HTMLElement | null} */ // @ts-ignore + const previousNode = currentNode.previousElementSibling; + if (!previousNode) { + setTargetElement(currentNode); + targetNode({ + editor: editor, + node: currentNode, + setTargetElement + }); + } else { + setTargetElement(previousNode); + targetNode({ + editor: editor, + node: previousNode, + setTargetElement + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Duplicate Node Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {import("tinymce").Editor} params.editor + * @param {HTMLElement|null} [params.node] + * @param {React.Dispatch>} [params.setTargetElement] + */ function targetNode({ editor , node , setTargetElement }) { + /** + * Initialize variables + */ const editorDocument = editor.getDoc(); + editorDocument.querySelectorAll(".target-node").forEach((elt)=>{ + elt.classList.remove("target-node"); + }); + const editorWindow = editor.getWin(); + const currentNode = editorWindow.getSelection()?.anchorNode?.parentElement; + const targetElement = node ? node : currentNode ? currentNode : null; + if (!targetElement) return; + targetElement?.classList?.add("target-node"); + if (setTargetElement) setTargetElement(targetElement); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: external "@mui/icons-material/HighlightAltTwoTone" +var HighlightAltTwoTone_ = __webpack_require__(328); +var HighlightAltTwoTone_default = /*#__PURE__*/__webpack_require__.n(HighlightAltTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/AdsClickTwoTone" +var AdsClickTwoTone_ = __webpack_require__(371); +var AdsClickTwoTone_default = /*#__PURE__*/__webpack_require__.n(AdsClickTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DoDisturbAltTwoTone" +var DoDisturbAltTwoTone_ = __webpack_require__(9361); +var DoDisturbAltTwoTone_default = /*#__PURE__*/__webpack_require__.n(DoDisturbAltTwoTone_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/su/components/RichText/HTMLSnippetsModalContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {HTMLElement?} props.targetElement + * @param {React.Dispatch>} props.setTargetElement + * @param {import("tinymce").Editor} props.editor + * @param {React.Dispatch>} props.setOpenSnippetsModal + */ function HTMLSnippetsModalContent({ targetElement , setTargetElement , editor , setOpenSnippetsModal , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(true); + const [snippets, setSnippets] = external_react_default().useState([]); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/docs/get-snippets", { + method: "post", + body: {} + }).then((res)=>{ + if (res.success) { + setSnippets(res.result); + setLoading(false); + } + }); + }, []); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(material_.Paper, { + className: "m-auto p-6 flex flex-col max-w-xl w-full max-h-[90vh] overflow-y-auto relative", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xl", + children: "Snippets" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-10 h-10 plain-text", + onClick: ()=>{ + setOpenSnippetsModal(false); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((Close_default()), {}) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap relative w-full min-h-[100px] items-start", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + snippets && Array.isArray(snippets) && snippets[0] && snippets.map((snippet, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col w-full items-start p-4 border border-slate-200 border-solid rounded cursor-pointer hover:shadow-lg transition-all hover:bg-slate-100", + onClick: (e)=>{ + if (targetElement) { + // const parser = new DOMParser(); + // const parsedNode = parser.parseFromString(Object.values(snippet)[0], "text/html"); + // const newElement = parsedNode.body.firstChild + const newElement = document.createElement("div"); + newElement.innerHTML = Object.values(snippet)[0]; + /** @type {any} */ const targetNewElement = newElement.firstChild; + if (targetNewElement) { + targetElement.appendChild(targetNewElement); + targetNode({ + editor: editor, + node: targetNewElement, + setTargetElement: setTargetElement + }); + } + setOpenSnippetsModal(false); + } else { + editor.insertContent(Object.values(snippet)[0], {}); + setOpenSnippetsModal(false); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-lg", + children: Object.keys(snippet)[0] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full block border border-slate-300 border-solid rounded-sm", + dangerouslySetInnerHTML: { + __html: Object.values(snippet)[0] + } + }) + ] + }, index); + }) + ] + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +// EXTERNAL MODULE: external "@mui/icons-material/SkipNextTwoTone" +var SkipNextTwoTone_ = __webpack_require__(282); +var SkipNextTwoTone_default = /*#__PURE__*/__webpack_require__.n(SkipNextTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/SkipPreviousTwoTone" +var SkipPreviousTwoTone_ = __webpack_require__(3729); +var SkipPreviousTwoTone_default = /*#__PURE__*/__webpack_require__.n(SkipPreviousTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DeleteTwoTone" +var DeleteTwoTone_ = __webpack_require__(6502); +var DeleteTwoTone_default = /*#__PURE__*/__webpack_require__.n(DeleteTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/TextRotateVerticalTwoTone" +var TextRotateVerticalTwoTone_ = __webpack_require__(4864); +var TextRotateVerticalTwoTone_default = /*#__PURE__*/__webpack_require__.n(TextRotateVerticalTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/TextRotateUpTwoTone" +var TextRotateUpTwoTone_ = __webpack_require__(1358); +var TextRotateUpTwoTone_default = /*#__PURE__*/__webpack_require__.n(TextRotateUpTwoTone_); +;// CONCATENATED MODULE: ./components/su/components/RichText/RichTextExtensionBlock.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + + + + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {React.MutableRefObject} props.editorRef + */ function RichTextExtensionBlock({ editorRef }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[targetElement:HTMLElement | null, setTargetElement: React.Dispatch>]} */ // @ts-ignore + const [targetElement, setTargetElement] = external_react_default().useState(null); + const [openStyleModal, setOpenStyleModal] = external_react_default().useState(false); + const [openSnippetsModal, setOpenSnippetsModal] = external_react_default().useState(false); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "absolute top-[60px] z-50 -left-[38px] w-[40px] flex flex-col items-end", + style: { + boxShadow: "0 0 40px rgba(15, 23, 42, 0.2)" + }, + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + column: true, + className: "gap-[1px]", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + targetNode({ + editor: editorRef.current, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button secondary", + children: /*#__PURE__*/ jsx_runtime_.jsx((AdsClickTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + moveElement({ + targetElement: targetElement, + back: true + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button dark", + children: /*#__PURE__*/ jsx_runtime_.jsx((TextRotateUpTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + moveElement({ + targetElement: targetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button dark", + children: /*#__PURE__*/ jsx_runtime_.jsx((TextRotateVerticalTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + setOpenSnippetsModal(true); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((ViewTimelineTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + setOpenStyleModal(true); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((StyleTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + duplicateNode({ + editor: editorRef.current, + targetElement, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((DifferenceTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + selectParent({ + editor: editorRef.current, + targetElement, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((HighlightAltTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + selectChild({ + editor: editorRef.current, + targetElement, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((HighlightAltTwoTone_default()), { + className: "rotate-180" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + selectPrevious({ + editor: editorRef.current, + targetElement, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((SkipPreviousTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + selectNext({ + editor: editorRef.current, + targetElement, + setTargetElement + }); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button", + children: /*#__PURE__*/ jsx_runtime_.jsx((SkipNextTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + if (targetElement) { + // @ts-ignore + const parentElement = targetElement.parentNode; + parentElement.removeChild(targetElement); + targetNode({ + editor: editorRef.current, + node: parentElement, + setTargetElement + }); + } + }, + style: { + width: "40px", + height: "40px" + }, + className: "button bg-red-500", + children: /*#__PURE__*/ jsx_runtime_.jsx((DeleteTwoTone_default()), {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + onClick: ()=>{ + const editorDocument = editorRef.current.getDoc(); + editorDocument.querySelectorAll(".target-node").forEach((elt)=>{ + elt.classList.remove("target-node"); + }); + // @ts-ignore + setTargetElement(null); + }, + style: { + width: "40px", + height: "40px" + }, + className: "button white", + children: /*#__PURE__*/ jsx_runtime_.jsx((DoDisturbAltTwoTone_default()), { + className: "rotate-180" + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(material_.Drawer, { + open: openStyleModal, + onClose: ()=>{ + setOpenStyleModal(false); + }, + anchor: "right", + children: /*#__PURE__*/ jsx_runtime_.jsx(ElementStyleModalContent, { + targetElement: targetElement, + setOpenStyleModal: setOpenStyleModal + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(material_.Modal, { + open: openSnippetsModal, + onClose: ()=>{ + setOpenSnippetsModal(false); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(HTMLSnippetsModalContent, { + targetElement: targetElement, + setTargetElement: setTargetElement, + editor: editorRef.current, + setOpenSnippetsModal: setOpenSnippetsModal + }) + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/components/RichText/DocsRichTextBlock.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {any} [props.blockObject] + * @param {string} [props.placeholder] + * @param {React.MutableRefObject} [props.editorRef] + * @param {number} [props.height] + * @param {boolean} [props.extend] + */ function DocsRichTextBlock({ user , blockObject , placeholder , editorRef , height , extend , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(tinymce_react_.Editor, { + tinymceScriptSrc: "/tinymce/tinymce.min.js", + onInit: (evt, editor)=>{ + if (extend) { + const editorBody = editor.getBody(); + editorBody.style.padding = "40px"; + editorBody.className = "RTE-DOCS"; + } + if (editorRef) { + editorRef.current = editor; + } + }, + initialValue: blockObject && blockObject["content"] ? blockObject["content"] : "", + init: { + height: height ? height : 400, + width: "100%", + relative_urls: false, + remove_script_host: false, + menubar: false, + plugins: extend ? [ + "advlist", + "autolink", + "lists", + "link", + "image", + "charmap", + "anchor", + "searchreplace", + "visualblocks", + "code", + "fullscreen", + "insertdatetime", + "media", + "table", + "preview", + "help", + "wordcount", + "codesample", + ] : [ + "link" + ], + toolbar: extend ? "undo redo | blocks | " + "bold italic forecolor | codesample link image | alignleft aligncenter " + "alignright alignjustify | bullist numlist outdent indent | " + "removeformat" : "undo redo | blocks | link", + content_style: "body { font-family:Helvetica,Arial,sans-serif; font-size:18px }", + placeholder: placeholder ? placeholder : "Type something ...", + content_css: extend ? "/styles/tiny.css" : undefined, + statusbar: extend ? true : false + } + }), + extend && editorRef && /*#__PURE__*/ jsx_runtime_.jsx(RichTextExtensionBlock, { + editorRef: editorRef + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +;// CONCATENATED MODULE: ./components/su/docs/CreatePageContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let timeout; +/** + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} [props.data] - Page content available + * @param {import("@/package-shared/types").UserType} props.user + */ function CreatePageContent({ data , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isUpdate = data?.title ? true : false; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [pageLevel, setPageLevel] = external_react_default().useState(data?.level); + const [pageOrder, setPageOrder] = external_react_default().useState(data?.page_order); + /** @type {[ targetParentPage: any, setTargetParentPage: React.Dispatch> ]} */ // @ts-ignore + const [parentPages, setParentPages] = external_react_default().useState(null); + /** @type {[ targetParentPage: any, setTargetParentPage: React.Dispatch> ]} */ // @ts-ignore + const [targetParentPage, setTargetParentPage] = external_react_default().useState(null); + /** @type {React.MutableRefObject} */ const descEditorRef = external_react_default().useRef(); + /** @type {React.MutableRefObject} */ const contentEditorRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + if (parseInt(pageLevel) > 1) { + window.clearTimeout(timeout); + timeout = window.setTimeout(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/docs/grab-parent-pages", { + method: "post", + body: { + pagesLevel: parseInt(pageLevel) - 1, + currentPageId: data?.id + } + }).then((res)=>{ + if (res.success && res.result && Array.isArray(res.result) && res.result[0]) { + setParentPages(res.result); + if (data.parent_id) { + const targetFilterPage = res.result.filter((/** @type {any} */ pg)=>pg.id == data.parent_id); + if (targetFilterPage[0]) { + setTargetParentPage(targetFilterPage[0]); + } else { + setTargetParentPage(res.result[0]); + } + } else { + setTargetParentPage(res.result[0]); + } + } + }); + }, 500); + } else { + setParentPages(null); + setTargetParentPage(null); + } + }, [ + pageLevel + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "items-start justify-start p-6", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "mb-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: isUpdate ? "Update page" : "Create a new Docs Page" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "mb-4", + children: /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper flex-col items-stretch gap-10 w-full relative", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + /** @type {HTMLInputElement} */ // @ts-ignore + const titleInputEl = formEl["title"]; + const editorDocument = contentEditorRef.current?.getDoc(); + const descEditorDocument = descEditorRef.current?.getDoc(); + editorDocument?.querySelectorAll(".target-node").forEach((tnode)=>tnode.classList.remove("target-node")); + /** + * ### Update URL + * @param {HTMLAnchorElement} anchor + */ function updateUrl(anchor) { + const url = anchor.href; + if (url?.match(/\~/)) { + anchor.href = url.replace(/.*?\~\//, "/"); + } + if (url?.match(/\.\.\//)) { + anchor.href = url.replace(/.*?\.\.\//, "/"); + } + } + editorDocument?.querySelectorAll("a").forEach((anchor)=>{ + updateUrl(anchor); + }); + descEditorDocument?.querySelectorAll("a").forEach((anchor)=>{ + updateUrl(anchor); + }); + const description = descEditorRef.current?.getContent(); + const content = contentEditorRef.current?.getBody().innerHTML; + const inner_text = contentEditorRef.current?.getBody().innerText; + const title = titleInputEl.value; + /** @type {any} */ let fetchObject = { + title, + description, + content, + text_content: inner_text, + level: pageLevel, + page_order: pageOrder + }; + if (isUpdate) { + fetchObject.id = data.id; + } + if (targetParentPage?.id) { + fetchObject.parent_id = targetParentPage.id; + } + (0,fetchApi/* default */.Z)(`/api/admin/docs/${isUpdate ? "update-page" : "add-page"}`, { + method: "post", + body: fetchObject + }).then((res)=>{ + if (res.success) { + // window.location.pathname = `/su/docs`; + window.location.reload(); + } else { + alert("Operation Failed!"); + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + }, + className: "flex flex-col gap-4 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + placeholder: "Enter a title", + fontSize: "30px", + name: "title", + defaultValue: isUpdate ? data.title : null + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + numberText: true, + placeholder: "Level", + defaultValue: isUpdate ? pageLevel : "1", + maxWidth: "140px", + minValue: 1, + maxValue: 4, + step: 1, + name: "page-level", + title: "Page Level", + setValue: setPageLevel + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + numberText: true, + placeholder: "Level", + defaultValue: isUpdate ? pageOrder : "1", + maxWidth: "140px", + minValue: 1, + step: 1, + name: "page-order", + title: "Page Order", + setValue: setPageOrder + }), + parentPages && Array.isArray(parentPages) && /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: parentPages.map((pageObject)=>{ + return { + title: pageObject.title, + payload: pageObject.id, + default: targetParentPage?.id == pageObject.id + }; + }), + title: "Parent Page", + required: true, + onChangeHandler: (e)=>{ + const targetPage = parentPages.filter((pg)=>pg.id == e.target.value); + if (targetPage[0]) { + setTargetParentPage(targetPage[0]); + } else { + window.alert("No Matching parent page!"); + } + } + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(DocsRichTextBlock, { + placeholder: "Describe this page briefly", + editorRef: descEditorRef, + blockObject: isUpdate ? { + content: data.description + } : null, + height: 200 + }), + /*#__PURE__*/ jsx_runtime_.jsx(DocsRichTextBlock, { + placeholder: "Page Content", + editorRef: contentEditorRef, + blockObject: isUpdate ? { + content: data.content + } : null, + height: 600, + extend: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + children: isUpdate ? "Update Page" : "Add Page" + }) + ] + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2434.js b/dsql-app/.local_dist/server/chunks/2434.js new file mode 100644 index 0000000..a334067 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2434.js @@ -0,0 +1,151 @@ +"use strict"; +exports.id = 2434; +exports.ids = [2434]; +exports.modules = { + +/***/ 1095: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ CodeBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6843); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9174); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * content: string, + * language: string, + * style?: React.CSSProperties, + * }} props - React component props including { children } + */ function CodeBlock({ content , language , style }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const [open, setOpen] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const handleClick = ()=>{ + setOpen(true); + }; + /** + * ## Handle Close + * @param {*} event + * @param {*} reason + * @returns + */ const handleClose = (event, reason)=>{ + if (reason === "clickaway") { + return; + } + setOpen(false); + }; + const action = /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray", + style: { + border: "none", + padding: "2px", + width: "20px", + height: "20px", + color: "white" + }, + // @ts-ignore + onClick: handleClose, + children: "✖" + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("pre", { + className: `language-${language ? language : "javascript"} w-full overflow-hidden code-block relative max-w-4xl`, + style: style ? style : {}, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("code", { + className: `w-full`, + style: { + wordBreak: "break-all" + }, + children: content + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined absolute top-2 right-2 z-20 copy-code hover:opacity-50", + style: { + padding: "2px", + border: "none" + }, + onClick: (/** @type {any} */ e)=>{ + navigator.clipboard.writeText(content).then(()=>{ + handleClick(); + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2___default()), { + fontSize: "small", + color: "action" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3___default()), { + open: open, + autoHideDuration: 2000, + onClose: handleClose, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "h-full text-white px-4 py-2 justify-between rounded", + style: { + maxWidth: "250px", + width: "250px", + backgroundColor: "#0b8862" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Code Copied!" + }), + action + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2435.js b/dsql-app/.local_dist/server/chunks/2435.js new file mode 100644 index 0000000..4d19e09 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2435.js @@ -0,0 +1,348 @@ +"use strict"; +exports.id = 2435; +exports.ids = [2435]; +exports.modules = { + +/***/ 2435: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ SuDocsPageListContent) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "@mui/icons-material/ArticleTwoTone" +var ArticleTwoTone_ = __webpack_require__(1891); +var ArticleTwoTone_default = /*#__PURE__*/__webpack_require__.n(ArticleTwoTone_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/AccountTreeTwoTone" +var AccountTreeTwoTone_ = __webpack_require__(4118); +var AccountTreeTwoTone_default = /*#__PURE__*/__webpack_require__.n(AccountTreeTwoTone_); +;// CONCATENATED MODULE: ./components/su/components/PageCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").MYSQL_docs_pages_table_def} props.docPageObject + */ function PageCard({ docPageObject }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ childPages: import("@/package-shared/types").MYSQL_docs_pages_table_def[], setChildPages: React.Dispatch> ]} */ // @ts-ignore + const [childPages, setChildPages] = external_react_default().useState([]); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/docs/get-child-pages", { + method: "post", + body: { + pageId: docPageObject.id + } + }).then((res)=>{ + if (res.success) { + setChildPages(res.result); + } + }); + }, []); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card col relative cursor-pointer", + onClick: (e)=>{ + // @ts-ignore + if (e.target?.closest(".cancel-link")) { + e.preventDefault(); + } else { + window.location.pathname = `/su/docs/pages/${docPageObject.id}`; + } + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((ArticleTwoTone_default()), { + color: "inherit", + className: "opacity-40 text-gray-600" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 relative z-10", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "title", + children: docPageObject.title + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "-my-3", + dangerouslySetInnerHTML: { + __html: docPageObject.description || "" + } + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "ml-auto cancel-link", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: ()=>{ + window.location.href = `/su/docs/edit-page?id=${docPageObject.id}`; + }, + className: "outlined small-text light-gray", + children: "Edit Page" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: ()=>{ + if (window.confirm("Delete this page?")) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/admin/docs/delete-page", { + method: "post", + body: docPageObject + }).then((res)=>{ + if (res.success) { + window.location.reload(); + } else {} + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + }, + className: "outlined small-text light-gray", + children: "Delete Page" + }) + ] + }) + ] + }), + childPages && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "-mt-[40px] pt-[40px] ml-[10px] pl-[20px] border-0 border-l border-slate-200 border-solid w-full flex-col items-start cancel-link", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((AccountTreeTwoTone_default()), { + className: "opacity-20", + fontSize: "small" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300 font-semibold", + children: "Children Pages" + }) + ] + }), + childPages.map((childPage, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card w-full", + onClick: ()=>{ + window.location.pathname = `/su/docs/pages/${childPage.id}`; + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((ArticleTwoTone_default()), { + color: "inherit", + className: "opacity-40 text-gray-500" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: childPage.title + }) + ] + }, index); + }) + ] + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +;// CONCATENATED MODULE: ./components/su/docs/SuDocsPageListContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Super User Page List Component + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + */ function SuDocsPageListContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { env } = data; + /** @type {import("@/package-shared/types").MYSQL_docs_pages_table_def[]} */ const docPages = data.docPages; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * ## Persist Function + * @param {boolean} pull + */ function persist(pull) { + if (window.confirm(pull ? "Update Docs DB from JSON file?" : "Update docs json file?")) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/admin/docs/persist", { + method: "post", + body: { + pull + } + }).then((res)=>{ + if (res.success) { + window.alert(pull ? "Docs database table Updated Sucessfully!" : "JSON data written Successfully!"); + } else { + window.alert("Operation failed!"); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }).catch((err)=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + } + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "items-start justify-start p-6", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex items-center justify-between w-full mb-6", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Documentation Pages" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/su/docs/create-page`, + className: "button", + children: "Create Page" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray", + onClick: ()=>{ + persist(false); + }, + children: "Push" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray", + onClick: ()=>{ + persist(true); + }, + children: "Pull" + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "paper flex-col items-stretch gap-10 w-full", + children: docPages.map((docPageObject, index)=>/*#__PURE__*/ jsx_runtime_.jsx(PageCard, { + docPageObject: docPageObject + }, index)) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2630.js b/dsql-app/.local_dist/server/chunks/2630.js new file mode 100644 index 0000000..17385ca --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2630.js @@ -0,0 +1,77 @@ +"use strict"; +exports.id = 2630; +exports.ids = [2630]; +exports.modules = { + +/***/ 2630: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ importExportTableDataFn) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const serverError = __webpack_require__(2163); +const DB_HANDLER = __webpack_require__(2224); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} ExportTableDataFnReturn + * @property {any} [tableData] + */ /** + * ============================================================================== + * @param {Object} params - Single object parameter + * @param {"export" | "import"} params.paradigm + * @param {string | number} params.userId + * @param {string} params.dbName + * @param {string} params.tableName + * @param {any} params.payload + * @param {"JSON" | "base64" | "object"} params.payloadType + * @return {Promise} + */ async function importExportTableDataFn({ paradigm , userId , dbName , tableName , payload , payloadType , }) { + /** @type {ExportTableDataFnReturn} */ let returnObject = {}; + try { + const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${userId}_${dbName.replace(/ /g, "")}`; + switch(paradigm){ + case "export": + const tableData = await DB_HANDLER(`SELECT * FROM \`${dbFullName}\`.\`${tableName}\``); + returnObject["tableData"] = tableData; + break; + case "import": + const jsonData = payloadType == "base64" ? Buffer.from(payload, "base64").toString() : payloadType == "JSON" ? payload : payload; + const writeData = payloadType === "object" ? payload : JSON.parse(jsonData); + for(let i = 0; i < writeData.length; i++){ + const dataToWrite = writeData[i]; + const newEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + data: dataToWrite, + dbFullName: dbFullName, + tableName: tableName, + dbContext: "Dsql User", + paradigm: "Full Access", + duplicateColumnName: "id", + duplicateColumnValue: dataToWrite?.id, + update: true + }); + if (newEntry.error) { + throw new Error(newEntry.error); + } + } + break; + default: + return null; + } + return returnObject; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/importExportTableDataFn", + message: error.message + }); + return null; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2733.js b/dsql-app/.local_dist/server/chunks/2733.js new file mode 100644 index 0000000..a49c0ea --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2733.js @@ -0,0 +1,118 @@ +"use strict"; +exports.id = 2733; +exports.ids = [2733]; +exports.modules = { + +/***/ 2733: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UserImage) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6718); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {string | import("@/package-shared/types").ImageObjectType} props.userImage + * @param {React.Dispatch>} props.setUserImage + * @param {Object} [props.database] + * @param {Object} [props.className] + */ function UserImage({ user , userImage , setUserImage , database , className , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const imagePreviewRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card no-hover col" + (className ? " " + className : ""), + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "bg-white rounded-full overflow-hidden w-24 h-24", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: userImage ? typeof userImage === "string" ? userImage : userImage.imageBase64Full : "/images/user_images/user-preset.png", + alt: "Database Image", + width: 100, + className: "w-full h-full object-cover", + // @ts-ignore + ref: imagePreviewRef, + "data-imagepreview": "image" + }) + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full flex-col image-selector-wrapper", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "button outlined secondary w-full whitespace-normal", + onClick: (e)=>{ + e.target// @ts-ignore + .closest(".image-selector-wrapper").querySelector("input").click(); + }, + children: "Upload Image" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + accept: ".png,.jpg,.jpeg,.webp", + placeholder: "Choose Database Image", + className: "hidden", + onChange: async (e)=>{ + let imageData = await (0,_functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({ + // @ts-ignore + imageInputFile: e.target.files[0], + maxWidth: 400 + }); + setUserImage(imageData); + } + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/2896.js b/dsql-app/.local_dist/server/chunks/2896.js new file mode 100644 index 0000000..86f5292 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/2896.js @@ -0,0 +1,241 @@ +"use strict"; +exports.id = 2896; +exports.ids = [2896]; +exports.modules = { + +/***/ 9350: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DocsGenereicHero) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.title + * @param {string} props.description + */ function DocsGenereicHero({ title , description }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "py-14", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full gap-10 justify-between items-start flex-col lg:flex-row relative z-10", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start max-w-[740px] text-left", + style: { + minWidth: "45%" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "m-0 leading-tight", + children: title + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-normal text-xl -my-4", + dangerouslySetInnerHTML: { + __html: description + } + }) + ] + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/grid.webp", + alt: "Dotted image background", + className: "absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 1273: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const serverError = __webpack_require__(7023); +const mysql = __webpack_require__(2261); +const path = __webpack_require__(1017); +const SSL_DIR = "/app/ssl"; +const connection = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + database: process.env.DSQL_DB_NAME, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +// const connection = mysql.createConnection({ +// host: process.env.DSQL_DB_HOST, +// user: process.env.DSQL_DB_USERNAME, +// password: process.env.DSQL_DB_PASSWORD, +// database: process.env.DSQL_DB_NAME, +// charset: "utf8mb4", +// }); +// connection.on("error", (err) => { +// console.log("CONNECTION STATE: ", connection.state); +// console.log(err.message); +// }); +// connection.on("connect", () => { +// console.log("CONNECTION ACTIVE: ", connection.state); +// }); +// connection.on("end", () => { +// console.log("CONNECTION DISCONNECTED: ", connection.state); +// }); +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Main DB Handler Function + * ============================================================================== + * @async + * + * @param {any} args + * @returns {Promise} + */ module.exports = async function dbHandler(...args) { + "production"?.match(/dev/) && fs.appendFileSync("./.tmp/sqlQuery.sql", args[0] + "\n" + Date() + "\n\n\n", "utf8"); + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + results = await new Promise((resolve, reject)=>{ + // @ts-ignore + connection.query(...args, (error, result, fields)=>{ + if (error) { + resolve({ + error: error.message + }); + } else { + resolve(result); + } + }); + // connection.on("error", (err) => { + // console.log("CONNECTION STATE: ", connection.state); + // console.log(err.message); + // }); + // connection.on("connect", () => { + // console.log("CONNECTION ACTIVE: ", connection.state); + // }); + // connection.on("end", () => { + // console.log("CONNECTION DISCONNECTED: ", connection.state); + // }); + /** ********************* Clean up */ }); + await connection.end(); + // connection.query(...args, (error, result, fields) => { + // if (error) { + // resolve({ error: error.message }); + // } else { + // resolve(result); + // } + // connection.end() + // }); + // connectionPool.query(...args, (error, result, fields) => { + // if (error) { + // resolve({ error: error.message }); + // } else { + // resolve(result); + // } + // }); + // connectionPool.getConnection(function (err, connection) { + // if (err) { + // resolve({ error: err.message }); + // connection.release(); + // return; + // } + // connection.query(...args, (error, result, fields) => { + // if (error) { + // resolve({ error: error.message }); + // } else { + // resolve(result); + // } + // connection.release(); + // }); + // }); + } catch (/** @type {any} */ error) { + fs.appendFileSync("./.tmp/dbErrorLogs.txt", JSON.stringify(error, null, 4) + "\n" + Date() + "\n\n\n", "utf8"); + results = null; + serverError({ + component: "dbHandler", + message: error.message + }); + // try { + // connection.end(); + // } catch (error) { + // console.log("ERROR in dbHandler Function =>", error.message); + // } + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results) { + return JSON.parse(JSON.stringify(results)); + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/3017.js b/dsql-app/.local_dist/server/chunks/3017.js new file mode 100644 index 0000000..4488743 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/3017.js @@ -0,0 +1,53 @@ +"use strict"; +exports.id = 3017; +exports.ids = [3017]; +exports.modules = { + +/***/ 3017: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +// const handleNodemailer = require("./handleNodemailer"); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * user?: { id?: number | string, first_name?: string, last_name?: string, email?: string } & *, + * message: string, + * component?: string, + * noMail?: boolean, + * }} params - user id + * + * @returns {Promise} + */ module.exports = async function serverError({ user , message , component , noMail , }) { + const log = `🚀 SERVER ERROR ===========================\nUser Id: ${user?.id}\nUser Name: ${user?.first_name} ${user?.last_name}\nUser Email: ${user?.email}\nError Message: ${message}\nComponent: ${component}\nDate: ${Date()}\n========================================`; + if (!fs.existsSync(`./.tmp/error.log`)) { + fs.writeFileSync(`./.tmp/error.log`, "", "utf-8"); + } + const initialText = fs.readFileSync(`./.tmp/error.log`, "utf-8"); + fs.writeFileSync(`./.tmp/error.log`, log); + fs.appendFileSync(`./.tmp/error.log`, `\n\n\n\n\n${initialText}`); +// if (process.env.NODE_ENV?.match(/production/) && !noMail) { +// handleNodemailer({ +// to: "benoti.san@gmail.com", +// subject: "SERVER Error in Datasquirel Application", +// text: "An Error occured in Datasquirel Application Server Side", +// html: log, +// }); +// } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/3314.js b/dsql-app/.local_dist/server/chunks/3314.js new file mode 100644 index 0000000..dcb0193 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/3314.js @@ -0,0 +1,39 @@ +"use strict"; +exports.id = 3314; +exports.ids = [3314]; +exports.modules = { + +/***/ 2527: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ grabUserSchemaData) +/* harmony export */ }); +// @ts-check +const serverError = __webpack_require__(2317); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * @param {Object} params + * @param {string | number} params.userId + * @returns {DSQL_DatabaseSchemaType[] | null} + */ function grabUserSchemaData({ userId }) { + try { + const userSchemaFilePath = path.resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${userId}/main.json`); + const userSchemaData = JSON.parse(fs.readFileSync(userSchemaFilePath, "utf-8")); + return userSchemaData; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/grabUserSchemaData", + message: error.message + }); + return null; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/3403.js b/dsql-app/.local_dist/server/chunks/3403.js new file mode 100644 index 0000000..24afdb4 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/3403.js @@ -0,0 +1,109 @@ +"use strict"; +exports.id = 3403; +exports.ids = [3403]; +exports.modules = { + +/***/ 3403: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +let DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_READ_ONLY_USERNAME, + password: process.env.DSQL_DB_READ_ONLY_PASSWORD, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {"Full Access" | "FA" | "Read Only"} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ function DSQL_USER_DB_HANDLER({ paradigm , database , queryString , queryValues , }) { + try { + return new Promise((resolve, reject)=>{ + const fullAccess = paradigm?.match(/full.access|^fa$/i) ? true : false; + try { + if (fullAccess) { + DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_FULL_ACCESS_USERNAME, + password: process.env.DSQL_DB_FULL_ACCESS_PASSWORD, + database: database, + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } + }); + } else { + DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_READ_ONLY_USERNAME, + password: process.env.DSQL_DB_READ_ONLY_PASSWORD, + database: database, + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } + }); + } + /** + * ### Run query Function + * @param {any} results + */ function runQuery(results) { + DSQL_USER.end(); + resolve(JSON.parse(JSON.stringify(results))); + } + /** + * ### Query Error + * @param {any} err + */ function queryError(err) { + DSQL_USER.end(); + resolve({ + error: err.message, + queryStringGenerated: queryString, + queryValuesGenerated: queryValues, + sql: err.sql + }); + } + if (queryValues && Array.isArray(queryValues) && queryValues[0]) { + DSQL_USER.query(queryString, queryValues).then(runQuery).catch(queryError); + } else { + DSQL_USER.query(queryString).then(runQuery).catch(queryError); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + fs.appendFileSync("./.tmp/dbErrorLogs.txt", error.message + "\n" + Date() + "\n\n\n", "utf8"); + resolve({ + error: error.message + }); + } + }); + } catch (/** @type {any} */ error) { + return { + success: false, + error: error.message + }; + } +} +module.exports = DSQL_USER_DB_HANDLER; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/370.js b/dsql-app/.local_dist/server/chunks/370.js new file mode 100644 index 0000000..d7a37c5 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/370.js @@ -0,0 +1,86 @@ +"use strict"; +exports.id = 370; +exports.ids = [370]; +exports.modules = { + +/***/ 370: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const http = __webpack_require__(3685); +const DB_HANDLER = __webpack_require__(9395); +const decrypt = __webpack_require__(5304); +const fs = __webpack_require__(7147); +const EXPIRY_TIME = 1000 * 60 * 60 * 24 * 1 * 7; // 7 days +/** + * @async + * @param {import("next").NextApiRequest | http.IncomingMessage & { cookies: Partial<{ [key: string]: string; }>; +}} req - https request object + * @param {import("next").NextApiResponse | http.ServerResponse} res - https response object + * @param {boolean | null} [csrf] - csrf key + * @param {any} [query] - query object + * + * @returns {Promise<(import("@/package-shared/types").UserType | null)>} + */ module.exports = async function userAuth(req, res, csrf, query) { + /** ********************* Check for existence of required cookie */ if (!req.cookies?.datasquirelAuthKey?.match(/./)) { + // console.log("No datasquirel key cookie present"); + return null; + } + /** ********************* Grab the payload */ let userPayload = decrypt(req.cookies.datasquirelAuthKey); + /** ********************* Return if no payload */ if (!userPayload) { + // console.log("Couldn't Decrypt cookie"); + return null; + } + /** ********************* Parse the payload */ let userObject = JSON.parse(userPayload); + const { user_type } = userObject; + if (!userObject.csrf_k) { + // console.log("No CSRF_K in decrypted payload"); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (csrf && // @ts-ignore + !req.headers["x-csrf-auth"]?.match(new RegExp(`${userObject.csrf_k}`))) { + // console.log("CSRF_K requested but does not match payload"); + return null; + } + const allowedAuthKeysPath = process.env.DSQL_USER_LOGIN_KEYS_PATH; + if (!allowedAuthKeysPath) { + console.log(`DSQL_USER_LOGIN_KEYS_PATH env variable not found. Please set this variable.`); + return null; + } + if (csrf && !fs.existsSync(`${allowedAuthKeysPath}/${userObject.csrf_k}`)) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* check user verification */ if (userObject.verification_status == 0 && !csrf) { + let currentVerificationStatus = await DB_HANDLER(`SELECT verification_status FROM users WHERE id='${userObject.id}'`); + if (currentVerificationStatus && currentVerificationStatus[0] && currentVerificationStatus[0].verification_status == 1) { + // userObject = await reAuthUser({ userId: userObject.id, res }); + res.setHeader("Set-Cookie", [ + `user_refresh=1` + ]); + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (userObject?.date && Date.now() - userObject.date > EXPIRY_TIME) { + // console.log("Cookie expired"); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* return user object */ return userObject; +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/3863.js b/dsql-app/.local_dist/server/chunks/3863.js new file mode 100644 index 0000000..007ac86 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/3863.js @@ -0,0 +1,157 @@ +"use strict"; +exports.id = 3863; +exports.ids = [3863]; +exports.modules = { + +/***/ 3863: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UserListCard) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5449); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_users_table_def} props.userObject + * @param {React.Dispatch>} props.setTargetUser + * @param {string} [props.paradigm] + */ function UserListCard({ userObject , setTargetUser , paradigm }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userName = (()=>{ + if (paradigm?.match(/invited/)) { + return `${userObject.inviteeFirstName} ${userObject.inviteeLastName} (${userObject.inviteeEmail})`; + } + return `${userObject.first_name} ${userObject.last_name} (${userObject.email})`; + })(); + const userImage = (()=>{ + if (paradigm?.match(/invited/)) { + return `${userObject.inviteeImage}`; + } + return `${userObject.image_thumbnail}`; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card no-hover items-center " + (paradigm?.match(/invited/) ? " green green-bg" : " primary"), + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: userImage, + className: "w-8 h-8 rounded-full object-cover bg-slate-200", + onError: (e)=>{ + // @ts-ignore + e.target.src = "/images/user_images/user-preset-thumbnail.png"; + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-sm font-semibold", + children: userName + }), + userObject?.user_priviledge?.match(/./) && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-sm ml-auto text-slate-900/50", + children: [ + "Priviledges:", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-slate-600 font-semibold", + children: userObject.user_priviledge.split("|").join(" | ") + }) + ] + }), + !paradigm?.match(/invited/) && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined text-xs px-3 py-1", + onClick: (e)=>{ + setTargetUser(userObject); + setTimeout(()=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .openPopup */ .Mw)("target-user-popup"); + }, 200); + }, + children: "Edit User Access" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined text-xs px-3 py-1", + onClick: (e)=>{ + setLoading(true); + if (window.confirm("Delete this user")) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/deleteUserUser", { + method: "post", + body: { + ...userObject + } + }, true).then((res)=>{ + setTimeout(()=>{ + setLoading(false); + }, 500); + window.location.reload(); + }); + } + }, + children: "Delete User" + }) + ] + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/3974.js b/dsql-app/.local_dist/server/chunks/3974.js new file mode 100644 index 0000000..4a2da4a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/3974.js @@ -0,0 +1,1199 @@ +"use strict"; +exports.id = 3974; +exports.ids = [3974]; +exports.modules = { + +/***/ 3726: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ AddDatabaseForm) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _pages_admin_user_id_databases_add_database__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6706); +/* harmony import */ var _functions_frontend_checkUniqueField__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4105); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5472); +/* harmony import */ var _DatabaseForm__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3121); +/* harmony import */ var _DatabaseImage__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(1933); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddDatabaseForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , dbImage , setDbImage , query } = react__WEBPACK_IMPORTED_MODULE_1___default().useContext(_pages_admin_user_id_databases_add_database__WEBPACK_IMPORTED_MODULE_3__.AddDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!user) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [alert, setAlert] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + // React.useEffect(() => { + // if (!dbImage?.imageBase64Full) { + // const presetImage = document.createElement("img"); + // presetImage.src = "/images/database-placeholder.png"; + // imageNodeToBase64SpecificWidth({ imageNode: presetImage, maxWidth: 400, mimeType: "image/png" }).then((res) => { + // setDbImage({ ...res, imageName: "Preset-db-image" }) + // }) + // } + // }, []) + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("section", { + className: "card", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full grid grid-cols-1 xl:grid-cols-2 gap-6 items-stretch", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "New Database Information" + }), + user && dbImage && setDbImage && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseForm__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage, + setLoading: setLoading, + query: query + }) + ] + }), + user && dbImage && setDbImage && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseImage__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3121: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ DatabaseForm) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/checkUniqueField.js +var checkUniqueField = __webpack_require__(4105); +// EXTERNAL MODULE: ./components/general/FormAlertBlock.jsx +var FormAlertBlock = __webpack_require__(7037); +// EXTERNAL MODULE: external "react-dom" +var external_react_dom_ = __webpack_require__(6405); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./functions/frontend/updateDiskUsage.js +var updateDiskUsage = __webpack_require__(1069); +;// CONCATENATED MODULE: ./functions/frontend/submitUpdateDatabaseForm.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {any} params.e + * @param {React.Dispatch>} params.setLoading + * @param {any} params.dbImage + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} params.database + * @param {import("@/package-shared/types").UserType} params.user + */ async function submitUpdateDatabaseForm({ e , setLoading , dbImage , database , user , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ setLoading(true); + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ /** @type {any} */ let formBody = { + db_description: e.target["database_description"]?.value?.match(/./) ? e.target["database_description"].value : null, + db_name: e.target["database_name"]?.value?.match(/./) ? e.target["database_name"].value : null, + db_slug: e.target["database_slug"]?.value?.match(/./) ? e.target["database_slug"].value : null, + db_full_name: database.db_full_name, + id: database.id, + active_clone: database.active_clone, + active_clone_parent_db: database.active_clone_parent_db + }; + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (dbImage) { + if (typeof dbImage === "string") { + formBody.db_image = dbImage; + } else if (typeof dbImage === "object") { + const uploadImage = await (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + dbImage + ], + folder: formBody.db_slug.replace(/_/g, "-"), + type: "image" + } + }, true); + formBody.db_image = uploadImage?.mediaData[0]?.media_thumbnail_url ? uploadImage.mediaData[0].media_thumbnail_url : "/images/database-placeholder.png"; + } + } else { + formBody.db_image = "/images/database-placeholder.png"; + } + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ (0,fetchApi/* default */.Z)("/api/updateUserDatabase", { + method: "post", + body: formBody + }, true).then((res)=>{ + if (res.success) { + (0,updateDiskUsage/* default */.Z)().then(()=>{ + window.location.pathname = `/admin/${user?.id}/databases`; + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } else { + alert("Error! Please Try Again"); + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./functions/frontend/submitNewDatabaseForm.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +let submitNewDatabaseForm_timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {any} params.e + * @param {React.Dispatch>} params.setLoading + * @param {any} params.dbImage + * @param {boolean} params.keepUpdated + * @param {boolean} params.keepDataUpdated + * @param {any} params.query + * @param {import("@/package-shared/types").UserType} params.user + */ async function submitNewDatabaseForm({ e , setLoading , dbImage , keepUpdated , keepDataUpdated , query , user , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ setLoading(true); + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ /** @type {any} */ let formBody = { + db_name: e.target["database_name"].value, + db_slug: e.target["database_slug"].value, + db_description: e.target["database_description"]?.value?.match(/./) ? e.target["database_description"].value : null + }; + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (dbImage) { + if (typeof dbImage === "string") { + formBody.db_image = dbImage; + } else if (typeof dbImage === "object") { + const uploadImage = await (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + dbImage + ], + folder: formBody.db_slug.replace(/_/g, "-"), + type: "image" + } + }, true); + formBody.db_image = uploadImage?.mediaData[0]?.media_thumbnail_url ? uploadImage.mediaData[0].media_thumbnail_url : "/images/database-placeholder.png"; + } + } + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (query?.duplicate) { + formBody["duplicate"] = query.duplicate; + formBody["keepUpdated"] = keepUpdated ? keepUpdated : false; + formBody["keepDataUpdated"] = keepDataUpdated ? keepDataUpdated : false; + } + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ (0,fetchApi/* default */.Z)("/api/createUserDatabase", { + method: "post", + body: formBody + }, true).then((res)=>{ + if (res.success) { + (0,updateDiskUsage/* default */.Z)().then(()=>{ + window.location.pathname = `/admin/${user?.id}/databases/${formBody.db_slug}`; + }); + } else { + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/form/FormCheckboxes.jsx +var FormCheckboxes = __webpack_require__(9486); +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let DatabaseForm_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {string | import("@/package-shared/types").ImageObjectType} props.dbImage + * @param {React.Dispatch>} [props.setDbImage] + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} [props.database] + * @param {React.Dispatch>} props.setLoading + * @param {any} [props.query] + */ function DatabaseForm({ user , dbImage , setDbImage , database , setLoading , query , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + * @param {string} value + */ async function checkDuplicateSlug(value) { + if (database?.db_slug === value) { + return null; + } + const duplicate = await (0,checkUniqueField/* default */.Z)({ + tableName: "user_databases", + columnName: "db_slug", + value: value, + userId: user.id + }); + return duplicate; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type { any } */ const alertState = external_react_default().useState(null); + /** @type { [alert: string | null, setAlert: React.Dispatch>] } */ const [alert, setAlert] = alertState; + const [keepUpdated, setKeepUpdated] = external_react_default().useState(false); + const [keepDataUpdated, setKeepDataUpdated] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full max-w-none xl:max-w-lg flex flex-col items-start gap-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + if (database) { + submitUpdateDatabaseForm({ + e, + setLoading, + dbImage, + database, + user + }); + } else { + submitNewDatabaseForm({ + e, + setLoading, + dbImage, + keepUpdated, + keepDataUpdated, + query, + user + }); + } + }, + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx(FormAlertBlock/* default */.Z, { + message: alert + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "database_name", + children: "Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "database_name", + id: "database_name", + placeholder: "Database Name", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const form = inputEl.closest("form"); + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + if (form) { + form["database_slug"].value = inputEl.value.toLowerCase().replace(/ /g, "_").replace(/[^a-zA-Z0-9-_]/g, ""); + let slugValue = form["database_slug"].value; + window.clearTimeout(DatabaseForm_timeout); + DatabaseForm_timeout = setTimeout(()=>{ + checkDuplicateSlug(slugValue).then((res)=>{ + if (res?.result) { + form["database_slug"].classList.add("warning"); + setAlert("Duplicate Database Name"); + } else { + form["database_slug"].classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + } + }, + defaultValue: database ? database.db_name : "", + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "database_slug", + children: "Slug" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "database_slug", + id: "database_slug", + placeholder: "Database Slug", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + let slugValue = inputEl.value; + window.clearTimeout(DatabaseForm_timeout); + DatabaseForm_timeout = setTimeout(()=>{ + checkDuplicateSlug(slugValue).then((res)=>{ + if (res?.result) { + inputEl.classList.add("warning"); + setAlert("Duplicate Database Name"); + } else { + inputEl.classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + }, + defaultValue: database ? database.db_slug : "", + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "database_description", + children: "Description (optional)" + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: "database_description", + id: "database_description", + placeholder: "Short Description of database", + defaultValue: database ? database.db_description : "" + }) + ] + }), + query?.duplicate && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card col items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + checkBoxValues: [ + { + payload: "Keep New Database Updated?", + title: "Keep New Database Updated?", + name: "clone_database", + onChangeHandler: (e)=>{ + if (e.target.checked) { + setKeepUpdated(true); + } else { + setKeepUpdated(false); + } + } + }, + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm italic text-slate-600 dark:text-slate-300", + children: "By checking this box the new Database stays up to date with changes to the structure of the parent Database" + }) + ] + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + type: "submit", + className: "w-full", + children: [ + database ? "Update" : "Create", + " Database" + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 1933: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabaseImage) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6718); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5449); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {string | null | import("@/package-shared/types").ImageObjectType} props.dbImage + * @param {React.Dispatch>} props.setDbImage + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} [props.database] + */ function DatabaseImage({ user , dbImage , setDbImage , database }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const imagePreviewRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card no-hover col items-center justify-center", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0", + children: "Database Image" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "bg-white rounded-full overflow-hidden w-24 h-24", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: dbImage ? typeof dbImage === "string" ? dbImage : dbImage.imageBase64Full : "/images/database-placeholder.png", + alt: "Database Image", + width: 100, + className: "w-full h-full object-cover", + // @ts-ignore + ref: imagePreviewRef, + "data-imagepreview": "image" + }) + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full flex-col", + id: "edit-database-image-option-wrapper", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + column: true, + className: "w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined w-full whitespace-normal", + onClick: (e)=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .openPopup */ .Mw)("user-media-popup"); + }, + children: "Choose Image from uploads" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined secondary w-full whitespace-normal", + onClick: (e)=>{ + /** @type {HTMLButtonElement} */ // @ts-ignore + const buttonEl = e.target; + buttonEl?.closest("#edit-database-image-option-wrapper")?.querySelector("input")?.click(); + }, + children: "Choose Image from Computer" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + accept: ".png,.jpg,.jpeg,.webp", + placeholder: "Choose Database Image", + className: "hidden", + onChange: async (e)=>{ + /** @type {File} */ // @ts-ignore + const imageInputFile = e.target.files[0]; + let imageData = await (0,_functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)({ + imageInputFile: imageInputFile, + maxWidth: 400 + }); + setDbImage(imageData); + } + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 9310: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UserMediaPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _ExistingFieldEdit__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9967); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {React.Dispatch>} props.setDbImage + */ function UserMediaPopup({ setDbImage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(true); + /** @type {any} */ const mediaState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type { [ media: import("@/package-shared/types").MYSQL_MediaType[] | null, setMedia: React.Dispatch> ] } */ const [media, setMedia] = mediaState; + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/getUserMedia").then((res)=>{ + setLoading(false); + setMedia(res.media); + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "user-media-popup", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0 text-lg", + children: "Your Uploaded Images" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "grid grid-cols-2", + children: media && media[0] && media.filter((media)=>media.media_type == "image").map((mediaObject, index)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full h-44 cursor-pointer hover:opacity-70", + onClick: (e)=>{ + setDbImage(mediaObject.media_thumbnail_url || null); + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: mediaObject.media_thumbnail_url, + alt: "User Media", + className: "w-full h-full object-contain" + }) + }, index + 1); + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4227: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const serverError = __webpack_require__(7023); +const NO_DB_HANDLER = __webpack_require__(2020); +/** + * Create database from Schema Function + * ============================================================================== + * @param {string} queryString - Query String + * @returns {Promise} + */ module.exports = async function noDatabaseDbHandler(queryString) { + "production"?.match(/dev/) && fs.appendFileSync("./.tmp/sqlQuery.sql", queryString + "\n" + Date() + "\n\n\n", "utf8"); + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + /** ********************* Run Query */ results = await NO_DB_HANDLER(queryString); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "noDatabaseDbHandler", + message: error.message + }); + console.log("ERROR in noDatabaseDbHandler =>", error.message); + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results) { + return results; + } else { + return null; + } +}; + + +/***/ }), + +/***/ 2020: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +// const mysql = require("mysql"); +// const NO_DB = mysql.createConnection({ +// host: process.env.DSQL_DB_HOST, +// user: process.env.DSQL_DB_USERNAME, +// password: process.env.DSQL_DB_PASSWORD, +// charset: "utf8mb4", +// }); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +let NO_DB = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {string} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ // @ts-ignore +function NO_DB_HANDLER(...args) { + try { + return new Promise((resolve, reject)=>{ + NO_DB.query(...args).then((results)=>{ + NO_DB.end(); + resolve(JSON.parse(JSON.stringify(results))); + }).catch((err)=>{ + NO_DB.end(); + resolve({ + error: err.message, + sql: err.sql + }); + }); + }); + } catch (/** @type {any} */ error) { + return { + success: false, + error: error.message + }; + } +} +module.exports = NO_DB_HANDLER; + + +/***/ }), + +/***/ 6706: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddDatabaseContext": () => (/* binding */ AddDatabaseContext), + "default": () => (/* binding */ AddDatabase), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./package-shared/functions/backend/noDatabaseDbHandler.js +var noDatabaseDbHandler = __webpack_require__(4227); +var noDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(noDatabaseDbHandler); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/databases/AddDatabaseForm.jsx +var AddDatabaseForm = __webpack_require__(3726); +;// CONCATENATED MODULE: ./components/admin/databases/AddDatabaseContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddDatabaseContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { query , duplicateDb , user } = external_react_default().useContext(AddDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const title = (()=>{ + if (query?.duplicate) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + "Duplicate", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${duplicateDb?.db_slug}`, + target: "_blank", + children: duplicateDb?.db_name + }), + " ", + "Database" + ] + }); + } + return "Add A New Database"; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: title + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(AddDatabaseForm/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/UserMediaPopup.jsx +var UserMediaPopup = __webpack_require__(9310); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/add-database.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AddDbContextType} */ let addDatabaseContextObject = {}; +const AddDatabaseContext = /*#__PURE__*/ external_react_default().createContext(addDatabaseContextObject); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases + * @param {any} props.query + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.duplicateDb + */ function AddDatabase({ user , databases , query , duplicateDb }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Add Database | Datasquirel"; + const pageDescription = "Add a database"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const dbImageState = external_react_default().useState("/images/database-placeholder.png"); + /** @type { [ dbImage:string | null | import("@/package-shared/types").ImageObjectType, setDbImage: React.Dispatch> ] } */ const [dbImage, setDbImage] = dbImageState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(AddDatabaseContext.Provider, { + value: { + user, + databases, + dbImage, + setDbImage, + query, + duplicateDb + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(AddDatabaseContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UserMediaPopup/* default */.Z, { + setDbImage: setDbImage + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.verification_status?.toString()?.match(/1/)) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const databases = await noDatabaseDbHandler_default()(`SELECT SCHEMA_NAME AS dbFullName FROM INFORMATION_SCHEMA.SCHEMATA WHERE SCHEMA_NAME LIKE 'user_${user.id}%'`); + let duplicateDb = {}; + if (query.duplicate) { + const dbDuplicateDb = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE db_full_name='${query.duplicate}'`); + if (dbDuplicateDb && dbDuplicateDb[0]) duplicateDb = dbDuplicateDb[0]; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + databases: databases, + query, + duplicateDb + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4017.js b/dsql-app/.local_dist/server/chunks/4017.js new file mode 100644 index 0000000..3946450 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4017.js @@ -0,0 +1,120 @@ +"use strict"; +exports.id = 4017; +exports.ids = [4017]; +exports.modules = { + +/***/ 4017: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ Logo) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5557); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {{ + * size?: string, + * adminAside?: boolean, + * collapseAsideMobile?: boolean, + * setCollapseAsideMobile?: React.Dispatch>, + * }} props - React component props + */ function Logo({ size , adminAside , collapseAsideMobile , setCollapseAsideMobile , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/", + className: "logo", + onClick: (e)=>{ + /** @type {*} */ const targetElement = e.target; + if (targetElement?.closest("button")) { + return e.preventDefault(); + } + }, + children: [ + adminAside && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + className: "flex lg:hidden small-text mr-2 primary-light", + onClick: (e)=>{ + if (collapseAsideMobile && setCollapseAsideMobile) { + setCollapseAsideMobile(false); + } else if (setCollapseAsideMobile) { + setCollapseAsideMobile(true); + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "-mt-0.5", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2___default()), { + color: "action" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "dark:text-white", + children: "Menu" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/logo-icon-alt-2.webp", + alt: "Datasquirel Logo", + width: 35, + className: "dark:hidden -mt-1.5 -mr-1.5" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/logo-icon-alt-2.webp", + alt: "Datasquirel Logo", + width: 35, + className: "hidden dark:flex -mt-1.5 -mr-1.5" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-slate-800 dark:text-white text-[20px] font-bold hidden sm:flex -mt-[1px]", + children: "Datasquirel" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4097.js b/dsql-app/.local_dist/server/chunks/4097.js new file mode 100644 index 0000000..96b35d3 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4097.js @@ -0,0 +1,106 @@ +"use strict"; +exports.id = 4097; +exports.ids = [4097]; +exports.modules = { + +/***/ 4097: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ PageHeadTags) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.pageTitle + * @param {string} props.pageDescription + * @param {string} props.pagePathname + * @param {boolean} [props.aceEditor] + */ function PageHeadTags({ pageTitle , pageDescription , pagePathname , aceEditor , }) { + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "canonical", + href: "http://localhost:7070" + pagePathname + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:url", + content: "http://localhost:7070" + pagePathname + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + itemProp: "url", + content: "http://localhost:7070" + pagePathname + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "twitter:url", + content: "http://localhost:7070" + pagePathname + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:title", + content: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + itemProp: "name", + content: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + itemProp: "description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "twitter:title", + content: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "twitter:description", + content: pageDescription + }), + aceEditor && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ace.min.js", + integrity: "sha512-q6CTB0jS+VuJnSct82rVcWlI06LGzNjaG3CWenHWVUncRvc4UQMFkA3a5Ip880xr+lBx38FcHDclOxPdSg+sBw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ext-language_tools.min.js", + integrity: "sha512-6g6cvocV7eT/J8L44lL8gJKqq9onqQeYGgJO0DmrsYFcCfRl6wYkYA/KHS768r4QVTB4JxsCcMQ9gIezxpTCZw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4105.js b/dsql-app/.local_dist/server/chunks/4105.js new file mode 100644 index 0000000..29a452d --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4105.js @@ -0,0 +1,54 @@ +"use strict"; +exports.id = 4105; +exports.ids = [4105]; +exports.modules = { + +/***/ 4105: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ checkUniqueField) +/* harmony export */ }); +/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6405); +/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_dom__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {string} params.tableName + * @param {string} params.columnName + * @param {string} params.value + * @param {string} [params.dbFullName] + * @param {any} [params.dispatch] + * @param {number} [params.userId] + * @param {number} [params.dbId] + */ async function checkUniqueField({ tableName , columnName , value , dbFullName , dispatch , userId , dbId , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const duplicate = await (0,_fetchApi__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)(`/api/checkDuplicateData?tableName=${tableName}&type=${columnName}&value=${value}${dbFullName ? "&dbFullName=" + dbFullName : ""}${userId ? "&userId=" + userId : ""}${dbId ? "&dbId=" + dbId : ""}`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return duplicate; +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4114.js b/dsql-app/.local_dist/server/chunks/4114.js new file mode 100644 index 0000000..568bdec --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4114.js @@ -0,0 +1,179 @@ +"use strict"; +exports.id = 4114; +exports.ids = [4114]; +exports.modules = { + +/***/ 4114: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormSelect) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} OptionObject + * @property {string} title + * @property {string} payload + * @property {boolean} [default] + */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {OptionObject[]} props.selectOptions - array of option objects + * @param {string} [props.name] + * @param {(e:any) => void} [props.onChangeHandler] + * @param {boolean} [props.required] + * @param {React.Dispatch>} [props.setAlert] + * @param {string | React.ReactNode} [props.title] + * @param {string} [props.defaultValue] + * @param {string} [props.info] + * @param {string} [props.id] + */ function FormSelect({ selectOptions , name , onChangeHandler , required , setAlert , title , defaultValue , info , id , }) { + try { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ function toggleDropdown(/** @type {any} */ e) { + if (e.type.match(/enter/i) && window.innerWidth < 1200) { + return; + } + const infoWrapper = e.target.closest(".info-wrapper"); + const dropdown = infoWrapper.querySelector(".info-dropdown"); + if (e.type.match(/leave/i) && !dropdown.classList.contains("hidden")) { + dropdown.classList.add("hidden"); + return; + } else if (e.type.match(/leave/i) && dropdown.classList.contains("hidden")) { + return; + } + if (!infoWrapper) { + dropdown.classList.add("hidden"); + return; + } + if (dropdown.classList.contains("hidden")) { + dropdown.classList.remove("hidden"); + return; + } + dropdown.classList.add("hidden"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "form-select-block flex items-start flex-col gap-0.5 w-full relative" + (info ? " pr-8" : ""), + children: [ + title && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("label", { + htmlFor: name, + children: [ + title, + required ? "" : " (optional)" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center w-full relative", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("select", { + name: name, + id: id ? id : name, + className: "w-full bg-white", + required: required, + onChange: (/** @type {any} */ e)=>{ + if (setAlert) setAlert(null); + e.target.classList.remove("warning"); + if (onChangeHandler) onChangeHandler(e); + }, + defaultValue: defaultValue ? defaultValue : undefined, + children: selectOptions.map((value, index)=>{ + const { payload , title } = value; + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: payload, + selected: value.default ? true : false, + children: title + }, index + 1); + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_1__.ChevronDown, { + className: "absolute right-2 text-base text-slate-500 pointer-events-none", + size: 20 + }), + info && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "info-wrapper absolute -right-10 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10", + style: { + top: "50%", + transform: "translate(0,-50%)" + }, + onMouseEnter: toggleDropdown, + onMouseLeave: toggleDropdown, + onClick: toggleDropdown, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/info-outlined-black.png", + alt: "", + className: "w-6 h-6 object-contain opacity-60 pointer-events-none" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: info + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "absolute -top-2 w-12", + style: { + height: "45px" + } + }) + ] + }) + ] + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log("ERROR in FormSelect =>", error); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: "Form Select Error" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4187.js b/dsql-app/.local_dist/server/chunks/4187.js new file mode 100644 index 0000000..cbf859d --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4187.js @@ -0,0 +1,166 @@ +"use strict"; +exports.id = 4187; +exports.ids = [4187]; +exports.modules = { + +/***/ 4187: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ SuDashboardContent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6729); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _components_UserCard__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1336); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + */ function SuDashboardContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userTitles = Object.keys(data.users[0]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ errorLog: string | null, setErrorLog: React.Dispatch> ]} */ // @ts-ignore + const [errorLog, setErrorLog] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + const [refresh, setRefresh] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + const [clearErrorLogLoading, setClearErrorLogLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + function fetchErrorLogs() { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/admin/grabErrorLogs").then((res)=>{ + if (res?.log && typeof res.log === "string" && !res.log?.match(/./)) { + setErrorLog("No Logs Yet"); + return; + } else if (res?.log) { + setErrorLog("No Logs"); + } + setErrorLog(res.log.replace(/\n|\r|\n\r|\\n/gm, "
")); + }); + } + console.log(typeof errorLog); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + fetchErrorLogs(); + if (refresh === 0) { + setInterval(()=>{ + fetchErrorLogs(); + }, 10000); + } + }, [ + refresh + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "items-stretch gap-10 w-full", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0 mb-6", + children: "Users" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex-col items-stretch gap-10", + children: data.users.map((/** @type {any} */ userObject, /** @type {number} */ index)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_UserCard__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + userObject: userObject + }, index + 1); + }) + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0", + children: "Error Logs" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + onClick: (e)=>{ + if (window.confirm("Clear Error Logs?")) { + setClearErrorLogLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/admin/clearErrorLogs", "post").then((res)=>{ + setRefresh((prev)=>prev + 1); + }); + setTimeout(()=>{ + setClearErrorLogLoading(false); + }, 2000); + } + }, + className: "outlined gray relative", + children: [ + clearErrorLogLoading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + width: "20px" + }), + "Clear Error Log" + ] + }) + }) + ] + }), + errorLog && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", { + dangerouslySetInnerHTML: { + __html: errorLog ? errorLog : "No Log" + } + }), + typeof errorLog !== "string" && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + position: "relative", + width: "25px" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4194.js b/dsql-app/.local_dist/server/chunks/4194.js new file mode 100644 index 0000000..49c3572 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4194.js @@ -0,0 +1,66 @@ +"use strict"; +exports.id = 4194; +exports.ids = [4194]; +exports.modules = { + +/***/ 4194: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const os = __webpack_require__(2037); +const { execSync } = __webpack_require__(2081); +const serverError = __webpack_require__(2163); +const { ServerResponse } = __webpack_require__(3685); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {Object} params - Single object parameter + * @param {string} params.dbName - Database Full Name + * @param {import("@/package-shared/types").UserType} params.user - Database Full Name + * @param {ServerResponse} params.res - Http response object + */ module.exports = async function exportDb({ dbName , user , res }) { + const mysqlDumpPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysqldump.exe" + "'" : "mysqldump"; + try { + /** @type {import("child_process").ExecSyncOptions} */ let execSyncOptions = { + cwd: process.cwd() + }; + const filePath = `./jsonData/dbSchemas/users/user-${user.id}/export.sql`; + if (os.platform().match(/win/i)) execSyncOptions.shell = "bash.exe"; + const exe = `${mysqlDumpPath} -u ${process.env.DSQL_DB_USERNAME} -h ${process.env.DSQL_DB_HOST} -p${process.env.DSQL_DB_PASSWORD} ${dbName} > ${filePath}`; + console.log(`exportDb.js exe => ${exe}`); + const dumpDb = execSync(exe, execSyncOptions); + // const file = fs.createWriteStream(filePath); + res.setHeader("Content-Type", "application/zip"); + res.setHeader("Content-Disposition", `attachment; filename=export.sql`); + const fileStream = fs.createReadStream(filePath); + /** ********************* Write response header */ fileStream.pipe(res); + // res.pipe(file); + // res.writeHead(200); + // await new Promise((resolve, reject) => { + // file.on("finish", () => { + // // res.pipe(file); + // resolve(true); + // }); + // }); + // return fs.readFileSync(filePath, "utf-8"); + // return file; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/exportDb/lines-30-46", + message: error.message, + user: user + }); + } +}; /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/424.js b/dsql-app/.local_dist/server/chunks/424.js new file mode 100644 index 0000000..e7623c6 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/424.js @@ -0,0 +1,137 @@ +"use strict"; +exports.id = 424; +exports.ids = [424]; +exports.modules = { + +/***/ 424: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ Breadcrumbs) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} [props.confirmedDelegetedUser] + * @param {any} [props.linksArray] + * @param {import("@/package-shared/types").UserType} [props.user] + */ function Breadcrumbs({ confirmedDelegetedUser , linksArray , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const linksState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(linksArray ? linksArray : null); + /** @type { [ links:any[], setLinks: React.Dispatch> ] } */ const [links, setLinks] = linksState; + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (linksArray) return; + let pathname = window.location.pathname; + let pathLinks = pathname.split("/"); + let validPathLinks = []; + validPathLinks.push({ + title: "Home", + path: pathname.match(/admin/) ? "/admin" : "/" + }); + const isDelegated = window.location.search?.match(/delegated=true/); + pathLinks.forEach((linkText, index, array)=>{ + if (!linkText?.match(/./) || index == 1) { + return; + } + if (linkText.match(/^\d+$/) && user) { + // validPathLinks.push({ + // title: user.first_name, + // path: `/admin/${linkText}`, + // }); + return; + } + validPathLinks.push({ + title: linkText, + path: (()=>{ + let path = ""; + for(let i = 0; i < array.length; i++){ + const lnText = array[i]; + if (i > index || !lnText.match(/./)) continue; + path += `/${lnText}`; + } + return path; + })() + }); + }); + setLinks(validPathLinks); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (!links || !links[1]) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + } + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "text-sm mt-2 flex-wrap", + children: links.map((linkObject, index, array)=>{ + if (index === links.length - 1) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: linkObject.path, + className: "text-slate-400 dark:text-slate-500 pointer-events-none", + children: linkObject.title + }, index); + } else { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: linkObject.path, + className: "query-url", + children: linkObject.title + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "opacity-20", + children: "|" + }) + ] + }, index); + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4294.js b/dsql-app/.local_dist/server/chunks/4294.js new file mode 100644 index 0000000..e2540bb --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4294.js @@ -0,0 +1,67 @@ +"use strict"; +exports.id = 4294; +exports.ids = [4294]; +exports.modules = { + +/***/ 4294: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const generator = __webpack_require__(3785); +const DB_HANDLER = __webpack_require__(2224); +const NO_DB_HANDLER = __webpack_require__(7487); +const encrypt = __webpack_require__(7547); +const addDbEntry = __webpack_require__(5338); +/** + * # Add Mariadb User + * + * @description this function adds a Mariadb user to the database server + * + * @param {object} params - parameters object * + * @param {number | string} params.userId - invited user object + * + * @returns {Promise} new user auth object payload + */ module.exports = async function addMariadbUser({ userId }) { + try { + const defaultMariadbUserHost = process.env.DSQL_DB_HOST || "127.0.0.1"; + const username = `dsql_user_${userId}`; + const password = generator.generate({ + length: 16, + numbers: true, + symbols: true, + uppercase: true, + exclude: "*#.'`\"" + }); + const encryptedPassword = encrypt(password); + await NO_DB_HANDLER(`CREATE USER IF NOT EXISTS '${username}'@'127.0.0.1' IDENTIFIED BY '${password}' REQUIRE SSL`); + const updateUser = await DB_HANDLER(`UPDATE users SET mariadb_user = ?, mariadb_host = '127.0.0.1', mariadb_pass = ? WHERE id = ?`, [ + username, + encryptedPassword, + userId + ]); + const addMariadbUser1 = await addDbEntry({ + tableName: "mariadb_users", + data: { + user_id: userId, + username, + host: defaultMariadbUserHost, + password: encryptedPassword, + primary: "1", + grants: '[{"database":"*","table":"*","privileges":["ALL"]}]' + }, + dbContext: "Master" + }); + console.log(`User ${userId} SQL credentials successfully added.`); + } catch (/** @type {any} */ error) { + console.log(`Error in adding SQL user in 'addMariadbUser' function =>`, error.message); + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4298.js b/dsql-app/.local_dist/server/chunks/4298.js new file mode 100644 index 0000000..0872561 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4298.js @@ -0,0 +1,523 @@ +exports.id = 4298; +exports.ids = [4298]; +exports.modules = { + +/***/ 6495: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Z = _extends; +function _extends() { + return extends_.apply(this, arguments); +} +function extends_() { + extends_ = Object.assign || function(target) { + for(var i = 1; i < arguments.length; i++){ + var source = arguments[i]; + for(var key in source){ + if (Object.prototype.hasOwnProperty.call(source, key)) { + target[key] = source[key]; + } + } + } + return target; + }; + return extends_.apply(this, arguments); +} + + +/***/ }), + +/***/ 1598: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Z = _interopRequireWildcard; +function _interopRequireWildcard(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) { + return obj; + } + if (obj === null || typeof obj !== "object" && typeof obj !== "function") { + return { + default: obj + }; + } + var cache = _getRequireWildcardCache(nodeInterop); + if (cache && cache.has(obj)) { + return cache.get(obj); + } + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for(var key in obj){ + if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) { + Object.defineProperty(newObj, key, desc); + } else { + newObj[key] = obj[key]; + } + } + } + newObj.default = obj; + if (cache) { + cache.set(obj, newObj); + } + return newObj; +} +function _getRequireWildcardCache(nodeInterop1) { + if (typeof WeakMap !== "function") return null; + var cacheBabelInterop = new WeakMap(); + var cacheNodeInterop = new WeakMap(); + return (_getRequireWildcardCache = function(nodeInterop) { + return nodeInterop ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop1); +} + + +/***/ }), + +/***/ 7273: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Z = _objectWithoutPropertiesLoose; +function _objectWithoutPropertiesLoose(source, excluded) { + if (source == null) return {}; + var target = {}; + var sourceKeys = Object.keys(source); + var key, i; + for(i = 0; i < sourceKeys.length; i++){ + key = sourceKeys[i]; + if (excluded.indexOf(key) >= 0) continue; + target[key] = source[key]; + } + return target; +} + + +/***/ }), + +/***/ 6007: +/***/ ((module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ + value: true +})); +exports["default"] = initHeadManager; +exports.isEqualNode = isEqualNode; +exports.DOMAttributeNames = void 0; +function initHeadManager() { + return { + mountedInstances: new Set(), + updateHead: (head)=>{ + const tags = {}; + head.forEach((h)=>{ + if (// it won't be inlined. In this case revert to the original behavior + h.type === "link" && h.props["data-optimized-fonts"]) { + if (document.querySelector(`style[data-href="${h.props["data-href"]}"]`)) { + return; + } else { + h.props.href = h.props["data-href"]; + h.props["data-href"] = undefined; + } + } + const components = tags[h.type] || []; + components.push(h); + tags[h.type] = components; + }); + const titleComponent = tags.title ? tags.title[0] : null; + let title = ""; + if (titleComponent) { + const { children } = titleComponent.props; + title = typeof children === "string" ? children : Array.isArray(children) ? children.join("") : ""; + } + if (title !== document.title) document.title = title; + [ + "meta", + "base", + "link", + "style", + "script" + ].forEach((type)=>{ + updateElements(type, tags[type] || []); + }); + } + }; +} +const DOMAttributeNames = { + acceptCharset: "accept-charset", + className: "class", + htmlFor: "for", + httpEquiv: "http-equiv", + noModule: "noModule" +}; +exports.DOMAttributeNames = DOMAttributeNames; +function reactElementToDOM({ type , props }) { + const el = document.createElement(type); + for(const p in props){ + if (!props.hasOwnProperty(p)) continue; + if (p === "children" || p === "dangerouslySetInnerHTML") continue; + // we don't render undefined props to the DOM + if (props[p] === undefined) continue; + const attr = DOMAttributeNames[p] || p.toLowerCase(); + if (type === "script" && (attr === "async" || attr === "defer" || attr === "noModule")) { + el[attr] = !!props[p]; + } else { + el.setAttribute(attr, props[p]); + } + } + const { children , dangerouslySetInnerHTML } = props; + if (dangerouslySetInnerHTML) { + el.innerHTML = dangerouslySetInnerHTML.__html || ""; + } else if (children) { + el.textContent = typeof children === "string" ? children : Array.isArray(children) ? children.join("") : ""; + } + return el; +} +function isEqualNode(oldTag, newTag) { + if (oldTag instanceof HTMLElement && newTag instanceof HTMLElement) { + const nonce = newTag.getAttribute("nonce"); + // Only strip the nonce if `oldTag` has had it stripped. An element's nonce attribute will not + // be stripped if there is no content security policy response header that includes a nonce. + if (nonce && !oldTag.getAttribute("nonce")) { + const cloneTag = newTag.cloneNode(true); + cloneTag.setAttribute("nonce", ""); + cloneTag.nonce = nonce; + return nonce === oldTag.nonce && oldTag.isEqualNode(cloneTag); + } + } + return oldTag.isEqualNode(newTag); +} +function updateElements(type, components) { + const headEl = document.getElementsByTagName("head")[0]; + const headCountEl = headEl.querySelector("meta[name=next-head-count]"); + if (false) {} + const headCount = Number(headCountEl.content); + const oldTags = []; + for(let i = 0, j = headCountEl.previousElementSibling; i < headCount; i++, j = (j == null ? void 0 : j.previousElementSibling) || null){ + var ref; + if ((j == null ? void 0 : (ref = j.tagName) == null ? void 0 : ref.toLowerCase()) === type) { + oldTags.push(j); + } + } + const newTags = components.map(reactElementToDOM).filter((newTag)=>{ + for(let k = 0, len = oldTags.length; k < len; k++){ + const oldTag = oldTags[k]; + if (isEqualNode(oldTag, newTag)) { + oldTags.splice(k, 1); + return false; + } + } + return true; + }); + oldTags.forEach((t)=>{ + var ref; + return (ref = t.parentNode) == null ? void 0 : ref.removeChild(t); + }); + newTags.forEach((t)=>headEl.insertBefore(t, headCountEl)); + headCountEl.content = (headCount - oldTags.length + newTags.length).toString(); +} +if ((typeof exports.default === "function" || typeof exports.default === "object" && exports.default !== null) && typeof exports.default.__esModule === "undefined") { + Object.defineProperty(exports.default, "__esModule", { + value: true + }); + Object.assign(exports.default, exports); + module.exports = exports.default; +} //# sourceMappingURL=head-manager.js.map + + +/***/ }), + +/***/ 9311: +/***/ ((module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ + value: true +})); +exports.cancelIdleCallback = exports.requestIdleCallback = void 0; +const requestIdleCallback = typeof self !== "undefined" && self.requestIdleCallback && self.requestIdleCallback.bind(window) || function(cb) { + let start = Date.now(); + return setTimeout(function() { + cb({ + didTimeout: false, + timeRemaining: function() { + return Math.max(0, 50 - (Date.now() - start)); + } + }); + }, 1); +}; +exports.requestIdleCallback = requestIdleCallback; +const cancelIdleCallback = typeof self !== "undefined" && self.cancelIdleCallback && self.cancelIdleCallback.bind(window) || function(id) { + return clearTimeout(id); +}; +exports.cancelIdleCallback = cancelIdleCallback; +if ((typeof exports.default === "function" || typeof exports.default === "object" && exports.default !== null) && typeof exports.default.__esModule === "undefined") { + Object.defineProperty(exports.default, "__esModule", { + value: true + }); + Object.assign(exports.default, exports); + module.exports = exports.default; +} //# sourceMappingURL=request-idle-callback.js.map + + +/***/ }), + +/***/ 699: +/***/ ((module, exports, __webpack_require__) => { + +"use strict"; + +"client"; +Object.defineProperty(exports, "__esModule", ({ + value: true +})); +exports.handleClientScriptLoad = handleClientScriptLoad; +exports.initScriptLoader = initScriptLoader; +exports["default"] = void 0; +var _extends = (__webpack_require__(6495)/* ["default"] */ .Z); +var _interop_require_wildcard = (__webpack_require__(1598)/* ["default"] */ .Z); +var _object_without_properties_loose = (__webpack_require__(7273)/* ["default"] */ .Z); +var _react = _interop_require_wildcard(__webpack_require__(6689)); +var _headManagerContext = __webpack_require__(2796); +var _headManager = __webpack_require__(6007); +var _requestIdleCallback = __webpack_require__(9311); +"client"; +const ScriptCache = new Map(); +const LoadCache = new Set(); +const ignoreProps = [ + "onLoad", + "onReady", + "dangerouslySetInnerHTML", + "children", + "onError", + "strategy", +]; +const loadScript = (props)=>{ + const { src , id , onLoad =()=>{} , onReady =null , dangerouslySetInnerHTML , children ="" , strategy ="afterInteractive" , onError , } = props; + const cacheKey = id || src; + // Script has already loaded + if (cacheKey && LoadCache.has(cacheKey)) { + return; + } + // Contents of this script are already loading/loaded + if (ScriptCache.has(src)) { + LoadCache.add(cacheKey); + // It is possible that multiple `next/script` components all have same "src", but has different "onLoad" + // This is to make sure the same remote script will only load once, but "onLoad" are executed in order + ScriptCache.get(src).then(onLoad, onError); + return; + } + /** Execute after the script first loaded */ const afterLoad = ()=>{ + // Run onReady for the first time after load event + if (onReady) { + onReady(); + } + // add cacheKey to LoadCache when load successfully + LoadCache.add(cacheKey); + }; + const el = document.createElement("script"); + const loadPromise = new Promise((resolve, reject)=>{ + el.addEventListener("load", function(e) { + resolve(); + if (onLoad) { + onLoad.call(this, e); + } + afterLoad(); + }); + el.addEventListener("error", function(e) { + reject(e); + }); + }).catch(function(e) { + if (onError) { + onError(e); + } + }); + if (dangerouslySetInnerHTML) { + el.innerHTML = dangerouslySetInnerHTML.__html || ""; + afterLoad(); + } else if (children) { + el.textContent = typeof children === "string" ? children : Array.isArray(children) ? children.join("") : ""; + afterLoad(); + } else if (src) { + el.src = src; + // do not add cacheKey into LoadCache for remote script here + // cacheKey will be added to LoadCache when it is actually loaded (see loadPromise above) + ScriptCache.set(src, loadPromise); + } + for (const [k, value] of Object.entries(props)){ + if (value === undefined || ignoreProps.includes(k)) { + continue; + } + const attr = _headManager.DOMAttributeNames[k] || k.toLowerCase(); + el.setAttribute(attr, value); + } + if (strategy === "worker") { + el.setAttribute("type", "text/partytown"); + } + el.setAttribute("data-nscript", strategy); + document.body.appendChild(el); +}; +function handleClientScriptLoad(props) { + const { strategy ="afterInteractive" } = props; + if (strategy === "lazyOnload") { + window.addEventListener("load", ()=>{ + (0, _requestIdleCallback).requestIdleCallback(()=>loadScript(props)); + }); + } else { + loadScript(props); + } +} +function loadLazyScript(props) { + if (document.readyState === "complete") { + (0, _requestIdleCallback).requestIdleCallback(()=>loadScript(props)); + } else { + window.addEventListener("load", ()=>{ + (0, _requestIdleCallback).requestIdleCallback(()=>loadScript(props)); + }); + } +} +function addBeforeInteractiveToCache() { + const scripts = [ + ...document.querySelectorAll('[data-nscript="beforeInteractive"]'), + ...document.querySelectorAll('[data-nscript="beforePageRender"]'), + ]; + scripts.forEach((script)=>{ + const cacheKey = script.id || script.getAttribute("src"); + LoadCache.add(cacheKey); + }); +} +function initScriptLoader(scriptLoaderItems) { + scriptLoaderItems.forEach(handleClientScriptLoad); + addBeforeInteractiveToCache(); +} +function Script(props) { + const { id , src ="" , onLoad =()=>{} , onReady =null , strategy ="afterInteractive" , onError } = props, restProps = _object_without_properties_loose(props, [ + "id", + "src", + "onLoad", + "onReady", + "strategy", + "onError" + ]); + // Context is available only during SSR + const { updateScripts , scripts , getIsSsr } = (0, _react).useContext(_headManagerContext.HeadManagerContext); + /** + * - First mount: + * 1. The useEffect for onReady executes + * 2. hasOnReadyEffectCalled.current is false, but the script hasn't loaded yet (not in LoadCache) + * onReady is skipped, set hasOnReadyEffectCalled.current to true + * 3. The useEffect for loadScript executes + * 4. hasLoadScriptEffectCalled.current is false, loadScript executes + * Once the script is loaded, the onLoad and onReady will be called by then + * [If strict mode is enabled / is wrapped in component] + * 5. The useEffect for onReady executes again + * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped + * 7. The useEffect for loadScript executes again + * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped + * + * - Second mount: + * 1. The useEffect for onReady executes + * 2. hasOnReadyEffectCalled.current is false, but the script has already loaded (found in LoadCache) + * onReady is called, set hasOnReadyEffectCalled.current to true + * 3. The useEffect for loadScript executes + * 4. The script is already loaded, loadScript bails out + * [If strict mode is enabled / is wrapped in component] + * 5. The useEffect for onReady executes again + * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped + * 7. The useEffect for loadScript executes again + * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped + */ const hasOnReadyEffectCalled = (0, _react).useRef(false); + (0, _react).useEffect(()=>{ + const cacheKey = id || src; + if (!hasOnReadyEffectCalled.current) { + // Run onReady if script has loaded before but component is re-mounted + if (onReady && cacheKey && LoadCache.has(cacheKey)) { + onReady(); + } + hasOnReadyEffectCalled.current = true; + } + }, [ + onReady, + id, + src + ]); + const hasLoadScriptEffectCalled = (0, _react).useRef(false); + (0, _react).useEffect(()=>{ + if (!hasLoadScriptEffectCalled.current) { + if (strategy === "afterInteractive") { + loadScript(props); + } else if (strategy === "lazyOnload") { + loadLazyScript(props); + } + hasLoadScriptEffectCalled.current = true; + } + }, [ + props, + strategy + ]); + if (strategy === "beforeInteractive" || strategy === "worker") { + if (updateScripts) { + scripts[strategy] = (scripts[strategy] || []).concat([ + _extends({ + id, + src, + onLoad, + onReady, + onError + }, restProps), + ]); + updateScripts(scripts); + } else if (getIsSsr && getIsSsr()) { + // Script has already loaded during SSR + LoadCache.add(id || src); + } else if (getIsSsr && !getIsSsr()) { + loadScript(props); + } + } + return null; +} +Object.defineProperty(Script, "__nextScript", { + value: true +}); +var _default = Script; +exports["default"] = _default; +if ((typeof exports.default === "function" || typeof exports.default === "object" && exports.default !== null) && typeof exports.default.__esModule === "undefined") { + Object.defineProperty(exports.default, "__esModule", { + value: true + }); + Object.assign(exports.default, exports); + module.exports = exports.default; +} //# sourceMappingURL=script.js.map + + +/***/ }), + +/***/ 4298: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +module.exports = __webpack_require__(699) + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4432.js b/dsql-app/.local_dist/server/chunks/4432.js new file mode 100644 index 0000000..9ceaec6 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4432.js @@ -0,0 +1,37 @@ +"use strict"; +exports.id = 4432; +exports.ids = [4432]; +exports.modules = { + +/***/ 4432: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { IncomingMessage } = __webpack_require__(3685); +const decrypt = __webpack_require__(5425); +/** + * @async + * @param {import("next").NextApiRequest | IncomingMessage & { cookies: Partial<{ [key: string]: string; }>} } req - https request object + * + * @returns {Promise<({ email: string, password: string, authKey: string, logged_in_status: boolean, date: number } | null)>} + */ module.exports = async function(req) { + /** ********************* Check for existence of required cookie */ if (!req.cookies?.datasquirelSuAdminUserAuthKey) { + return null; + } + /** ********************* Grab the payload */ let userPayload = decrypt(req.cookies.datasquirelSuAdminUserAuthKey); + /** ********************* Return if no payload */ if (!userPayload) return null; + /** ********************* Parse the payload */ let userObject = JSON.parse(userPayload); + if (userObject.password !== process.env.DSQL_USER_KEY) return null; + if (userObject.authKey !== process.env.DSQL_SPECIAL_KEY) return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* return user object */ return userObject; +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4598.js b/dsql-app/.local_dist/server/chunks/4598.js new file mode 100644 index 0000000..82dfc8b --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4598.js @@ -0,0 +1,89 @@ +"use strict"; +exports.id = 4598; +exports.ids = [4598]; +exports.modules = { + +/***/ 4598: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FadedImage) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * src: string, + * alt?: string, + * className?: string, + * fadeHeight?: string, + * width?: number, + * height?: number, + * opacity?: number + * }} props - Server props + */ function FadedImage({ src , alt , className , fadeHeight , width , height , opacity , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "overflow-hidden z-0" + (className ? " " + className : ""), + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: src, + alt: alt, + className: "w-full h-full object-cover", + width: width, + height: height + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "fade-side", + style: { + height: fadeHeight + } + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/464.js b/dsql-app/.local_dist/server/chunks/464.js new file mode 100644 index 0000000..dbfee09 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/464.js @@ -0,0 +1,172 @@ +"use strict"; +exports.id = 464; +exports.ids = [464]; +exports.modules = { + +/***/ 5753: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ generateTypeDefinition) +/* harmony export */ }); +/* harmony import */ var _functions_frontend_defaultFieldsRegexp__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3907); +// @ts-check + +/** + * Generate a type definition for a query + * ============================================================================== + * @param {object} param0 + * @param {"JavaScript" | "TypeScript" | undefined} param0.paradigm + * @param {import("@/package-shared/types").DSQL_TableSchemaType} param0.table + * @param {any} param0.query + * @param {import("@/package-shared/types").UserType} [param0.user] + + * @returns {string | null} + */ function generateTypeDefinition({ paradigm , table , query , user , }) { + /** @type {string | null} */ let typeDefinition = ``; + try { + const tdName = `DSQL_${query.single}_${query.single_table}`.toUpperCase(); + const fields = table.fields; + function typeMap(/** @type {string} */ type) { + if (type?.match(/int/i)) { + return "number"; + } + if (type?.match(/text|varchar|timestamp/i)) { + return "string"; + } + return "string"; + } + const typesArrayTypeScript = []; + const typesArrayJavascript = []; + typesArrayTypeScript.push(`type ${tdName} = {`); + typesArrayJavascript.push(`/**\n * @typedef {object} ${tdName}`); + fields.forEach((field)=>{ + const nullValue = field.nullValue ? "?" : field.fieldName?.match(_functions_frontend_defaultFieldsRegexp__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z) ? "?" : ""; + typesArrayTypeScript.push(` ${field.fieldName}${nullValue}: ${typeMap(field.dataType || "")};`); + typesArrayJavascript.push(` * @property {${typeMap(field.dataType || "")}${nullValue}} ${field.fieldName}`); + }); + typesArrayTypeScript.push(`}`); + typesArrayJavascript.push(` */`); + if (paradigm?.match(/javascript/i)) { + typeDefinition = typesArrayJavascript.join("\n"); + } + if (paradigm?.match(/typescript/i)) { + typeDefinition = typesArrayTypeScript.join("\n"); + } + } catch (/** @type {any} */ error) { + console.log(error.message); + typeDefinition = null; + } + return typeDefinition; +} + + +/***/ }), + +/***/ 6169: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ExpandBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {boolean} props.collapse + * @param {React.Dispatch>} props.setCollapse + */ function ExpandBlock({ collapse , setCollapse }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "collapse-block" + (collapse ? " -mt-16 -mb-6 pt-10" : " mt-0 mb-0 p-0"), + onClick: (e)=>{ + if (collapse) { + setCollapse(false); + } else { + setCollapse(true); + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: collapse ? "Expand" : "Collapse" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/down-arrow-dark.svg", + alt: "Down Arrow", + width: 16, + className: "dark:hidden opacity-30 " + (collapse ? "" : "rotate-180") + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/down-arrow-white.svg", + alt: "Down Arrow", + width: 16, + className: "opacity-30 hidden dark:flex " + (collapse ? "" : "rotate-180") + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3907: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +// @ts-check +/** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const defaultFieldsRegexp = /^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (defaultFieldsRegexp); + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4858.js b/dsql-app/.local_dist/server/chunks/4858.js new file mode 100644 index 0000000..eca3fa1 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4858.js @@ -0,0 +1,752 @@ +"use strict"; +exports.id = 4858; +exports.ids = [4858]; +exports.modules = { + +/***/ 6355: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DiskUsageComponent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(6729); +/* harmony import */ var _functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(1069); +/* harmony import */ var _LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _mui_icons_material_CloudQueueRounded__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4008); +/* harmony import */ var _mui_icons_material_CloudQueueRounded__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CloudQueueRounded__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _mui_icons_material_RefreshRounded__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(36); +/* harmony import */ var _mui_icons_material_RefreshRounded__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_RefreshRounded__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _mui_icons_material_CloudOffTwoTone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(69); +/* harmony import */ var _mui_icons_material_CloudOffTwoTone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CloudOffTwoTone__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DiskUsageComponent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(true); + /** @type {[ diskUsage: number, setDiskUsage: React.Dispatch> ]} */ // @ts-ignore + const [diskUsage, setDiskUsage] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + const [refresh, setRefresh] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (diskUsage) return; + // if (localStorage.getItem("disk_usage")) { + // setDiskUsage(parseFloat(localStorage.getItem("disk_usage"))); + // return; + // } + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)("/api/getDiskUsage").then((res)=>{ + // console.log(res); + if (res?.total) { + setDiskUsage(res.total); + localStorage.setItem("disk_usage", res.total); + } + setLoading(false); + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (loading) return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "button ghost small-text", + style: { + height: "30px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + width: "15px", + position: "relative" + }) + }); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: diskUsage ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "button ghost small-text normal-weight p-0", + style: { + height: "30px", + padding: 0 + }, + onClick: (e)=>{ + setLoading(true); + (0,_functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z)().then(()=>{ + setRefresh((prev)=>prev + 1); + setLoading(false); + }); + }, + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + width: "15px" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.HardDrive, { + size: 20, + className: "text-slate-400 mr-[3px]" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-bold text-slate-700 dark:text-white", + children: diskUsage && diskUsage.toFixed(2) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-slate-500", + children: "mb" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.RotateCw, { + size: 17, + className: "text-slate-400", + strokeWidth: 2 + }) + ] + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-sm info gray font-normal w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_CloudOffTwoTone__WEBPACK_IMPORTED_MODULE_5___default()), { + color: "inherit", + className: "opacity-50 text-slate-500", + fontSize: "small" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "No Disk Usage Data Available Yet" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 1069: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ updateDiskUsage) +/* harmony export */ }); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * + * @requires search-field name attribute + */ async function updateDiskUsage() { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const res = await (0,_fetchApi__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)("/api/getDiskUsage"); + localStorage.setItem("disk_usage", res.total); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 4858: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ AdminLayout) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "next/head" +var head_ = __webpack_require__(968); +var head_default = /*#__PURE__*/__webpack_require__.n(head_); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/Footer.jsx +var Footer = __webpack_require__(5281); +// EXTERNAL MODULE: external "@mui/icons-material/DynamicFormTwoTone" +var DynamicFormTwoTone_ = __webpack_require__(8979); +// EXTERNAL MODULE: external "@mui/icons-material/CollectionsTwoTone" +var CollectionsTwoTone_ = __webpack_require__(7306); +// EXTERNAL MODULE: external "@mui/icons-material/PeopleOutlineTwoTone" +var PeopleOutlineTwoTone_ = __webpack_require__(9806); +// EXTERNAL MODULE: external "@mui/icons-material/SchemaTwoTone" +var SchemaTwoTone_ = __webpack_require__(1799); +// EXTERNAL MODULE: external "@mui/icons-material/LockTwoTone" +var LockTwoTone_ = __webpack_require__(2814); +// EXTERNAL MODULE: ./components/general/Logo.jsx +var Logo = __webpack_require__(4017); +// EXTERNAL MODULE: external "@mui/icons-material/AdminPanelSettingsTwoTone" +var AdminPanelSettingsTwoTone_ = __webpack_require__(4003); +var AdminPanelSettingsTwoTone_default = /*#__PURE__*/__webpack_require__.n(AdminPanelSettingsTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/LanguageOutlined" +var LanguageOutlined_ = __webpack_require__(300); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./layouts/components/AdminLayout/Aside.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {import("@/package-shared/types").UserType} props.user + */ function Aside({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [collapseAsideMobile, setCollapseAsideMobile] = external_react_default().useState(true); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("aside", { + className: "aside" + (collapseAsideMobile ? " mobile-collapsed" : " mobile-expanded"), + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Logo/* default */.Z, { + adminAside: true, + collapseAsideMobile: collapseAsideMobile, + setCollapseAsideMobile: setCollapseAsideMobile + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "opacity-0 mt-4" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "main-links" + (collapseAsideMobile ? " hidden lg:flex" : " "), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: "/admin", + "data-currentlink": "/admin", + "data-strictlink": "true", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.CircleGauge, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Dashboard" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases`, + "data-currentlink": `/admin/${user?.id}/databases`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Database, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Databases" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/media`, + "data-currentlink": `/admin/${user?.id}/media`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Images, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Media" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users`, + "data-currentlink": `/admin/${user?.id}/users`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Users, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Users" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/schema`, + "data-currentlink": `/admin/${user?.id}/schema`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.BookText, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Schema" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/api-keys`, + "data-currentlink": `/admin/${user?.id}/api-keys`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.FileKey2, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "API Keys" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/connect`, + "data-currentlink": `/admin/${user?.id}/connect`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Globe, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Connect" + }) + ] + }), + true && user.id == 1 && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su`, + "data-currentlink": `/su`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((AdminPanelSettingsTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Super Admin User" + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "opacity-80" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col gap-0 items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/settings`, + "data-currentlink": `/admin/${user?.id}/settings`, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Settings" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/docs", + "data-currentlink": "/docs", + target: "_blank", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Documentation" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/logout", + "data-currentlink": "/logout", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Logout" + }) + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/Header.jsx +var Header = __webpack_require__(7108); +// EXTERNAL MODULE: ./layouts/components/AdminLayout/AdminUserBlock.jsx + 1 modules +var AdminUserBlock = __webpack_require__(5484); +;// CONCATENATED MODULE: ./layouts/components/AdminLayout/AdminHeader.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {import("@/package-shared/types").UserType} props.user - Authenticated User + * @param {import("react").ReactNode} [props.extraHeaderContent] - Extra JSX content to be inserted in the header + */ function AdminHeader({ user , extraHeaderContent }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [activeUser, setActiveUser] = external_react_default().useState(user ? user : null); + external_react_default().useEffect(()=>{ + if (user?.logged_in_status) { + setActiveUser(user ? user : null); + } + }, [ + user + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "overflow-visible w-full px-0 md:px-8 py-0 flex justify-center bg-white dark:bg-slate-800 shadow-lg gap-4 dark:shadow-black/10 z-50 shadow-slate-900/5", + style: { + zIndex: 700, + border: "none" + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full items-center justify-between gap-4 md:gap-8", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "hidden xl:flex flex-col items-stretch grow fixed xl:static top-0 right-0 px-4 xl:px-0 shadow-xl xl:shadow-none h-screen xl:h-auto overflow-auto xl:overflow-visible w-screen sl:w-auto bg-white xl:bg-transparent pb-10 xl:pb-0", + id: "main-nav-content-wrapper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-center mb-2 flex xl:hidden", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/", + className: "hidden xl:flex", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/logo-icon-alt-2.png", + alt: "Logo Icon", + width: 37 + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray ml-auto", + onClick: (e)=>{ + const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + border: "none" + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-4xl", + children: "✕" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex items-center w-full gap-6 grow flex-col xl:flex-row justify-start xl:justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "gap-6", + children: extraHeaderContent + }), + /*#__PURE__*/ jsx_runtime_.jsx(AdminUserBlock/* default */.Z, { + activeUser: activeUser + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "bg-transparent w-16 p-4 gap-1.5 flex xl:hidden flex-col hover:bg-transparent transition-all ml-auto", + onClick: (e)=>{ + const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + minWidth: "50px", + backgroundColor: "transparent" + }, + id: "main-header-hamburger-button", + "aria-label": "Mobile Hambutget Button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./functions/frontend/updateNavLinks.js +var updateNavLinks = __webpack_require__(9678); +// EXTERNAL MODULE: ./components/general/DiskUsageComponent.jsx +var DiskUsageComponent = __webpack_require__(6355); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./layouts/AdminLayout.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +// import updateNavLinks from '../functions/frontend/updateNavLinks'; + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * children: import("react").ReactNode, + * head?: import("react").ReactNode, + * user: import("@/package-shared/types").UserType, + * productionEnvironment?: string, + * extraHeaderContent?: import("react").ReactNode, + * aceEditor?: boolean, + * }} props - children component + */ function AdminLayout({ children , head , user , productionEnvironment , extraHeaderContent , aceEditor , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!extraHeaderContent) extraHeaderContent = /*#__PURE__*/ jsx_runtime_.jsx(DiskUsageComponent/* default */.Z, {}); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ external_react_default().useEffect(()=>{ + /** @type {NodeListOf} */ const links = document.querySelectorAll("aside .main-links a"); + (0,updateNavLinks/* default */.Z)({ + links: links + }); + if (document.cookie.match(/user_refresh=1/)) { + (0,fetchApi/* default */.Z)("/api/reAuthenticateUser", { + method: "post", + body: {} + }, true).then((/** @type {import("@/pages/api/reAuthenticateUser").reAuthenticateUserResponse} */ res)=>{ + if (res.status && res.user) { + document.cookie = "user_refresh=0;max-age=0"; + localStorage.setItem("csrf", res.user.csrf_k); + localStorage.setItem("user", JSON.stringify(res.user)); + window.location.reload(); + } + }); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)((head_default()), { + children: [ + head, + /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ace.min.js", + integrity: "sha512-q6CTB0jS+VuJnSct82rVcWlI06LGzNjaG3CWenHWVUncRvc4UQMFkA3a5Ip880xr+lBx38FcHDclOxPdSg+sBw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }), + /*#__PURE__*/ jsx_runtime_.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ext-language_tools.min.js", + integrity: "sha512-6g6cvocV7eT/J8L44lL8gJKqq9onqQeYGgJO0DmrsYFcCfRl6wYkYA/KHS768r4QVTB4JxsCcMQ9gIezxpTCZw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "admin w-full flex items-start gap-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Aside, { + user: user + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("main", { + className: "relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(AdminHeader, { + user: user, + extraHeaderContent: extraHeaderContent + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "admin-content", + children: children + }), + /*#__PURE__*/ jsx_runtime_.jsx("footer", { + className: "flex justify-center w-full items-center p-4", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "max-w-6xl w-full justify-center flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex items-center gap-2 scale-75", + children: /*#__PURE__*/ jsx_runtime_.jsx(Logo/* default */.Z, {}) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm text-slate-400 dark:text-slate-600 text-center", + children: [ + new Date().getFullYear(), + " \xa9 Datasquirel. All rights reserved." + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/docs", + children: "Docs" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/terms", + children: "Terms" + }) + ] + }) + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4893.js b/dsql-app/.local_dist/server/chunks/4893.js new file mode 100644 index 0000000..991203a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4893.js @@ -0,0 +1,1318 @@ +"use strict"; +exports.id = 4893; +exports.ids = [4893]; +exports.modules = { + +/***/ 4893: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ TableFields) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "gsap" +var external_gsap_ = __webpack_require__(4287); +var external_gsap_default = /*#__PURE__*/__webpack_require__.n(external_gsap_); +;// CONCATENATED MODULE: ./functions/frontend/addNewTempField.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {DSQL_FieldSchemaType[]} params.tableFields + * @param {React.Dispatch>} params.setTableFields + * @param {React.Dispatch>} [params.setRefresh] + * @param {React.Dispatch>} [params.setPageRefresh] + * @param {React.MutableRefObject> | undefined>} params.refreshFieldsListRef + * + * @requires search-field name attribute + */ function addNewTempField({ tableFields , setTableFields , setRefresh , setPageRefresh , refreshFieldsListRef , }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ let newArray = tableFields; + let spliceIndex = newArray.findIndex((field)=>field.fieldName === "date_created"); + newArray.splice(spliceIndex, 0, { + newTempField: true + }); + setTableFields(newArray); + // setRefresh && setRefresh((prev) => prev + 1); + // setPageRefresh && setPageRefresh((prev) => prev + 1); + if (refreshFieldsListRef?.current) refreshFieldsListRef.current((prev)=>prev + 1); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: ./components/general/ExpandBlock.jsx +var ExpandBlock = __webpack_require__(6169); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/defaultFieldsRegexp.js +var defaultFieldsRegexp = __webpack_require__(3907); +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +;// CONCATENATED MODULE: ./functions/frontend/reorderField.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {DSQL_FieldSchemaType[]} params.tableFields + * @param {React.Dispatch>} params.setTableFields + * @param {React.MutableRefObject> | undefined>} params.refreshFieldsListRef + * @param {"up" | "down"} params.order + * @param {DSQL_FieldSchemaType} params.field + * @param {any} params.e + */ function reorderField({ tableFields , setTableFields , refreshFieldsListRef , order , field , e , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ let newFields = external_lodash_default().cloneDeep(tableFields); + let targetFieldIndex = newFields.findIndex((_field)=>_field.fieldName === field.fieldName); + if (targetFieldIndex < 0) { + return; + } + let targetField = newFields[targetFieldIndex]; + if (order === "up" && targetFieldIndex && targetFieldIndex <= 1) { + console.log("Min Reached =>", targetFieldIndex); + return; + } else if (order === "down" && targetFieldIndex && targetFieldIndex >= newFields.length - 7) { + console.log("Max Reached =>", targetFieldIndex); + return; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** @type {HTMLDivElement} */ const targetFieldElement = e.target.closest(".table-field-wrapper"); + const previousElement = targetFieldElement.previousElementSibling; + const nextElement = targetFieldElement.nextElementSibling; + // @ts-ignore + const Flip = window.DSQL.Flip; + const state = Flip.getState(targetFieldElement); + let nextState; + if (order === "up") { + nextState = Flip.getState(previousElement); + targetFieldElement.parentNode?.insertBefore(targetFieldElement, previousElement); + } else if (nextElement?.nextElementSibling) { + nextState = Flip.getState(nextElement); + targetFieldElement.parentNode?.insertBefore(targetFieldElement, nextElement.nextElementSibling); + } + Flip.from(state, { + duration: 0.3, + ease: "power1.inOut" + }); + Flip.from(nextState, { + duration: 0.3, + ease: "power1.inOut" + }); + } catch (/** @type {any} */ error) { + console.log("Error =>", error.message); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!targetFieldIndex) { + console.log("No target Field Index =>", targetFieldIndex); + return; + } + newFields.splice(targetFieldIndex, 1); + if (order === "up") { + newFields.splice(targetFieldIndex - 1, 0, targetField); + } else { + newFields.splice(targetFieldIndex + 1, 0, targetField); + } + setTimeout(()=>{ + setTableFields([ + ...newFields + ]); + if (refreshFieldsListRef.current) refreshFieldsListRef.current((prev)=>prev + 1); + }, 500); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/ExistingFieldEdit.jsx +var ExistingFieldEdit = __webpack_require__(9967); +// EXTERNAL MODULE: ./components/admin/databases/fields/fields-inputs/ForeignKey.jsx +var ForeignKey = __webpack_require__(3699); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/admin/databases/ClonedSingleTableFieldCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.field + * @param {React.Dispatch>} [props.setTargetField] + * @param {Object} [props.fieldIndex] + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch>} props.setTableFields + * @param {any} [props.refreshFieldsListRef] + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.currentTable + * @param {import("@/package-shared/types").UserType} props.user + * @param {boolean} props.isDelegated + * @param {React.Dispatch>} props.setLoading + */ function ClonedSingleTableFieldCard({ field , setTargetField , fieldIndex , tableFields , setTableFields , refreshFieldsListRef , database , currentTable , user , isDelegated , setLoading , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [fieldData, setFieldData] = external_react_default().useState(field); + const [activeEdit, setActiveEdit] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full table-field-wrapper" + (activeEdit ? " shadow-2xl shadow-slate-700/40 relative z-50" : ""), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover items-center w-full py-4" + (activeEdit ? " rounded-t" : " rounded") + (fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) ? " text-slate-400 pointer-events-none border-slate-200 border" : " light-gray"), + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold" + (fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) ? " dark:text-slate-500" : " dark:text-white"), + children: fieldData.fieldName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs py-1 px-2 bg-slate-100 dark:bg-slate-700 dark:text-slate-200 rounded ", + children: fieldData.dataType + }), + fieldData?.foreignKey && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "text-xs bg-primary text-white px-2 py-0.5 rounded-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Foreign Key: " + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + fieldData.foreignKey.destinationTableName, + " (", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: fieldData.foreignKey.destinationTableColumnName + }), + " ", + ")" + ] + }) + ] + }), + fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300 text-sm font-semibold ml-0 md:ml-auto", + children: "Default Field" + }), + !isDelegated && !fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) && fieldData.dataType?.match(/INT/) && !fieldData.foreignKey && !database?.active_clone?.toString()?.match(/1/) ? /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-0 md:ml-auto flex-wrap", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined py-1 text-xs gray", + onClick: (e)=>{ + if (activeEdit) { + setActiveEdit(false); + } else { + setActiveEdit(true); + } + }, + style: { + color: "var(--slate-500)" + }, + children: "Add Foreign Key" + }) + }) : !isDelegated && !fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) && fieldData.dataType?.match(/INT/) && !database?.active_clone?.toString()?.match(/1/) ? /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-0 md:ml-auto flex-wrap", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button py-1 text-xs light-gray", + onClick: (e)=>{ + if (window.confirm("Delete this foreign Key?")) { + delete field.foreignKey; + setLoading(true); + (0,fetchApi/* default */.Z)("/api/updateClonedTableForeignKeys", { + method: "post", + body: { + tableData: currentTable, + database: database.db_full_name, + dbSlug: database.db_slug, + delegated: window.location?.search?.match(/delegated=true/i) ? true : false + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert("Update Failed, Please Try again."); + } + }); + } + }, + style: { + color: "var(--slate-500)" + }, + children: "Delete Foreign Key" + }) + }) : /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}) + ] + }), + activeEdit && !isDelegated && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "card col w-full -mt-5 pt-0 no-hover", + children: /*#__PURE__*/ jsx_runtime_.jsx(ForeignKey/* default */.Z, { + targetField: field, + setFieldData: setFieldData, + tableFields: tableFields, + setTableFields: setTableFields, + database: database, + currentTable: currentTable, + user: user, + setActiveEdit: setActiveEdit, + activeClonedTable: true + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./functions/frontend/addNewField.js +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 2 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [ExistingFieldEdit.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\ExistingFieldEdit.jsx + * `import` Statement Found in [NewFieldTemp.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\NewFieldTemp.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {number} params.fieldIndex + * @param {React.Dispatch>} params.setTableFields + * @param {React.MutableRefObject>>} params.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} params.payload + * + * @requires search-field name attribute + */ function addNewField({ fieldIndex , setTableFields , refreshFieldsListRef , payload , }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ setTableFields((prev)=>{ + let newArray = prev; + newArray.splice(fieldIndex, 1, payload); + return newArray; + }); + // setRefresh && setRefresh((prev) => prev + 1); + // setPageRefresh && setPageRefresh((prev) => prev + 1); + if (refreshFieldsListRef?.current) refreshFieldsListRef.current((prev)=>prev + 1); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: ./components/admin/databases/MoreOptionsModal.jsx + 5 modules +var MoreOptionsModal = __webpack_require__(4209); +// EXTERNAL MODULE: ./components/admin/databases/fields/text/JSONTextOption.jsx +var JSONTextOption = __webpack_require__(4838); +;// CONCATENATED MODULE: ./components/admin/databases/NewFieldFormContent.jsx +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 1 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [TableFields.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\TableFields.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ let NewFieldFormContent_timeout; +/** //////////////////////////////////////////////////////////////////////////////// */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} [props.tableFields] + * @param {React.Dispatch>} props.setTableFields + * @param {any} props.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {import("@/package-shared/types").UserType} props.user + * @param {boolean} props.isNewField + * @param {string} props.literalValue + * @param {React.Dispatch>} props.setLiteralValue + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.tempFieldData + * @param {React.Dispatch>} props.setTempFieldData + * @param {string} props.dataTypeValue + * @param {React.Dispatch>} props.setDataTypeValue + * @param {string} props.dataType + * @param {React.Dispatch>} props.setDataType + * @param {string} props.dataTypeDesc + * @param {React.Dispatch>} props.setDataTypeDesc + */ function NewFieldFormContent({ fieldIndex , setTableFields , database , user , isNewField , setLiteralValue , tempFieldData , setTempFieldData , dataTypeValue , setDataTypeValue , dataType , setDataType , dataTypeDesc , setDataTypeDesc , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const varcharDesc = "Varchar is simply letters and numbers within the range 0 - 255"; + const dataTypes = __webpack_require__(9594); + /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.LegacyRef} */ const newFieldRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + if (!newFieldRef.current) return; + newFieldRef.current.scrollIntoView({ + block: "center", + behavior: "smooth" + }); + newFieldRef.current.querySelector("input")?.focus(); + }, []); + const isLiteral = Boolean(dataType.match(/uuid/i)); + /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + isNewField && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "absolute -top-4 text-sm bg-fuchsia-600 dark:bg-white text-white dark:text-fuchsia-800 px-3 py-1 rounded-full", + children: "New Field" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-4 flex-wrap xl:flex-nowrap flex-col xl:flex-row items-stretch w-full xl:w-auto", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_name", + children: "Field Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "new_field_name", + id: "new_field_name", + placeholder: "Eg. post_title", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const parsedValue = inputEl.value.toLowerCase().replace(/ /g, "_"); + inputEl.value = parsedValue; + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-4 xl:gap-0.5", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-start flex-wrap xl:flex-nowrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_data_type", + children: "Data Type" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper reversed text-sm w-full items-start gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex", + children: "Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mt-0 xl:-mt-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: dataTypeDesc + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full xl:w-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "new_field_data_type", + id: "new_field_data_type", + className: "w-full xl:w-auto", + onChange: (e)=>{ + /** @type {HTMLSelectElement} */ // @ts-ignore + const selectEl = e.target; + setDataType(selectEl.value); + selectEl.childNodes.forEach((/** @type {any} */ option)=>{ + if (option.value === selectEl.value) { + setDataTypeDesc(option.dataset.desc); + } + if (option.value === selectEl.value && option.dataset.literal) { + setLiteralValue(option.dataset.literal); + } + }); + }, + children: dataTypes.map((type, index)=>{ + if (type.name.match(/VARCHAR/)) { + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: type.name, + "data-desc": type.description, + children: type.title + "(" + (dataTypeValue ? dataTypeValue : 200) + ")" + }, index + 1); + } else { + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: type.name, + "data-desc": type.description, + "data-literal": type.valueLiteral || undefined, + children: type.title + }, index + 1); + } + }) + }), + dataType.match(/VARCHAR/) && /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "number", + defaultValue: dataTypeValue, + className: "px-2", + style: { + maxWidth: "60px" + }, + max: 255, + min: 5, + onChange: (e)=>{ + setDataTypeValue(e.target.value); + } + }) + ] + }) + ] + }), + dataType?.match(/text/i) && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(JSONTextOption/* default */.Z, { + targetField: tempFieldData + }) + }), + !isLiteral && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_required", + children: "Required?" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "new_field_required", + id: "new_field_required", + className: "px-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }) + ] + }), + !isLiteral && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_default_value", + children: "Default Value (optional)" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "new_field_default_value", + id: "new_field_default_value", + placeholder: "Default Value" + }) + ] + }), + !isLiteral && /*#__PURE__*/ jsx_runtime_.jsx(MoreOptionsModal/* default */.Z, { + database, + setFieldData: setTempFieldData, + targetField: tempFieldData, + user, + fieldIndex + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "secondary mt-auto flex-wrap xl:flex-nowrap w-full xl:w-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "secondary mt-auto py-3 w-full sm:w-auto justify-center grow", + children: "Add Field" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined-gray mt-auto py-2.5 w-full sm:w-auto justify-center grow", + onClick: (e)=>{ + setTableFields((prev)=>prev.filter((field, index)=>index != fieldIndex)); + }, + children: "Cancel" + }) + ] + }) + ] + }); +/** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ } /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ + +;// CONCATENATED MODULE: ./components/admin/databases/NewFieldTemp.jsx +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 1 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [TableFields.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\TableFields.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ let NewFieldTemp_timeout; +/** //////////////////////////////////////////////////////////////////////////////// */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} [props.tableFields] + * @param {React.Dispatch>} props.setTableFields + * @param {any} props.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {import("@/package-shared/types").UserType} props.user + */ function NewFieldTemp({ fieldIndex , tableFields , setTableFields , refreshFieldsListRef , database , currentTable , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const varcharDesc = "Varchar is simply letters and numbers within the range 0 - 255"; + const dataTypes = __webpack_require__(9594); + /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [dataType, setDataType] = external_react_default().useState("VARCHAR"); + const [dataTypeValue, setDataTypeValue] = external_react_default().useState("200"); + // const dataTypeDescState = React.useState(); + const [dataTypeDesc, setDataTypeDesc] = external_react_default().useState(varcharDesc); + /** @type {any} */ const tempFieldDataState = external_react_default().useState({}); + /** @type { [tempFieldData: import("@/package-shared/types").DSQL_FieldSchemaType, setTempFieldData: React.Dispatch>] } */ const [tempFieldData, setTempFieldData] = tempFieldDataState; + /** @type {React.LegacyRef} */ const newFieldRef = external_react_default().useRef(); + const [literalValue, setLiteralValue] = external_react_default().useState(""); + external_react_default().useEffect(()=>{ + if (!newFieldRef.current) return; + newFieldRef.current.scrollIntoView({ + block: "center", + behavior: "smooth" + }); + newFieldRef.current.querySelector("input")?.focus(); + }, []); + const isLiteral = Boolean(dataType.match(/uuid/i)); + /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full mt-1 flex-wrap relative z-0 hover:z-20", + // @ts-ignore + ref: newFieldRef, + children: /*#__PURE__*/ jsx_runtime_.jsx("form", { + className: "flex flex-row items-start gap-4 w-full justify-between border border-solid p-4 pt-6 border-slate-400 rounded focus:shadow-lg shadow-slate-400/40 dark:shadow-black/30 relative flex-wrap xl:flex-nowrap shadow-xl", + onSubmit: (e)=>{ + e.preventDefault(); + /** @type {import("@/package-shared/types").DSQL_ForeignKeyType | undefined} */ const targetForeignKey = tempFieldData.foreignKey; + if (targetForeignKey && !targetForeignKey.destinationTableName) { + delete tempFieldData.foreignKey; + } + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + let new_field_name = formEl["new_field_name"].value; + let new_field_data_type = formEl["new_field_data_type"].value; + let new_field_required = formEl["new_field_required"]?.value; + let new_field_default_value = formEl["new_field_default_value"]?.value; + let new_field_encryption = formEl["encryption_field"]?.value; + let rich_text_option = formEl["rich_text_option"]?.value; + const foreignKeyElement = formEl["foreign_key_field"]; + const foreignKeyDestinationTableElement = formEl["foreign_key_destination_table_name"]; + const foreignKeyDestinationTableColumnElement = formEl["foreign_key_destination_table_column_name"]; + let foreign_key_field = foreignKeyElement?.value; + let newFieldObject = { + ...tempFieldData, + fieldName: new_field_name, + dataType: tempFieldData?.dataType && tempFieldData?.foreignKey ? tempFieldData.dataType : new_field_data_type?.match(/VARCHAR/) ? `${new_field_data_type}(${dataTypeValue})` : new_field_data_type + }; + if (new_field_required?.match(/yes/i)) { + newFieldObject.notNullValue = true; + } else if (!new_field_default_value?.match(/./)) { + newFieldObject.nullValue = true; + } + if (new_field_default_value?.match(/./)) { + newFieldObject.defaultValue = new_field_default_value; + } + if (new_field_encryption?.match(/yes/i)) { + newFieldObject.encrypted = true; + } + if (foreignKeyDestinationTableColumnElement?.value?.match(/./i) && !foreignKeyDestinationTableColumnElement?.value?.match(/^--$/i)) { + newFieldObject.dataType = foreignKeyDestinationTableColumnElement.dataset.dataType; + newFieldObject.foreignKey = { + foreignKeyName: foreignKeyDestinationTableColumnElement.dataset.foreignKeyName, + destinationTableName: foreignKeyDestinationTableElement.dataset.destinationTableName, + destinationTableColumnName: foreignKeyDestinationTableColumnElement.dataset.destinationTableColumnName, + cascadeDelete: true + }; + } + if (rich_text_option?.match(/yes/i)) { + newFieldObject.richText = true; + } + if (isLiteral) { + newFieldObject.defaultValueLiteral = literalValue; + newFieldObject.nullValue = false; + } else { + delete newFieldObject.defaultValueLiteral; + } + console.log("newFieldObject", newFieldObject); + addNewField({ + fieldIndex, + setTableFields, + refreshFieldsListRef, + payload: newFieldObject + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(NewFieldFormContent, { + database, + fieldIndex, + isNewField: true, + literalValue, + refreshFieldsListRef, + setLiteralValue, + setTableFields, + user, + currentTable, + tableFields, + tempFieldData, + setTempFieldData, + dataTypeValue, + setDataTypeValue, + dataType, + setDataType, + dataTypeDesc, + setDataTypeDesc + }) + }) + }); +/** //////////////////////////////////////// */ /** //////////////////////////////////////// */ /** //////////////////////////////////////// */ } /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ /** //////////////////////////////////////////////////////////////////////////////// */ + +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/admin/databases/SingleTableFieldCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let SingleTableFieldCard_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.field + * @param {React.Dispatch>} props.setTargetField + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch>} props.setTableFields + * @param {React.MutableRefObject> | undefined>} props.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {any} props.confirmedDelegetedUser + * @param {import("@/package-shared/types").UserType} props.user + */ function SingleTableFieldCard({ field , setTargetField , fieldIndex , tableFields , setTableFields , refreshFieldsListRef , database , currentTable , confirmedDelegetedUser , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [fieldData, setFieldData] = external_react_default().useState(field); + const [activeEdit, setActiveEdit] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full table-field-wrapper" + (activeEdit ? " shadow-2xl shadow-slate-300/40 dark:shadow-black/30 relative z-50" : ""), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover items-center w-full py-4" + (activeEdit ? " rounded-t" : " rounded") + (fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) ? " text-slate-400 pointer-events-none border-slate-200 border" : " light-gray"), + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold" + (fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) ? " dark:text-slate-500" : " dark:text-white"), + children: fieldData.fieldName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs py-1 px-2 bg-slate-100 dark:bg-slate-700 dark:text-slate-200 rounded ", + children: fieldData.dataType + }), + fieldData?.foreignKey && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "text-xs bg-primary text-white px-2 py-0.5 rounded-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Foreign Key: " + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + fieldData.foreignKey.destinationTableName, + " (", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: fieldData.foreignKey.destinationTableColumnName + }), + " ", + ")" + ] + }) + ] + }), + fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300 text-sm font-semibold ml-0 md:ml-auto", + children: "Default Field" + }), + !fieldData.fieldName?.match(defaultFieldsRegexp/* default */.Z) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-0 md:ml-auto flex-wrap", + children: (!isDelegated || isDelegated && isTableEditable) && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined py-1 text-xs gray", + onClick: (e)=>{ + if (activeEdit) { + setActiveEdit(false); + } else { + setActiveEdit(true); + } + }, + style: { + color: "var(--slate-500)" + }, + children: "Edit" + }), + !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined py-1 text-xs gray", + onClick: (e)=>{ + if (window.confirm(`Delete "${field.fieldName}"?`)) { + setTableFields((prev)=>prev.filter((field, index)=>index != fieldIndex)); + } + }, + style: { + color: "var(--slate-500)" + }, + children: "Delete" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray p-2 w-8 h-8 rounded-full rotate-180", + onClick: (e)=>{ + reorderField({ + tableFields, + setTableFields, + refreshFieldsListRef, + order: "up", + field, + e + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronDown, { + size: 20 + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray p-2 w-8 h-8 rounded-full", + onClick: (e)=>{ + reorderField({ + tableFields, + setTableFields, + refreshFieldsListRef, + order: "down", + field, + e + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronDown, { + size: 20 + }) + }) + ] + }) + ] + }) + }) + ] + }), + activeEdit && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full", + children: /*#__PURE__*/ jsx_runtime_.jsx(ExistingFieldEdit/* default */.Z, { + fieldIndex: fieldIndex, + tableFields: tableFields, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + targetField: field, + setActiveEdit: setActiveEdit, + database: database, + currentTable: currentTable, + user: user + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/functions/generateTypeDefinition.js +var generateTypeDefinition = __webpack_require__(5753); +;// CONCATENATED MODULE: ./components/admin/databases/TableFields.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let reactKey = 1; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch>} props.setTableFields + * @param {React.Dispatch>} props.setTargetField + * @param {React.MutableRefObject> | undefined>} props.refreshFieldsListRef + * @param {boolean} [props.updateTable] + * @param {(setLoading?: React.Dispatch>) => void} [props.updateTableAfterFieldsUpdateFunction] + * @param {boolean} [props.collapsed] + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.table] + * @param {any} [props.confirmedDelegetedUser] + * @param {any} props.query + */ function TableFields({ user , tableFields , setTableFields , setTargetField , refreshFieldsListRef , updateTable , updateTableAfterFieldsUpdateFunction , collapsed , database , table , confirmedDelegetedUser , query , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const cloneParentDb = table?.childTable ? table.childTableDbFullName?.replace(new RegExp(/datasquirel_user_\d+_/), "") : null; + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [refresh, setRefresh] = external_react_default().useState(0); + refreshFieldsListRef.current = setRefresh; + const [loading, setLoading] = external_react_default().useState(false); + const [collapse, setCollapse] = external_react_default().useState(collapsed || false); + external_react_default().useEffect(()=>{ + const { Flip } = __webpack_require__(2700); + external_gsap_default().registerPlugin(Flip); + // @ts-ignore + const DSQL = window.DSQL; + if (DSQL) { + DSQL.Flip = Flip; + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (isDelegated && !isTableEditable) { + return /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}); + } + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper green", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + table?.childTable ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left title", + children: "Fields" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray", + onClick: (e)=>{ + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "JavaScript", + table, + query, + user + }); + if (txt) { + navigator.clipboard.writeText(txt).then(()=>{ + window.alert("JavaScript Type Definition Copied"); + }); + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Copy TypeDef (JS)" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray", + onClick: (e)=>{ + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "TypeScript", + table, + query, + user + }); + if (txt) { + navigator.clipboard.writeText(txt).then(()=>{ + window.alert("TypeScript Type Definition Copied"); + }); + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Copy TypeDef (TS)" + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col w-full", + style: collapse ? { + maxHeight: "200px" + } : {}, + children: tableFields && tableFields[0] && tableFields.map((field, index)=>{ + reactKey++; + return /*#__PURE__*/ jsx_runtime_.jsx(ClonedSingleTableFieldCard, { + field: field, + fieldIndex: index, + setTargetField: setTargetField, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + tableFields: tableFields, + database: database, + setLoading: setLoading, + currentTable: table, + user: user, + isDelegated: isDelegated + }, reactKey); + }) + }), + collapsed && /*#__PURE__*/ jsx_runtime_.jsx(ExpandBlock/* default */.Z, { + collapse: collapse || false, + setCollapse: setCollapse + }) + ] + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left title", + children: "Fields" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button secondary outlined", + onClick: (e)=>{ + if (collapse) setCollapse(false); + addNewTempField({ + setTableFields, + tableFields, + setRefresh, + refreshFieldsListRef + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Field" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray", + onClick: (e)=>{ + if (!table) return; + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "JavaScript", + table, + query, + user + }); + if (txt) { + navigator.clipboard.writeText(txt).then(()=>{ + window.alert("JavaScript Type Definition Copied"); + }); + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Copy TypeDef (JS)" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray", + onClick: (e)=>{ + if (!table) return; + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "TypeScript", + table, + query, + user + }); + if (txt) { + navigator.clipboard.writeText(txt).then(()=>{ + window.alert("TypeScript Type Definition Copied"); + }); + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Copy TypeDef (TS)" + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full", + style: collapse ? { + maxHeight: "200px" + } : {}, + children: [ + tableFields && tableFields[0] && tableFields.map((field, index)=>{ + reactKey++; + if (field.newTempField) { + return /*#__PURE__*/ jsx_runtime_.jsx(NewFieldTemp, { + fieldIndex: index, + tableFields: tableFields, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + database: database, + currentTable: table, + user: user + }, reactKey); + } else { + return /*#__PURE__*/ jsx_runtime_.jsx(SingleTableFieldCard, { + field: field, + fieldIndex: index, + setTargetField: setTargetField, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + tableFields: tableFields, + database: database, + currentTable: table, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }, reactKey); + } + }), + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray w-full more-padding", + style: { + borderStyle: "dashed" + }, + onClick: (e)=>{ + if (collapse) setCollapse(false); + addNewTempField({ + setTableFields, + tableFields, + setRefresh, + refreshFieldsListRef + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Field" + }) + ] + }), + updateTable && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "secondary w-full py-3", + onClick: (e)=>{ + setLoading(true); + updateTableAfterFieldsUpdateFunction && updateTableAfterFieldsUpdateFunction(setLoading); + }, + children: "Update Table Fields" + }) + ] + }) + ] + }), + collapsed && /*#__PURE__*/ jsx_runtime_.jsx(ExpandBlock/* default */.Z, { + collapse: collapse, + setCollapse: setCollapse + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4941.js b/dsql-app/.local_dist/server/chunks/4941.js new file mode 100644 index 0000000..7445177 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4941.js @@ -0,0 +1,558 @@ +"use strict"; +exports.id = 4941; +exports.ids = [4941]; +exports.modules = { + +/***/ 9230: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ CopySlug) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5050); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {{ + * slugText: string, + * justIcon?: boolean, + * title?: string, + * outlined?: boolean, + * }} props - React component props including { children } + */ function CopySlug({ slugText , justIcon , title , outlined }) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "button small-text" + (outlined ? " outlined gray bg-white" : " ghost light-gray"), + onClick: (e)=>{ + navigator.clipboard.writeText(slugText).then(()=>{ + alert(`Copied: "${slugText}"`); + }); + }, + style: outlined ? undefined : { + padding: 0 + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_3__.Copy, { + size: outlined ? 15 : 20 + }), + !justIcon && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-slate-500 dark:text-slate-300", + children: title ? title : "Copy Slug" + }) + ] + }); +} + + +/***/ }), + +/***/ 4941: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ExtraContentDatabase) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _CopySlug__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9230); +/* harmony import */ var _mui_icons_material_CodeRounded__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3849); +/* harmony import */ var _mui_icons_material_CodeRounded__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CodeRounded__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _DiskUsageComponent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6355); +/* harmony import */ var _functions_frontend_downloadApiStream__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(7851); +/* harmony import */ var _mui_icons_material_SendToMobileTwoTone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6500); +/* harmony import */ var _mui_icons_material_SendToMobileTwoTone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_SendToMobileTwoTone__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _mui_icons_material_SummarizeTwoTone__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7428); +/* harmony import */ var _mui_icons_material_SummarizeTwoTone__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_SummarizeTwoTone__WEBPACK_IMPORTED_MODULE_6__); +/* harmony import */ var _mui_icons_material_TipsAndUpdatesTwoTone__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(507); +/* harmony import */ var _mui_icons_material_TipsAndUpdatesTwoTone__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_TipsAndUpdatesTwoTone__WEBPACK_IMPORTED_MODULE_7__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(6729); +/* harmony import */ var _LoadingBlock__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(5264); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_9__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} [props.query] + * @param {any} [props.confirmedDelegetedUser] + * @param {import("@/package-shared/types").UserType} props.user + */ function ExtraContentDatabase({ database , query , confirmedDelegetedUser , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const { active_clone , active_clone_parent_db } = database; + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [links, setLinks] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-wrap justify-center gap-4", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper gap-4", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "relative", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-8 h-8 relative", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: database.db_image, + alt: "Database Image", + width: 20, + className: "w-full h-full rounded-full object-cover" + }), + confirmedDelegetedUser?.delegated && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: " absolute -bottom-2 left-5 gap-1", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: confirmedDelegetedUser.rootUserImage, + alt: "Root User Image", + className: "w-5 h-5 rounded-full object-cover border-2 border-white dark:border-slate-800 border-solid" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-xs", + children: confirmedDelegetedUser.rootUserEmail + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-semibold text-base" + (confirmedDelegetedUser?.delegated ? " -mt-3" : ""), + children: database.db_name + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_9__.ChevronDown, { + size: 20 + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown p-0", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/edit-database`, + className: "button plain-text more-padding normal-weight", + children: "Edit Database" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + !active_clone && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/add-database?duplicate=${database.db_full_name}`, + className: "button plain-text more-padding normal-weight", + children: "Duplicate Database" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/schema`, + className: "button plain-text more-padding normal-weight", + children: "Schema" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users`, + className: "button plain-text more-padding normal-weight", + children: "Database Users" + }), + !isDelegated && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(NonDelegatedSection, { + database: database, + user: user + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "vertical" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_CopySlug__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + slugText: database.db_slug, + title: `Copy Database Slug` + }), + !isDelegated && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "vertical" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/shell`, + className: "button ghost small-text", + style: { + height: "30px", + padding: 0 + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_9__.SquareTerminal, { + size: 20 + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-sm font-semibold", + children: "Shell" + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "vertical" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DiskUsageComponent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ## Buttons for Database Root Owner + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").UserType} props.user + */ function NonDelegatedSection({ database , user }) { + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + /** @type {React.RefObject} */ // @ts-ignore + const uploadSchemaButtonRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_LoadingBlock__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/shell`, + className: "button plain-text more-padding normal-weight", + children: "Shell" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + database?.remote_connected == 1 ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(DisconnectButton, { + database: database + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/connect`, + className: "button plain-text more-padding normal-weight", + children: "Connect" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + className: "button plain-text more-padding normal-weight w-full", + onClick: (e)=>{ + (0,_functions_frontend_downloadApiStream__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)({ + url: `/api/exportDatabase?dbName=${database.db_full_name}`, + fileName: `${database.db_full_name}.sql` + }); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_SendToMobileTwoTone__WEBPACK_IMPORTED_MODULE_5___default()), { + fontSize: "small", + color: "action", + className: "opacity-50" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Export Database" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + name: "upload-update-schema", + id: "", + ref: uploadSchemaButtonRef, + className: "hidden" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + className: "button green outlined more-padding normal-weight w-full rounded-none -mb-[1px]", + onClick: (e)=>{ + if (!uploadSchemaButtonRef.current) return; + uploadSchemaButtonRef.current.addEventListener("change", (e)=>{ + /** + * @type {HTMLInputElement} + */ // @ts-ignore + const inputEl = e.target; + const file = inputEl.files?.[0]; + if (!file) { + alert("No File Selected"); + return; + } + var reader = new FileReader(); + reader.onload = function(ev) { + var fileContent = ev.target?.result; + if (!fileContent) { + alert("Invalid File!"); + } + try { + const fileContentString = fileContent?.toString(); + if (!fileContentString) { + throw new Error("Invalid File!"); + } + const schemaObject = JSON.parse(fileContentString); + if (window.confirm("Are you sure you want to use this schema file for the current database?")) { + if (window.confirm("Remember if any existing table doesn't exist in the new schema file that table and all its content will be erased forever. Continue?")) { + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .Z)("/api/user-schema/replace-database-schema", { + method: "POST", + body: { + schema: schemaObject, + dbId: database.id + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }).finally(()=>{ + setLoading(false); + }); + } + } + } catch (/** @type {any} */ error) { + alert("Invalid File. Please enter a valid JSON file"); + } + }; + reader.readAsText(file); + // if (window.confirm("Update?")) { + // console.log("Updating"); + // } + }); + uploadSchemaButtonRef.current?.click(); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_TipsAndUpdatesTwoTone__WEBPACK_IMPORTED_MODULE_7___default()), { + fontSize: "small", + color: "action", + className: "opacity-50 text-inherit" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Update From Schema" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + className: "button secondary outlined more-padding normal-weight w-full rounded-none", + onClick: (e)=>{ + (0,_functions_frontend_downloadApiStream__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)({ + url: `/api/downloadDatabaseSchema?dbName=${database.db_full_name}`, + fileName: `${database.db_full_name}.json` + }); + // fetchApi(`/api/downloadDatabaseSchema?dbName=${database.db_full_name}`).then((res)=>{ + // console.log(res); + // }) + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_SummarizeTwoTone__WEBPACK_IMPORTED_MODULE_6___default()), { + fontSize: "small", + color: "action", + className: "opacity-50 text-inherit" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Download Schema" + }) + ] + }) + ] + }); +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ### Disconnect Remote Db Button + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + */ function DisconnectButton({ database }) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "button plain-text more-padding normal-weight w-full", + onClick: (e)=>{ + if (!window.confirm("Disconnect this Database from the remote host?")) return; + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .Z)(`/api/connect/disconnect`, { + method: "POST", + body: { + dbId: database.id + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + console.log(res); + alert(res.msg || "Remote disconnection failed. Please try again."); + } + }); + }, + children: "Disconnect" + }); +} + + +/***/ }), + +/***/ 7851: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ downloadApiStream) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {{ + * url: string, + * fileName: string, + * setLoading?: React.Dispatch>, + * }} params - params + * + * @requires search-field name attribute + */ function downloadApiStream({ url , fileName , setLoading }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ if (setLoading) setLoading(true); + fetch(url, { + method: "GET", + // @ts-ignore + headers: { + "x-csrf-auth": localStorage.getItem("csrf") + } + }).then((res)=>{ + return res.body; + }).then((body)=>{ + const reader = body?.getReader(); + if (reader) { + return new ReadableStream({ + start (controller) { + return pump(); + /** @type {() => any} */ function pump() { + return reader?.read().then(({ done , value })=>{ + // When no more data needs to be consumed, close the stream + if (done) { + controller.close(); + return; + } + // Enqueue the next data chunk into our target stream + controller.enqueue(value); + return pump(); + }); + } + } + }); + } + // console.log(body); + // const blob = new Blob([body.text], { type: "application/pdf" }); + // const url = URL.createObjectURL(blob); + // const link = document.createElement("a"); + // link.href = blob; + // link.download = `${database.db_full_name}.sql`; + // link.style.display = "none"; + // document.body.appendChild(link); + // link.click(); + // URL.revokeObjectURL(url); + // document.body.removeChild(link); + // setTimeout(() => { + // setLoading(false); + // }, 1000); + }).then((stream)=>{ + return new Response(stream); + }).then((response)=>response.blob()).then((blob)=>URL.createObjectURL(blob)).then((url)=>{ + const link = document.createElement("a"); + link.href = url; + link.download = fileName; + link.style.display = "none"; + document.body.appendChild(link); + link.click(); + URL.revokeObjectURL(url); + document.body.removeChild(link); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 1000); + }).catch((error)=>{ + console.log(error); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 1000); + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/4986.js b/dsql-app/.local_dist/server/chunks/4986.js new file mode 100644 index 0000000..6d20c7c --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/4986.js @@ -0,0 +1,86 @@ +"use strict"; +exports.id = 4986; +exports.ids = [4986]; +exports.modules = { + +/***/ 4986: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ActiveCloneDbBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {object} props.database + * @param {string} props.database.active_clone_parent_db + * @param {import("@/package-shared/types").UserType} props.user + */ function ActiveCloneDbBanner({ database , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const parentDbSlug = database.active_clone_parent_db?.replace(/datasquirel_user_\d+_/, ""); + const targetDbUrl = `/admin/${user?.id}/databases/${parentDbSlug}`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "info green", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text font-normal", + children: [ + "This database is an active clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: targetDbUrl, + target: "_blank", + className: "query-url", + children: parentDbSlug + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5114.js b/dsql-app/.local_dist/server/chunks/5114.js new file mode 100644 index 0000000..9ecf970 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5114.js @@ -0,0 +1,424 @@ +"use strict"; +exports.id = 5114; +exports.ids = [5114]; +exports.modules = { + +/***/ 5114: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ CreateAccountForm) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./functions/frontend/submitNewUserForm.js +// @ts-check + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # Submit New Image Form + * @param {object} param0 + * @param {*} param0.e + * @param {React.Dispatch>} param0.setLoading + * @param {import("@/package-shared/types").UserType} [param0.user] + * @param {*} [param0.image] + * @param {*} [param0.query] + */ async function submitNewUserForm({ e , setLoading , user , image , query , }) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + setLoading(true); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let formBody = { + first_name: e.target["first_name"].value, + last_name: e.target["last_name"].value, + email: user ? null : e.target["email_address"].value, + username: user ? null : e.target["username"].value, + password: user ? null : e.target["password"].value, + image: image ? image : null + }; + // @ts-ignore + if (query?.invite) formBody["inviteObject"] = query; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const apiRoute = user ? "/api/updateUser" : "/api/registerUser"; + (0,fetchApi/* default */.Z)(apiRoute, { + method: "post", + body: formBody + }, user ? true : false).then((res)=>{ + console.log(res); + if (!user && res?.insertId) { + localStorage.setItem("id", res.insertId); + (0,fetchApi/* default */.Z)("/api/loginUser", { + method: "post", + body: { + email: formBody.email, + password: formBody.password + } + }).then((_res)=>{ + console.log(_res); + localStorage.setItem("csrf", _res.user.csrf_k); + localStorage.setItem("stripe_id", _res.user.stripe_id); + localStorage.setItem("user", JSON.stringify(_res.userPayload)); + window.location.href = "/admin"; + }); + } else if (user && res?.user) { + // fetchApi("/api/reauthUser") + window.location.reload(); + } else if (res?.msg) { + alert(res.msg); + } + }).catch((err)=>{ + console.log(err); + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 2000); + }); +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/FormAlertBlock.jsx +var FormAlertBlock = __webpack_require__(7037); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/pages/login/SocialLogin.jsx + 3 modules +var SocialLogin = __webpack_require__(8374); +;// CONCATENATED MODULE: ./components/pages/create-account/CreateAccountForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// + + + + + +//////////////////////////////////////// +/** @type {any} */ let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {import("@/package-shared/types").CreateAccountQueryType} [props.query] + * @param {any} [props.image] + */ function CreateAccountForm({ user , query , image }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const defaultEmail = query?.email ? query.email : user?.email ? user.email : ""; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ alert: string | null, setAlert: React.Dispatch> ]} */ // @ts-ignore + const [alert, setAlert] = external_react_default().useState(null); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "relative w-full max-w-2xl flex-col items-start", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + !user && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "opacity-0" + }), + /*#__PURE__*/ jsx_runtime_.jsx(SocialLogin/* default */.Z, { + user: null, + userType: "admin", + setLoading: setLoading + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-center relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "bg-white dark:bg-slate-800 px-3 relative z-10", + children: "OR" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "absolute" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-start gap-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + submitNewUserForm({ + e, + setLoading, + user, + image, + query + }); + }, + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx(FormAlertBlock/* default */.Z, { + message: alert + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "first_name", + children: "First Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "first_name", + id: "first_name", + placeholder: "First Name", + autoComplete: "given-name", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + }, + defaultValue: user ? user.first_name : "", + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "last_name", + children: "Last Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "last_name", + id: "last_name", + placeholder: "Last Name", + autoComplete: "family-name", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + }, + defaultValue: user ? user.last_name : "", + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "username", + children: "Username" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "username", + id: "username", + placeholder: "Username", + autoComplete: "username", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + (0,fetchApi/* default */.Z)(`/api/checkDuplicateData?type=username&value=${inputEl.value}&tableName=users`).then((res)=>{ + console.log(res); + if (res?.result) { + setAlert("Username Already Exists"); + inputEl.classList.add("warning"); + } else { + setAlert(null); + inputEl.classList.remove("warning"); + } + }); + }, 300); + }, + defaultValue: user ? user.username : "", + required: user ? false : true, + readOnly: user ? true : false + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "email_address", + children: "Email Address" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "email", + name: "email_address", + id: "email_address", + placeholder: "Email Address", + autoComplete: "email", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + (0,fetchApi/* default */.Z)(`/api/checkDuplicateData?type=email&value=${inputEl.value}&tableName=users`).then((res)=>{ + console.log(res); + if (res?.result) { + setAlert("Email Already Exists"); + inputEl.classList.add("warning"); + } else { + setAlert(null); + inputEl.classList.remove("warning"); + } + }); + }, 300); + }, + defaultValue: defaultEmail, + required: true, + readOnly: user ? true : false + }) + ] + }), + !user && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "password", + children: "Password" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "password", + name: "password", + id: "password", + placeholder: "Password", + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "confirm_password", + children: "Confirm Password" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "password", + name: "confirm_password", + id: "confirm_password", + placeholder: "Confirm Password", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let passwordInput = inputEl.closest("form")?.["password"].value; + let passwordRepeatInput = inputEl.value; + if (passwordInput === passwordRepeatInput) { + inputEl.classList.remove("warning"); + } else { + inputEl.classList.add("warning"); + } + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm", + children: [ + 'By clicking "Create Account" you agree to our', + " ", + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/terms", + target: "_blank", + className: "font-bold", + children: "Terms and Conditions" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "w-full", + children: user ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Update Account Info" + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Create Account" + }) + }), + !user && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm", + children: [ + "Already Have an Account?", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/login", + className: "font-bold", + children: "Login" + }) + ] + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5116.js b/dsql-app/.local_dist/server/chunks/5116.js new file mode 100644 index 0000000..4d6a247 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5116.js @@ -0,0 +1,99 @@ +"use strict"; +exports.id = 5116; +exports.ids = [5116]; +exports.modules = { + +/***/ 5116: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const http = __webpack_require__(3685); +const decrypt = __webpack_require__(5304); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} grabDelegatedUserFromCookieReturn + * @property {number} dbUserId + * @property {number} [dbUserId] + * @property {number} [rootUserId] + * @property {string} [rootUserName] + * @property {string} [rootUserEmail] + * @property {string} [rootUserImage] + * @property {string} [databaseFullName] + * @property {string} [databaseSlug] + * @property {string[]} [allowedTables] + * @property {string} [priviledges] + * @property {string} [database] + * @property {boolean} [delegated] + */ /** + * @param {object} params - user id + * @param {import("next").NextApiRequest | http.IncomingMessage & { cookies: Partial<{ [key: string]: string; }>}} params.request - HTTPS request object + * @param {string | string[]} params.databaseSlug - Database name slug + * @param {{ id: number, first_name: string, last_name: string }} params.user + * @param {any} params.query - query params + * + * @returns {Promise} new user auth object payload + */ module.exports = async function grabDelegatedUserFromCookie({ request , databaseSlug , user , query , }) { + try { + /** + * Fetch user + * + * @description Fetch user from db + */ let dbUserId = user.id; + let delegatedUserObject = null; + if (!query?.delegated) return { + dbUserId + }; + const rootUserId = query.dbUserId; + const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${rootUserId}_${databaseSlug}`; + const tokenName = `${process.env.DSQL_USER_DELEGATED_DB_COOKIE_PREFIX}${dbFullName}`; + try { + if (!request.cookies?.[tokenName]) throw new Error("Cookie not present"); + // @ts-ignore + const decryptedToken = decrypt(request.cookies[tokenName]); + if (!decryptedToken) throw new Error("Invalid Token"); + delegatedUserObject = JSON.parse(decryptedToken); + if (delegatedUserObject.databaseSlug === databaseSlug) { + dbUserId = delegatedUserObject.rootUserId; + return { + dbUserId: dbUserId, + rootUserId: delegatedUserObject.rootUserId, + rootUserName: delegatedUserObject.rootUserName, + rootUserEmail: delegatedUserObject.rootUserEmail, + rootUserImage: delegatedUserObject.rootUserImage, + databaseFullName: delegatedUserObject.databaseFullName, + databaseSlug: delegatedUserObject.databaseSlug, + allowedTables: delegatedUserObject.allowedTables, + priviledges: delegatedUserObject.priviledges, + database: delegatedUserObject.databaseSlug, + delegated: true + }; + } + } catch (error) { + // serverError({ + // component: "grabDelegatedUserFromCookie", + // message: error.message, + // user: user, + // }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return { + dbUserId + }; + } catch (error1) { + return null; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5264.js b/dsql-app/.local_dist/server/chunks/5264.js new file mode 100644 index 0000000..9cdf134 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5264.js @@ -0,0 +1,63 @@ +"use strict"; +exports.id = 5264; +exports.ids = [5264]; +exports.modules = { + +/***/ 5264: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ LoadingBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Loading Block Functional Component + * ============================================================================== + * @param {{ + * width?: string, + * position?: *, + * style?: import("react").CSSProperties, + * borderWidth?: string, + * screen?: boolean, + * title?: string, + * }} props - React Component Props + */ function LoadingBlock({ width , position , style , borderWidth , screen , title , }) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: " top-0 left-0 w-full h-full flex items-center justify-center gap-4 bg-white/80 dark:bg-slate-800/80 z-50" + (screen ? " fixed" : " absolute"), + style: { + ...style, + position: position, + zIndex: 20000 + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "general_loader", + style: width ? { + width: width, + height: width, + minWidth: width, + borderWidth: borderWidth ? borderWidth : "4px" + } : {} + }), + title ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: title + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}) + ] + }); +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5304.js b/dsql-app/.local_dist/server/chunks/5304.js new file mode 100644 index 0000000..001c37a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5304.js @@ -0,0 +1,46 @@ +"use strict"; +exports.id = 5304; +exports.ids = [5304]; +exports.modules = { + +/***/ 5304: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { scryptSync , createDecipheriv } = __webpack_require__(6113); +const { Buffer } = __webpack_require__(4300); +// const serverError = require("./serverError"); +/** + * @param {string} encryptedString + * @returns {string | null} + */ const decrypt = (encryptedString)=>{ + // /** @type {import("crypto").CipherCCMTypes} */ + const algorithm = "aes-192-cbc"; + const password = process.env.DSQL_ENCRYPTION_PASSWORD || ""; + const salt = process.env.DSQL_ENCRYPTION_SALT || ""; + // /** @type {import("crypto").CipherKey} */ + let key = scryptSync(password, salt, 24); + let iv = Buffer.alloc(16, 0); + // @ts-ignore + const decipher = createDecipheriv(algorithm, key, iv); + /** ********************* Decrypt String */ try { + let decrypted = decipher.update(encryptedString, "hex", "utf8"); + decrypted += decipher.final("utf8"); + return decrypted; + } catch (error) { + // serverError({ + // component: "decrypt", + // message: error.message, + // user: {}, + // }); + return null; + } +}; +module.exports = decrypt; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5313.js b/dsql-app/.local_dist/server/chunks/5313.js new file mode 100644 index 0000000..99fe248 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5313.js @@ -0,0 +1,516 @@ +"use strict"; +exports.id = 5313; +exports.ids = [5313]; +exports.modules = { + +/***/ 8282: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ SuAdminLayout) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "next/head" +var head_ = __webpack_require__(968); +var head_default = /*#__PURE__*/__webpack_require__.n(head_); +// EXTERNAL MODULE: ./components/general/Logo.jsx +var Logo = __webpack_require__(4017); +// EXTERNAL MODULE: external "@mui/icons-material/CottageTwoTone" +var CottageTwoTone_ = __webpack_require__(386); +var CottageTwoTone_default = /*#__PURE__*/__webpack_require__.n(CottageTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/PeopleAltTwoTone" +var PeopleAltTwoTone_ = __webpack_require__(8245); +var PeopleAltTwoTone_default = /*#__PURE__*/__webpack_require__.n(PeopleAltTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/ErrorTwoTone" +var ErrorTwoTone_ = __webpack_require__(6094); +var ErrorTwoTone_default = /*#__PURE__*/__webpack_require__.n(ErrorTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/BackupTwoTone" +var BackupTwoTone_ = __webpack_require__(9318); +var BackupTwoTone_default = /*#__PURE__*/__webpack_require__.n(BackupTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DocumentScannerTwoTone" +var DocumentScannerTwoTone_ = __webpack_require__(6817); +// EXTERNAL MODULE: external "@mui/icons-material/TerminalTwoTone" +var TerminalTwoTone_ = __webpack_require__(415); +var TerminalTwoTone_default = /*#__PURE__*/__webpack_require__.n(TerminalTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/LockPersonTwoTone" +var LockPersonTwoTone_ = __webpack_require__(6547); +var LockPersonTwoTone_default = /*#__PURE__*/__webpack_require__.n(LockPersonTwoTone_); +;// CONCATENATED MODULE: ./layouts/components/SuAdminLayout/Aside.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ "use client"; + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + */ function Aside(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [collapseAsideMobile, setCollapseAsideMobile] = external_react_default().useState(true); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("aside", { + className: "aside" + (collapseAsideMobile ? " mobile-collapsed" : " mobile-expanded"), + style: { + maxWidth: collapseAsideMobile ? "250px" : "300px", + zIndex: 800 + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Logo/* default */.Z, { + adminAside: true, + collapseAsideMobile: collapseAsideMobile, + setCollapseAsideMobile: setCollapseAsideMobile + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "opacity-0 mt-4" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "main-links" + (collapseAsideMobile ? " hidden lg:flex" : " "), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su`, + "data-currentlink": `/su`, + "data-strictlink": "true", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((CottageTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Dashboard" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/users`, + "data-currentlink": `/su/users`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((PeopleAltTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Users" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/error-logs`, + "data-currentlink": `/su/error-logs`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((ErrorTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Error Logs" + }) + ] + }), + false && /*#__PURE__*/ 0, + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/backups`, + "data-currentlink": `/su/backups`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((BackupTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Backups" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/console`, + "data-currentlink": `/su/console`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((TerminalTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Console" + }) + ] + }), + true && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/envar`, + "data-currentlink": `/su/envar`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((LockPersonTwoTone_default()), { + className: "text-slate-400" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Env" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./components/general/ThemeSelector.jsx +var ThemeSelector = __webpack_require__(4981); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./layouts/components/SuAdminLayout/AdminHeader.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ "use client"; + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {import("@/package-shared/types").UserType} props.user + * @param {React.ReactNode} [props.extraHeaderContent] + */ function AdminHeader({ user , extraHeaderContent }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [activeUser, setActiveUser] = external_react_default().useState(user ? user : null); + external_react_default().useEffect(()=>{ + if (user?.logged_in_status) { + setActiveUser(user ? user : null); + } + }, [ + user + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "overflow-visible w-full px-0 md:px-8 py-0 flex justify-center bg-white dark:bg-slate-800 shadow-lg gap-4 dark:shadow-black/10 z-50 shadow-slate-900/5", + style: { + zIndex: 700, + border: "none" + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full items-center justify-between gap-4 md:gap-8", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "hidden xl:flex flex-col items-stretch grow fixed xl:static top-0 right-0 px-4 xl:px-0 shadow-xl xl:shadow-none h-screen xl:h-auto overflow-auto xl:overflow-visible w-screen sl:w-auto bg-white xl:bg-transparent pb-10 xl:pb-0", + id: "main-nav-content-wrapper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-center mb-2 flex xl:hidden", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/", + className: "hidden xl:flex", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/logo-icon-alt-2.png", + alt: "Logo Icon", + width: 37 + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray ml-auto", + onClick: (e)=>{ + /** @type {any} */ const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + border: "none" + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-4xl", + children: "✕" + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex items-center w-full gap-6 grow flex-col xl:flex-row justify-start xl:justify-between", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "gap-2 flex-col-reverse xl:flex-row gap-y-6 w-full xl:w-auto py-2", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "ml-auto dropdown-wrapper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "bg-white rounded-full overflow-hidden", + style: { + width: "36px", + height: "36px" + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/user_images/user-preset-thumbnail.png", + alt: "User Image", + width: 35, + className: "w-full h-full object-cover" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "Super User" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronDown, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown", + children: /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/su/logout`, + children: "Logout" + }) + }) + ] + }) + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-2", + children: /*#__PURE__*/ jsx_runtime_.jsx(ThemeSelector/* default */.Z, {}) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "bg-transparent w-16 p-4 gap-1.5 flex xl:hidden flex-col hover:bg-transparent transition-all ml-auto", + onClick: (e)=>{ + /** @type {any} */ const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + minWidth: "50px", + backgroundColor: "transparent" + }, + id: "main-header-hamburger-button", + "aria-label": "Mobile Hambutget Button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./functions/frontend/updateNavLinks.js +var updateNavLinks = __webpack_require__(9678); +;// CONCATENATED MODULE: ./layouts/SuAdminLayout.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React Props + * @param {React.ReactNode} props.children - children component + * @param {React.ReactNode} [props.head] - head Items + * @param {import("@/package-shared/types").UserType} props.user - user object + */ function SuAdminLayout({ children , head , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ external_react_default().useEffect(()=>{ + /** @type { NodeListOf } */ const links = document.querySelectorAll("aside .main-links a"); + (0,updateNavLinks/* default */.Z)({ + links: links + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)((head_default()), { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("link", { + rel: "stylesheet", + href: "/styles/admin.css" + }), + head + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "admin w-full flex items-start gap-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Aside, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("main", { + className: "relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(AdminHeader, { + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start gap-6 px-4 sl:px-8 py-8 bg-slate-50 dark:bg-slate-900", + children: children + }), + /*#__PURE__*/ jsx_runtime_.jsx("footer", { + className: "flex justify-center w-full items-center p-4", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "max-w-6xl w-full justify-center flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: "/", + className: "flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/logo-icon-alt-2.png", + alt: "Datasquirel Logo", + width: 30 + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-lg font-bold", + children: "Datasquirel" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm text-slate-400 dark:text-slate-600 text-center", + children: [ + new Date().getFullYear(), + " \xa9 Datasquirel. All rights reserved." + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/docs", + children: "Docs" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-25", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/terms", + children: "Terms" + }) + ] + }) + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5338.js b/dsql-app/.local_dist/server/chunks/5338.js new file mode 100644 index 0000000..097bcfd --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5338.js @@ -0,0 +1,176 @@ +"use strict"; +exports.id = 5338; +exports.ids = [5338]; +exports.modules = { + +/***/ 5338: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const encrypt = __webpack_require__(7547); +const sanitizeHtml = __webpack_require__(6109); +const sanitizeHtmlOptions = __webpack_require__(9544); +const updateDb = __webpack_require__(5886); +const updateDbEntry = __webpack_require__(5886); +const _ = __webpack_require__(6517); +const DB_HANDLER = __webpack_require__(2224); +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {("Master" | "Dsql User")} [params.dbContext] - What is the database context? "Master" + * or "Dsql User". Defaults to "Master" + * @param {("Read Only" | "Full Access")} [params.paradigm] - What is the paradigm for "Dsql User"? + * "Read only" or "Full Access"? Defaults to "Read Only" + * @param {string} [params.dbFullName] - Database full name + * @param {string} params.tableName - Table name + * @param {any} params.data - Data to add + * @param {import("../../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @param {string} [params.duplicateColumnName] - Duplicate column name + * @param {string} [params.duplicateColumnValue] - Duplicate column value + * @param {boolean} [params.update] - Update this row if it exists + * @param {string} [params.encryptionKey] - Update this row if it exists + * @param {string} [params.encryptionSalt] - Update this row if it exists + * + * @returns {Promise} + */ async function addDbEntry({ dbContext , paradigm , dbFullName , tableName , data , tableSchema , duplicateColumnName , duplicateColumnValue , update , encryptionKey , encryptionSalt , }) { + /** + * Initialize variables + */ const isMaster = dbContext?.match(/dsql.user/i) ? false : dbFullName && !dbFullName.match(/^datasquirel$/) ? false : true; + /** @type { any } */ const dbHandler = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (data?.["date_created_timestamp"]) delete data["date_created_timestamp"]; + if (data?.["date_updated_timestamp"]) delete data["date_updated_timestamp"]; + if (data?.["date_updated"]) delete data["date_updated"]; + if (data?.["date_updated_code"]) delete data["date_updated_code"]; + if (data?.["date_created"]) delete data["date_created"]; + if (data?.["date_created_code"]) delete data["date_created_code"]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ if (duplicateColumnName && typeof duplicateColumnName === "string") { + const duplicateValue = isMaster ? await dbHandler(`SELECT * FROM \`${tableName}\` WHERE \`${duplicateColumnName}\`=?`, [ + duplicateColumnValue + ]) : await dbHandler({ + paradigm: "Read Only", + database: dbFullName, + queryString: `SELECT * FROM \`${tableName}\` WHERE \`${duplicateColumnName}\`=?`, + queryValues: [ + duplicateColumnValue + ] + }); + if (duplicateValue?.[0] && !update) { + return null; + } else if (duplicateValue && duplicateValue[0] && update) { + return await updateDbEntry({ + dbContext, + paradigm, + dbFullName, + tableName, + data, + tableSchema, + encryptionKey, + encryptionSalt, + identifierColumnName: duplicateColumnName, + identifierValue: duplicateColumnValue || "" + }); + } + } + /** + * Declare variables + * + * @description Declare "results" variable + */ const dataKeys = Object.keys(data); + let insertKeysArray = []; + let insertValuesArray = []; + for(let i = 0; i < dataKeys.length; i++){ + try { + const dataKey = dataKeys[i]; + // @ts-ignore + let value = data?.[dataKey]; + const targetFieldSchemaArray = tableSchema ? tableSchema?.fields?.filter((field)=>field.fieldName == dataKey) : null; + const targetFieldSchema = targetFieldSchemaArray && targetFieldSchemaArray[0] ? targetFieldSchemaArray[0] : null; + if (value == null || value == undefined) continue; + if (targetFieldSchema?.encrypted) { + value = encrypt(value, encryptionKey, encryptionSalt); + console.log("DSQL: Encrypted value =>", value); + } + if (targetFieldSchema?.richText) { + value = sanitizeHtml(value, sanitizeHtmlOptions); + } + if (targetFieldSchema?.pattern) { + const pattern = new RegExp(targetFieldSchema.pattern, targetFieldSchema.patternFlags || ""); + if (!pattern.test(value)) { + console.log("DSQL: Pattern not matched =>", value); + value = ""; + } + } + insertKeysArray.push("`" + dataKey + "`"); + if (typeof value === "object") { + value = JSON.stringify(value); + } + if (typeof value == "number") { + insertValuesArray.push(String(value)); + } else { + insertValuesArray.push(value); + } + } catch (/** @type {any} */ error) { + console.log("DSQL: Error in parsing data keys =>", error.message); + continue; + } + } + //////////////////////////////////////// + if (!data?.["date_created"]) { + insertKeysArray.push("`date_created`"); + insertValuesArray.push(Date()); + } + if (!data?.["date_created_code"]) { + insertKeysArray.push("`date_created_code`"); + insertValuesArray.push(Date.now()); + } + //////////////////////////////////////// + if (!data?.["date_updated"]) { + insertKeysArray.push("`date_updated`"); + insertValuesArray.push(Date()); + } + if (!data?.["date_updated_code"]) { + insertKeysArray.push("`date_updated_code`"); + insertValuesArray.push(Date.now()); + } + //////////////////////////////////////// + const query = `INSERT INTO \`${tableName}\` (${insertKeysArray.join(",")}) VALUES (${insertValuesArray.map(()=>"?").join(",")})`; + const queryValuesArray = insertValuesArray; + const newInsert = isMaster ? await dbHandler(query, queryValuesArray) : await dbHandler({ + paradigm, + database: dbFullName, + queryString: query, + queryValues: queryValuesArray + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return newInsert; +} +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = addDbEntry; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5425.js b/dsql-app/.local_dist/server/chunks/5425.js new file mode 100644 index 0000000..3f9cd0c --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5425.js @@ -0,0 +1,46 @@ +"use strict"; +exports.id = 5425; +exports.ids = [5425]; +exports.modules = { + +/***/ 5425: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { scryptSync , createDecipheriv } = __webpack_require__(6113); +const { Buffer } = __webpack_require__(4300); +// const serverError = require("./serverError"); +/** + * @param {string} encryptedString + * @returns {string | null} + */ const decrypt = (encryptedString)=>{ + // /** @type {import("crypto").CipherCCMTypes} */ + const algorithm = "aes-192-cbc"; + const password = process.env.DSQL_ENCRYPTION_PASSWORD || ""; + const salt = process.env.DSQL_ENCRYPTION_SALT || ""; + // /** @type {import("crypto").CipherKey} */ + let key = scryptSync(password, salt, 24); + let iv = Buffer.alloc(16, 0); + // @ts-ignore + const decipher = createDecipheriv(algorithm, key, iv); + /** ********************* Decrypt String */ try { + let decrypted = decipher.update(encryptedString, "hex", "utf8"); + decrypted += decipher.final("utf8"); + return decrypted; + } catch (error) { + // serverError({ + // component: "decrypt", + // message: error.message, + // user: {}, + // }); + return null; + } +}; +module.exports = decrypt; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5449.js b/dsql-app/.local_dist/server/chunks/5449.js new file mode 100644 index 0000000..f3f1524 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5449.js @@ -0,0 +1,105 @@ +"use strict"; +exports.id = 5449; +exports.ids = [5449]; +exports.modules = { + +/***/ 5449: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ButtonGroup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {{ + * children: React.ReactNode, + * column?: boolean, + * className?: string, + * }} props - React component props including { children } + */ function ButtonGroup({ children , column , className }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const btnGroupRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + try { + /** @type {HTMLDivElement & *} */ const buttonGroupWrapper = btnGroupRef.current; + /** @type {any} */ const children = buttonGroupWrapper.childNodes; + const allAvailableBtns = Array.from(children); + if (allAvailableBtns?.length === 1) return; + allAvailableBtns.forEach((btn, index)=>{ + let targetElement = btn; + if (targetElement.classList.contains("dropdown-wrapper")) { + const targetClild = Array.from(btn.childNodes).filter((node)=>node?.nodeName?.match(/button/i) || node.classList.contains("button")); + if (targetClild && targetClild[0]) { + targetElement = targetClild[0]; + } + } + const targetBorderSide = column ? "borderTop" : "borderLeft"; + const targetBorderRadiusStart = column ? "borderBottomRightRadius" : "borderTopRightRadius"; + const targetBorderRadiusEnd = column ? "borderBottomLeftRadius" : "borderBottomRightRadius"; + const targetBorderOppositeRadiusStart = column ? "borderTopRightRadius" : "borderTopLeftRadius"; + const targetBorderOppositeRadiusEnd = column ? "borderTopLeftRadius" : "borderBottomLeftRadius"; + if (index < allAvailableBtns.length - 1) { + targetElement.style[targetBorderRadiusStart] = 0; + targetElement.style[targetBorderRadiusEnd] = 0; + } + if (index > 0) { + targetElement.style[targetBorderSide] = "none"; + targetElement.style[targetBorderOppositeRadiusStart] = 0; + targetElement.style[targetBorderOppositeRadiusEnd] = 0; + } + }); + } catch (/** @type {any} */ error) { + console.log(error.message); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "items-stretch gap-0" + (column ? " flex-col" : " flex-wrap xl:flex-nowrap") + (className ? " " + className : ""), + // @ts-ignore + ref: btnGroupRef, + children: children + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5472.js b/dsql-app/.local_dist/server/chunks/5472.js new file mode 100644 index 0000000..4272b56 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5472.js @@ -0,0 +1,184 @@ +"use strict"; +exports.id = 5472; +exports.ids = [5472]; +exports.modules = { + +/***/ 5472: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Mw": () => (/* binding */ openPopup), +/* harmony export */ "ZP": () => (/* binding */ GeneralPopup), +/* harmony export */ "j4": () => (/* binding */ closePopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {React.ReactNode} props.children - React children + * @param {string} props.title - Popup title + * @param {Object} [props.data] - data to pass in the "data-data" attribute as JSON + * @param {boolean} [props.fullPage] - If the popup will span the full screen + * @param {string} [props.wrapperClasses] - Popup wrapper additional class names + * @param {() => void} [props.closePopupDispatch] - Function to run when popup is closed + * @param {React.CSSProperties} [props.wrapperStyle] - React styles for the popup wrapper + * @param {boolean} [props.noContainer] - If no container should be provided + */ function GeneralPopup({ children , title , data , fullPage , wrapperClasses , closePopupDispatch , wrapperStyle , noContainer , }) { + /** + * Get Contexts + * + * @description { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @description Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ if (fullPage) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "popup-bg overflow-hidden " + (wrapperClasses ? wrapperClasses : ""), + "data-popupid": title ? title : null, + style: wrapperStyle, + children: [ + noContainer ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_2___default().Fragment), { + children: children + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "relative w-full h-full z-50", + "data-data": data ? JSON.stringify(data) : "", + children: children + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "popup-cancel-button fixed outlined gray", + onClick: (e)=>{ + closePopup(); + if (closePopupDispatch) closePopupDispatch(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_1__.X, { + color: "white", + size: 20 + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "popup-canceller", + onClick: (e)=>{ + closePopup(); + closePopupDispatch && closePopupDispatch(); + } + }) + ] + }); + } + //////////////////////////////////////// + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "popup-bg", + "data-popupid": title ? title : null, + children: [ + noContainer ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_2___default().Fragment), { + children: children + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "popup-content-container minimal-scrollbars", + "data-data": data ? JSON.stringify(data) : "", + children: [ + children, + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray popup-cancel-button", + onClick: (e)=>{ + closePopup(); + closePopupDispatch && closePopupDispatch(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-normal", + children: "✖" + }) + }) + ] + }), + noContainer && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "gray popup-cancel-button", + onClick: (e)=>{ + closePopup(); + closePopupDispatch && closePopupDispatch(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-normal", + children: "✖" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "popup-canceller", + onClick: (e)=>{ + closePopup(); + closePopupDispatch && closePopupDispatch(); + } + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Open Popup Function + * ============================================================================== + * @param {string} popupId - popup id + * @param {(popup?: Element) => void} [openPopupDispatch] - Function to run on popup open + */ function openPopup(popupId, openPopupDispatch) { + let popup = document.querySelector(`[data-popupid='${popupId}']`); + if (popup) { + // @ts-ignore + popup.style.display = "flex"; + openPopupDispatch && openPopupDispatch(popup); + } +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Close Popup Function + * ============================================================================== + * @param {() => void} [closePopupDispatch] - Function to run on popup open + */ function closePopup(closePopupDispatch) { + document.querySelectorAll(`[data-popupid]`).forEach((popup)=>{ + // @ts-ignore + popup.style.display = "none"; + }); + closePopupDispatch && closePopupDispatch(); +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5886.js b/dsql-app/.local_dist/server/chunks/5886.js new file mode 100644 index 0000000..fd4b09c --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5886.js @@ -0,0 +1,191 @@ +"use strict"; +exports.id = 5886; +exports.ids = [5886]; +exports.modules = { + +/***/ 5886: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const encrypt = __webpack_require__(7547); +const sanitizeHtml = __webpack_require__(6109); +const sanitizeHtmlOptions = __webpack_require__(9544); +const DB_HANDLER = __webpack_require__(2224); +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** + * Update DB Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {("Master" | "Dsql User")} [params.dbContext] - What is the database context? "Master" + * or "Dsql User". Defaults to "Master" + * @param {("Read Only" | "Full Access")} [params.paradigm] - What is the paradigm for "Dsql User"? + * "Read only" or "Full Access"? Defaults to "Read Only" + * @param {string} [params.dbFullName] - Database full name + * @param {string} params.tableName - Table name + * @param {string} [params.encryptionKey] + * @param {string} [params.encryptionSalt] + * @param {any} params.data - Data to add + * @param {import("../../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @param {string} params.identifierColumnName - Update row identifier column name + * @param {string | number} params.identifierValue - Update row identifier column value + * + * @returns {Promise} + */ async function updateDbEntry({ dbContext , paradigm , dbFullName , tableName , data , tableSchema , identifierColumnName , identifierValue , encryptionKey , encryptionSalt , }) { + /** + * Check if data is valid + */ if (!data || !Object.keys(data).length) return null; + const isMaster = dbContext?.match(/dsql.user/i) ? false : dbFullName && !dbFullName.match(/^datasquirel$/) ? false : true; + /** @type {(a1:any, a2?:any)=> any } */ const dbHandler = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Declare variables + * + * @description Declare "results" variable + */ const dataKeys = Object.keys(data); + let updateKeyValueArray = []; + let updateValues = []; + for(let i = 0; i < dataKeys.length; i++){ + try { + const dataKey = dataKeys[i]; + // @ts-ignore + let value = data[dataKey]; + const targetFieldSchemaArray = tableSchema ? tableSchema?.fields?.filter((field)=>field.fieldName === dataKey) : null; + const targetFieldSchema = targetFieldSchemaArray && targetFieldSchemaArray[0] ? targetFieldSchemaArray[0] : null; + if (value == null || value == undefined) continue; + if (targetFieldSchema?.richText) { + value = sanitizeHtml(value, sanitizeHtmlOptions); + } + if (targetFieldSchema?.encrypted) { + value = encrypt(value, encryptionKey, encryptionSalt); + } + if (typeof value === "object") { + value = JSON.stringify(value); + } + if (targetFieldSchema?.pattern) { + const pattern = new RegExp(targetFieldSchema.pattern, targetFieldSchema.patternFlags || ""); + if (!pattern.test(value)) { + console.log("DSQL: Pattern not matched =>", value); + value = ""; + } + } + if (typeof value === "string" && value.match(/^null$/i)) { + value = { + toSqlString: function() { + return "NULL"; + } + }; + } + if (typeof value === "string" && !value.match(/./i)) { + value = { + toSqlString: function() { + return "NULL"; + } + }; + } + updateKeyValueArray.push(`\`${dataKey}\`=?`); + if (typeof value == "number") { + updateValues.push(String(value)); + } else { + updateValues.push(value); + } + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + //////////////////////////////////////// + console.log("DSQL: Error in parsing data keys in update function =>", error.message); + continue; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + updateKeyValueArray.push(`date_updated='${Date()}'`); + updateKeyValueArray.push(`date_updated_code='${Date.now()}'`); + //////////////////////////////////////// + //////////////////////////////////////// + const query = `UPDATE ${tableName} SET ${updateKeyValueArray.join(",")} WHERE \`${identifierColumnName}\`=?`; + updateValues.push(identifierValue); + const updatedEntry = isMaster ? await dbHandler(query, updateValues) : await dbHandler({ + paradigm, + database: dbFullName, + queryString: query, + queryValues: updateValues + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return updatedEntry; +} +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = updateDbEntry; + + +/***/ }), + +/***/ 9544: +/***/ ((module) => { + +// @ts-check + +const sanitizeHtmlOptions = { + allowedTags: [ + "b", + "i", + "em", + "strong", + "a", + "p", + "span", + "ul", + "ol", + "li", + "h1", + "h2", + "h3", + "h4", + "h5", + "h6", + "img", + "div", + "button", + "pre", + "code", + "br" + ], + allowedAttributes: { + a: [ + "href" + ], + img: [ + "src", + "alt", + "width", + "height", + "class", + "style" + ], + "*": [ + "style", + "class" + ] + } +}; +module.exports = sanitizeHtmlOptions; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/5910.js b/dsql-app/.local_dist/server/chunks/5910.js new file mode 100644 index 0000000..c8acf88 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/5910.js @@ -0,0 +1,130 @@ +"use strict"; +exports.id = 5910; +exports.ids = [5910]; +exports.modules = { + +/***/ 5910: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const sharp = __webpack_require__(7441); +const serverError = __webpack_require__(2163); +const grabPaths = __webpack_require__(6715); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * + * @param {object} params + * @param {string} params.imageSourceBase64 + * @param {string} params.imageName + * @param {any} params.user + * @param {string} [params.mimeType] + * @param {number} [params.thumbnailSize] + * @param {string} [params.folder] + * @param {boolean} [params.isPrivate] + * @returns {Promise<{ urlPath: string, urlThumbnailPath: string, urlRelativePath: string, urlThumbnailRelativePath: string } | undefined | null>} + */ module.exports = async function fsWriteImageToDiskFromBase64({ imageSourceBase64 , imageName , user , mimeType , thumbnailSize , folder , isPrivate , }) { + try { + const buffer = Buffer.from(imageSourceBase64, "base64"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const MAX_SIZE = 1800; + const MAX_SIZE_THUMBNAIL = thumbnailSize ? parseInt(thumbnailSize.toString()) : 400; + // const sharpImage = sharp(imagePath); + const sharpImageRaw = sharp(buffer); + const sharpImageThumbnailRaw = sharp(buffer); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Construct root paths + */ const grabedPaths = grabPaths({ + isPrivate: isPrivate, + user: user, + folder: folder + }); + if (!grabedPaths) { + return null; + } + const { fileRootPath , urlRootPath , relativePath } = grabedPaths; + const imageRootPath = fileRootPath; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Main Image + * + * @description Main Image + */ let imageMetadataRaw = await sharpImageRaw.metadata(); + let { width , height , format } = imageMetadataRaw; + /** @type {keyof import("sharp").FormatEnum} */ // @ts-ignore + const finalFormat = mimeType ? mimeType : format; + if (width && height && width > MAX_SIZE) { + let resizeRatio = MAX_SIZE / width; + sharpImageRaw.resize(MAX_SIZE, Math.round(height * resizeRatio), { + fit: "cover" + }); + } + sharpImageRaw.toFormat(finalFormat, { + quality: 80 + }); + //////////////////////////////////////// + let newImageMetadataRaw = await sharpImageRaw.metadata(); + //////////////////////////////////////// + let imageFullName = `${imageName}.${finalFormat}`; + let imagePath = imageRootPath + imageFullName; + const urlPath = urlRootPath + imageFullName; + const urlRelativePath = relativePath + imageFullName; + await sharpImageRaw.toFile(imagePath); + /** + * Thumbnail + * + * @description Thumbnail + */ if (width && height && width > MAX_SIZE_THUMBNAIL) { + let resizeRatio1 = MAX_SIZE_THUMBNAIL / width; + sharpImageThumbnailRaw.resize(MAX_SIZE_THUMBNAIL, Math.round(height * resizeRatio1), { + fit: "cover" + }); + } else if (width && height) { + const LOWER_THUMBNAIL_SIZE = 150; + let resizeRatio2 = LOWER_THUMBNAIL_SIZE / width; + sharpImageThumbnailRaw.resize(LOWER_THUMBNAIL_SIZE, Math.round(height * resizeRatio2), { + fit: "cover" + }); + } + sharpImageThumbnailRaw.toFormat(finalFormat, { + quality: 80 + }); + //////////////////////////////////////// + let imageThumbnailFullName = `${imageName}_thumbnail.${finalFormat}`; + let imageThumbnailPath = imageRootPath + imageThumbnailFullName; + const urlThumbnailPath = urlRootPath + imageThumbnailFullName; + const urlThumbnailRelativePath = relativePath + imageThumbnailFullName; + await sharpImageThumbnailRaw.toFile(imageThumbnailPath); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return { + urlPath, + urlThumbnailPath, + urlRelativePath, + urlThumbnailRelativePath + }; + // console.log("===================================="); + // console.log("Complete!!!"); + // console.log("===================================="); + } catch (/** @type {any} */ error) { + console.log("Write Image to Disk error =>", error.message); + serverError({ + component: "functions/backend/fsWriteImageToDiskFromBase64", + message: error.message + }); + return null; + } +}; /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6000.js b/dsql-app/.local_dist/server/chunks/6000.js new file mode 100644 index 0000000..1d00b00 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6000.js @@ -0,0 +1,115 @@ +"use strict"; +exports.id = 6000; +exports.ids = [6000]; +exports.modules = { + +/***/ 6000: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DocsAside) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DocsAsidePageObject[]} props.pages + */ function DocsAside({ pages }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ if (!pages || !pages[0]) return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const topLevelPages = pages?.filter((page)=>page.level == 1); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + //////////////////////////////////////// + /** @type {NodeListOf} */ let asideLinks = document.querySelectorAll("aside a"); + if (asideLinks && asideLinks[0]) { + asideLinks.forEach((link)=>{ + if (link.pathname === window.location.pathname) { + link.classList.add("active"); + } + }); + } + }, []); + //////////////////////////////////////// + /** + * ## Generate List Function + * @param {import("@/package-shared/types").DocsAsidePageObject[]} cPages + * @param {string} baseUrl + * @returns + */ function generateList(cPages, baseUrl) { + return cPages.map((page, index)=>{ + const url = `${baseUrl}/${page.slug}`; + const childrenPages = pages.filter((pg)=>pg.level == 2 && pg.parent_id == page.id); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("li", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: url, + className: page?.level == 1 ? "font-semibold" : "text-slate-600", + children: page.title + }), + childrenPages && childrenPages[0] && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("ul", { + className: "pl-4 gap-2 flex flex-col items-start text-sm mt-2", + children: generateList(childrenPages, url) + }) + ] + }, index); + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("aside", { + className: "w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-2xl m-0 mb-4 text-left font-semibold", + children: "Docs" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("ul", { + className: "pl-4 gap-4 flex flex-col items-start", + children: generateList(topLevelPages, "/docs") + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/613.js b/dsql-app/.local_dist/server/chunks/613.js new file mode 100644 index 0000000..4d79741 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/613.js @@ -0,0 +1,184 @@ +"use strict"; +exports.id = 613; +exports.ids = [613]; +exports.modules = { + +/***/ 613: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +const datasquirel = __webpack_require__(9538); +const serverError = __webpack_require__(2163); +const DB_HANDLER = __webpack_require__(2224); +const addDbEntry = __webpack_require__(5338); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Add Admin User on Login + * ============================================================================== + * + * @description this function handles admin users that have been invited by another + * admin user. This fires when the invited user has been logged in or a new account + * has been created for the invited user + * + * @param {object} params - parameters object + * + * @param {object} params.query - query object + * @param {number} params.query.invite - Invitation user id + * @param {string} params.query.database_access - String containing authorized databases + * @param {string} params.query.priviledge - String containing databases priviledges + * @param {string} params.query.email - Inviting user email address + * + * @param {import("@/package-shared/types").UserType} params.user - invited user object + * + * @returns {Promise} new user auth object payload + */ module.exports = async function addAdminUserOnLogin({ query , user }) { + try { + /** + * Fetch user + * + * @description Fetch user from db + */ // @ts-ignore + const { invite , database_access , priviledge , email } = query; + const lastInviteTimeArray = await DB_HANDLER(`SELECT date_created_code FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + // if (lastInviteTimeArray && lastInviteTimeArray[0]?.date_created_code) { + // const timeSinceLastInvite = Date.now() - parseInt(lastInviteTimeArray[0].date_created_code); + // if (timeSinceLastInvite > 21600000) { + // throw new Error("Invitation expired"); + // } + // } else if (!lastInviteTimeArray || !lastInviteTimeArray[0]) { + // throw new Error("No Invitation Found"); + // } + if (!lastInviteTimeArray || !lastInviteTimeArray[0]) { + throw new Error("No Invitation Found"); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + // @ts-ignore + const invitingUserDb = await DB_HANDLER(`SELECT first_name,last_name,email FROM users WHERE id=?`, [ + invite + ]); + if (invitingUserDb?.[0]) { + const existingUserUser = await DB_HANDLER(`SELECT email FROM user_users WHERE user_id=? AND invited_user_id=? AND user_type='admin' AND email=?`, [ + invite, + user.id, + email + ]); + if (existingUserUser?.[0]) { + console.log("User already added"); + } else { + // const newUserUser = await DB_HANDLER( + // `INSERT IGNORE INTO user_users + // (user_id, invited_user_id, database_access, first_name, last_name, phone, email, username, user_type, user_priviledge) + // VALUES + // (?,?,?,?,?,?,?,?,?,?) + // )`, + // [ + // invite, + // user.id, + // database_access, + // user.first_name, + // user.last_name, + // user.phone, + // user.email, + // user.username, + // "admin", + // priviledge, + // ] + // ); + addDbEntry({ + dbFullName: "datasquirel", + tableName: "user_users", + data: { + user_id: invite, + invited_user_id: user.id, + database_access: database_access, + first_name: user.first_name, + last_name: user.last_name, + phone: user.phone, + email: user.email, + username: user.username, + user_type: "admin", + user_priviledge: priviledge, + image: user.image, + image_thumbnail: user.image_thumbnail + } + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + // @ts-ignore + const dbTableData = await DB_HANDLER(`SELECT db_tables_data FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + // @ts-ignore + const clearEntries = await DB_HANDLER(`DELETE FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=?`, [ + invite, + user.id + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (dbTableData && dbTableData[0]) { + const dbTableEntries = dbTableData[0].db_tables_data.split("|"); + for(let i = 0; i < dbTableEntries.length; i++){ + const dbTableEntry = dbTableEntries[i]; + const dbTableEntryArray = dbTableEntry.split("-"); + const [db_slug, table_slug] = dbTableEntryArray; + const newEntry = await addDbEntry({ + dbFullName: "datasquirel", + tableName: "delegated_user_tables", + data: { + delegated_user_id: user.id, + root_user_id: invite, + database: db_slug, + table: table_slug, + priviledge: priviledge + } + }); + } + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } + // @ts-ignore + const inviteAccepted = await DB_HANDLER(`UPDATE invitations SET invitation_status='Accepted' WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + serverError({ + component: "addAdminUserOnLogin", + message: error.message, + user: user + }); + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6147.js b/dsql-app/.local_dist/server/chunks/6147.js new file mode 100644 index 0000000..fffcd28 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6147.js @@ -0,0 +1,82 @@ +"use strict"; +exports.id = 6147; +exports.ids = [6147]; +exports.modules = { + +/***/ 6147: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const DB_HANDLER = __webpack_require__(2224); +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** + * Imports: Handle imports + */ /** + * Delete DB Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {string} [params.dbContext] - What is the database context? "Master" + * or "Dsql User". Defaults to "Master" + * @param {("Read Only" | "Full Access")} [params.paradigm] - What is the paradigm for "Dsql User"? + * "Read only" or "Full Access"? Defaults to "Read Only" + * @param {string} params.dbFullName - Database full name + * @param {string} params.tableName - Table name + * @param {import("../../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @param {string} params.identifierColumnName - Update row identifier column name + * @param {string|number} params.identifierValue - Update row identifier column value + * + * @returns {Promise} + */ async function deleteDbEntry({ dbContext , paradigm , dbFullName , tableName , identifierColumnName , identifierValue , }) { + try { + /** + * Check if data is valid + */ const isMaster = dbContext?.match(/dsql.user/i) ? false : dbFullName && !dbFullName.match(/^datasquirel$/) ? false : true; + /** @type { (a1:any, a2?:any) => any } */ const dbHandler = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Execution + * + * @description + */ const query = `DELETE FROM ${tableName} WHERE \`${identifierColumnName}\`=?`; + const deletedEntry = isMaster ? await dbHandler(query, [ + identifierValue + ]) : await dbHandler({ + paradigm, + queryString: query, + database: dbFullName, + queryValues: [ + identifierValue + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return deletedEntry; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return null; + } +} +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = deleteDbEntry; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6217.js b/dsql-app/.local_dist/server/chunks/6217.js new file mode 100644 index 0000000..2245d08 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6217.js @@ -0,0 +1,163 @@ +"use strict"; +exports.id = 6217; +exports.ids = [6217]; +exports.modules = { + +/***/ 6217: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ GeneralLayout) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "next/head" +var head_ = __webpack_require__(968); +var head_default = /*#__PURE__*/__webpack_require__.n(head_); +// EXTERNAL MODULE: ./functions/frontend/updateNavLinks.js +var updateNavLinks = __webpack_require__(9678); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/Header.jsx +var Header = __webpack_require__(7108); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/Footer.jsx +var Footer = __webpack_require__(5281); +;// CONCATENATED MODULE: ./layouts/components/GeneralLayout/ProductionHeadComponent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {*} props.head + * @param {*} props.productionEnvironment + */ function ProductionHeadComponent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/ScrollToTopButton.jsx +var ScrollToTopButton = __webpack_require__(9360); +;// CONCATENATED MODULE: ./layouts/GeneralLayout.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React Component Props + * @param {React.ReactNode} props.children - children component + * @param {React.ReactNode} props.head - head Items + * @param {import("@/package-shared/types").UserType | null} [props.user] - user object + * @param {*} [props.productionEnvironment] + * @param {boolean} [props.darkBgHeader] + * @param {boolean} [props.transparentHeader] + */ function GeneralLayout({ children , head , user , productionEnvironment , darkBgHeader , transparentHeader , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ external_react_default().useEffect(()=>{ + (0,updateNavLinks/* default */.Z)({}); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((head_default()), { + children: head + }), + /*#__PURE__*/ jsx_runtime_.jsx(ProductionHeadComponent, { + head: head, + productionEnvironment: productionEnvironment + }), + /*#__PURE__*/ jsx_runtime_.jsx(Header/* default */.Z, { + user: user, + darkBg: darkBgHeader, + transparent: transparentHeader + }), + children, + /*#__PURE__*/ jsx_runtime_.jsx(Footer/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ScrollToTopButton/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6251.js b/dsql-app/.local_dist/server/chunks/6251.js new file mode 100644 index 0000000..fa5d9eb --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6251.js @@ -0,0 +1,142 @@ +"use strict"; +exports.id = 6251; +exports.ids = [6251]; +exports.modules = { + +/***/ 6251: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ SuErrorLogsContent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6729); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SuErrorLogsContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ errorLog: string | null, setErrorLog: React.Dispatch> ]} */ // @ts-ignore + const [errorLog, setErrorLog] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const [refresh, setRefresh] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + function fetchErrorLogs() { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/admin/grabErrorLogs").then((res)=>{ + if (typeof res.log === "string" && !res.log?.match(/./)) { + setErrorLog("No Logs Yet"); + return; + } else { + setErrorLog(""); + } + setErrorLog(res.log.replace(/\n|\r|\n\r|\\n/gm, "
")); + }); + } + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + fetchErrorLogs(); + if (refresh === 0) { + setInterval(()=>{ + fetchErrorLogs(); + }, 10000); + } + }, [ + refresh + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0", + children: "Error Logs" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + onClick: (e)=>{ + if (window.confirm("Clear Error Logs?")) { + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/admin/clearErrorLogs", "post").then((res)=>{ + console.log(res); + setRefresh((prev)=>prev + 1); + }); + setTimeout(()=>{ + setLoading(false); + }, 2000); + } + }, + className: "outlined gray relative", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + width: "20px" + }), + "Clear Error Log" + ] + }) + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper", + children: [ + errorLog && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", { + dangerouslySetInnerHTML: { + __html: errorLog ? errorLog : "No Log" + } + }), + !errorLog && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + position: "relative", + width: "25px" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6390.js b/dsql-app/.local_dist/server/chunks/6390.js new file mode 100644 index 0000000..07fc27d --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6390.js @@ -0,0 +1,2325 @@ +"use strict"; +exports.id = 6390; +exports.ids = [6390]; +exports.modules = { + +/***/ 9201: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ChooseMediaTypePopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _mui_icons_material_CollectionsTwoTone__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7306); +/* harmony import */ var _mui_icons_material_CollectionsTwoTone__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CollectionsTwoTone__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _mui_icons_material_AssignmentTwoTone__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9765); +/* harmony import */ var _mui_icons_material_AssignmentTwoTone__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_AssignmentTwoTone__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _mui_icons_material_VideoCameraBackTwoTone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(871); +/* harmony import */ var _mui_icons_material_VideoCameraBackTwoTone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_VideoCameraBackTwoTone__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + */ function ChooseMediaTypePopup({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "choose-media-type-popoup", + noContainer: true, + wrapperClasses: "items-center", + wrapperStyle: { + alignItems: "center" + }, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "paper items-center max-w-2xl m-auto z-50 p-4 xl:p-10", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0 text-center text-lg leading-tight", + children: [ + "What kind of Media do you", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("br", {}), + "want to upload?" + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Please Select the media type to upload." + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card cursor-pointer", + onClick: (e)=>{ + if (user?.verification_status?.toString().match(/1/)) { + const inputEl = document.getElementById("upload_image_input"); + inputEl?.click(); + } else { + alert("Please Verify to Add Media"); + } + setTimeout(()=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, 500); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.Images, { + size: 50, + className: "text-primary" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "content", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "title", + children: "Images" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-sm", + children: "General image formats like JPEG, PNG, SVG, WEBP, etc." + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card cursor-pointer", + onClick: (e)=>{ + if (user?.verification_status?.toString().match(/1/)) { + document.getElementById("upload_file_input")?.click(); + } else { + alert("Please Verify to Add Media"); + } + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.Files, { + size: 50, + className: "text-secondary" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "content", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "title", + children: "Files" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-sm", + children: "Other documents type. Like PDF, XLSX, CSV, etc." + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card cursor-pointer", + onClick: (e)=>{ + if (user?.verification_status?.toString().match(/1/)) { + document.getElementById("upload_video_input")?.click(); + } else { + alert("Please Verify to Add Media"); + } + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.FileVideo2, { + size: 55, + className: "text-slate-600" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "content", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "title", + children: "Videos" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-sm", + children: [ + "Video Files. ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: "MP4" + }), + " for now. These files can be streamed. Max 200mb" + ] + }) + ] + }) + ] + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 7604: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ MediaList) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: external "@mui/icons-material/FolderCopyTwoTone" +var FolderCopyTwoTone_ = __webpack_require__(8398); +var FolderCopyTwoTone_default = /*#__PURE__*/__webpack_require__.n(FolderCopyTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DeleteOutlineOutlined" +var DeleteOutlineOutlined_ = __webpack_require__(8757); +var DeleteOutlineOutlined_default = /*#__PURE__*/__webpack_require__.n(DeleteOutlineOutlined_); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/media/MediaFolderCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.folderName + * @param {string} [props.folder] + * @param {import("@/package-shared/types").UserType} props.user + */ function MediaFolderCard({ folderName , folder , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const fullFolderName = `${folder ? folder + "/" : ""}${folderName}`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/media/${fullFolderName}`, + className: "card col items-center justify-center", + onClick: (e)=>{ + // @ts-ignore + if (e.target.closest("button")) return e.preventDefault(); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx((FolderCopyTwoTone_default()), { + sx: { + fontSize: 100 + }, + className: "opacity-20" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "absolute top-4 left-4 text-xs bg-slate-200 dark:bg-slate-700 px-2 py-0.5 rounded-full", + children: "Folder" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: folderName + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "plain-text absolute top-2 right-2", + onClick: (e)=>{ + if (window.confirm("Delete this Folder and all its contents?")) { + setLoading(true); + if (window.confirm("NOTE: this folder and all its contents will be permanently lost. Continue?")) { + (0,fetchApi/* default */.Z)("/api/deleteMediaFolder", { + method: "post", + body: { + folder: fullFolderName + } + }, true).then((res)=>{ + if (res.success) window.location.reload(); + }); + } else { + setLoading(false); + } + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((DeleteOutlineOutlined_default()), { + // fontSize="small" + className: "opacity-30" + }) + }) + ] + }, folderName); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: ./functions/frontend/downloadFile.js +var downloadFile = __webpack_require__(8826); +// EXTERNAL MODULE: external "@mui/icons-material/AssignmentTwoTone" +var AssignmentTwoTone_ = __webpack_require__(9765); +var AssignmentTwoTone_default = /*#__PURE__*/__webpack_require__.n(AssignmentTwoTone_); +;// CONCATENATED MODULE: ./components/admin/media/card/MediaPreviewSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject - Media Object + * @param {string} props.staticHost + */ function MediaPreviewSection({ mediaObject , staticHost }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const mediaThumbnailUrl = mediaObject.media_thumbnail_path ? mediaObject?.private ? mediaObject.media_thumbnail_url : `${staticHost}${mediaObject.media_thumbnail_path}` : mediaObject.media_thumbnail_url; + const mediaUrl = mediaObject.media_path ? mediaObject?.private ? mediaObject.media_url : `${staticHost}${mediaObject.media_path}` : mediaObject.media_url; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: mediaObject.media_type?.match(/file/i) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "cursor-pointer hover:opacity-80", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((AssignmentTwoTone_default()), { + sx: { + fontSize: 100 + }, + className: "opacity-10" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "info w-auto small gray absolute top-4 right-4", + children: mediaObject.media_type.replace(/.*\//, "").toUpperCase() + }) + ] + }) : mediaObject.media_type?.match(/video/i) ? /*#__PURE__*/ jsx_runtime_.jsx("video", { + src: mediaUrl, + className: "w-full h-60 object-cover", + controls: true, + muted: true, + autoPlay: true, + loop: true + }) : /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: mediaThumbnailUrl, + alt: mediaObject.media_name, + className: "w-full h-60 object-cover bg-slate-200 rounded", + onError: (e)=>{ + if (mediaObject?.private) { + return; + } + (0,fetchApi/* default */.Z)("/api/purgeDb", { + method: "post", + body: { + paradigm: "user_media", + payload: mediaObject + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + console.log(res); + console.log(mediaThumbnailUrl); + console.log(mediaUrl); + } + }); + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/media/card/MediaMoreButton.jsx +var MediaMoreButton = __webpack_require__(4642); +;// CONCATENATED MODULE: ./components/admin/media/card/MediaLinksDropdown.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject - Media Object + * @param {string} props.staticHost + */ function MediaLinksDropdown({ mediaObject , staticHost }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const mediaThumbnailUrl = mediaObject.media_thumbnail_path ? `${staticHost}/${mediaObject.media_thumbnail_path}` : mediaObject.media_thumbnail_url; + const mediaUrl = mediaObject.media_path ? `${staticHost}/${mediaObject.media_path}` : mediaObject.media_url; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ if (mediaObject?.private) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper w-full xl:w-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined secondary small-text w-full hidden xl:flex bg-secondary/10", + children: "Copy Link" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mobile-transform gap-2 w-full", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + column: true, + className: "w-full mb-2 xl:mb-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "gray outlined normal-weight more-padding", + onClick: (e)=>{ + navigator.clipboard.writeText(mediaObject.media_url || "").then(()=>{ + alert(`Media url ${mediaObject.media_url} Copied to clipboard`); + }); + }, + children: "Copy Full Link" + }), + !mediaObject?.media_type?.match(/file|video/i) && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "gray outlined normal-weight more-padding", + onClick: (e)=>{ + navigator.clipboard.writeText(mediaObject.media_thumbnail_url || "").then(()=>{ + alert(`Media url ${mediaObject.media_thumbnail_url} Copied to clipboard`); + }); + }, + children: "Copy Thumbnail Link" + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/LockOpenOutlined" +var LockOpenOutlined_ = __webpack_require__(8083); +// EXTERNAL MODULE: external "@mui/icons-material/LockPersonRounded" +var LockPersonRounded_ = __webpack_require__(4624); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/admin/media/card/MediaPrivacyButton.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject - Media Object + * @param {React.Dispatch>} props.setLoading - Set loading function + */ function MediaPrivacyButton({ mediaObject , setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [isPrivate, setIsPrivate] = external_react_default().useState(false); + if (mediaObject?.media_type?.match(/video/i)) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "light-gray p-2 w-8 h-8 rounded-full absolute top-4 left-4 bg-white" + (mediaObject?.private ? " " : " text-slate-400 fill-slate-400"), + style: { + backgroundColor: "white" + }, + onClick: (e)=>{ + const confirmText = mediaObject.private ? "This media is private: Make it public?" : "Make this media Private?"; + if (window.confirm(confirmText)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/media/addPrivateMedia", { + method: "post", + body: { + ...mediaObject + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert("Action Failed!"); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }).catch((err)=>{ + console.log(err); + }); + } + }, + children: mediaObject?.private ? /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Lock, { + size: 20, + color: "green" + }) : /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.LockOpen, { + color: "black", + size: 20 + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/downloadPrivateFile.js +var downloadPrivateFile = __webpack_require__(8436); +;// CONCATENATED MODULE: ./components/admin/media/card/MediaListCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject + * @param {React.Dispatch>} props.setTargetMedia + * @param {string} props.staticHost + * @param {string} [props.folder] + */ function MediaListCard({ mediaObject , setTargetMedia , folder , staticHost , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(mediaObject?.private ? true : false); + const [updatedMediaObject, setUpdatedMediaObject] = external_react_default().useState(mediaObject); + external_react_default().useEffect(()=>{ + if (mediaObject?.private && mediaObject.media_thumbnail_url && !updatedMediaObject.media_type?.match(/file/i)) { + (0,downloadPrivateFile/* default */.Z)({ + url: mediaObject.media_thumbnail_url + }).then((res)=>{ + setUpdatedMediaObject({ + ...mediaObject, + media_thumbnail_url: res + }); + setLoading(false); + }).catch((err)=>{ + console.log(err.message); + }); + } else if (loading) { + setLoading(false); + } + }, []); + const mediaThumbnailUrl = updatedMediaObject.media_thumbnail_path ? `${staticHost}/${updatedMediaObject.media_thumbnail_path}` : updatedMediaObject.media_thumbnail_url; + const mediaUrl = updatedMediaObject.media_path ? `${staticHost}/${updatedMediaObject.media_path}` : updatedMediaObject.media_url; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "media-card card col", + onClick: (e)=>{ + // @ts-ignore + if (e.target.closest("button") || e.target.closest(".button")) return; + if (updatedMediaObject.media_type?.match(/file/i) && !updatedMediaObject.private) { + const url = mediaUrl; + window.open(url, "__blank"); + return; + } else if (updatedMediaObject.media_type?.match(/file/i) && updatedMediaObject.private) { + return; + } + setTargetMedia(updatedMediaObject); + (0,GeneralPopup/* openPopup */.Mw)("target-media-popup"); + }, + onMouseEnter: (e)=>{ + // @ts-ignore + e.target.closest(".media-card").style.zIndex = "10"; + }, + onMouseLeave: (e)=>{ + // @ts-ignore + e.target.closest(".media-card").style.zIndex = "0"; + }, + style: updatedMediaObject?.private ? { + outline: "5px solid var(--sec-color-light)", + borderColor: "var(--sec-color-lighter)" + } : {}, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx(MediaPreviewSection, { + mediaObject: updatedMediaObject, + staticHost: staticHost + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-center xl:items-start flex-wrap w-full mt-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "w-full", + style: { + wordBreak: "break-all" + }, + children: updatedMediaObject.media_name + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-wrap w-full", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + className: "flex-wrap w-full items-stretch", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "secondary small-text relative w-full xl:w-auto mb-2 xl:mb-0", + onClick: (e)=>{ + (0,downloadFile/* default */.Z)({ + mediaObject: updatedMediaObject, + fileName: mediaUrl?.match(/[^\/]+$/)?.[0] || "", + setLoading: setLoading + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Download" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(MediaLinksDropdown, { + mediaObject: updatedMediaObject, + staticHost: staticHost + }), + /*#__PURE__*/ jsx_runtime_.jsx(MediaMoreButton/* default */.Z, { + mediaObject: updatedMediaObject, + setLoading: setLoading + }) + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(MediaPrivacyButton, { + mediaObject: updatedMediaObject, + setLoading: setLoading + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/PermMediaTwoTone" +var PermMediaTwoTone_ = __webpack_require__(5580); +var PermMediaTwoTone_default = /*#__PURE__*/__webpack_require__.n(PermMediaTwoTone_); +;// CONCATENATED MODULE: ./components/admin/media/MediaList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any[]} [props.media] + * @param {React.Dispatch>} props.setTargetMedia + * @param {string} props.staticHost + * @param {string[]} [props.folders] + * @param {string} [props.folder] + * @param {import("@/package-shared/types").UserType} props.user + */ function MediaList({ media , setTargetMedia , folders , folder , staticHost , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper overflow-visible", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Media List" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full gap-4 grid grid-cols-1 md:grid-cols-2 xl:grid-cols-3 items-stretch", + children: [ + folders && folders[0] && folders.map((folderName)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(MediaFolderCard, { + folder: folder, + folderName: folderName, + user: user + }, folderName); + }), + media && media[0] && media.map((mediaObject)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(MediaListCard, { + mediaObject: mediaObject, + setTargetMedia: setTargetMedia, + folder: folder, + staticHost: staticHost + }, mediaObject.id); + }) + ] + }), + !media?.[0] && /*#__PURE__*/ jsx_runtime_.jsx(NewMediaBanner, {}) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ function NewMediaBanner() { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray dashed w-full p-10 flex-col", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("choose-media-type-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "No Media Added." + }), + /*#__PURE__*/ jsx_runtime_.jsx((PermMediaTwoTone_default()), { + color: "inherit", + sx: { + fontSize: 80 + }, + className: "opacity-40 text-gray-500" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Add Media" + }) + ] + }); +} + + +/***/ }), + +/***/ 1597: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ NewFolderPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6729); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} [props.folder] + */ function NewFolderPopup({ folder }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const [existingFolder, setExistingFolder] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "add-folder-popoup", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0", + children: "Add A New Folder" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col w-full relative", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + window.clearTimeout(timeout); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/addNewMediaFolder", { + method: "post", + body: { + name: (folder ? `${folder}/` : "") + formEl["new-folder-name"].value + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + setLoading(false); + } + }); + }, + className: "w-full flex flex-col items-stretch gap-2", + children: [ + existingFolder && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-xs text-orange-700 bg-orange-100 flex items-center justify-center rounded px-2 py-1", + children: "Folder Already Exists. Please Change the name." + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "new-folder-name", + id: "new-folder-name", + placeholder: "New Folder Name", + className: "w-full" + (existingFolder ? " warning" : ""), + onChange: (e)=>{ + e.target.value = e.target.value.toLocaleLowerCase().replace(/ /g, "-"); + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)(`/api/checkExistingFolder?name=${e.target.value}${folder ? "&folder=" + folder : ""}`).then((res)=>{ + if (e.target.value?.match(/./) && res?.success) { + setExistingFolder(true); + alert("Folder Already Exists"); + } else { + setExistingFolder(false); + } + }); + }, 500); + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + children: "Add New Folder" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4891: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ NewMediaPopup) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./functions/frontend/updateDiskUsage.js +var updateDiskUsage = __webpack_require__(1069); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/LockOpenOutlined" +var LockOpenOutlined_ = __webpack_require__(8083); +var LockOpenOutlined_default = /*#__PURE__*/__webpack_require__.n(LockOpenOutlined_); +// EXTERNAL MODULE: external "@mui/icons-material/LockPersonRounded" +var LockPersonRounded_ = __webpack_require__(4624); +var LockPersonRounded_default = /*#__PURE__*/__webpack_require__.n(LockPersonRounded_); +;// CONCATENATED MODULE: ./components/admin/media/TogglePrivacyButton.jsx +// @ts-check +/** + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").ImageObjectType | import("@/package-shared/types").FileObjectType} props.mediaObject - Single Image or file object + */ function TogglePrivacyButton({ mediaObject }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [privacy, setPrivacy] = external_react_.useState(false); + external_react_.useEffect(()=>{ + mediaObject.private = privacy; + }, [ + privacy + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "light-gray p-2 w-8 h-8 rounded-full absolute top-2 left-2 bg-white" + (privacy ? " " : " text-slate-400 fill-slate-400"), + style: { + backgroundColor: "white" + }, + onClick: (e)=>{ + setPrivacy((prev)=>!prev); + }, + children: privacy ? /*#__PURE__*/ jsx_runtime_.jsx((LockPersonRounded_default()), { + fontSize: "small", + color: "secondary" + }) : /*#__PURE__*/ jsx_runtime_.jsx((LockOpenOutlined_default()), { + fontSize: "small", + className: "fill-inherit text-inherit" + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/media/NewMediaCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {import("@/package-shared/types").ImageObjectType & import("@/package-shared/types").FileObjectType} MediaType + */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {MediaType} props.imageObject - Single Image object + * @param {MediaType[]} props.newMedia - Origin Array of media objects + * @param {React.Dispatch>} props.setNewMedia - Set media Dispatch => React setState + * @param {boolean} [props.video] - Is this a video object + */ function NewMediaCard({ imageObject , newMedia , setNewMedia , video , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const finalFileObject = imageObject; + const finalFileSrc = finalFileObject.imageBase64Full || finalFileObject.fileBase64Full; + let finalFileName = finalFileObject.imageName || finalFileObject.fileName; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "border border-slate-300 rounded max-h-44 flex-col w-full overflow-hidden h-full bg-slate-200 relative p-2", + children: [ + video ? /*#__PURE__*/ jsx_runtime_.jsx("video", { + src: finalFileSrc, + className: "w-full h-full object-contain", + muted: true, + autoPlay: true, + controls: true + }) : /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: finalFileSrc, + alt: finalFileName, + className: "w-full h-full object-contain" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + defaultValue: finalFileName, + onInput: (e)=>{ + // @ts-ignore + const value = e.target.value?.replace(/ /g, "-"); + if (imageObject.fileName) { + imageObject.fileName = value; + } + if (imageObject.imageName) { + imageObject.imageName = value; + } + }, + className: "absolute bottom-1 text-sm left-2 px-2 py-1", + style: { + width: "calc(100% - 15px)" + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined bg-white absolute top-2 right-2 p-1 w-8 h-8 rounded-full", + style: { + backgroundColor: "white", + borderColor: "var(--slate-200)" + }, + onClick: (e)=>{ + let spliceIndex = newMedia.findIndex((media)=>media.imageBase64 === imageObject.imageBase64 || media.fileBase64 === imageObject.fileBase64); + let newMediaArray = newMedia; + newMediaArray.splice(spliceIndex, 1); + setNewMedia([ + ...newMediaArray + ]); + }, + children: "✖" + }), + !video && /*#__PURE__*/ jsx_runtime_.jsx(TogglePrivacyButton, { + mediaObject: imageObject + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/AssignmentTwoTone" +var AssignmentTwoTone_ = __webpack_require__(9765); +var AssignmentTwoTone_default = /*#__PURE__*/__webpack_require__.n(AssignmentTwoTone_); +;// CONCATENATED MODULE: ./components/admin/media/NewFileCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").FileObjectType} props.fileObject - Single Image object + * @param {import("@/package-shared/types").FileObjectType[]} props.newFile - Origin Array of media objects + * @param {React.Dispatch>} props.setNewFile - Set media Dispatch => React setState + */ function NewFileCard({ fileObject , newFile , setNewFile }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "border border-slate-300 rounded max-h-44 flex-col w-full overflow-hidden h-full bg-slate-200 relative p-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((AssignmentTwoTone_default()), { + sx: { + fontSize: 100 + }, + className: "opacity-20" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + defaultValue: fileObject.fileName, + onInput: (e)=>{ + // @ts-ignore + fileObject.fileName = e.target.value?.replace(/ /g, "-"); + }, + className: "absolute bottom-1 text-sm left-2 px-2 py-1", + style: { + width: "calc(100% - 15px)" + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined bg-white absolute top-2 right-2 p-1 w-8 h-8 rounded-full", + style: { + backgroundColor: "white", + borderColor: "var(--slate-200)" + }, + onClick: (e)=>{ + let spliceIndex = newFile.findIndex((file)=>file.fileBase64 === fileObject.fileBase64); + let newFileArray = newFile; + newFileArray.splice(spliceIndex, 1); + setNewFile([ + ...newFileArray + ]); + }, + children: "✖" + }), + /*#__PURE__*/ jsx_runtime_.jsx(TogglePrivacyButton, { + mediaObject: fileObject + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/media/NewMediaPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").ImageObjectType[] | null} props.newMedia + * @param {React.Dispatch>} props.setNewMedia + * @param {import("@/package-shared/types").FileObjectType[] | null} [props.newFile] + * @param {React.Dispatch>} props.setNewFile + * @param {import("@/package-shared/types").FileObjectType[] | null} [props.newVideo] + * @param {React.Dispatch>} props.setNewVideo + * @param {string} [props.folder] + */ function NewMediaPopup({ newMedia , setNewMedia , newFile , setNewFile , newVideo , setNewVideo , folder , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const type = newMedia?.[0] ? "images" : newFile?.[0] ? "files" : "videos"; + const array = type?.match(/image/i) ? newMedia : type?.match(/file/i) ? newFile : newVideo; + const dispatch = type?.match(/image/i) ? setNewMedia : type?.match(/file/i) ? setNewFile : setNewVideo; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + external_react_default().useEffect(()=>{ + if (array && array[0]) (0,GeneralPopup/* openPopup */.Mw)("new-media-popup"); + // if (type?.match(/image/i)) { + // } else { + // openPopup("new-media-popup"); + // } + }, [ + newMedia, + newFile, + newVideo + ]); + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(GeneralPopup/* default */.ZP, { + title: "new-media-popup", + closePopupDispatch: ()=>{ + setNewMedia(null); + setNewFile(null); + setNewVideo(null); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + screen: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("h4", { + className: "m-0", + children: "Upload New Media" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "grid grid-cols-2 gap-4 w-full", + children: array && array[0] && array.map((media, index)=>{ + if (type?.match(/image/i)) { + return /*#__PURE__*/ jsx_runtime_.jsx(NewMediaCard, { + // @ts-ignore + imageObject: media, + // @ts-ignore + newMedia: array, + // @ts-ignore + setNewMedia: dispatch + }, index + 1); + } + if (type?.match(/video/i)) { + return /*#__PURE__*/ jsx_runtime_.jsx(NewMediaCard, { + // @ts-ignore + imageObject: media, + // @ts-ignore + newMedia: array, + // @ts-ignore + setNewMedia: dispatch, + video: true + }, index + 1); + } + return /*#__PURE__*/ jsx_runtime_.jsx(NewFileCard, { + // @ts-ignore + fileObject: media, + // @ts-ignore + newFile: array, + // @ts-ignore + setNewFile: dispatch + }, index + 1); + }) + }), + array && array[0] && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "py-3 w-full relative z-50" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + setLoading(true); + const fetchObject = type?.match(/image/i) ? { + type: type, + folder: folder, + media: array.map((media)=>{ + return { + // @ts-ignore + imageBase64: media.imageBase64, + // @ts-ignore + imageName: media.imageName, + // @ts-ignore + imageSize: media.imageSize, + // @ts-ignore + private: media.private + }; + }) + } : { + type: type, + folder: folder, + media: array.map((media)=>{ + return { + // @ts-ignore + fileBase64: media.fileBase64, + // @ts-ignore + fileName: media.fileName, + // @ts-ignore + fileSize: media.fileSize, + // @ts-ignore + fileType: media.fileType, + // @ts-ignore + private: media.private, + video: Boolean(type?.match(/video/i)) + }; + }) + }; + (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (res.success) { + (0,updateDiskUsage/* default */.Z)().then(()=>{ + window.location.reload(); + }); + } else { + alert("Image Upload Failed"); + console.log(res); + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + }, + children: "Upload Media" + }) + ] + }); +} + + +/***/ }), + +/***/ 3428: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ TargetMediaPreviewPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(6729); +/* harmony import */ var _functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(1069); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5449); +/* harmony import */ var _functions_frontend_downloadFile__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(8826); +/* harmony import */ var _functions_frontend_downloadPrivateFile__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8436); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _card_MediaMoreButton__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(4642); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def | null} props.targetMedia + * @param {string} props.staticHost + * @param {React.Dispatch>} props.setTargetMedia + * @param {import("@/package-shared/types").MYSQL_user_media_table_def[]} props.media + */ function TargetMediaPreviewPopup({ targetMedia , staticHost , setTargetMedia , media , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const mediaOriginThumbnailUrl = targetMedia?.media_thumbnail_path ? `${staticHost}/${targetMedia?.media_thumbnail_path}` : targetMedia?.media_thumbnail_url; + const mediaOriginUrl = targetMedia?.media_path ? `${staticHost}/${targetMedia?.media_path}` : targetMedia?.media_url; + const isVideo = Boolean(targetMedia?.media_type?.match(/video/i)); + const targetMediaIndex = targetMedia ? media.findIndex((snMedia)=>snMedia.id == targetMedia.id) : null; + const isMediaIndex = typeof targetMediaIndex == "number" && targetMediaIndex >= 0; + const nextMedia = (()=>{ + if (!isMediaIndex) return null; + const targetNextMedia = media[targetMediaIndex + 1]; + if (!targetNextMedia) return null; + if (!targetNextMedia?.media_type?.match(/image/i)) { + const nextMedia = media.slice(targetMediaIndex + 1).find((med)=>{ + if (med.media_type?.match(/image/i)) return true; + return false; + }); + if (nextMedia) return nextMedia; + return null; + } + return targetNextMedia; + })(); + const prevMedia = (()=>{ + if (!isMediaIndex) return null; + const targetPrevMedia = media[targetMediaIndex - 1]; + if (!targetPrevMedia) return null; + if (!targetPrevMedia?.media_type?.match(/image/i)) { + const prevMedia = media.slice(0, targetMediaIndex - 1).findLast((med)=>{ + if (med.media_type?.match(/image/i)) return true; + return false; + }); + if (prevMedia) return prevMedia; + return null; + } + return targetPrevMedia; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetMedia?.private ? true : false); + const [ready, setReady] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const [mediaUrl, setMediaUrl] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(mediaOriginUrl); + /** + * @type {React.RefObject} + */ // @ts-ignore + const imageRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (targetMedia?.private) { + (0,_functions_frontend_downloadPrivateFile__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)({ + url: targetMedia.media_url || "" + }).then((res)=>{ + if (res) { + setMediaUrl(res); + setLoading(false); + } + }).catch((err)=>{ + console.log(err.message); + }); + } else { + setMediaUrl(targetMedia?.media_url || ""); + } + }, [ + targetMedia + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "target-media-popup", + noContainer: true, + fullPage: true, + closePopupDispatch: ()=>{ + setReady(false); + setTargetMedia(null); + }, + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + !ready && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + targetMedia && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "self-center h-screen py-4", + children: [ + mediaUrl ? isVideo ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("video", { + src: mediaUrl, + className: "w-full h-full object-cover", + controls: true, + muted: true, + autoPlay: true, + loop: true, + onCanPlay: ()=>{ + setReady(true); + }, + style: ready ? undefined : { + display: "none" + } + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: mediaUrl, + alt: targetMedia.media_name, + className: "bg-slate-200 rounded w-full h-full object-contain", + ref: imageRef, + onLoad: (e)=>{ + setReady(true); + }, + style: ready ? undefined : { + display: "none" + } + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {}), + prevMedia && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "absolute left-5 md:left-10 z-[100] cursor-pointer p-5 bg-slate-800/40 rounded-full", + onClick: (e)=>{ + setTargetMedia(null); + setTargetMedia(prevMedia); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_5__.ChevronLeft, { + color: "white" + }) + }), + nextMedia && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "absolute right-5 md:right-10 z-[100] cursor-pointer p-5 bg-slate-800/40 rounded-full", + onClick: (e)=>{ + setTargetMedia(null); + setTargetMedia(nextMedia); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_5__.ChevronRight, { + color: "white" + }) + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "info gray absolute top-5 left-5 w-auto mr-5", + style: { + backgroundColor: "white" + }, + children: targetMedia.media_path?.replace(/.*\//, "") + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "absolute bottom-6 left-6 p-2 bg-white dark:bg-slate-900 rounded z-20 hidden lg:flex flex-col items-stretch", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + column: true, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_card_MediaMoreButton__WEBPACK_IMPORTED_MODULE_6__/* .RenameMediaButton */ ._, { + mediaObject: targetMedia, + setLoading: setLoading + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined secondary more-padding", + onClick: (e)=>{ + (0,_functions_frontend_downloadFile__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z)({ + mediaObject: targetMedia, + fileName: targetMedia.media_url?.match(/[^\/]+$/)?.[0] || "", + setLoading: setLoading + }); + }, + children: "Download" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + if (window.confirm(`Delete this media?`)) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)("/api/deleteUserMedia", { + method: "post", + body: targetMedia + }, true).then((res)=>{ + if (res.success) { + (0,_functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)().then(()=>{ + window.location.reload(); + }); + } else { + alert("Media deletion Failed! Please try again."); + } + }); + } + }, + className: "more-padding", + children: "Delete" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray w-full bg-white more-padding", + onClick: (e)=>{ + navigator.clipboard.writeText(targetMedia.media_url || "").then(()=>{ + alert(`Media url ${targetMedia.media_url} Copied to clipboard`); + }); + }, + children: "Copy Full Image Link" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray w-full more-padding", + onClick: (e)=>{ + navigator.clipboard.writeText(targetMedia.media_thumbnail_url || "").then(()=>{ + alert(`Media url ${targetMedia.media_thumbnail_url} Copied to clipboard`); + }); + }, + style: { + borderTop: "1px solid #0b8862" + }, + children: "Copy Image Thumbnail Link" + }) + ] + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4642: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ MediaMoreButton), +/* harmony export */ "_": () => (/* binding */ RenameMediaButton) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6729); +/* harmony import */ var _functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1069); +/* harmony import */ var _general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5449); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject - Media Object + * @param {React.Dispatch>} props.setLoading - Set loading function + */ function MediaMoreButton({ mediaObject , setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper w-full xl:w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray small-text hidden xl:flex", + children: "More" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "dropdown mobile-transform gap-2 w-full", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + column: true, + className: "w-full mb-2 xl:mb-0", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(RenameMediaButton, { + mediaObject, + setLoading + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray normal-weight more-padding w-full xl:w-auto", + onClick: (e)=>{ + if (window.confirm(`Delete this media?`)) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/deleteUserMedia", { + method: "post", + body: mediaObject + }, true).then((res)=>{ + if (res.success) { + (0,_functions_frontend_updateDiskUsage__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)().then(()=>{ + window.location.reload(); + }); + } else { + alert("Media deletion Failed! Please try again."); + } + }); + } + }, + children: "Delete" + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # Rename Media + * @param {object} props + * @param {import("@/package-shared/types").MYSQL_user_media_table_def} props.mediaObject - Media Object + * @param {React.Dispatch>} props.setLoading - Set loading function + */ function RenameMediaButton({ mediaObject , setLoading }) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + const newName = window.prompt(`Rename media`, mediaObject.media_name); + if (newName && window.confirm(`Rename "${mediaObject.media_name}" to "${newName}"`)) { + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/renameMedia", { + method: "post", + body: { + mediaObject: mediaObject, + newName: newName.replace(/ /g, "-"), + newThumbnailName: newName.replace(/ /g, "-") + "_thumbnail" + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert(res.msg); + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + } + }, + className: "outlined gray normal-weight more-padding", + children: "Rename" + }); +} + + +/***/ }), + +/***/ 8916: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UploadFileComponent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_inputFileToBase64__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3314); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {React.Dispatch>} props.setNewFile - Set files array => React.useState dispatch Function + * @param {React.Dispatch>} props.setLoading - Set Page loading => React.useState dispatch Function + */ function UploadFileComponent({ setNewFile , setLoading }) { + /** + * Get Contexts + * + * @description { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @description Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + name: "upload_file_input", + id: "upload_file_input", + className: "hidden", + accept: ".xlsx,.pdf,.csv,.json", + multiple: true, + onChange: async (e)=>{ + if (setLoading) setLoading(true); + let fileInputsArray = []; + let files = e.target.files; + if (files?.length) { + for(let i = 0; i < files.length; i++){ + const file = files[i]; + if (file.type?.match(/sheet/)) { + const blobURL = URL.createObjectURL(file); + console.log(blobURL); + } else { + const imageData = await (0,_functions_frontend_inputFileToBase64__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z)({ + inputFile: file + }); + fileInputsArray.push(imageData); + } + } + setNewFile(fileInputsArray); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 200); + } else { + window.alert("No Files selected"); + } + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3770: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UploadImageComponent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6718); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {React.Dispatch>} props.setNewMedia - Set new Media Array + * @param {React.Dispatch>} props.setLoading - Set Page loading => React.useState dispatch Function + */ function UploadImageComponent({ setNewMedia , setLoading }) { + /** + * Get Contexts + * + * @description { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @description Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + name: "upload_image_input", + id: "upload_image_input", + className: "hidden", + accept: "image/*", + multiple: true, + onChange: async (e)=>{ + if (setLoading) setLoading(true); + let imagesInputsArray = []; + let files = e.target.files; + if (files?.length) { + for(let i = 0; i < files.length; i++){ + const file = files[i]; + if (file.type?.match(/sheet/)) { + const blobURL = URL.createObjectURL(file); + console.log(blobURL); + } else { + const imageData = await (0,_functions_frontend_imageInputFileToBase64__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z)({ + imageInputFile: file, + maxWidth: 1800 + }); + imagesInputsArray.push(imageData); + } + } + setNewMedia(imagesInputsArray); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 200); + } else { + window.alert("No Files selected"); + } + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 7525: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UploadVideoComponent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_inputFileToBase64__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3314); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {React.Dispatch>} props.setNewVideo - Set files array => React.useState dispatch Function + * @param {React.Dispatch>} props.setLoading - Set Page loading => React.useState dispatch Function + */ function UploadVideoComponent({ setNewVideo , setLoading }) { + /** + * Get Contexts + * + * @description { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @description Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "file", + name: "upload_video_input", + id: "upload_video_input", + className: "hidden", + accept: ".mp4", + multiple: true, + onChange: async (e)=>{ + if (setLoading) setLoading(true); + let fileInputsArray = []; + let files = e.target.files; + if (files?.length) { + for(let i = 0; i < files.length; i++){ + const file = files[i]; + if (file.type?.match(/sheet/)) { + const blobURL = URL.createObjectURL(file); + console.log(blobURL); + } else { + const imageData = await (0,_functions_frontend_inputFileToBase64__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z)({ + inputFile: file + }); + fileInputsArray.push(imageData); + } + } + setNewVideo(fileInputsArray); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 200); + } else { + window.alert("No Videos selected"); + } + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8826: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ downloadFile) +/* harmony export */ }); +/* harmony import */ var _downloadPrivateFile__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8436); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {{ + * mediaObject: import("@/package-shared/types").MYSQL_user_media_table_def, + * fileName: string, + * setLoading: React.Dispatch>, + * }} params - params + * + * @requires search-field name attribute + */ async function downloadFile({ mediaObject , fileName , setLoading , }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ if (setLoading) setLoading(true); + /** @type {any} */ let file; + const isPrivate = Boolean(mediaObject?.private || mediaObject?.media_url?.match(/^\@/)); + if (isPrivate) { + file = await (0,_downloadPrivateFile__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)({ + url: mediaObject.media_url || "" + }); + } else { + file = await fetch(mediaObject.media_url || ""); + } + const blob = isPrivate ? file : await file.blob(); + const downloadableUrl = isPrivate ? file : URL.createObjectURL(blob); + const link = document.createElement("a"); + link.href = downloadableUrl; + link.download = fileName; + link.style.display = "none"; + document.body.appendChild(link); + link.click(); + URL.revokeObjectURL(downloadableUrl); + document.body.removeChild(link); + setTimeout(()=>{ + if (setLoading) setLoading(false); + }, 500); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 8436: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ downloadPrivateFile) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Download private file function + * ============================================================================== + * @async + * + * @param {{ url: string }} params - params + * + * @returns {Promise} + */ async function downloadPrivateFile({ url }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ return new Promise((resolve, reject)=>{ + fetch("/api/media/getPrivateMedia", { + method: "POST", + body: JSON.stringify({ + path: url + }), + // @ts-ignore + headers: { + "x-csrf-auth": localStorage.getItem("csrf") + } + }).then((res)=>res.blob()).then((data)=>{ + const downloadableUrl = URL.createObjectURL(data); + resolve(downloadableUrl); + }); + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6478.js b/dsql-app/.local_dist/server/chunks/6478.js new file mode 100644 index 0000000..4160dab --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6478.js @@ -0,0 +1,90 @@ +"use strict"; +exports.id = 6478; +exports.ids = [6478]; +exports.modules = { + +/***/ 6478: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ LoadingScreen) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6843); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9174); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + */ function LoadingScreen() { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex flex-col gap-4 items-center justify-center w-full h-screen p-6 bg-slate-100", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-center justify-center gap-4 px-6 py-20 bg-white rounded shadow-sm max-w-2xl w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/logo-icon-alt-2.webp", + alt: "Datasquirel Logo", + width: 60 + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-10 h-10 flex flex-col items-center justify-center", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + width: "25px", + position: "relative" + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6715.js b/dsql-app/.local_dist/server/chunks/6715.js new file mode 100644 index 0000000..7a31894 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6715.js @@ -0,0 +1,67 @@ +"use strict"; +exports.id = 6715; +exports.ids = [6715]; +exports.modules = { + +/***/ 6715: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** + * Imports: Handle imports + */ /** + * Grab Paths Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {boolean} [params.isPrivate] - Is this file private or not? + * @param {any} params.user - User object + * @param {string} [params.folder] - Folder, if available + * @param {boolean} [params.video] - Video, if available + * @param {boolean} [params.pathOnly] - Just generate the directories' paths + * + * @returns {{ fileRootPath: string, urlRootPath: string, relativePath: string } | null} + */ module.exports = function grabPaths({ isPrivate , user , folder , video , pathOnly , }) { + /** + * Initialize variables + */ const isProduction = "production".match(/production/); + const userId = user?.id || user?.user_id; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return null; + } + const relativePath = isPrivate ? `@/${video ? "videos" : "media"}/${folder ? folder + "/" : ""}` : video ? `/videos/user-videos/user-${userId}/${folder ? folder + "/" : ""}` : `/images/user-images/user-${userId}/${folder ? folder + "/" : ""}`; + const fileRootPath = isPrivate ? `./jsonData/dbSchemas/users/user-${userId}/media/${folder ? folder + "/" : ""}` : path.join(STATIC_ROOT, relativePath); + if (!fs.existsSync(fileRootPath) && !pathOnly) { + fs.mkdirSync(fileRootPath, { + recursive: true + }); + } + const urlRootPath = isPrivate ? `@/media/${folder ? folder + "/" : ""}` : `${process.env.DSQL_STATIC_HOST}${relativePath}`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return { + fileRootPath: fileRootPath, + urlRootPath: urlRootPath, + relativePath + }; +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6718.js b/dsql-app/.local_dist/server/chunks/6718.js new file mode 100644 index 0000000..a82c56e --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6718.js @@ -0,0 +1,82 @@ +"use strict"; +exports.id = 6718; +exports.ids = [6718]; +exports.modules = { + +/***/ 6718: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ imageInputFileToBase64) +/* harmony export */ }); +// @ts-check +/** + * Upload Image function + * ------------------------------------------------------------------------------ + * @param {object} params + * @param {File} params.imageInputFile image input file + * @param {number} [params.maxWidth] optional maximum width + * @requires Image {imagePreviewNode} - optional image dispatch node + * @return object containing image data in base 64 and image name + */ async function imageInputFileToBase64({ imageInputFile , maxWidth , }) { + /** + * Initialize + * ------------------------------------------------------------------------------ + */ /** ********************* Variables */ let imagePreviewNode = document.querySelector(`[data-imagepreview='image']`); + let imageName = imageInputFile.name.replace(/\..*/, ""); + let imageDataBase64; + let imageSize; + let canvas = document.createElement("canvas"); + const MIME_TYPE = imageInputFile.type; + const QUALITY = 0.95; + const MAX_WIDTH = maxWidth ? maxWidth : null; + const MAX_HEIGHT = null; + const file = imageInputFile; // get the file + const blobURL = URL.createObjectURL(file); + const img = new Image(); + /** ********************* Add source to new image */ img.src = blobURL; + imageDataBase64 = await new Promise((res, rej)=>{ + /** ********************* Handle Errors in loading image */ img.onerror = function() { + URL.revokeObjectURL(this.src); + console.log("Cannot load image"); + }; + /** ********************* Handle new image when loaded */ img.onload = function() { + // @ts-ignore + URL.revokeObjectURL(this.src); + if (MAX_WIDTH) { + const scaleSize = MAX_WIDTH / img.naturalWidth; + canvas.width = img.naturalWidth < MAX_WIDTH ? img.naturalWidth : MAX_WIDTH; + canvas.height = img.naturalWidth < MAX_WIDTH ? img.naturalHeight : img.naturalHeight * scaleSize; + } else { + canvas.width = img.naturalWidth; + canvas.height = img.naturalHeight; + } + const ctx = canvas.getContext("2d"); + ctx?.drawImage(img, 0, 0, canvas.width, canvas.height); + const srcEncoded = canvas.toDataURL(MIME_TYPE, QUALITY); + if (imagePreviewNode) { + document.querySelectorAll(`[data-imagepreview='image']`).forEach((/** @type {any} */ img)=>{ + img.src = srcEncoded; + }); + } + res(srcEncoded); + }; + }); + imageSize = await new Promise((res, rej)=>{ + canvas.toBlob((blob)=>{ + res(blob?.size); + }, MIME_TYPE, QUALITY); + }); + return { + imageBase64: imageDataBase64.replace(/.*?base64,/, ""), + imageBase64Full: imageDataBase64, + imageName: imageName, + imageSize: imageSize + }; +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6729.js b/dsql-app/.local_dist/server/chunks/6729.js new file mode 100644 index 0000000..7719fad --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6729.js @@ -0,0 +1,124 @@ +"use strict"; +exports.id = 6729; +exports.ids = [6729]; +exports.modules = { + +/***/ 6729: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ fetchApi) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Fetch Function + * ============================================================================== + * @async + * + * @param {string} url - Admin or Site page + * @param {{ + * method: "POST" | "GET" | "DELETE" | "PUT" | "PATCH" | "post" | "get" | "delete" | "put" | "patch", + * body: object | string, + * headers?: HeadersInit, + * } | string} [options] - options object or string: **optional + * @param {boolean} [csrf] - Add CSRF? + * + * @returns {Promise<*>} + */ async function fetchApi(url, options, csrf) { + /** ********************* Initialize data variable */ let data; + const finalUrl = url.match(/\?/) ? url : url + window.location.search; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (typeof options === "string") { + try { + let fetchData; + switch(options){ + case "post": + fetchData = await fetch(finalUrl, { + method: options, + // @ts-ignore + headers: { + "Content-Type": "application/json", + "x-csrf-auth": csrf ? localStorage.getItem("csrf") : "" + } + }); + data = fetchData.json(); + break; + default: + fetchData = await fetch(finalUrl); + data = fetchData.json(); + break; + } + } catch (error) { + data = null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else if (typeof options === "object") { + try { + let fetchData1; + /** ********************* Convert body to JSON if not JSON */ if (options.body && typeof options.body === "object") { + let oldOptionsBody = options.body; + options.body = JSON.stringify(oldOptionsBody); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (options.headers) { + //////////////////////////////////////// + // @ts-ignore + options.headers["x-csrf-auth"] = csrf ? localStorage.getItem("csrf") : ""; + /** @type {any} */ const finalOptions = { + ...options + }; + fetchData1 = await fetch(finalUrl, finalOptions); + //////////////////////////////////////// + } else { + fetchData1 = await fetch(finalUrl, { + ...options, + // @ts-ignore + headers: { + "Content-Type": "application/json", + "x-csrf-auth": csrf ? localStorage.getItem("csrf") : "" + } + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + data = fetchData1.json(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error1) { + data = null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else { + try { + let fetchData2 = await fetch(finalUrl); + data = fetchData2.json(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error2) { + data = null; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return data; +} +var FETCH = fetchApi; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6825.js b/dsql-app/.local_dist/server/chunks/6825.js new file mode 100644 index 0000000..a6dcf92 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6825.js @@ -0,0 +1,86 @@ +"use strict"; +exports.id = 6825; +exports.ids = [6825]; +exports.modules = { + +/***/ 6825: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const http = __webpack_require__(3685); +const DB_HANDLER = __webpack_require__(2224); +const decrypt = __webpack_require__(5425); +const fs = __webpack_require__(7147); +const EXPIRY_TIME = 1000 * 60 * 60 * 24 * 1 * 7; // 7 days +/** + * @async + * @param {import("next").NextApiRequest | http.IncomingMessage & { cookies: Partial<{ [key: string]: string; }>; +}} req - https request object + * @param {import("next").NextApiResponse | http.ServerResponse} res - https response object + * @param {boolean | null} [csrf] - csrf key + * @param {any} [query] - query object + * + * @returns {Promise<(import("@/package-shared/types").UserType | null)>} + */ module.exports = async function userAuth(req, res, csrf, query) { + /** ********************* Check for existence of required cookie */ if (!req.cookies?.datasquirelAuthKey?.match(/./)) { + // console.log("No datasquirel key cookie present"); + return null; + } + /** ********************* Grab the payload */ let userPayload = decrypt(req.cookies.datasquirelAuthKey); + /** ********************* Return if no payload */ if (!userPayload) { + // console.log("Couldn't Decrypt cookie"); + return null; + } + /** ********************* Parse the payload */ let userObject = JSON.parse(userPayload); + const { user_type } = userObject; + if (!userObject.csrf_k) { + // console.log("No CSRF_K in decrypted payload"); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (csrf && // @ts-ignore + !req.headers["x-csrf-auth"]?.match(new RegExp(`${userObject.csrf_k}`))) { + // console.log("CSRF_K requested but does not match payload"); + return null; + } + const allowedAuthKeysPath = process.env.DSQL_USER_LOGIN_KEYS_PATH; + if (!allowedAuthKeysPath) { + console.log(`DSQL_USER_LOGIN_KEYS_PATH env variable not found. Please set this variable.`); + return null; + } + if (csrf && !fs.existsSync(`${allowedAuthKeysPath}/${userObject.csrf_k}`)) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* check user verification */ if (userObject.verification_status == 0 && !csrf) { + let currentVerificationStatus = await DB_HANDLER(`SELECT verification_status FROM users WHERE id='${userObject.id}'`); + if (currentVerificationStatus && currentVerificationStatus[0] && currentVerificationStatus[0].verification_status == 1) { + // userObject = await reAuthUser({ userId: userObject.id, res }); + res.setHeader("Set-Cookie", [ + `user_refresh=1` + ]); + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (userObject?.date && Date.now() - userObject.date > EXPIRY_TIME) { + // console.log("Cookie expired"); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* return user object */ return userObject; +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6859.js b/dsql-app/.local_dist/server/chunks/6859.js new file mode 100644 index 0000000..de417ec --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6859.js @@ -0,0 +1,776 @@ +exports.id = 6859; +exports.ids = [6859]; +exports.modules = { + +/***/ 3105: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +"use strict"; +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Html = Html; +exports.Main = Main; +__webpack_unused_export__ = void 0; +var _react = _interopRequireWildcard(__webpack_require__(6689)); +var _constants = __webpack_require__(6724); +var _getPageFiles = __webpack_require__(4140); +var _htmlescape = __webpack_require__(9716); +var _isError = _interopRequireDefault(__webpack_require__(676)); +var _htmlContext = __webpack_require__(8743); +class Document extends _react.default.Component { + /** + * `getInitialProps` hook returns the context object with the addition of `renderPage`. + * `renderPage` callback executes `React` rendering logic synchronously to support server-rendering wrappers + */ static getInitialProps(ctx) { + return ctx.defaultGetInitialProps(ctx); + } + render() { + return /*#__PURE__*/ _react.default.createElement(Html, null, /*#__PURE__*/ _react.default.createElement(Head, null), /*#__PURE__*/ _react.default.createElement("body", null, /*#__PURE__*/ _react.default.createElement(Main, null), /*#__PURE__*/ _react.default.createElement(NextScript, null))); + } +} +__webpack_unused_export__ = Document; +function _interopRequireDefault(obj) { + return obj && obj.__esModule ? obj : { + default: obj + }; +} +function _getRequireWildcardCache() { + if (typeof WeakMap !== "function") return null; + var cache = new WeakMap(); + _getRequireWildcardCache = function() { + return cache; + }; + return cache; +} +function _interopRequireWildcard(obj) { + if (obj && obj.__esModule) { + return obj; + } + if (obj === null || typeof obj !== "object" && typeof obj !== "function") { + return { + default: obj + }; + } + var cache = _getRequireWildcardCache(); + if (cache && cache.has(obj)) { + return cache.get(obj); + } + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for(var key in obj){ + if (Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) { + Object.defineProperty(newObj, key, desc); + } else { + newObj[key] = obj[key]; + } + } + } + newObj.default = obj; + if (cache) { + cache.set(obj, newObj); + } + return newObj; +} +function getDocumentFiles(buildManifest, pathname, inAmpMode) { + const sharedFiles = (0, _getPageFiles).getPageFiles(buildManifest, "/_app"); + const pageFiles = true && inAmpMode ? [] : (0, _getPageFiles).getPageFiles(buildManifest, pathname); + return { + sharedFiles, + pageFiles, + allFiles: [ + ...new Set([ + ...sharedFiles, + ...pageFiles + ]) + ] + }; +} +function getPolyfillScripts(context, props) { + // polyfills.js has to be rendered as nomodule without async + // It also has to be the first script to load + const { assetPrefix , buildManifest , devOnlyCacheBusterQueryString , disableOptimizedLoading , crossOrigin , } = context; + return buildManifest.polyfillFiles.filter((polyfill)=>polyfill.endsWith(".js") && !polyfill.endsWith(".module.js")).map((polyfill)=>/*#__PURE__*/ _react.default.createElement("script", { + key: polyfill, + defer: !disableOptimizedLoading, + nonce: props.nonce, + crossOrigin: props.crossOrigin || crossOrigin, + noModule: true, + src: `${assetPrefix}/_next/${polyfill}${devOnlyCacheBusterQueryString}` + })); +} +function hasComponentProps(child) { + return !!child && !!child.props; +} +function AmpStyles({ styles }) { + if (!styles) return null; + // try to parse styles from fragment for backwards compat + const curStyles = Array.isArray(styles) ? styles : []; + if (styles.props && // @ts-ignore Property 'props' does not exist on type ReactElement + Array.isArray(styles.props.children)) { + const hasStyles = (el)=>{ + var ref, ref1; + return el == null ? void 0 : (ref = el.props) == null ? void 0 : (ref1 = ref.dangerouslySetInnerHTML) == null ? void 0 : ref1.__html; + }; + // @ts-ignore Property 'props' does not exist on type ReactElement + styles.props.children.forEach((child)=>{ + if (Array.isArray(child)) { + child.forEach((el)=>hasStyles(el) && curStyles.push(el)); + } else if (hasStyles(child)) { + curStyles.push(child); + } + }); + } + /* Add custom styles before AMP styles to prevent accidental overrides */ return /*#__PURE__*/ _react.default.createElement("style", { + "amp-custom": "", + dangerouslySetInnerHTML: { + __html: curStyles.map((style)=>style.props.dangerouslySetInnerHTML.__html).join("").replace(/\/\*# sourceMappingURL=.*\*\//g, "").replace(/\/\*@ sourceURL=.*?\*\//g, "") + } + }); +} +function getDynamicChunks(context, props, files) { + const { dynamicImports , assetPrefix , isDevelopment , devOnlyCacheBusterQueryString , disableOptimizedLoading , crossOrigin , } = context; + return dynamicImports.map((file)=>{ + if (!file.endsWith(".js") || files.allFiles.includes(file)) return null; + return /*#__PURE__*/ _react.default.createElement("script", { + async: !isDevelopment && disableOptimizedLoading, + defer: !disableOptimizedLoading, + key: file, + src: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + nonce: props.nonce, + crossOrigin: props.crossOrigin || crossOrigin + }); + }); +} +function getScripts(context, props, files) { + var ref; + const { assetPrefix , buildManifest , isDevelopment , devOnlyCacheBusterQueryString , disableOptimizedLoading , crossOrigin , } = context; + const normalScripts = files.allFiles.filter((file)=>file.endsWith(".js")); + const lowPriorityScripts = (ref = buildManifest.lowPriorityFiles) == null ? void 0 : ref.filter((file)=>file.endsWith(".js")); + return [ + ...normalScripts, + ...lowPriorityScripts + ].map((file)=>{ + return /*#__PURE__*/ _react.default.createElement("script", { + key: file, + src: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + nonce: props.nonce, + async: !isDevelopment && disableOptimizedLoading, + defer: !disableOptimizedLoading, + crossOrigin: props.crossOrigin || crossOrigin + }); + }); +} +function getPreNextWorkerScripts(context, props) { + const { assetPrefix , scriptLoader , crossOrigin , nextScriptWorkers } = context; + // disable `nextScriptWorkers` in edge runtime + if (!nextScriptWorkers || "nodejs" === "edge") return null; + try { + let { partytownSnippet } = require("@builder.io/partytown/integration"); + const children = Array.isArray(props.children) ? props.children : [ + props.children + ]; + // Check to see if the user has defined their own Partytown configuration + const userDefinedConfig = children.find((child)=>{ + var ref, ref2; + return hasComponentProps(child) && (child == null ? void 0 : (ref = child.props) == null ? void 0 : (ref2 = ref.dangerouslySetInnerHTML) == null ? void 0 : ref2.__html.length) && "data-partytown-config" in child.props; + }); + return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, !userDefinedConfig && /*#__PURE__*/ _react.default.createElement("script", { + "data-partytown-config": "", + dangerouslySetInnerHTML: { + __html: ` + partytown = { + lib: "${assetPrefix}/_next/static/~partytown/" + }; + ` + } + }), /*#__PURE__*/ _react.default.createElement("script", { + "data-partytown": "", + dangerouslySetInnerHTML: { + __html: partytownSnippet() + } + }), (scriptLoader.worker || []).map((file, index)=>{ + const { strategy , src , children: scriptChildren , dangerouslySetInnerHTML , ...scriptProps } = file; + let srcProps = {}; + if (src) { + // Use external src if provided + srcProps.src = src; + } else if (dangerouslySetInnerHTML && dangerouslySetInnerHTML.__html) { + // Embed inline script if provided with dangerouslySetInnerHTML + srcProps.dangerouslySetInnerHTML = { + __html: dangerouslySetInnerHTML.__html + }; + } else if (scriptChildren) { + // Embed inline script if provided with children + srcProps.dangerouslySetInnerHTML = { + __html: typeof scriptChildren === "string" ? scriptChildren : Array.isArray(scriptChildren) ? scriptChildren.join("") : "" + }; + } else { + throw new Error("Invalid usage of next/script. Did you forget to include a src attribute or an inline script? https://nextjs.org/docs/messages/invalid-script"); + } + return /*#__PURE__*/ _react.default.createElement("script", Object.assign({}, srcProps, scriptProps, { + type: "text/partytown", + key: src || index, + nonce: props.nonce, + "data-nscript": "worker", + crossOrigin: props.crossOrigin || crossOrigin + })); + })); + } catch (err) { + if ((0, _isError).default(err) && err.code !== "MODULE_NOT_FOUND") { + console.warn(`Warning: ${err.message}`); + } + return null; + } +} +function getPreNextScripts(context, props) { + const { scriptLoader , disableOptimizedLoading , crossOrigin } = context; + const webWorkerScripts = getPreNextWorkerScripts(context, props); + const beforeInteractiveScripts = (scriptLoader.beforeInteractive || []).filter((script)=>script.src).map((file, index)=>{ + const { strategy , ...scriptProps } = file; + var _defer; + return /*#__PURE__*/ _react.default.createElement("script", Object.assign({}, scriptProps, { + key: scriptProps.src || index, + defer: (_defer = scriptProps.defer) != null ? _defer : !disableOptimizedLoading, + nonce: props.nonce, + "data-nscript": "beforeInteractive", + crossOrigin: props.crossOrigin || crossOrigin + })); + }); + return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, webWorkerScripts, beforeInteractiveScripts); +} +function getHeadHTMLProps(props) { + const { crossOrigin , nonce , ...restProps } = props; + // This assignment is necessary for additional type checking to avoid unsupported attributes in + const headProps = restProps; + return headProps; +} +function getAmpPath(ampPath, asPath) { + return ampPath || `${asPath}${asPath.includes("?") ? "&" : "?"}amp=1`; +} +class Head extends _react.default.Component { + static contextType = _htmlContext.HtmlContext; + getCssLinks(files) { + const { assetPrefix , devOnlyCacheBusterQueryString , dynamicImports , crossOrigin , optimizeCss , optimizeFonts , } = this.context; + const cssFiles = files.allFiles.filter((f)=>f.endsWith(".css")); + const sharedFiles = new Set(files.sharedFiles); + // Unmanaged files are CSS files that will be handled directly by the + // webpack runtime (`mini-css-extract-plugin`). + let unmangedFiles = new Set([]); + let dynamicCssFiles = Array.from(new Set(dynamicImports.filter((file)=>file.endsWith(".css")))); + if (dynamicCssFiles.length) { + const existing = new Set(cssFiles); + dynamicCssFiles = dynamicCssFiles.filter((f)=>!(existing.has(f) || sharedFiles.has(f))); + unmangedFiles = new Set(dynamicCssFiles); + cssFiles.push(...dynamicCssFiles); + } + let cssLinkElements = []; + cssFiles.forEach((file)=>{ + const isSharedFile = sharedFiles.has(file); + if (!optimizeCss) { + cssLinkElements.push(/*#__PURE__*/ _react.default.createElement("link", { + key: `${file}-preload`, + nonce: this.props.nonce, + rel: "preload", + href: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + as: "style", + crossOrigin: this.props.crossOrigin || crossOrigin + })); + } + const isUnmanagedFile = unmangedFiles.has(file); + cssLinkElements.push(/*#__PURE__*/ _react.default.createElement("link", { + key: file, + nonce: this.props.nonce, + rel: "stylesheet", + href: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + crossOrigin: this.props.crossOrigin || crossOrigin, + "data-n-g": isUnmanagedFile ? undefined : isSharedFile ? "" : undefined, + "data-n-p": isUnmanagedFile ? undefined : isSharedFile ? undefined : "" + })); + }); + if ( true && optimizeFonts) { + cssLinkElements = this.makeStylesheetInert(cssLinkElements); + } + return cssLinkElements.length === 0 ? null : cssLinkElements; + } + getPreloadDynamicChunks() { + const { dynamicImports , assetPrefix , devOnlyCacheBusterQueryString , crossOrigin , } = this.context; + return dynamicImports.map((file)=>{ + if (!file.endsWith(".js")) { + return null; + } + return /*#__PURE__*/ _react.default.createElement("link", { + rel: "preload", + key: file, + href: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + as: "script", + nonce: this.props.nonce, + crossOrigin: this.props.crossOrigin || crossOrigin + }); + }) // Filter out nulled scripts + .filter(Boolean); + } + getPreloadMainLinks(files) { + const { assetPrefix , devOnlyCacheBusterQueryString , scriptLoader , crossOrigin , } = this.context; + const preloadFiles = files.allFiles.filter((file)=>{ + return file.endsWith(".js"); + }); + return [ + ...(scriptLoader.beforeInteractive || []).map((file)=>/*#__PURE__*/ _react.default.createElement("link", { + key: file.src, + nonce: this.props.nonce, + rel: "preload", + href: file.src, + as: "script", + crossOrigin: this.props.crossOrigin || crossOrigin + })), + ...preloadFiles.map((file)=>/*#__PURE__*/ _react.default.createElement("link", { + key: file, + nonce: this.props.nonce, + rel: "preload", + href: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + as: "script", + crossOrigin: this.props.crossOrigin || crossOrigin + })), + ]; + } + getBeforeInteractiveInlineScripts() { + const { scriptLoader } = this.context; + const { nonce , crossOrigin } = this.props; + return (scriptLoader.beforeInteractive || []).filter((script)=>!script.src && (script.dangerouslySetInnerHTML || script.children)).map((file, index)=>{ + const { strategy , children , dangerouslySetInnerHTML , src , ...scriptProps } = file; + let html = ""; + if (dangerouslySetInnerHTML && dangerouslySetInnerHTML.__html) { + html = dangerouslySetInnerHTML.__html; + } else if (children) { + html = typeof children === "string" ? children : Array.isArray(children) ? children.join("") : ""; + } + return /*#__PURE__*/ _react.default.createElement("script", Object.assign({}, scriptProps, { + dangerouslySetInnerHTML: { + __html: html + }, + key: scriptProps.id || index, + nonce: nonce, + "data-nscript": "beforeInteractive", + crossOrigin: crossOrigin || undefined + })); + }); + } + getDynamicChunks(files) { + return getDynamicChunks(this.context, this.props, files); + } + getPreNextScripts() { + return getPreNextScripts(this.context, this.props); + } + getScripts(files) { + return getScripts(this.context, this.props, files); + } + getPolyfillScripts() { + return getPolyfillScripts(this.context, this.props); + } + makeStylesheetInert(node) { + return _react.default.Children.map(node, (c)=>{ + var ref5, ref3; + if ((c == null ? void 0 : c.type) === "link" && (c == null ? void 0 : (ref5 = c.props) == null ? void 0 : ref5.href) && _constants.OPTIMIZED_FONT_PROVIDERS.some(({ url })=>{ + var ref, ref4; + return c == null ? void 0 : (ref = c.props) == null ? void 0 : (ref4 = ref.href) == null ? void 0 : ref4.startsWith(url); + })) { + const newProps = { + ...c.props || {}, + "data-href": c.props.href, + href: undefined + }; + return /*#__PURE__*/ _react.default.cloneElement(c, newProps); + } else if (c == null ? void 0 : (ref3 = c.props) == null ? void 0 : ref3.children) { + const newProps1 = { + ...c.props || {}, + children: this.makeStylesheetInert(c.props.children) + }; + return /*#__PURE__*/ _react.default.cloneElement(c, newProps1); + } + return c; + }).filter(Boolean); + } + render() { + const { styles , ampPath , inAmpMode , hybridAmp , canonicalBase , __NEXT_DATA__ , dangerousAsPath , headTags , unstable_runtimeJS , unstable_JsPreload , disableOptimizedLoading , optimizeCss , optimizeFonts , } = this.context; + const disableRuntimeJS = unstable_runtimeJS === false; + const disableJsPreload = unstable_JsPreload === false || !disableOptimizedLoading; + this.context.docComponentsRendered.Head = true; + let { head } = this.context; + let cssPreloads = []; + let otherHeadElements = []; + if (head) { + head.forEach((c)=>{ + if (c && c.type === "link" && c.props["rel"] === "preload" && c.props["as"] === "style") { + cssPreloads.push(c); + } else { + c && otherHeadElements.push(c); + } + }); + head = cssPreloads.concat(otherHeadElements); + } + let children = _react.default.Children.toArray(this.props.children).filter(Boolean); + // show a warning if Head contains (only in development) + if (false) {} + if ( true && optimizeFonts && !( true && inAmpMode)) { + children = this.makeStylesheetInert(children); + } + let hasAmphtmlRel = false; + let hasCanonicalRel = false; + // show warning and remove conflicting amp head tags + head = _react.default.Children.map(head || [], (child)=>{ + if (!child) return child; + const { type , props } = child; + if ( true && inAmpMode) { + let badProp = ""; + if (type === "meta" && props.name === "viewport") { + badProp = 'name="viewport"'; + } else if (type === "link" && props.rel === "canonical") { + hasCanonicalRel = true; + } else if (type === "script") { + // only block if + // 1. it has a src and isn't pointing to ampproject's CDN + // 2. it is using dangerouslySetInnerHTML without a type or + // a type of text/javascript + if (props.src && props.src.indexOf("ampproject") < -1 || props.dangerouslySetInnerHTML && (!props.type || props.type === "text/javascript")) { + badProp = "<script"; + Object.keys(props).forEach((prop)=>{ + badProp += ` ${prop}="${props[prop]}"`; + }); + badProp += "/>"; + } + } + if (badProp) { + console.warn(`Found conflicting amp tag "${child.type}" with conflicting prop ${badProp} in ${__NEXT_DATA__.page}. https://nextjs.org/docs/messages/conflicting-amp-tag`); + return null; + } + } else { + // non-amp mode + if (type === "link" && props.rel === "amphtml") { + hasAmphtmlRel = true; + } + } + return child; + }); + const files = getDocumentFiles(this.context.buildManifest, this.context.__NEXT_DATA__.page, true && inAmpMode); + var _nonce, _nonce1; + return /*#__PURE__*/ _react.default.createElement("head", Object.assign({}, getHeadHTMLProps(this.props)), this.context.isDevelopment && /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/ _react.default.createElement("style", { + "data-next-hide-fouc": true, + "data-ampdevmode": true && inAmpMode ? "true" : undefined, + dangerouslySetInnerHTML: { + __html: `body{display:none}` + } + }), /*#__PURE__*/ _react.default.createElement("noscript", { + "data-next-hide-fouc": true, + "data-ampdevmode": true && inAmpMode ? "true" : undefined + }, /*#__PURE__*/ _react.default.createElement("style", { + dangerouslySetInnerHTML: { + __html: `body{display:block}` + } + }))), head, /*#__PURE__*/ _react.default.createElement("meta", { + name: "next-head-count", + content: _react.default.Children.count(head || []).toString() + }), children, optimizeFonts && /*#__PURE__*/ _react.default.createElement("meta", { + name: "next-font-preconnect" + }), true && inAmpMode && /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/ _react.default.createElement("meta", { + name: "viewport", + content: "width=device-width,minimum-scale=1,initial-scale=1" + }), !hasCanonicalRel && /*#__PURE__*/ _react.default.createElement("link", { + rel: "canonical", + href: canonicalBase + (__webpack_require__(6368).cleanAmpPath)(dangerousAsPath) + }), /*#__PURE__*/ _react.default.createElement("link", { + rel: "preload", + as: "script", + href: "https://cdn.ampproject.org/v0.js" + }), /*#__PURE__*/ _react.default.createElement(AmpStyles, { + styles: styles + }), /*#__PURE__*/ _react.default.createElement("style", { + "amp-boilerplate": "", + dangerouslySetInnerHTML: { + __html: `body{-webkit-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-moz-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-ms-animation:-amp-start 8s steps(1,end) 0s 1 normal both;animation:-amp-start 8s steps(1,end) 0s 1 normal both}@-webkit-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-moz-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-ms-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-o-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}` + } + }), /*#__PURE__*/ _react.default.createElement("noscript", null, /*#__PURE__*/ _react.default.createElement("style", { + "amp-boilerplate": "", + dangerouslySetInnerHTML: { + __html: `body{-webkit-animation:none;-moz-animation:none;-ms-animation:none;animation:none}` + } + })), /*#__PURE__*/ _react.default.createElement("script", { + async: true, + src: "https://cdn.ampproject.org/v0.js" + })), !( true && inAmpMode) && /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, !hasAmphtmlRel && hybridAmp && /*#__PURE__*/ _react.default.createElement("link", { + rel: "amphtml", + href: canonicalBase + getAmpPath(ampPath, dangerousAsPath) + }), this.getBeforeInteractiveInlineScripts(), !optimizeCss && this.getCssLinks(files), !optimizeCss && /*#__PURE__*/ _react.default.createElement("noscript", { + "data-n-css": (_nonce = this.props.nonce) != null ? _nonce : "" + }), !disableRuntimeJS && !disableJsPreload && this.getPreloadDynamicChunks(), !disableRuntimeJS && !disableJsPreload && this.getPreloadMainLinks(files), !disableOptimizedLoading && !disableRuntimeJS && this.getPolyfillScripts(), !disableOptimizedLoading && !disableRuntimeJS && this.getPreNextScripts(), !disableOptimizedLoading && !disableRuntimeJS && this.getDynamicChunks(files), !disableOptimizedLoading && !disableRuntimeJS && this.getScripts(files), optimizeCss && this.getCssLinks(files), optimizeCss && /*#__PURE__*/ _react.default.createElement("noscript", { + "data-n-css": (_nonce1 = this.props.nonce) != null ? _nonce1 : "" + }), this.context.isDevelopment && // this element is used to mount development styles so the + // ordering matches production + // (by default, style-loader injects at the bottom of <head />) + /*#__PURE__*/ _react.default.createElement("noscript", { + id: "__next_css__DO_NOT_USE__" + }), styles || null), /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, {}, ...headTags || [])); + } +} +exports.Head = Head; +function handleDocumentScriptLoaderItems(scriptLoader, __NEXT_DATA__, props) { + var ref10, ref7, ref8, ref9; + if (!props.children) return; + const scriptLoaderItems = []; + const children = Array.isArray(props.children) ? props.children : [ + props.children + ]; + const headChildren = (ref10 = children.find((child)=>child.type === Head)) == null ? void 0 : (ref7 = ref10.props) == null ? void 0 : ref7.children; + const bodyChildren = (ref8 = children.find((child)=>child.type === "body")) == null ? void 0 : (ref9 = ref8.props) == null ? void 0 : ref9.children; + // Scripts with beforeInteractive can be placed inside Head or <body> so children of both needs to be traversed + const combinedChildren = [ + ...Array.isArray(headChildren) ? headChildren : [ + headChildren + ], + ...Array.isArray(bodyChildren) ? bodyChildren : [ + bodyChildren + ], + ]; + _react.default.Children.forEach(combinedChildren, (child)=>{ + var ref; + if (!child) return; + // When using the `next/script` component, register it in script loader. + if ((ref = child.type) == null ? void 0 : ref.__nextScript) { + if (child.props.strategy === "beforeInteractive") { + scriptLoader.beforeInteractive = (scriptLoader.beforeInteractive || []).concat([ + { + ...child.props + }, + ]); + return; + } else if ([ + "lazyOnload", + "afterInteractive", + "worker" + ].includes(child.props.strategy)) { + scriptLoaderItems.push(child.props); + return; + } + } + }); + __NEXT_DATA__.scriptLoader = scriptLoaderItems; +} +class NextScript extends _react.default.Component { + static contextType = _htmlContext.HtmlContext; + getDynamicChunks(files) { + return getDynamicChunks(this.context, this.props, files); + } + getPreNextScripts() { + return getPreNextScripts(this.context, this.props); + } + getScripts(files) { + return getScripts(this.context, this.props, files); + } + getPolyfillScripts() { + return getPolyfillScripts(this.context, this.props); + } + static getInlineScriptSource(context) { + const { __NEXT_DATA__ , largePageDataBytes } = context; + try { + const data = JSON.stringify(__NEXT_DATA__); + const bytes = false ? 0 : Buffer.from(data).byteLength; + const prettyBytes = (__webpack_require__(5955)/* ["default"] */ .Z); + if (largePageDataBytes && bytes > largePageDataBytes) { + console.warn(`Warning: data for page "${__NEXT_DATA__.page}"${__NEXT_DATA__.page === context.dangerousAsPath ? "" : ` (path "${context.dangerousAsPath}")`} is ${prettyBytes(bytes)} which exceeds the threshold of ${prettyBytes(largePageDataBytes)}, this amount of data can reduce performance.\nSee more info here: https://nextjs.org/docs/messages/large-page-data`); + } + return (0, _htmlescape).htmlEscapeJsonString(data); + } catch (err) { + if ((0, _isError).default(err) && err.message.indexOf("circular structure") !== -1) { + throw new Error(`Circular structure in "getInitialProps" result of page "${__NEXT_DATA__.page}". https://nextjs.org/docs/messages/circular-structure`); + } + throw err; + } + } + render() { + const { assetPrefix , inAmpMode , buildManifest , unstable_runtimeJS , docComponentsRendered , devOnlyCacheBusterQueryString , disableOptimizedLoading , crossOrigin , } = this.context; + const disableRuntimeJS = unstable_runtimeJS === false; + docComponentsRendered.NextScript = true; + if ( true && inAmpMode) { + if (true) { + return null; + } + const ampDevFiles = [ + ...buildManifest.devFiles, + ...buildManifest.polyfillFiles, + ...buildManifest.ampDevFiles, + ]; + return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, disableRuntimeJS ? null : /*#__PURE__*/ _react.default.createElement("script", { + id: "__NEXT_DATA__", + type: "application/json", + nonce: this.props.nonce, + crossOrigin: this.props.crossOrigin || crossOrigin, + dangerouslySetInnerHTML: { + __html: NextScript.getInlineScriptSource(this.context) + }, + "data-ampdevmode": true + }), ampDevFiles.map((file)=>/*#__PURE__*/ _react.default.createElement("script", { + key: file, + src: `${assetPrefix}/_next/${file}${devOnlyCacheBusterQueryString}`, + nonce: this.props.nonce, + crossOrigin: this.props.crossOrigin || crossOrigin, + "data-ampdevmode": true + }))); + } + if (false) {} + const files = getDocumentFiles(this.context.buildManifest, this.context.__NEXT_DATA__.page, true && inAmpMode); + return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, !disableRuntimeJS && buildManifest.devFiles ? buildManifest.devFiles.map((file)=>/*#__PURE__*/ _react.default.createElement("script", { + key: file, + src: `${assetPrefix}/_next/${encodeURI(file)}${devOnlyCacheBusterQueryString}`, + nonce: this.props.nonce, + crossOrigin: this.props.crossOrigin || crossOrigin + })) : null, disableRuntimeJS ? null : /*#__PURE__*/ _react.default.createElement("script", { + id: "__NEXT_DATA__", + type: "application/json", + nonce: this.props.nonce, + crossOrigin: this.props.crossOrigin || crossOrigin, + dangerouslySetInnerHTML: { + __html: NextScript.getInlineScriptSource(this.context) + } + }), disableOptimizedLoading && !disableRuntimeJS && this.getPolyfillScripts(), disableOptimizedLoading && !disableRuntimeJS && this.getPreNextScripts(), disableOptimizedLoading && !disableRuntimeJS && this.getDynamicChunks(files), disableOptimizedLoading && !disableRuntimeJS && this.getScripts(files)); + } +} +exports.NextScript = NextScript; +function Html(props) { + const { inAmpMode , docComponentsRendered , locale , scriptLoader , __NEXT_DATA__ , } = (0, _react).useContext(_htmlContext.HtmlContext); + docComponentsRendered.Html = true; + handleDocumentScriptLoaderItems(scriptLoader, __NEXT_DATA__, props); + return /*#__PURE__*/ _react.default.createElement("html", Object.assign({}, props, { + lang: props.lang || locale || undefined, + amp: true && inAmpMode ? "" : undefined, + "data-ampdevmode": true && inAmpMode && "production" !== "production" ? 0 : undefined + })); +} +function Main() { + const { docComponentsRendered } = (0, _react).useContext(_htmlContext.HtmlContext); + docComponentsRendered.Main = true; + // @ts-ignore + return /*#__PURE__*/ _react.default.createElement("next-js-internal-body-render-target", null); +} +// Add a special property to the built-in `Document` component so later we can +// identify if a user customized `Document` is used or not. +const InternalFunctionDocument = function InternalFunctionDocument() { + return /*#__PURE__*/ _react.default.createElement(Html, null, /*#__PURE__*/ _react.default.createElement(Head, null), /*#__PURE__*/ _react.default.createElement("body", null, /*#__PURE__*/ _react.default.createElement(Main, null), /*#__PURE__*/ _react.default.createElement(NextScript, null))); +}; +Document[_constants.NEXT_BUILTIN_DOCUMENT] = InternalFunctionDocument; //# sourceMappingURL=_document.js.map + + +/***/ }), + +/***/ 676: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ + value: true +})); +exports["default"] = isError; +exports.getProperError = getProperError; +var _isPlainObject = __webpack_require__(8524); +function isError(err) { + return typeof err === "object" && err !== null && "name" in err && "message" in err; +} +function getProperError(err) { + if (isError(err)) { + return err; + } + if (false) {} + return new Error((0, _isPlainObject).isPlainObject(err) ? JSON.stringify(err) : err + ""); +} + +//# sourceMappingURL=is-error.js.map + +/***/ }), + +/***/ 5955: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Z = prettyBytes; +function prettyBytes(number, options) { + if (!Number.isFinite(number)) { + throw new TypeError(`Expected a finite number, got ${typeof number}: ${number}`); + } + options = Object.assign({}, options); + if (options.signed && number === 0) { + return " 0 B"; + } + const isNegative = number < 0; + const prefix = isNegative ? "-" : options.signed ? "+" : ""; + if (isNegative) { + number = -number; + } + if (number < 1) { + const numberString = toLocaleString(number, options.locale); + return prefix + numberString + " B"; + } + const exponent = Math.min(Math.floor(Math.log10(number) / 3), UNITS.length - 1); + number = Number((number / Math.pow(1000, exponent)).toPrecision(3)); + const numberString = toLocaleString(number, options.locale); + const unit = UNITS[exponent]; + return prefix + numberString + " " + unit; +} +/* +MIT License + +Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +*/ const UNITS = [ + "B", + "kB", + "MB", + "GB", + "TB", + "PB", + "EB", + "ZB", + "YB" +]; +/* +Formats the given number using `Number#toLocaleString`. +- If locale is a string, the value is expected to be a locale-key (for example: `de`). +- If locale is true, the system default locale is used for translation. +- If no value for locale is specified, the number is returned unmodified. +*/ const toLocaleString = (number, locale)=>{ + let result = number; + if (typeof locale === "string") { + result = number.toLocaleString(locale); + } else if (locale === true) { + result = number.toLocaleString(); + } + return result; +}; + +//# sourceMappingURL=pretty-bytes.js.map + +/***/ }), + +/***/ 6859: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +module.exports = __webpack_require__(3105) + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/6926.js b/dsql-app/.local_dist/server/chunks/6926.js new file mode 100644 index 0000000..b18beef --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/6926.js @@ -0,0 +1,100 @@ +"use strict"; +exports.id = 6926; +exports.ids = [6926]; +exports.modules = { + +/***/ 6926: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +const nodemailer = __webpack_require__(5184); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +let transporter = nodemailer.createTransport({ + host: process.env.DSQL_MAIL_HOST, + port: 465, + secure: true, + auth: { + user: process.env.DSQL_MAIL_EMAIL, + pass: process.env.DSQL_MAIL_PASSWORD + } +}); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # Handle mails + * @param {object} mailObject - Mail Object with params + * @param {string} [mailObject.to] - who is recieving this email? Comma separated for multiple recipients + * @param {string} [mailObject.subject] - Mail Subject + * @param {string} [mailObject.text] - Mail text + * @param {string} [mailObject.html] - Mail HTML + * @param {string | null} [mailObject.alias] - Sender alias: "support" or null + * + * @returns {Promise<any>} mail object + */ module.exports = async function handleNodemailer({ to , subject , text , html , alias , }) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!process.env.DSQL_MAIL_HOST || !process.env.DSQL_MAIL_EMAIL || !process.env.DSQL_MAIL_PASSWORD) { + return null; + } + const sender = (()=>{ + if (alias?.match(/support/i)) return process.env.DSQL_MAIL_EMAIL; + return process.env.DSQL_MAIL_EMAIL; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let sentMessage; + if (!fs.existsSync("./email/index.html")) { + return; + } + let mailRoot = fs.readFileSync("./email/index.html", "utf8"); + let finalHtml = mailRoot.replace(/{{email_body}}/, html ? html : "").replace(/{{issue_date}}/, Date().substring(0, 24)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + let mailObject = {}; + mailObject["from"] = `"Datasquirel" <${sender}>`; + mailObject["sender"] = sender; + if (alias) mailObject["replyTo "] = sender; + // mailObject["priority"] = "high"; + mailObject["to"] = to; + mailObject["subject"] = subject; + mailObject["text"] = text; + mailObject["html"] = finalHtml; + // send mail with defined transport object + let info = await transporter.sendMail(mailObject); + sentMessage = info; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + console.log("ERROR in handleNodemailer Function =>", error.message); + // serverError({ + // component: "handleNodemailer", + // message: error.message, + // user: { email: to }, + // }); + } + return sentMessage; +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7023.js b/dsql-app/.local_dist/server/chunks/7023.js new file mode 100644 index 0000000..1fa26c0 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7023.js @@ -0,0 +1,53 @@ +"use strict"; +exports.id = 7023; +exports.ids = [7023]; +exports.modules = { + +/***/ 7023: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +// const handleNodemailer = require("./handleNodemailer"); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * user?: { id?: number | string, first_name?: string, last_name?: string, email?: string } & *, + * message: string, + * component?: string, + * noMail?: boolean, + * }} params - user id + * + * @returns {Promise<void>} + */ module.exports = async function serverError({ user , message , component , noMail , }) { + const log = `🚀 SERVER ERROR ===========================\nUser Id: ${user?.id}\nUser Name: ${user?.first_name} ${user?.last_name}\nUser Email: ${user?.email}\nError Message: ${message}\nComponent: ${component}\nDate: ${Date()}\n========================================`; + if (!fs.existsSync(`./.tmp/error.log`)) { + fs.writeFileSync(`./.tmp/error.log`, "", "utf-8"); + } + const initialText = fs.readFileSync(`./.tmp/error.log`, "utf-8"); + fs.writeFileSync(`./.tmp/error.log`, log); + fs.appendFileSync(`./.tmp/error.log`, `\n\n\n\n\n${initialText}`); +// if (process.env.NODE_ENV?.match(/production/) && !noMail) { +// handleNodemailer({ +// to: "benoti.san@gmail.com", +// subject: "SERVER Error in Datasquirel Application", +// text: "An Error occured in Datasquirel Application Server Side", +// html: log, +// }); +// } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7037.js b/dsql-app/.local_dist/server/chunks/7037.js new file mode 100644 index 0000000..a9b174e --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7037.js @@ -0,0 +1,50 @@ +"use strict"; +exports.id = 7037; +exports.ids = [7037]; +exports.modules = { + +/***/ 7037: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormAlertBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string | undefined | null} props.message + */ function FormAlertBlock({ message }) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/warning.png", + alt: "Warning Image Icon", + width: 22, + className: "-my-2" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: message + }) + ] + }); +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7192.js b/dsql-app/.local_dist/server/chunks/7192.js new file mode 100644 index 0000000..56d21f0 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7192.js @@ -0,0 +1,73 @@ +"use strict"; +exports.id = 7192; +exports.ids = [7192]; +exports.modules = { + +/***/ 7192: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const generator = __webpack_require__(3785); +const DB_HANDLER = __webpack_require__(2224); +const NO_DB_HANDLER = __webpack_require__(7487); +const encrypt = __webpack_require__(7547); +const addDbEntry = __webpack_require__(5338); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Add Mariadb User + * ============================================================================== + * + * @description this function adds a Mariadb user to the database server + * + * @param {object} params - parameters object * + * @param {number | string} params.userId - invited user object + * + * @returns {Promise<any>} new user auth object payload + */ module.exports = async function addMariadbUser({ userId }) { + try { + const defaultMariadbUserHost = process.env.DSQL_DB_HOST || "127.0.0.1"; + const username = `dsql_user_${userId}`; + const password = generator.generate({ + length: 16, + numbers: true, + symbols: true, + uppercase: true, + exclude: "*#.'`\"" + }); + const encryptedPassword = encrypt(password); + await NO_DB_HANDLER(`CREATE USER IF NOT EXISTS '${username}'@'127.0.0.1' IDENTIFIED BY '${password}' REQUIRE SSL`); + const updateUser = await DB_HANDLER(`UPDATE users SET mariadb_user = ?, mariadb_host = '127.0.0.1', mariadb_pass = ? WHERE id = ?`, [ + username, + encryptedPassword, + userId + ]); + const addMariadbUser1 = await addDbEntry({ + tableName: "mariadb_users", + data: { + user_id: userId, + username, + host: defaultMariadbUserHost, + password: encryptedPassword, + primary: "1", + grants: '[{"database":"*","table":"*","privileges":["ALL"]}]' + }, + dbContext: "Master" + }); + console.log("addMariadbUser =>", addMariadbUser1); + console.log(`User ${userId} SQL credentials successfully added.`); + } catch (/** @type {any} */ error) { + console.log(`Error in adding SQL user in 'addMariadbUser' function =>`, error.message); + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/722.js b/dsql-app/.local_dist/server/chunks/722.js new file mode 100644 index 0000000..adc3baf --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/722.js @@ -0,0 +1,101 @@ +"use strict"; +exports.id = 722; +exports.ids = [722]; +exports.modules = { + +/***/ 722: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports + * ============================================================================== + */ +const https = __webpack_require__(5687); +const http = __webpack_require__(3685); +const { URL } = __webpack_require__(7310); +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Main Function + * ============================================================================== + * @param {{ + * scheme?: string, + * url?: string, + * method?: string, + * hostname?: string, + * path?: string, + * port?: number | string, + * headers?: object, + * body?: object, + * }} params - params + */ module.exports = function httpsRequest({ url , method , hostname , path , headers , body , port , scheme , }) { + const reqPayloadString = body ? JSON.stringify(body) : null; + const PARSED_URL = url ? new URL(url) : null; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** @type {any} */ let requestOptions = { + method: method || "GET", + hostname: PARSED_URL ? PARSED_URL.hostname : hostname, + port: scheme?.match(/https/i) ? 443 : PARSED_URL ? PARSED_URL.protocol?.match(/https/i) ? 443 : PARSED_URL.port : port ? Number(port) : 80, + headers: {} + }; + if (path) requestOptions.path = path; + // if (href) requestOptions.href = href; + if (headers) requestOptions.headers = headers; + if (body) { + requestOptions.headers["Content-Type"] = "application/json"; + requestOptions.headers["Content-Length"] = reqPayloadString ? Buffer.from(reqPayloadString).length : undefined; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + return new Promise((res, rej)=>{ + const httpsRequest = (scheme?.match(/https/i) ? https : PARSED_URL?.protocol?.match(/https/i) ? https : http).request(/* ====== Request Options object ====== */ requestOptions, //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /* ====== Callback function ====== */ (response)=>{ + var str = ""; + // ## another chunk of data has been received, so append it to `str` + response.on("data", function(chunk) { + str += chunk; + }); + // ## the whole response has been received, so we just print it out here + response.on("end", function() { + res(str); + }); + response.on("error", (error)=>{ + console.log("HTTP response error =>", error.message); + rej(`HTTP response error =>, ${error.message}`); + }); + response.on("close", ()=>{ + console.log("HTTP(S) Response Closed Successfully"); + }); + }); + if (body) httpsRequest.write(reqPayloadString); + httpsRequest.on("error", (error)=>{ + console.log("HTTPS request ERROR =>", error.message); + rej(`HTTP request error =>, ${error.message}`); + }); + httpsRequest.end(); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + }); +}; ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7487.js b/dsql-app/.local_dist/server/chunks/7487.js new file mode 100644 index 0000000..b3ae667 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7487.js @@ -0,0 +1,68 @@ +"use strict"; +exports.id = 7487; +exports.ids = [7487]; +exports.modules = { + +/***/ 7487: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +// const mysql = require("mysql"); +// const NO_DB = mysql.createConnection({ +// host: process.env.DSQL_DB_HOST, +// user: process.env.DSQL_DB_USERNAME, +// password: process.env.DSQL_DB_PASSWORD, +// charset: "utf8mb4", +// }); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +let NO_DB = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {string} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ // @ts-ignore +function NO_DB_HANDLER(...args) { + try { + return new Promise((resolve, reject)=>{ + NO_DB.query(...args).then((results)=>{ + NO_DB.end(); + resolve(JSON.parse(JSON.stringify(results))); + }).catch((err)=>{ + NO_DB.end(); + resolve({ + error: err.message, + sql: err.sql + }); + }); + }); + } catch (/** @type {any} */ error) { + return { + success: false, + error: error.message + }; + } +} +module.exports = NO_DB_HANDLER; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/75.js b/dsql-app/.local_dist/server/chunks/75.js new file mode 100644 index 0000000..82ca43f --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/75.js @@ -0,0 +1,61 @@ +"use strict"; +exports.id = 75; +exports.ids = [75]; +exports.modules = { + +/***/ 4739: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabaseSlugCopy) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5050); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + + +// import DifferenceOutlinedIcon from "@mui/icons-material/DifferenceOutlined"; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {{ + * slugText: string, + * smaller?: boolean, + * outlined?: boolean, + * }} props - React component props including { children } + */ function DatabaseSlugCopy({ slugText , smaller , outlined }) { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "button " + (outlined ? " outlined gray" : "light-gray") + (smaller ? " small-text" : ""), + onClick: (e)=>{ + navigator.clipboard.writeText(slugText).then(()=>{ + alert(`Database Slug "${slugText}" Copied to Clipboard. Use this as the database name when querying data`); + }); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_2___default()), { + color: "action", + sx: { + opacity: 0.5, + fontSize: 15 + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: slugText + }) + ] + }); +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7531.js b/dsql-app/.local_dist/server/chunks/7531.js new file mode 100644 index 0000000..a7ccbf3 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7531.js @@ -0,0 +1,530 @@ +"use strict"; +exports.id = 7531; +exports.ids = [7531]; +exports.modules = { + +/***/ 7531: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleDbUserContext": () => (/* binding */ SingleDbUserContext), + "default": () => (/* binding */ DatabaseSingleUserPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/users/UserImage.jsx +var UserImage = __webpack_require__(2733); +;// CONCATENATED MODULE: ./components/admin/users/SingleDbUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleDbUserContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { singleUser , database , user } = external_react_default().useContext(SingleDbUserContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userFields = Object.keys(singleUser).filter((key)=>!key.match(/^id$|^date_|^user_id$|^social_|^disk_usage|user_type/)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ userImage: any, setUserImage: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [userImage, setUserImage] = external_react_default().useState(singleUser["image"]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + userImage && /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: userImage, + alt: "", + className: "avatar large outlined" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + singleUser.first_name, + " ", + singleUser.last_name + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users/${singleUser.id}/change-password`, + className: "button outlined gray", + children: "Change Password" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "bg-red-500", + onClick: (e)=>{ + setLoading(true); + if (window.confirm("Delete this user?")) { + (0,fetchApi/* default */.Z)("/api/deleteDbUser", { + method: "post", + body: { + userId: singleUser.id, + dbFullName: database.db_full_name + } + }, true).then((res)=>{ + if (res.success) window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/users`; + }); + } + }, + children: "Delete User" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex-col items-stretch", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-col items-stretch gap-4", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const form = e.target; + const formFields = Array.from(form); + /** @type {any} */ const formFieldsObject = {}; + formFields.forEach((/** @type {any} */ field)=>{ + if (field?.nodeName?.match(/button/i)) return; + if (!field?.name || !field?.value?.match(/./)) return; + if (field?.name?.match(/username|email/)) return; + formFieldsObject[field.name] = field.value; + }); + const fetchObject = { + dbFullName: database.db_full_name, + payload: { + ...formFieldsObject, + id: singleUser["id"] + } + }; + (0,fetchApi/* default */.Z)("/api/updateDbUser", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (userImage?.imageBase64) { + userImage["imageName"] = `${database.db_slug}-user-${singleUser.id}`; + userImage["mimeType"] = "jpeg"; + delete userImage["imageBase64Full"]; + (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + userImage + ], + folder: database.db_slug.replace(/_/g, "-"), + type: "image" + } + }, true).then((_res)=>{ + if (_res && _res.mediaData && _res.mediaData[0]?.media_url) { + (0,fetchApi/* default */.Z)("/api/updateDbUser", { + method: "post", + body: { + dbFullName: database.db_full_name, + payload: { + id: singleUser.id, + image: _res.mediaData[0].media_url, + image_thumbnail: _res.mediaData[0].media_thumbnail_url + } + } + }, true).then((__res)=>{ + if (__res.success) window.location.reload(); + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + } else { + window.location.reload(); + } + }); + } else { + window.location.reload(); + } + }); + }, + children: [ + userFields.map((field, index)=>{ + if (field?.match(/password|^database|email|username/)) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: field, + id: field, + // @ts-ignore + value: singleUser[field], + placeholder: field, + className: "opacity-40 pointer-events-none", + onChange: (e)=>{ + e.preventDefault(); + } + }, index + 1) + ] + }, index + 1); + } + if (field?.match(/more_user_data/)) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: field, + id: field, + defaultValue: // @ts-ignore + singleUser[field] ? singleUser[field] : undefined, + placeholder: field, + rows: 6 + }, index + 1) + ] + }, index + 1); + } + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: field, + id: field, + defaultValue: // @ts-ignore + singleUser[field] ? singleUser[field] : undefined, + placeholder: field + }, index + 1) + ] + }, index + 1); + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "border border-slate-300 dark:border-slate-600 border-solid bg-slate-100 dark:bg-slate-700 rounded p-6 flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600", + children: "Update Image" + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserImage/* default */.Z, { + userImage: userImage, + setUserImage: setUserImage, + className: "w-full" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: "Update User" + }) + ] + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/users/[user]/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DatabaseSingleUserContextType} */ // @ts-ignore +const init = {}; +const SingleDbUserContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {import("@/package-shared/types").MYSQL_user_users_table_def} props.singleUser + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function DatabaseSingleUserPage({ user , database , table , dbSchemaData , singleUser , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${singleUser.first_name} ${singleUser.last_name} Users | Datasquirel"`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(SingleDbUserContext.Provider, { + value: { + user, + database, + table, + dbSchemaData, + singleUser, + query, + confirmedDelegetedUser + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(SingleDbUserContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + // @ts-ignore + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const { dbUserId , rootUserId } = dbUserDataObj; + const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + console.log("Database Not Found"); + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === "users")[0]; + const singleUser = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM users WHERE id='${query.user}'`, + tableSchema: targetTable + }); + if (!singleUser?.[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases/${database[0].db_slug}/users`, + permanent: false + } + }; + } + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database?.[0] || null, + table: targetTable ? targetTable : {}, + dbSchemaData: dbSchemaData, + singleUser: singleUser?.[0] || null, + query, + confirmedDelegetedUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7547.js b/dsql-app/.local_dist/server/chunks/7547.js new file mode 100644 index 0000000..fdc0950 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7547.js @@ -0,0 +1,46 @@ +"use strict"; +exports.id = 7547; +exports.ids = [7547]; +exports.modules = { + +/***/ 7547: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { scryptSync , createCipheriv } = __webpack_require__(6113); +const { Buffer } = __webpack_require__(4300); +const serverError = __webpack_require__(3017); +/** + * @async + * @param {string} data + * @param {string} [encryptionKey] + * @param {string} [encryptionSalt] + * @returns {string | null} + */ const encrypt = (data, encryptionKey, encryptionSalt)=>{ + const algorithm = "aes-192-cbc"; + const password = encryptionKey ? encryptionKey : process.env.DSQL_ENCRYPTION_PASSWORD || ""; + /** ********************* Generate key */ const salt = encryptionSalt ? encryptionSalt : process.env.DSQL_ENCRYPTION_SALT || ""; + let key = scryptSync(password, salt, 24); + let iv = Buffer.alloc(16, 0); + // @ts-ignore + const cipher = createCipheriv(algorithm, key, iv); + /** ********************* Encrypt data */ try { + let encrypted = cipher.update(data, "utf8", "hex"); + encrypted += cipher.final("hex"); + return encrypted; + } catch (/** @type {any} */ error) { + serverError({ + component: "encrypt", + message: error.message + }); + return null; + } +}; +module.exports = encrypt; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7638.js b/dsql-app/.local_dist/server/chunks/7638.js new file mode 100644 index 0000000..8682abd --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7638.js @@ -0,0 +1,41 @@ +"use strict"; +exports.id = 7638; +exports.ids = [7638]; +exports.modules = { + +/***/ 7638: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ setUserSchemaData) +/* harmony export */ }); +// @ts-check +const serverError = __webpack_require__(2163); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * @param {Object} params + * @param {string | number} params.userId + * @param {DSQL_DatabaseSchemaType[]} params.schemaData + * @returns {boolean} + */ function setUserSchemaData({ userId , schemaData }) { + try { + const userSchemaFilePath = path.resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${userId}/main.json`); + fs.writeFileSync(userSchemaFilePath, JSON.stringify(schemaData), "utf8"); + return true; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/setUserSchemaData", + message: error.message + }); + return false; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/766.js b/dsql-app/.local_dist/server/chunks/766.js new file mode 100644 index 0000000..de73794 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/766.js @@ -0,0 +1,55 @@ +"use strict"; +exports.id = 766; +exports.ids = [766]; +exports.modules = { + +/***/ 766: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Handle Table Entries Order + * ================================================================= + * @param {object} param0 + * @param {string} param0.dbName + * @param {string} param0.tableName + * @param {number} param0.entryId + * @param {string} param0.entryOrder + * @param {import("@/package-shared/types").DSQL_TableSchemaType} param0.tableSchema + */ module.exports = async function handleTableEntryOrder({ dbName , entryId , entryOrder , tableName , tableSchema , }) { + try { + const isOrderField = Boolean(tableSchema.fields.find((fld)=>Boolean(fld.fieldName?.match(/^order$/i)))); + if (isOrderField && entryOrder) { + const existingOrder = await DSQL_USER_DB_HANDLER({ + database: dbName, + paradigm: "Full Access", + queryString: `SELECT * FROM ${tableName} WHERE \`order\` = '${entryOrder}' AND id != ?`, + queryValues: [ + String(entryId) + ] + }); + if (!existingOrder?.[0]) throw new Error("No Existing Order"); + await DSQL_USER_DB_HANDLER({ + database: dbName, + paradigm: "Full Access", + queryString: `UPDATE ${tableName} SET \`order\` = \`order\` + 1 WHERE \`order\` >= ${entryOrder} AND id != ?`, + queryValues: [ + String(entryId) + ] + }); + } + return true; + } catch (/** @type {any} */ error) { + return false; + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7839.js b/dsql-app/.local_dist/server/chunks/7839.js new file mode 100644 index 0000000..c192117 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7839.js @@ -0,0 +1,350 @@ +"use strict"; +exports.id = 7839; +exports.ids = [7839]; +exports.modules = { + +/***/ 7839: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +const addAdminUserOnLogin = __webpack_require__(613); +const handleNodemailer = __webpack_require__(6926); +const { ServerResponse } = __webpack_require__(3685); +const path = __webpack_require__(1017); +const addMariadbUser = __webpack_require__(4294); +const varDatabaseDbHandler = __webpack_require__(1311); +const encrypt = __webpack_require__(7547); +const addDbEntry = __webpack_require__(5338); +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * @typedef {object} FunctionReturn + * @property {boolean} success - Did the operation complete successfully or not? + * @property {{ + * id: number, + * first_name: string, + * last_name: string, + * }|null} user - User payload object: or "null" + */ /** + * Handle Social User Auth on Datasquirel Database + * ============================================================================== + * + * @description This function handles all social login logic after the social user + * has been authenticated and userpayload is present. The payload MUST contain the + * specified fields because this funciton will create a new user if the authenticated + * user does not exist. + * + * @param {{ + * database?: string, + * social_id: string|number, + * email: string, + * social_platform: string, + * payload: any, + * res?: ServerResponse, + * invitation?: any, + * supEmail?: string, + * additionalFields?: object, + * }} params - function parameters inside an object + * + * @returns {Promise<any>} - Response object + */ module.exports = async function handleSocialDb({ database , social_id , email , social_platform , payload , res , invitation , supEmail , additionalFields , }) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + try { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + let existingSocialIdUser = await varDatabaseDbHandler({ + database: database ? database : "datasquirel", + queryString: `SELECT * FROM users WHERE social_id = ? AND social_login='1' AND social_platform = ? `, + queryValuesArray: [ + social_id.toString(), + social_platform + ] + }); + if (existingSocialIdUser && existingSocialIdUser[0]) { + return await loginSocialUser({ + user: existingSocialIdUser[0], + social_platform, + res, + invitation, + database, + additionalFields + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const finalEmail = email ? email : supEmail ? supEmail : null; + if (!finalEmail) { + return { + success: false, + user: null, + msg: "No Email Present", + social_id, + social_platform, + payload + }; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + let existingEmailOnly = await varDatabaseDbHandler({ + database: database ? database : "datasquirel", + queryString: `SELECT * FROM users WHERE email='${finalEmail}'` + }); + if (existingEmailOnly && existingEmailOnly[0]) { + return { + user: null, + msg: "This Email is already taken", + alert: true + }; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const foundUser = await varDatabaseDbHandler({ + database: database ? database : "datasquirel", + queryString: `SELECT * FROM users WHERE email='${finalEmail}' AND social_login='1' AND social_platform='${social_platform}' AND social_id='${social_id}'` + }); + if (foundUser && foundUser[0]) { + return await loginSocialUser({ + user: payload, + social_platform, + res, + invitation, + database, + additionalFields + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const socialHashedPassword = encrypt(social_id.toString()); + /** @type {any} */ const data = { + social_login: "1", + verification_status: supEmail ? "0" : "1", + password: socialHashedPassword + }; + Object.keys(payload).forEach((key)=>{ + data[key] = payload[key]; + }); + /** @type {any} */ const newUser = await addDbEntry({ + dbContext: database ? "Dsql User" : undefined, + paradigm: database ? "Full Access" : undefined, + dbFullName: database ? database : "datasquirel", + tableName: "users", + duplicateColumnName: "email", + duplicateColumnValue: finalEmail, + data: { + ...data, + email: finalEmail + } + }); + if (newUser?.insertId) { + if (!database) { + /** + * Add a Mariadb User for this User + */ await addMariadbUser({ + userId: newUser.insertId + }); + } + const newUserQueried = await varDatabaseDbHandler({ + database: database ? database : "datasquirel", + queryString: `SELECT * FROM users WHERE id='${newUser.insertId}'` + }); + if (!newUserQueried || !newUserQueried[0]) return { + user: null, + msg: "User Insertion Failed!" + }; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (supEmail && database?.match(/^datasquirel$/)) { + /** + * Send email Verification + * + * @description Send verification email to newly created agent + */ let generatedToken = encrypt(JSON.stringify({ + id: newUser.insertId, + email: supEmail, + dateCode: Date.now() + })); + handleNodemailer({ + to: supEmail, + subject: "Verify Email Address", + text: "Please click the link to verify your email address", + html: fs.readFileSync("./email/send-email-verification-link.html", "utf8").replace(/{{host}}/, process.env.DSQL_HOST || "").replace(/{{token}}/, generatedToken || "") + }).then((mail)=>{}); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return null; + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ if (!database || database?.match(/^datasquirel$/)) { + let newUserSchemaFolderPath = `./jsonData/dbSchemas/users/user-${newUser.insertId}`; + let newUserMediaFolderPath = path.join(STATIC_ROOT, `images/user-images/user-${newUser.insertId}`); + fs.mkdirSync(newUserSchemaFolderPath); + fs.mkdirSync(newUserMediaFolderPath); + fs.writeFileSync(`${newUserSchemaFolderPath}/main.json`, JSON.stringify([]), "utf8"); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + return await loginSocialUser({ + user: newUserQueried[0], + social_platform, + res, + invitation, + database, + additionalFields + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } else { + console.log("Social User Failed to insert in 'handleSocialDb.js' backend function =>", newUser); + return { + success: false, + user: null, + msg: "Social User Failed to insert in 'handleSocialDb.js' backend function => ", + newUser: newUser + }; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log("ERROR in 'handleSocialDb.js' backend function =>", error.message); + return { + success: false, + user: null, + error: error.message + }; + // serverError({ + // component: "/functions/backend/social-login/handleSocialDb.js - main-catch-error", + // message: error.message, + // user: { first_name, last_name }, + // }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + return { + user: null, + msg: "User Login Failed!" + }; +}; +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * Function to login social user + * ============================================================================== + * @description This function logs in the user after 'handleSocialDb' function finishes + * the user creation or confirmation process + * + * @async + * + * @param {object} params - function parameters inside an object + * @param {{ + * first_name: string, + * last_name: string, + * email: string, + * social_id: string|number, + * }} params.user - user object + * @param {string} params.social_platform - Whether its "google" or "facebook" or "github" + * @param {ServerResponse} [params.res] - Https response object + * @param {any} [params.invitation] - A query object if user was invited + * @param {string} [params.database] - Target Database + * @param {object} [params.additionalFields] - Additional fields to be added to the user payload + * + * @returns {Promise<any>} + */ async function loginSocialUser({ user , social_platform , res , invitation , database , additionalFields , }) { + const foundUser = await varDatabaseDbHandler({ + database: database ? database : "datasquirel", + queryString: `SELECT * FROM users WHERE email='${user.email}' AND social_id='${user.social_id}' AND social_platform='${social_platform}'` + }); + if (!foundUser?.[0]) return { + success: false, + user: null + }; + let csrfKey = Math.random().toString(36).substring(2) + "-" + Math.random().toString(36).substring(2); + /** @type {any} */ let userPayload = { + id: foundUser[0].id, + type: foundUser[0].type || "", + stripe_id: foundUser[0].stripe_id || "", + first_name: foundUser[0].first_name, + last_name: foundUser[0].last_name, + username: foundUser[0].username, + email: foundUser[0].email, + social_id: foundUser[0].social_id, + image: foundUser[0].image, + image_thumbnail: foundUser[0].image_thumbnail, + verification_status: foundUser[0].verification_status, + social_login: foundUser[0].social_login, + social_platform: foundUser[0].social_platform, + csrf_k: csrfKey, + logged_in_status: true, + date: Date.now() + }; + if (additionalFields && Object.keys(additionalFields).length > 0) { + Object.keys(additionalFields).forEach((key)=>{ + userPayload[key] = foundUser[0][key]; + }); + } + let encryptedPayload = encrypt(JSON.stringify(userPayload)); + if (res?.setHeader) { + res.setHeader("Set-Cookie", [ + `datasquirelAuthKey=${encryptedPayload};samesite=strict;path=/;HttpOnly=true;Secure=true`, + `csrf=${csrfKey};samesite=strict;path=/;HttpOnly=true`, + ]); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (invitation && (!database || database?.match(/^datasquirel$/))) { + addAdminUserOnLogin({ + query: invitation, + user: userPayload + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + return { + success: true, + user: userPayload + }; +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7901.js b/dsql-app/.local_dist/server/chunks/7901.js new file mode 100644 index 0000000..31aac6a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7901.js @@ -0,0 +1,429 @@ +"use strict"; +exports.id = 7901; +exports.ids = [7901]; +exports.modules = { + +/***/ 7901: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ FormInput) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +;// CONCATENATED MODULE: ./functions/frontend/numberFormat.js +// @ts-check +/** + * @param {object} param0 + * @param {string | number} param0.value + * @param {"string" | "raw"} [param0.format] + */ function numberFormat({ value , format }) { + let finalValue; + if (!value) return 0; + try { + switch(format){ + case "string": + finalValue = value.toString().replace(/\D/g, "").replace(/\B(?=(\d{3})+(?!\d))/g, ","); + break; + case "raw": + finalValue = parseInt(value.toString().replace(/\D/g, "")); + break; + default: + finalValue = parseInt(value.toString().replace(/\D/g, "")); + break; + } + } catch (error) { + finalValue = 0; + console.log(error); + } + return finalValue; +} + +;// CONCATENATED MODULE: ./functions/frontend/numberFormatFloat.js +// @ts-check +/** + * @param {object} param0 + * @param {string | number} param0.value + * @param {"string" | "raw"} [param0.format] + * @param {number} [param0.decimals] + */ function numberFormatFloat({ value , format , decimals }) { + let finalValue; + const negativeValuePrefix = value?.toString()?.match(/^\-/) ? "-" : ""; + try { + switch(format){ + case "string": + const finalValueSidesArray = value.toString().split("."); + finalValue = negativeValuePrefix + finalValueSidesArray[0].toString().replace(/[^0-9\.]/g, "").replace(/\B(?=(\d{3})+(?!\d))/g, ",") + (finalValueSidesArray[1] ? decimals ? `.${finalValueSidesArray[1].substring(0, decimals)}` : `.${finalValueSidesArray[1].substring(0, 2)}` : ""); + break; + case "raw": + finalValue = parseFloat(negativeValuePrefix + value.toString().replace(/[^0-9\.]/g, "")); + break; + default: + finalValue = parseFloat(negativeValuePrefix + value.toString().replace(/[^0-9\.]/g, "")); + break; + } + } catch (error) { + finalValue = 0; + console.log(error); + } + return finalValue; +} + +;// CONCATENATED MODULE: ./components/form/FormInput.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let /** @type {any} */ incrementTimeout, /** @type {any} */ incrementInterval; +/** + * Form Input + * ============================================================================== + * @param {Object} props - Server props + * @param {string} [props.title] + * @param {string} [props.name] + * @param {string} [props.defaultValue] + * @param {string} [props.placeholder] + * @param {string} [props.autoComplete] + * @param {(e: Event) => void} [props.onInputHandler] + * @param {boolean} [props.required] + * @param {string} [props.inputType] + * @param {React.Dispatch<React.SetStateAction<any>>} [props.setAlert] + * @param {React.Dispatch<React.SetStateAction<string | number>>} [props.setValue] - A react state dispatch function to set + * the current number value + * @param {string} [props.prefix] + * @param {number} [props.minValue] + * @param {number} [props.maxValue] + * @param {boolean?} [props.encrypted] + * @param {boolean?} [props.numberText] + * @param {string} [props.appendCurrency] + * @param {{current: *}} [props.elementRef] + * @param {(e: Event) => void} [props.onChangeHandler] + * @param {string} [props.value] + * @param {number} [props.step] + * @param {boolean} [props.decimal] + * @param {string} [props.pattern] + * @param {string} [props.info] + * @param {string} [props.id] + * @param {string} [props.fontSize] - Eg. "20px" + * @param {string} [props.maxWidth] - Eg. "200px" + */ function FormInput(props) { + try { + /** + * Destructure Props + * + * @abstract Destructure Props + */ const { title , name , defaultValue , placeholder , autoComplete , onInputHandler , required , inputType , setAlert , prefix , minValue , maxValue , encrypted , numberText , appendCurrency , elementRef , onChangeHandler , value , step , decimal , pattern , info , fontSize , maxWidth , setValue , id , } = props; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ function inputChangeHangler(/** @type {any} */ e) { + if (e.target.value.match(/./)) { + e.target.classList.remove("warning"); + setAlert && setAlert(null); + } else if (e.target.required) { + e.target.classList.add("warning"); + } + if (numberText) { + e.target.value = e.target.value.toString().match(/^0+$/) ? "0" : e.target.value.toString().replace(decimal ? /[^0-9\.]/g : /\D/g, "").replace(/^0*/, "").replace(/\B(?=(\d{3})+(?!\d))/g, ","); + } + if (onInputHandler) onInputHandler(e); + if (onChangeHandler) onChangeHandler(e); + } + function toggleDropdown(/** @type {any} */ e) { + if (e.type.match(/enter/i) && window.innerWidth < 1200) { + return; + } + const infoWrapper = e.target.closest(".info-wrapper"); + const dropdown = infoWrapper.querySelector(".info-dropdown"); + if (e.type.match(/leave/i) && !dropdown.classList.contains("hidden")) { + dropdown.classList.add("hidden"); + return; + } else if (e.type.match(/leave/i) && dropdown.classList.contains("hidden")) { + return; + } + if (!infoWrapper) { + dropdown.classList.add("hidden"); + return; + } + if (dropdown.classList.contains("hidden")) { + dropdown.classList.remove("hidden"); + return; + } + dropdown.classList.add("hidden"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.MutableRefObject<HTMLInputElement>} */ const currentElementRef = elementRef ? elementRef : external_react_default().useRef(); + //////////////////////////////////////// + function decrementNumber(/** @type {any} */ e) { + const newValue = decimal ? parseFloat(numberFormatFloat({ + value: currentElementRef.current?.value || 0 + }).toString()) - (step ? parseFloat(step.toString()) : 20) : parseInt(numberFormat({ + value: currentElementRef.current.value + }).toString()) - (step ? step : 20); + const currentNumberValue = decimal ? numberFormatFloat({ + value: newValue, + format: "raw" + }) : numberFormat({ + value: newValue, + format: "raw" + }); + if (minValue && typeof currentNumberValue == "number" && currentNumberValue < minValue) return; + currentElementRef.current.value = decimal ? parseFloat(numberFormatFloat({ + value: newValue, + format: "raw" + }).toString()).toFixed(typeof decimal === "number" ? decimal : 2) : numberFormat({ + value: newValue, + format: "string" + }).toString(); + if (setValue) setValue(currentElementRef.current.value); + } + function incrementNumber(/** @type {any} */ e) { + const newValue = decimal ? parseFloat(numberFormatFloat({ + value: currentElementRef.current.value + }).toString()) + (step ? parseFloat(step.toString()) : 20) : parseInt(numberFormat({ + value: currentElementRef.current.value + }).toString()) + (step ? step : 20); + const newFormattedValue = decimal ? parseFloat(numberFormatFloat({ + value: newValue, + format: "raw" + }).toString()).toFixed(typeof decimal === "number" ? decimal : 2) : numberFormat({ + value: newValue, + format: "string" + }); + const currentNumberValue = decimal ? parseFloat(numberFormatFloat({ + value: newFormattedValue, + format: "raw" + }).toString()) : parseInt(numberFormat({ + value: newFormattedValue, + format: "raw" + }).toString()); + if (maxValue && currentNumberValue > maxValue) return; + currentElementRef.current.value = newFormattedValue.toString(); + if (setValue) setValue(currentElementRef.current.value); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "form-input-wrapper flex flex-col items-start gap-0.5 w-full relative", + style: { + ...maxWidth ? { + maxWidth: maxWidth + } : {} + }, + children: [ + title && /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: name, + children: title + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex items-center w-full relative", + children: [ + prefix && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute left-4 bottom-2 text-lg", + children: prefix + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: inputType ? inputType : "text", + name: name, + id: id ? id : name, + ref: currentElementRef, + placeholder: placeholder ? placeholder : title ? title : "", + autoComplete: autoComplete, + onInput: (e)=>{ + // if (!onInputHandler) return; + inputChangeHangler(e); + }, + onChange: (e)=>{ + // if (!onChangeHandler) return; + inputChangeHangler(e); + }, + value: value ? value : undefined, + defaultValue: value ? undefined : defaultValue ? defaultValue : undefined, + pattern: pattern ? pattern.toString() : undefined, + required: required ? required : false, + style: { + ...fontSize ? { + fontSize: fontSize + } : {}, + ...prefix ? { + paddingLeft: "35px" + } : {} + }, + min: minValue, + max: maxValue, + "data-encrypted": encrypted ? encrypted : null, + "data-appendcurrency": appendCurrency ? appendCurrency : null, + className: "bg-white" + (info ? " pr-16" : "") + }), + numberText && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "absolute gap-1" + (info ? " right-12" : " right-4"), + style: { + top: "50%", + transform: "translate(0,-50%)" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "number-text-button w-10 md:w-8 h-10 md:h-8 rounded-full bg-slate-100 dark:bg-slate-800 flex items-center justify-center cursor-pointer hover:bg-slate-200 text-2xl font-semibold touch-none", + onMouseDown: (e)=>{ + e.preventDefault(); + if (window.innerWidth < 1200) return; + decrementNumber(e); + incrementTimeout = setTimeout(()=>{ + incrementInterval = setInterval(()=>{ + decrementNumber(e); + }, 50); + }, 200); + }, + onTouchStart: (e)=>{ + e.preventDefault(); + if (window.innerWidth >= 1200) return; + decrementNumber(e); + incrementTimeout = setTimeout(()=>{ + incrementInterval = setInterval(()=>{ + decrementNumber(e); + }, 50); + }, 200); + }, + onMouseUp: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + onTouchEnd: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + onMouseLeave: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + onTouchMove: (e)=>{ + e.preventDefault(); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "pointer-events-none", + children: "-" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "number-text-button w-10 md:w-8 h-10 md:h-8 rounded-full bg-slate-100 dark:bg-slate-800 flex items-center justify-center cursor-pointer hover:bg-slate-200 text-2xl font-semibold touch-none", + onMouseDown: (e)=>{ + e.preventDefault(); + if (window.innerWidth < 1200) return; + incrementNumber(e); + incrementTimeout = setTimeout(()=>{ + incrementInterval = setInterval(()=>{ + incrementNumber(e); + }, 50); + }, 200); + }, + onTouchStart: (e)=>{ + e.preventDefault(); + if (window.innerWidth >= 1200) return; + incrementNumber(e); + incrementTimeout = setTimeout(()=>{ + incrementInterval = setInterval(()=>{ + incrementNumber(e); + }, 50); + }, 200); + }, + onMouseUp: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + onTouchEnd: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + onMouseLeave: (e)=>{ + window.clearTimeout(incrementTimeout); + window.clearInterval(incrementInterval); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "pointer-events-none", + children: "+" + }) + }) + ] + }), + info && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "info-wrapper absolute right-2 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10", + style: { + top: "50%", + transform: "translate(0,-50%)" + }, + onMouseEnter: toggleDropdown, + onMouseLeave: toggleDropdown, + onClick: toggleDropdown, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/info-outlined-black.png", + alt: "", + className: "w-6 h-6 object-contain opacity-60 pointer-events-none" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: info + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-2 w-12", + style: { + height: "45px" + } + }) + ] + }) + ] + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log("ERROR in FormInput =>", error); + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: "Form Input Error" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7926.js b/dsql-app/.local_dist/server/chunks/7926.js new file mode 100644 index 0000000..fa08171 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7926.js @@ -0,0 +1,502 @@ +"use strict"; +exports.id = 7926; +exports.ids = [7926]; +exports.modules = { + +/***/ 8124: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ DashboardContent) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./pages/admin/[user_id]/index.jsx +var _user_id_ = __webpack_require__(1457); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/VerificationBanner.jsx +var VerificationBanner = __webpack_require__(7946); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesContent.jsx +var DatabasesContent = __webpack_require__(8744); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesList.jsx +var DatabasesList = __webpack_require__(6891); +;// CONCATENATED MODULE: ./components/admin/dashboard/DatabasesSummary.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabasesSummary(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , setTargetDatabase , user } = external_react_default().useContext(_user_id_.DashboardContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabasesList/* default */.Z, { + databases: databases, + setTargetDatabase: setTargetDatabase, + title: "Recently added Databases", + more: true, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/DelegatedDatabasesSection.jsx +var DelegatedDatabasesSection = __webpack_require__(5592); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/general/MetricCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.icon + * @param {string} props.metric + * @param {string | number} props.count + * @param {string} [props.url] + */ function MetricCard({ icon , metric , count , url }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: url, + className: "card col w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute top-4 right-4", + children: icon + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "content-block", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "metric text-slate-800 dark:text-white", + children: count + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-slate-600 dark:text-slate-400", + children: metric + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/dashboard/Metrics.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function Metrics(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , setTargetDatabase , metrics , user } = external_react_default().useContext(_user_id_.DashboardContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "p-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "grid grid-cols-1 md:grid-cols-2 xl:grid-cols-4 w-full gap-6 items-stretch", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(MetricCard, { + metric: "Databases Created", + count: metrics?.dbCount || 0, + icon: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Database, { + size: 20, + className: "text-secondary2" + }), + url: `/admin/${user?.id}/databases` + }), + /*#__PURE__*/ jsx_runtime_.jsx(MetricCard, { + metric: "Tables Created", + count: metrics?.tablesCount || 0, + icon: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Sheet, { + size: 20, + className: "text-primary" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(MetricCard, { + metric: "Media Added", + count: metrics?.mediaCount || 0, + icon: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Images, { + size: 20, + className: "text-slate-500" + }), + url: `/admin/${user?.id}/media` + }), + /*#__PURE__*/ jsx_runtime_.jsx(MetricCard, { + metric: "API Keys", + count: metrics?.apiKeysCount || 0, + icon: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Key, { + size: 20, + className: "text-slate-900 dark:text-white" + }), + url: `/admin/${user?.id}/api-keys` + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/dashboard/DashboardContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DashboardContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , user } = external_react_default().useContext(_user_id_.DashboardContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Dashboard" + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Metrics, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DatabasesSummary, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DelegatedDatabasesSection/* default */.Z, { + user: user + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx(VerificationBanner/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 1457: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "DashboardContext": () => (/* binding */ DashboardContext), +/* harmony export */ "default": () => (/* binding */ Dashboard), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4858); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _components_admin_dashboard_DashboardContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8124); +/* harmony import */ var _components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5012); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DashboardContextType} */ let DashboardContextObject = {}; +const DashboardContext = /*#__PURE__*/ react__WEBPACK_IMPORTED_MODULE_1___default().createContext(DashboardContextObject); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases - Server props + * @param {import("@/package-shared/types").MetricsType} props.metrics - Server props + */ function Dashboard({ user , databases , metrics }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {*} */ const targetDbState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type { [ targetDatabase: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type | undefined, setTargetDatabase: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type>> ] } */ const [targetDatabase, setTargetDatabase] = targetDbState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(DashboardContext.Provider, { + value: { + user, + databases, + targetDatabase, + setTargetDatabase, + metrics + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_dashboard_DashboardContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + targetDatabase: targetDatabase + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} */ const databases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT * FROM user_databases WHERE user_id=? ORDER BY id DESC LIMIT 3`, [ + user.id + ]); + const metrics = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default()(` + SELECT ( + SELECT COUNT(id) FROM user_databases WHERE user_id=? + ) AS dbCount, + ( + SELECT COUNT(id) FROM user_database_tables WHERE user_id=? + ) AS tablesCount, + ( + SELECT COUNT(id) FROM user_media WHERE user_id=? + ) AS mediaCount, + ( + SELECT COUNT(id) FROM api_keys WHERE user_id=? + ) AS apiKeysCount + `, [ + user.id, + user.id, + user.id, + user.id + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + databases: databases, + metrics: metrics && metrics[0] ? metrics[0] : {} + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/7946.js b/dsql-app/.local_dist/server/chunks/7946.js new file mode 100644 index 0000000..5414a53 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/7946.js @@ -0,0 +1,78 @@ +"use strict"; +exports.id = 7946; +exports.ids = [7946]; +exports.modules = { + +/***/ 7946: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ VerificationBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function VerificationBanner(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/email-verification", + className: "card w-full items-center justify-center py-4 gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/warning.png", + alt: "Down Arrow", + width: 25, + className: "" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Your Account is not verified. Please verify your account." + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8095.js b/dsql-app/.local_dist/server/chunks/8095.js new file mode 100644 index 0000000..7815a76 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8095.js @@ -0,0 +1,626 @@ +"use strict"; +exports.id = 8095; +exports.ids = [8095]; +exports.modules = { + +/***/ 7335: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ BriefIntroSection) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +// EXTERNAL MODULE: external "@mui/icons-material/CloudDoneTwoTone" +var CloudDoneTwoTone_ = __webpack_require__(5891); +;// CONCATENATED MODULE: ./components/general/ScreenShotDescriptionCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.image + * @param {string} props.title + * @param {string} [props.description] + * @param {"green" | "gray"} [props.color] + * @param {number} [props.imageHeight] + */ function ScreenShotDescriptionCard({ image , title , description , color , imageHeight , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const subColor = (()=>{ + if (color == "green") return "green"; + if (color == "gray") return "gray"; + return ""; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "color-card shadow-xl" + (color ? " " + subColor : ""), + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "title m-0 text-2xl", + children: title + }), + description && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-600 dark:text-slate-400 text-left", + children: description + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "image-block", + style: imageHeight ? { + height: `${imageHeight}px` + } : undefined, + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: image, + alt: `${title} Image` + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/general/ContainedSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.image + * @param {string} props.title + * @param {string} [props.description] + * @param {"green" | "gray" | "purple"} [props.color] + * @param {number} [props.height] + * @param {boolean} [props.h2] + * @param {string} [props.url] + * @param {string} [props.cta] + */ function ContainedSection({ image , title , description , color , height , h2 , url , cta , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const subColor = (()=>{ + if (color == "green") return "green"; + if (color == "gray") return "gray"; + if (color == "purple") return "purple"; + return ""; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "contained-section shadow-xl" + (color ? " " + subColor : ""), + style: height ? { + height: `${height}px` + } : undefined, + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "content text-left", + children: [ + h2 ? /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "m-0 text-white", + children: title + }) : /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-white", + children: title + }), + description && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: description + }), + url && cta && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: url, + className: "button mt-4", + children: cta + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "image-block", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: image, + alt: `${title} Image` + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/geometric-overlay.webp", + className: "absolute z-0 left-0 top-0 w-full h-full opacity-80 mix-blend-overlay", + alt: "Background Image" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/pages/homepage/BriefIntroSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function BriefIntroSection(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "py-20", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "main-container flex-col items-center text-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "m-0 lg:text-left", + children: "All your data storage needs in one place" + }), + /*#__PURE__*/ jsx_runtime_.jsx("p", { + className: "m-0 ", + children: "Datasquirel solves the hassle of storing data across different platforms using a centralized, easy-to-use, SQL-based cloud database administration system. Now you can have all your data in one place and retrieve from any location or environment using HTTP REST API calls and SQL queries." + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "grid grid-cols-1 xl:grid-cols-2 w-full mt-10 gap-10", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(ScreenShotDescriptionCard, { + image: "/images/screenshots/databases-light.webp", + title: "Data and Content", + description: "Create databases, tables, dynamic datatypes including rich text, JSON and other editable code blocks", + imageHeight: 400 + }), + /*#__PURE__*/ jsx_runtime_.jsx(ScreenShotDescriptionCard, { + image: "/images/screenshots/media-list-white.webp", + title: "Images, Videos, and other Media", + description: "Static images automatically compressed with multiple format support, videos, pdf, excel documents, and more.", + color: "green", + imageHeight: 400 + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "mt-10 w-full", + children: /*#__PURE__*/ jsx_runtime_.jsx(ContainedSection, { + image: "/images/screenshots/tables-list-white.webp", + title: "All the power of SQL without the hassle", + description: "Indexes, Foreign keys, encryption, triggers, stored proceedures, etc. You get the best of both worlds: the full power of SQL, and the best UI yet to better manipulate your data.", + cta: "Learn More", + url: "/about", + height: 500 + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3987: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FooterCta) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ArticleTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1891); +/* harmony import */ var _mui_icons_material_ArticleTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ArticleTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType | null } [props.user] + */ function FooterCta({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "py-24 border-0 border-t border-b border-slate-100 dark:border-slate-100/10 border-solid", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full max-w-6xl gap-10 justify-between flex-col relative z-10", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-center max-w-2xl text-center ", + style: { + minWidth: "45%" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "m-0 leading-tight", + children: "Get started For Free." + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-lg font-normal", + children: "Get Started At no cost. Learn how to create and retrieve data by viewing our documentation." + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-start justify-center w-full mt-4", + children: [ + !user?.logged_in_status && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/create-account", + className: "button", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "", + children: "Sign Up For Free" + }) + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/docs", + className: "button outlined gray", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_ArticleTwoTone__WEBPACK_IMPORTED_MODULE_2___default()), { + sx: { + opacity: 0.8, + fontSize: 16 + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "See The Docs" + }) + ] + }) + ] + }) + ] + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/grid.webp", + alt: "Dotted image background", + className: "absolute top-0 left-0 w-full h-full object-cover opacity-80 dark:opacity-10 z-0" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 662: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* unused harmony export default */ +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ThumbUpAltTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5768); +/* harmony import */ var _mui_icons_material_ThumbUpAltTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ThumbUpAltTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function MainFeaturesSection(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ _jsx("section", { + className: "py-20", + children: /*#__PURE__*/ _jsxs("div", { + className: "main-container flex-col items-center text-center", + children: [ + /*#__PURE__*/ _jsxs("div", { + children: [ + /*#__PURE__*/ _jsx(ThumbUpAltTwoToneIcon, { + color: "action" + }), + /*#__PURE__*/ _jsx("span", { + className: "text-slate-500 dark:text-white/80 font-medium", + children: "Built from ground up with core basic priciples" + }) + ] + }), + /*#__PURE__*/ _jsx("h2", { + className: "m-0 lg:text-left", + children: "Doing the basics and doing it right" + }), + /*#__PURE__*/ _jsxs("p", { + className: "m-0 ", + children: [ + "The main purpose of a database is to do three main things:", + " ", + /*#__PURE__*/ _jsx("b", { + children: "Create" + }), + ", ", + /*#__PURE__*/ _jsx("b", { + children: "Store" + }), + ", and ", + /*#__PURE__*/ _jsx("b", { + children: "Retrieve" + }), + ". Datasquirel focuses on these basic tasks and simplifies it as much as possible, then builds on them to make your data management even more robust." + ] + }), + /*#__PURE__*/ _jsxs("div", { + className: "grid grid-cols-1 xl:grid-cols-3 w-full gap-10 items-stretch mt-10 text-left", + children: [ + /*#__PURE__*/ _jsxs("div", { + className: "card col items-start", + children: [ + /*#__PURE__*/ _jsx("img", { + src: "/images/elastic-girl-with-the-book-and-the-globe.webp", + alt: "Real Estaste Crypto Image", + width: 250, + height: 250, + className: "object-contain" + }), + /*#__PURE__*/ _jsx("h3", { + className: "m-0", + children: "Create." + }), + /*#__PURE__*/ _jsx("span", { + className: "font-normal mb-4", + children: "Create databases, tables, columns, rows, fields, entries. Datasquirel uses all conventional SQL methods and query system for creating databases and entries: both for the GUI and for the REST api." + }), + /*#__PURE__*/ _jsx("div", { + className: "flex items-start justify-start w-full mt-auto", + children: /*#__PURE__*/ _jsx("a", { + href: "/docs/quick-start", + className: "button outlined gray", + children: /*#__PURE__*/ _jsx("span", { + children: "Learn More" + }) + }) + }) + ] + }), + /*#__PURE__*/ _jsxs("div", { + className: "card col items-start", + children: [ + /*#__PURE__*/ _jsx("img", { + src: "/images/elastic-11.webp", + alt: "Real Estaste Crypto Image", + width: 250, + height: 250, + className: "object-contain" + }), + /*#__PURE__*/ _jsx("h2", { + className: "m-0 text-3xl", + children: "Store." + }), + /*#__PURE__*/ _jsx("span", { + className: "font-normal mb-4", + children: "Store data in different formats as compatible with SQL standards. Integers, varchars, text. In addition datasquirel provides a media storage platform for easy and quick storage of images." + }), + /*#__PURE__*/ _jsxs("div", { + className: "flex items-center justify-start w-full mt-auto flex-wrap", + children: [ + /*#__PURE__*/ _jsx("a", { + href: "/docs/gui-reference/create-entry", + className: "button outlined gray", + children: /*#__PURE__*/ _jsx("span", { + children: "Learn More" + }) + }), + /*#__PURE__*/ _jsxs("a", { + href: "/docs/database-reference/data-types", + className: "text-sm text-sky-500 flex items-center gap-1", + style: { + border: "none" + }, + children: [ + "View Datatypes", + /*#__PURE__*/ _jsx("img", { + src: "/images/icons8-next-button-66.png", + alt: "", + width: 20 + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ _jsxs("div", { + className: "card col items-start", + children: [ + /*#__PURE__*/ _jsx("img", { + src: "/images/elastic-girl-looking-for-an-employee-online.webp", + alt: "Real Estaste Crypto Image", + width: 250, + height: 250, + className: "object-contain" + }), + /*#__PURE__*/ _jsx("h2", { + className: "m-0 text-3xl", + children: "Retrieve." + }), + /*#__PURE__*/ _jsx("span", { + className: "font-normal mb-4", + children: "Get sotred data from anywhere. Using SQLs powerful query system you can run queries directly via REST api with just a few lines of code. For stored media you have access to images and thumbnail links which you can view anywhere." + }), + /*#__PURE__*/ _jsxs("div", { + className: "flex items-center justify-start w-full mt-auto flex-wrap", + children: [ + /*#__PURE__*/ _jsx("a", { + href: "/docs/api-reference/get-data", + className: "button outlined gray", + children: /*#__PURE__*/ _jsx("span", { + children: "Learn More" + }) + }), + /*#__PURE__*/ _jsxs("a", { + href: "/docs/api-reference/get-data", + className: "text-sm text-sky-500 flex items-center gap-1", + style: { + border: "none" + }, + children: [ + "Rest API Docs", + /*#__PURE__*/ _jsx("img", { + src: "/images/icons8-next-button-66.png", + alt: "", + width: 20 + }) + ] + }) + ] + }) + ] + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8164.js b/dsql-app/.local_dist/server/chunks/8164.js new file mode 100644 index 0000000..d0e8c91 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8164.js @@ -0,0 +1,40 @@ +"use strict"; +exports.id = 8164; +exports.ids = [8164]; +exports.modules = { + +/***/ 8164: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ grabUserSchemaData) +/* harmony export */ }); +// @ts-check +const serverError = __webpack_require__(2163); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * @param {Object} params + * @param {string | number} params.userId + * @returns {DSQL_DatabaseSchemaType[] | null} + */ function grabUserSchemaData({ userId }) { + try { + const userSchemaFilePath = path.resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${userId}/main.json`); + const userSchemaData = JSON.parse(fs.readFileSync(userSchemaFilePath, "utf-8")); + return userSchemaData; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/grabUserSchemaData", + message: error.message + }); + return null; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8264.js b/dsql-app/.local_dist/server/chunks/8264.js new file mode 100644 index 0000000..5af6271 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8264.js @@ -0,0 +1,727 @@ +"use strict"; +exports.id = 8264; +exports.ids = [8264]; +exports.modules = { + +/***/ 8264: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabasesTablesList), +/* harmony export */ "w": () => (/* binding */ ConnectedDatabaseBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _TablesList__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6734); +/* harmony import */ var _general_ActiveCloneDbBanner__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4986); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def[]} props.tables + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def | null>>} props.setTargetTable + * @param {any} props.confirmedDelegetedUser + * @param {any} props.query + * @param {import("@/package-shared/types").UserType} [props.user] + */ function DatabasesTablesList({ database , tables , setTargetTable , confirmedDelegetedUser , query , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + database.active_clone && user ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_ActiveCloneDbBanner__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + database: database, + user: user + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(ConnectedDatabaseBanner, { + database: database + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper gray", + children: [ + tables && tables[0] ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-wrap gap-4 justify-between w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0", + children: "Tables" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables`, + className: "button outlined gray small-text", + children: "See All Tables" + }) + ] + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0", + children: "This Database is empty" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", {}), + user ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_TablesList__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + database: database, + tables: tables, + setTargetTable: setTargetTable, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + user: user + }) : null + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ## Connected Database Banner + * @param {object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + */ function ConnectedDatabaseBanner({ database }) { + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "info green", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text font-normal", + children: [ + "This database is an active clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: database.remote_db_full_name?.replace(/datasquirel_user_\d+_/, "") + }), + " ", + "on", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + className: "font-bold text-inherit", + href: database.remote_connection_host, + target: "_blank", + children: database.remote_connection_host + }), + " ", + "Host" + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 6734: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ TablesList) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: external "@mui/icons-material/BackupTableTwoTone" +var BackupTableTwoTone_ = __webpack_require__(1522); +var BackupTableTwoTone_default = /*#__PURE__*/__webpack_require__.n(BackupTableTwoTone_); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/admin/databases/TableListCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def} props.table + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def | null>>} props.setTargetTable + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} [props.confirmedDelegetedUser] + * @param {any} [props.query] + * @param {any} [props.icons] + * @param {import("@/package-shared/types").UserType} props.user + */ function TableListCard({ table , setTargetTable , database , confirmedDelegetedUser , query , icons , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Table/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.table_slug}`, + className: "card w-full items-center justify-between py-4" + (table?.child_table ? " green" : ""), + onClick: (e)=>{ + /** @type {HTMLAnchorElement} */ // @ts-ignore + const linkEl = e.target; + if (linkEl.closest(".db-list-item-actions-block")) { + e.preventDefault(); + } + }, + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap items-center flex", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((BackupTableTwoTone_default()), { + fontSize: "small", + className: "opacity-50", + color: "action" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "title", + style: { + fontSize: "16px" + }, + children: table.table_name + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm text-slate-400", + children: [ + "Created: ", + table.date_created?.substring(0, 21) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "db-list-item-actions-block flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.table_slug || "", + outlined: true + }), + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray small-text", + onClick: (e)=>{ + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.table_slug}/edit-table`; + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Edit" + }) + }) + }), + !active_clone_parent_db && !table.child_table && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray small-text", + onClick: (e)=>{ + window.location.href = `/admin/${user?.id}/databases/${database.db_slug}/tables/add-table?clone=true&clone_db=${database.db_slug}&clone_table=${table.table_slug}`; + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Clone" + }) + }), + (!isDelegated || isDelegated && isTableDeletable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined light-gray small-text", + onClick: (e)=>{ + setTargetTable(table); + (0,GeneralPopup/* openPopup */.Mw)("delete-table-confirmation"); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Delete" + }) + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronRight, { + className: "text-slate-600", + size: 20 + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/DriveFileRenameOutlineTwoTone" +var DriveFileRenameOutlineTwoTone_ = __webpack_require__(8193); +var DriveFileRenameOutlineTwoTone_default = /*#__PURE__*/__webpack_require__.n(DriveFileRenameOutlineTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/StorageTwoTone" +var StorageTwoTone_ = __webpack_require__(4063); +var StorageTwoTone_default = /*#__PURE__*/__webpack_require__.n(StorageTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DifferenceTwoTone" +var DifferenceTwoTone_ = __webpack_require__(930); +var DifferenceTwoTone_default = /*#__PURE__*/__webpack_require__.n(DifferenceTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/DeleteForeverTwoTone" +var DeleteForeverTwoTone_ = __webpack_require__(7039); +var DeleteForeverTwoTone_default = /*#__PURE__*/__webpack_require__.n(DeleteForeverTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/CopyAllTwoTone" +var CopyAllTwoTone_ = __webpack_require__(5050); +var CopyAllTwoTone_default = /*#__PURE__*/__webpack_require__.n(CopyAllTwoTone_); +// EXTERNAL MODULE: external "@mui/icons-material/TableViewTwoTone" +var TableViewTwoTone_ = __webpack_require__(3851); +var TableViewTwoTone_default = /*#__PURE__*/__webpack_require__.n(TableViewTwoTone_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./functions/frontend/inputFileToBase64.js +var inputFileToBase64 = __webpack_require__(3314); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/databases/ImportDbComponent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {Object} props.database + */ function ImportDbComponent({ database }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.LegacyRef<HTMLInputElement | undefined>} */ const fileRef = external_react_default().useRef(); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "file", + name: "sql-file-input", + id: "sql-file-input", + accept: ".sql", + className: "hidden", + // @ts-ignore + ref: fileRef + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex-col normal-weight outlined gray dashed w-full p-8 relative", + onClick: (e)=>{ + fileRef.current?.addEventListener("change", (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (!inputEl.files?.[0]) { + window.alert("No FIles selected"); + return; + } + (0,inputFileToBase64/* default */.Z)({ + inputFile: inputEl.files[0] + }).then((fileObject)=>{ + if (window.confirm(`Use this file '${fileObject.fileName}' as your import file?`)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/importDatabase", { + method: "post", + body: { + database: database, + fileBase64: fileObject.fileBase64 + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert("Import Failed!"); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + }); + }); + fileRef.current?.click(); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Do you have an SQL file already?" + }), + /*#__PURE__*/ jsx_runtime_.jsx((StorageTwoTone_default()), { + sx: { + fontSize: 80 + }, + className: "opacity-20" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Import Database" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/SummarizeTwoTone" +var SummarizeTwoTone_ = __webpack_require__(7428); +var SummarizeTwoTone_default = /*#__PURE__*/__webpack_require__.n(SummarizeTwoTone_); +;// CONCATENATED MODULE: ./components/admin/databases/ImportSchemaComponent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {Object} props.database + */ function ImportSchemaComponent({ database }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.LegacyRef<HTMLInputElement | undefined>} */ const fileRef = external_react_default().useRef(); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "file", + name: "json_file_input", + id: "json_file_input", + accept: ".json", + className: "hidden", + // @ts-ignore + ref: fileRef + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex-col normal-weight outlined gray dashed w-full p-8 relative", + onClick: (e)=>{ + fileRef.current?.addEventListener("change", (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (!inputEl.files?.[0]) { + window.alert("No FIles selected"); + return; + } + (0,inputFileToBase64/* default */.Z)({ + inputFile: inputEl.files[0] + }).then((fileObject)=>{ + if (window.confirm(`Use this file '${fileObject.fileName}' as your import file?`)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/importDatabaseSchema", { + method: "post", + body: { + database: database, + fileBase64: fileObject.fileBase64 + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert("Import Failed!"); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + }); + }); + fileRef.current?.click(); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Do you have a JSON schema?" + }), + /*#__PURE__*/ jsx_runtime_.jsx((SummarizeTwoTone_default()), { + sx: { + fontSize: 80 + }, + className: "opacity-20" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Import JSON schema" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/TablesList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def[]} props.tables + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def | null>>} props.setTargetTable + * @param {any} props.confirmedDelegetedUser + * @param {any} props.query + * @param {import("@/package-shared/types").UserType} props.user + */ function TablesList({ database , tables , setTargetTable , confirmedDelegetedUser , query , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Table/i); + const addTablePlaceholder = (()=>{ + if ((!tables || !tables[0]) && !isDelegated) return true; + if ((!tables || !tables[0]) && isDelegated && isTableCreatable) return true; + return false; + })(); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col", + children: [ + tables && tables[0] && tables.map((table)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(TableListCard, { + table: table, + setTargetTable: setTargetTable, + database: database, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + icons: { + edit: (DriveFileRenameOutlineTwoTone_default()), + duplicate: (DifferenceTwoTone_default()), + delete: (DeleteForeverTwoTone_default()), + copy: (CopyAllTwoTone_default()) + }, + user: user + }, table.id); + }), + addTablePlaceholder && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full grid grid-cols-1 xl:grid-cols-2 items-stretch gap-6", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/add-table`, + className: "button flex-col normal-weight outlined gray dashed border-dotted w-full p-8", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "No Tables Created." + }), + /*#__PURE__*/ jsx_runtime_.jsx((TableViewTwoTone_default()), { + sx: { + fontSize: 100 + }, + className: "opacity-20" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Add Table" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(ImportDbComponent, { + database: database + }), + /*#__PURE__*/ jsx_runtime_.jsx(ImportSchemaComponent, { + database: database + }) + ] + }) + }), + (!tables || !tables[0]) && isDelegated && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm bg-slate-100 px-3 py-2 rounded w-full flex items-center justify-center text-slate-400", + children: "Tables will show here once the owner of the database adds one" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8313.js b/dsql-app/.local_dist/server/chunks/8313.js new file mode 100644 index 0000000..6bc2707 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8313.js @@ -0,0 +1,175 @@ +"use strict"; +exports.id = 8313; +exports.ids = [8313]; +exports.modules = { + +/***/ 4981: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ThemeSelector) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + */ function ThemeSelector(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [theme, setTheme] = react__WEBPACK_IMPORTED_MODULE_1___default().useState("Light Mode"); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + let existingTheme = localStorage.getItem("theme"); + if (existingTheme?.match(/dark/)) { + setTheme("Dark Mode"); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "", + id: "theme-selector-wrapper", + onClick: ()=>{ + const graphicWrapper = document.getElementById("theme-selector-graphic-wrapper"); + let existingTheme = localStorage.getItem("theme"); + const sunIcon = graphicWrapper?.querySelector("img.sun"); + const moonIcon = graphicWrapper?.querySelector("img.moon"); + //////////////////////////////////////// + if (!existingTheme || existingTheme?.match(/light/)) { + document.documentElement.className = "dark"; + localStorage.setItem("theme", "dark"); + existingTheme = "dark"; + //////////////////////////////////////// + sunIcon?.classList.add("hidden"); + moonIcon?.classList.remove("hidden"); + // @ts-ignore + graphicWrapper?.firstChild?.classList.add("ml-auto"); + //////////////////////////////////////// + setTheme("Dark Mode"); + //////////////////////////////////////// + } else if (existingTheme?.match(/dark/)) { + document.documentElement.className = "light"; + localStorage.setItem("theme", "light"); + existingTheme = "light"; + //////////////////////////////////////// + moonIcon?.classList.add("hidden"); + sunIcon?.classList.remove("hidden"); + // @ts-ignore + graphicWrapper?.firstChild?.classList.remove("ml-auto"); + //////////////////////////////////////// + setTheme("Light Mode"); + //////////////////////////////////////// + } + //////////////////////////////////////// + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "p-1 rounded-full w-12 transition-all", + id: "theme-selector-graphic-wrapper", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "pointer-events-none transition-all dark:ml-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/sun.png", + alt: "Sun Icon", + width: 18, + className: "sun dark:hidden" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/new-moon.png", + alt: "Sun Icon", + width: 18, + className: "moon hidden dark:flex" + }) + ] + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9678: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ updateNavLinks) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * + * @param {object} param0 + * @param {HTMLAnchorElement[] | NodeListOf<HTMLAnchorElement>} [param0.links] + */ async function updateNavLinks({ links }) { + /** @type {NodeListOf<HTMLAnchorElement> | HTMLAnchorElement[]} */ let navLinks = links ? links : document.querySelectorAll("nav a"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (navLinks) { + navLinks.forEach((link)=>{ + if (link.dataset.currentlink === window.location.pathname) { + link.classList.add("active"); + } else if (window.location.pathname.match(new RegExp(`${link.dataset.currentlink}\\/.*`)) && !link.dataset.strictlink) { + link.classList.add("active"); + } + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const isDbPathValid = window.location.pathname.match(/\/databases\/.*/); + if (isDbPathValid) { + const links1 = document.querySelectorAll("a"); + if (links1 && window.location.search.match(/delegated=true/)) { + links1.forEach((link, index)=>{ + if (!link?.pathname?.match(/databases/)) return; + link.href = link.pathname + window.location.search; + }); + } + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8326.js b/dsql-app/.local_dist/server/chunks/8326.js new file mode 100644 index 0000000..49a8bda --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8326.js @@ -0,0 +1,90 @@ +"use strict"; +exports.id = 8326; +exports.ids = [8326]; +exports.modules = { + +/***/ 9046: +/***/ ((module) => { + +// @ts-check +/** + * Regular expression to match default fields + * + * @description Regular expression to match default fields + */ +const defaultFieldsRegexp = /^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = defaultFieldsRegexp; + + +/***/ }), + +/***/ 8326: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const decrypt = __webpack_require__(5425); +const defaultFieldsRegexp = __webpack_require__(9046); +/** + * Parse Database results + * ============================================================================== + * @description this function takes a database results array gotten from a DB handler + * function, decrypts encrypted fields, and returns an updated array with no encrypted + * fields + * + * @param {object} params - Single object params + * @param {any[]} params.unparsedResults - Array of data objects containing Fields(keys) + * and corresponding values of the fields(values) + * @param {import("../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @returns {Promise<object[]|null>} + */ module.exports = async function parseDbResults({ unparsedResults , tableSchema , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ let parsedResults = []; + try { + /** + * Declare variables + * + * @description Declare "results" variable + */ for(let pr = 0; pr < unparsedResults.length; pr++){ + let result = unparsedResults[pr]; + let resultFieldNames = Object.keys(result); + for(let i = 0; i < resultFieldNames.length; i++){ + const resultFieldName = resultFieldNames[i]; + let resultFieldSchema = tableSchema?.fields[i]; + if (resultFieldName?.match(defaultFieldsRegexp)) { + continue; + } + let value = result[resultFieldName]; + if (typeof value !== "number" && !value) { + continue; + } + if (resultFieldSchema?.encrypted) { + if (value?.match(/./)) { + result[resultFieldName] = decrypt(value); + } + } + } + parsedResults.push(result); + } + /** + * Declare variables + * + * @description Declare "results" variable + */ return parsedResults; + } catch (/** @type {any} */ error) { + console.log("ERROR in parseDbResults Function =>", error.message); + return unparsedResults; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8345.js b/dsql-app/.local_dist/server/chunks/8345.js new file mode 100644 index 0000000..1831a88 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8345.js @@ -0,0 +1,90 @@ +"use strict"; +exports.id = 8345; +exports.ids = [8345]; +exports.modules = { + +/***/ 3314: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ inputFileToBase64) +/* harmony export */ }); +// @ts-check +/** + * @typedef {{ + * fileBase64: string | null, + * fileBase64Full: string | null, + * fileName: string | null, + * fileSize: number | null, + * fileType: string | null, + * }} FunctionReturn + */ /** + * Upload a file + * ============================================================================== + * @async + * + * @param {{ + * inputFile: File, + * }} params - Single object passed + * + * @description This function takes in a *SINGLE* input file from a HTML file input element. + * HTML file input elements usually return an array of input objects, so be sure to select the target + * file from the array. + * + * @returns { Promise<FunctionReturn> } - Return Object + */ async function inputFileToBase64({ inputFile }) { + /** + * == Initialize + * + * @description Initialize + */ // const allowedTypesRegex = /image\/*|\/pdf/; + // if (!inputFile?.type?.match(allowedTypesRegex)) { + // window.alert(`We currently don't support ${inputFile.type} file types. Support is coming soon. For now we support only images and PDFs.`); + // return { + // fileBase64: null, + // fileBase64Full: null, + // fileName: inputFile.name, + // fileSize: null, + // fileType: null, + // }; + // } + try { + /** + * == Process File + */ let fileName = inputFile.name.replace(/\..*/, ""); + /** Add source to new file **/ const fileData = await new Promise((resolve, reject)=>{ + var reader = new FileReader(); + reader.readAsDataURL(inputFile); + reader.onload = function() { + resolve(reader.result); + }; + reader.onerror = function(/** @type {any} */ error) { + console.log("Error: ", error.message); + }; + }); + return { + fileBase64: fileData.replace(/.*?base64,/, ""), + fileBase64Full: fileData, + fileName: fileName, + fileSize: inputFile.size, + fileType: inputFile.type + }; + } catch (/** @type {any} */ error) { + console.log("Image Processing Error! =>", error.message); + return { + fileBase64: null, + fileBase64Full: null, + fileName: inputFile.name, + fileSize: null, + fileType: null + }; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8374.js b/dsql-app/.local_dist/server/chunks/8374.js new file mode 100644 index 0000000..12d2cd0 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8374.js @@ -0,0 +1,708 @@ +"use strict"; +exports.id = 8374; +exports.ids = [8374]; +exports.modules = { + +/***/ 8374: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ SocialLogin) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var frontend_fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/pages/login/GoogleIdentityButton.jsx +/** + * Imports + * ============================================================================== + */ /** ********************* React/Next Imports */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Props from getServerSideProps or getStaticProps + * @param {import("@/package-shared/types").UserType} props.user + * @param {string} [props.userType] + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setLoading + */ function GoogleIdentityButton({ user , userType , setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (user?.logged_in_status || user?.current?.logged_in_status) return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ external_react_default().useEffect(()=>{ + function handleCredentialResponse(response) { + window.activeGooglePrompt = false; + userLoginWithGoogle({ + gUser: null, + tokenRes: response.credential, + setLoading + }); + } + //////////////////////////////////////// + google.accounts.id.initialize({ + client_id: "392696781563-imb0ddojfn6m4bdokjk5v80jn546t9tq.apps.googleusercontent.com", + callback: handleCredentialResponse + }); + //////////////////////////////////////// + google.accounts.id.renderButton(document.getElementById("google-identity-button"), { + theme: "outline", + size: "large", + logo_alignment: "center" + }); + //////////////////////////////////////// + // if (user?.logged_in_status || document.cookie.match(/google_prompt_skipped=true/)) { + // google.accounts.id.cancel(); + // return; + // } + //////////////////////////////////////// + // window.activeGooglePrompt = true; + // google.accounts.id.prompt((notification) => { + // console.log("getMomentType => ", notification.getMomentType()); + // console.log("getDismissedReason => ", notification.getDismissedReason()); + // console.log("getNotDisplayedReason => ", notification.getNotDisplayedReason()); + // console.log("getSkippedReason => ", notification.getSkippedReason()); + // console.log("isDismissedMoment => ", notification.isDismissedMoment()); + // console.log("isDisplayMoment => ", notification.isDisplayMoment()); + // console.log("isDisplayed => ", notification.isDisplayed()); + // console.log("isNotDisplayed => ", notification.isNotDisplayed()); + // console.log("isSkippedMoment => ", notification.isSkippedMoment()); + // if (notification.isSkippedMoment()) { + // document.cookie = "google_prompt_skipped=true;max-age=" + 60000 * 60 * 24 * 5; + // window.activeGooglePrompt = false; + // } + // if (notification.isNotDisplayed()) { + // window.activeGooglePrompt = false; + // } + // }); // also display the One Tap dialog + }, []); + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex items-center justify-center h-[45px] overflow-hidden button outlined normal-weight small-text gray p-0", + style: { + padding: 0 + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "relative w-full h-full justify-center", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full h-full justify-center bg-white dark:bg-slate-800 relative z-10 pointer-events-none", + style: { + border: "none" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/google.png", + width: 18, + height: 18, + alt: "" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Login With Google" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + id: "google-identity-button", + className: "w-full absolute justify-center top-0 left-0", + style: { + transform: "scale(2)" + } + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ function userLoginWithGoogle({ gUser , tokenRes , setLoading }) { + setLoading(true); + if (!tokenRes) { + console.log("No Token Response received!"); + return closeLoader(); + } + (0,frontend_fetchApi/* default */.Z)(`/api/social-login/google-auth${window.location.search}`, { + method: "post", + body: { + token: tokenRes + } + }).then(async (res)=>{ + if (res.success && res.user) { + localStorage.setItem("csrf", res.user.csrf_k); + localStorage.setItem("user", JSON.stringify(res.user)); + window.location.reload(); + } else { + console.log(res); + setLoading(false); + if (res.alert) { + window.alert(res.msg); + } + } + }).catch(async (err)=>{ + alert("Login Failed"); + console.log("Google login fetch error => ", err); + setLoading(false); + }); +} + +// EXTERNAL MODULE: ./functions/frontend/clearCaches.js +var clearCaches = __webpack_require__(9137); +;// CONCATENATED MODULE: ./components/pages/login/GithubLogin.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Props from getServerSideProps or getStaticProps + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setLoading + */ function GithubLogin({ user , setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (user?.logged_in_status) return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ external_react_default().useEffect(()=>{ + const urlQuery = window.location.search; + const urlQueryParams = new URLSearchParams(urlQuery); + const codeParam = urlQueryParams.get("code"); + const emailParam = urlQueryParams.get("email"); + if (codeParam) { + setLoading(true); + (0,frontend_fetchApi/* default */.Z)(`/api/social-login/github-auth?code=${codeParam}${emailParam ? "&email=" + emailParam : ""}`).then((res)=>{ + if (!res?.success) { + if (res.msg?.match(/Github User Email not present/i)) { + const enterEmail = window.prompt(`Cannot access the email address of this github account. Please enter an email address to continue.`); + if (enterEmail && enterEmail?.match(/.*@.*\..*/) && !enterEmail?.match(/ /)) { + const newFetchUrl = `https://github.com/login/oauth/authorize?client_id=${"0729d312ff3108b79188"}&scope=user&redirect_uri=${"http://localhost:7070"}${window.location.pathname}?email=${enterEmail}`; + window.location.assign(newFetchUrl); + } + } + } + if (res?.msg && res?.alert) { + window.alert(res.msg); + } + if (res?.success && res?.user) { + localStorage.setItem("csrf", res.user.csrf_k); + localStorage.setItem("user", JSON.stringify(res.user)); + (0,clearCaches/* default */.Z)().then(()=>{ + window.location.reload(); + }); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }).catch((error)=>{ + console.log(error); + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + }, []); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex items-center justify-center", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray w-full more-padding small-text normal-weight gap-6", + onClick: (e)=>{ + setLoading(true); + const fetchUrl = `https://github.com/login/oauth/authorize?client_id=${"0729d312ff3108b79188"}&scope=user&redirect_uri=${"http://localhost:7070"}${window.location.pathname}`; + console.log(fetchUrl); + window.location.assign(fetchUrl); + // fetch(fetchUrl, { + // headers: { + // "Access-Control-Allow-Origin": "*", + // }, + // }) + // .then((res) => res.json()) + // .then((data) => { + // console.log(data); + // setTimeout(() => { + // setLoading(false); + // }, 1000); + // }) + // .catch((error) => { + // console.log(error); + // setTimeout(() => { + // setLoading(false); + // }, 1000); + // }); + setTimeout(()=>{ + setLoading(false); + }, 1000); + // fetchApi(fetchUrl).then((res) => { + // console.log(res); + // setTimeout(() => { + // setLoading(false); + // }, 1000); + // }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/github.png", + width: 18, + height: 18, + alt: "", + className: "flex dark:hidden" + }), + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/github-white.png", + width: 18, + height: 18, + alt: "", + className: "hidden dark:flex" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Login With Github" + }) + ] + }) + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/pages/login/FacebookSignInButton.jsx +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ********************* React/Next Imports */ + + +/** ~ End React/Next Imports *************** */ /** ********************* Functions and Other Page Imports */ // import clearCaches from "../functions/frontend/ "; +// import { closeLoader, openLoader } from "./PageLoaderBlock"; +/** ~ End Functions and Other Page Imports *************** */ /** ********************* Context Providers */ /** ~ End Context Providers *************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props object + * @param {function(): void} props.setLoading - Props from getServerSideProps or getStaticProps + */ function FacebookSignInButton({ setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ let [isSignedIn, setIsSignedIn] = React.useState(false); + let [refresh, setRefresh] = React.useState(0); + React.useEffect(()=>{ + // let reloads = localStorage.getItem("login_reloads"); + // if (reloads && parseInt(reloads) >= 1) return; + FB.init({ + appId: "2910275882608968", + cookie: true, + xfbml: true, + version: "v13.0" + }); + if (isSignedIn) return; + FB.getLoginStatus((response)=>{ + // console.log(response); + // if (!response.authResponse) { + // } else + if (response.status === "connected") { + // console.log("Facebook User Signed in"); + setIsSignedIn(true); + userLoginWithFacebook(response, setIsSignedIn, setLoading); + } else { + setIsSignedIn(false); + } + }); + }, [ + refresh + ]); + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ _jsx("div", { + className: "w-full", + children: /*#__PURE__*/ _jsxs("div", { + className: "w-full", + children: [ + !isSignedIn && /*#__PURE__*/ _jsxs("div", { + className: "button outlined gray w-full more-padding normal-weight small-text gap-6", + onClick: ()=>{ + if (setLoading) setLoading(true); + FB.login((res)=>{ + if (res.status === "connected") { + setIsSignedIn(true); + userLoginWithFacebook(res, setIsSignedIn, setLoading); + } else { + if (setLoading) setLoading(false); + } + setRefresh((prev)=>prev + 1); + }, { + auth_type: "rerequest", + scope: "email,public_profile", + return_scopes: true, + enable_profile_selector: true + }); + }, + children: [ + /*#__PURE__*/ _jsx("img", { + src: "/images/facebook.png", + width: 18, + height: 18, + alt: "" + }), + /*#__PURE__*/ _jsx("span", { + children: "Login With Facebook" + }) + ] + }), + isSignedIn && /*#__PURE__*/ _jsxs("div", { + className: "button outlined gray w-full pointer-events-none more-padding", + onClick: ()=>{ + if (setLoading) setLoading(true); + FB.logout((res)=>{ + // console.log(res); + setIsSignedIn(false); + if (setLoading) setLoading(false); + }); + }, + children: [ + /*#__PURE__*/ _jsx("img", { + src: "/images/facebook.png", + width: 20, + alt: "" + }), + /*#__PURE__*/ _jsx("span", { + children: "Sign Out of Facebook" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** + * Facebook Login Function + * ============================================================================== + * @param {object} fbUser - React component props object + * @param {object} fbUser.authResponse - React component props object + * @param {function(): void} signInDispatch - Set signin status + * @param {function(): void} setLoading - Set loading function + */ function userLoginWithFacebook(fbUser, signInDispatch, setLoading) { + console.log("LOGGING IN WITH FB ..."); + if (!fbUser.authResponse) { + if (setLoading) setLoading(false); + return; + } + FB.api("/me", { + fields: "first_name,last_name,email,name,picture" + }, async (response)=>{ + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ let existingSocialId = await fetchApi(`/api/social-login/utils/checkSocialId?social_id=${response.id}&social_platform=facebook`); + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ let finalEmail, supEmail; + if (!response.email) { + /** + * Get Email Function + * ============================================================================== + * + * @description get email from server + */ async function getEmail() { + if (existingSocialId.social_id) { + let existingEmailExistingUser = await fetchApi(`/api/social-login/utils/getEmailFromSocialId?social_id=${response.id}&social_platform=facebook`); + finalEmail = existingEmailExistingUser.email; + return existingEmailExistingUser.email; + } + let userEmail = window.prompt("You have no email linked with this account: please Enter an email address to continue"); + if (!userEmail) { + alert("Can't create account without an email address: please provide an email address for easy contact. Thanks."); + return false; + } + let isEmailValid = userEmail.match(/.*@.*\..*/); + if (!isEmailValid) { + alert("Email not valid: Please enter a valid email address"); + return await getEmail(); + } + let existingEmail = await fetchApi(`/api/social-login/utils/checkEmail?email=${userEmail}`); + if (existingEmail?.email) { + alert("Email already taken: please enter another email address"); + return await getEmail(); + } else { + supEmail = userEmail; + return userEmail; + } + } + let isEmailResolved = await getEmail(); + if (isEmailResolved) { + finalEmail = isEmailResolved; + } else { + finalEmail = null; + } + } else { + finalEmail = response.email; + } + //////////////////////////////////////// + if (!finalEmail) { + alert("No Email Provided, Please try again"); + if (setLoading) setLoading(false); + return; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let usernamEmail = (()=>{ + if (!response.email) { + return `facebook_${response.name.toLowerCase().replace(/ /g, "-")}`; + } else { + return `facebook_${response.email.replace(/@.*/, "")}`; + } + })(); + let fbUserImage = `https://graph.facebook.com/${response.id}/picture?type=large`; + let fbUserImageTiny = response.picture.data.url; + fetch(`/api/social-login/facebook-auth${window.location.search}`, { + method: "post", + headers: { + "Content-Type": "application/json" + }, + body: JSON.stringify({ + facebookUserId: response.id, + facebookUserImage: fbUserImage, + facebookUserFullName: response.name, + facebookUserFirstName: response.first_name, + facebookUserLastName: response.last_name, + facebookUserEmail: finalEmail, + supEmail: supEmail + }) + }).then((res)=>res.json()).then(async (data)=>{ + signInDispatch(true); + localStorage.setItem("user", JSON.stringify(data.user)); + localStorage.setItem("csrf", JSON.stringify(data.user.csrf_k)); + window.location.reload(); + }).catch(async (err)=>{ + console.log(err); + signInDispatch(true); + }); + }); +} + +;// CONCATENATED MODULE: ./components/pages/login/SocialLogin.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {any} props.user + * @param {string} props.userType + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setLoading + */ function SocialLogin({ user , userType , setLoading }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ if (true) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (user?.logged_in_status) return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [googleLogin, setGoogleLogin] = external_react_default().useState(false); + // const [facebookLogin, setFacebookLogin] = React.useState(false); + external_react_default().useEffect(()=>{ + if (!user?.logged_in_status) { + // if (window.location.protocol.match(/https/i)) { + // const facebookScript = document.createElement("script"); + // facebookScript.src = `https://connect.facebook.net/en_US/sdk.js#xfbml=1&version=v14.0&appId=${process.env.NEXT_PUBLIC_DSQL_FACEBOOK_ID}&autoLogAppEvents=1`; + // facebookScript.className = "social-script-tag"; + // facebookScript.crossOrigin = "anonymous"; + // document.body.appendChild(facebookScript); + // facebookScript.onload = function (e) { + // // console.log("Facebook SDK loaded"); + // setFacebookLogin(true); + // }; + // } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const googleScript = document.createElement("script"); + googleScript.src = "https://accounts.google.com/gsi/client"; + googleScript.className = "social-script-tag"; + document.body.appendChild(googleScript); + googleScript.onload = function(e) { + // @ts-ignore + if (google) setGoogleLogin(true); + }; + //////////////////////////////////////// + return function cleanup() { + document.querySelectorAll(".social-script-tag")?.forEach((scriptTag)=>{ + scriptTag.parentNode?.removeChild(scriptTag); + }); + }; + } + }, [ + user + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-stretch gap-3 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(GithubLogin, { + user: user, + setLoading: setLoading + }), + googleLogin && /*#__PURE__*/ jsx_runtime_.jsx(GoogleIdentityButton, { + user: user, + userType: userType, + setLoading: setLoading + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9137: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ clearCaches) +/* harmony export */ }); +// @ts-check +/** + * Clear Caches function + * ============================================================================== + */ async function clearCaches() { + try { + /** Initialize + * ============================================================================== + */ /** ********************* Variables */ const keys = await caches.keys(); + if (keys[0]) { + await Promise.all(keys.map((key)=>{ + return caches.delete(key); + })); + } + } catch (/** @type {any} */ error) { + console.log("Error in clearing cache =>", error.message); + } +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8499.js b/dsql-app/.local_dist/server/chunks/8499.js new file mode 100644 index 0000000..8f534f6 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8499.js @@ -0,0 +1,284 @@ +"use strict"; +exports.id = 8499; +exports.ids = [8499]; +exports.modules = { + +/***/ 8499: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +/** # MODULE TRACE +====================================================================== + * Detected 3 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [get.js] => file:///d:\GitHub\datasquirel\pages\api\query\get.js + * `import` Statement Found in [post.js] => file:///d:\GitHub\datasquirel\pages\api\query\post.js + * `import` Statement Found in [add-user.js] => file:///d:\GitHub\datasquirel\pages\api\user\add-user.js +==== MODULE TRACE END ==== */ // @ts-check + +const fs = __webpack_require__(7147); +const fullAccessDbHandler = __webpack_require__(8539); +const varReadOnlyDatabaseDbHandler = __webpack_require__(3118); +const serverError = __webpack_require__(3017); +const addDbEntry = __webpack_require__(5338); +const updateDbEntry = __webpack_require__(5886); +const deleteDbEntry = __webpack_require__(6147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Run DSQL users queries + * ============================================================================== + * @param {object} params - An object containing the function parameters. + * @param {string} params.dbFullName - Database full name. Eg. "datasquire_user_2_test" + * @param {string|any} params.query - Query string or object + * @param {boolean} [params.readOnly] - Is this operation read only? + * @param {import("../../../types").DSQL_DatabaseSchemaType} [params.dbSchema] - Database schema + * @param {string[]} [params.queryValuesArray] - An optional array of query values if "?" is used in the query string + * @param {string} [params.tableName] - Table Name + * + * @return {Promise<any>} + */ async function runQuery({ dbFullName , query , readOnly , dbSchema , queryValuesArray , tableName , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ /** @type {any} */ let result; + /** @type {any} */ let error; + /** @type {import("../../../types").DSQL_TableSchemaType | undefined} */ let tableSchema; + if (dbSchema) { + try { + const table = tableName ? tableName : typeof query == "string" ? null : query ? query?.table : null; + if (!table) throw new Error("No table name provided"); + tableSchema = dbSchema.tables.filter((tb)=>tb?.tableName === table)[0]; + } catch (_err) { + // console.log("ERROR getting tableSchema: ", _err.message); + } + } + /** + * Declare variables + * + * @description Declare "results" variable + */ try { + if (typeof query === "string") { + if (readOnly) { + result = await varReadOnlyDatabaseDbHandler({ + queryString: query, + queryValuesArray, + database: dbFullName, + tableSchema + }); + } else { + result = await fullAccessDbHandler({ + queryString: query, + queryValuesArray, + database: dbFullName, + tableSchema + }); + } + } else if (typeof query === "object") { + /** + * Declare variables + * + * @description Declare "results" variable + */ const { data , action , table: table1 , identifierColumnName , identifierValue , update , duplicateColumnName , duplicateColumnValue , } = query; + switch(action.toLowerCase()){ + case "insert": + result = await addDbEntry({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: table1, + data: data, + update, + duplicateColumnName, + duplicateColumnValue, + tableSchema + }); + if (!result?.insertId) { + error = new Error("Couldn't insert data"); + } + break; + case "update": + result = await updateDbEntry({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: table1, + data: data, + identifierColumnName, + identifierValue, + tableSchema + }); + break; + case "delete": + result = await deleteDbEntry({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: table1, + identifierColumnName, + identifierValue, + tableSchema + }); + break; + default: + result = null; + break; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + serverError({ + component: "functions/backend/runQuery", + message: error1.message + }); + result = null; + error1 = error1.message; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return { + result, + error + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +module.exports = runQuery; + + +/***/ }), + +/***/ 8539: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +const parseDbResults = __webpack_require__(8326); +const serverError = __webpack_require__(3017); +/** + * + * @param {object} param0 + * @param {string} param0.queryString + * @param {string} param0.database + * @param {import("../../types").DSQL_TableSchemaType | null} [param0.tableSchema] + * @param {string[]} [param0.queryValuesArray] + * @returns + */ module.exports = async function fullAccessDbHandler({ queryString , database , tableSchema , queryValuesArray , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + /** ********************* Run Query */ results = await DSQL_USER_DB_HANDLER({ + paradigm: "Full Access", + database, + queryString, + queryValues: queryValuesArray + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + serverError({ + component: "fullAccessDbHandler", + message: error.message + }); + /** + * Return error + */ return error.message; + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results && tableSchema) { + const unparsedResults = results; + const parsedResults = await parseDbResults({ + unparsedResults: unparsedResults, + tableSchema: tableSchema + }); + return parsedResults; + } else if (results) { + return results; + } else { + return null; + } +}; + + +/***/ }), + +/***/ 3118: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const serverError = __webpack_require__(3017); +const parseDbResults = __webpack_require__(8326); +const DSQL_USER_DB_HANDLER = __webpack_require__(3403); +/** + * + * @param {object} param0 + * @param {string} param0.queryString + * @param {string} param0.database + * @param {string[]} [param0.queryValuesArray] + * @param {import("../../types").DSQL_TableSchemaType} [param0.tableSchema] + * @returns + */ module.exports = async function varReadOnlyDatabaseDbHandler({ queryString , database , queryValuesArray , tableSchema , }) { + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + results = await DSQL_USER_DB_HANDLER({ + paradigm: "Read Only", + database, + queryString, + queryValues: queryValuesArray + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + serverError({ + component: "varReadOnlyDatabaseDbHandler", + message: error.message, + noMail: true + }); + /** + * Return error + */ return error.message; + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results) { + const unparsedResults = results; + const parsedResults = await parseDbResults({ + unparsedResults: unparsedResults, + tableSchema: tableSchema + }); + return parsedResults; + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8682.js b/dsql-app/.local_dist/server/chunks/8682.js new file mode 100644 index 0000000..e3793dc --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8682.js @@ -0,0 +1,109 @@ +"use strict"; +exports.id = 8682; +exports.ids = [8682]; +exports.modules = { + +/***/ 8682: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +let DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_READ_ONLY_USERNAME, + password: process.env.DSQL_DB_READ_ONLY_PASSWORD, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {"Full Access" | "FA" | "Read Only"} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ function DSQL_USER_DB_HANDLER({ paradigm , database , queryString , queryValues , }) { + try { + return new Promise((resolve, reject)=>{ + const fullAccess = paradigm?.match(/full.access|^fa$/i) ? true : false; + try { + if (fullAccess) { + DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_FULL_ACCESS_USERNAME, + password: process.env.DSQL_DB_FULL_ACCESS_PASSWORD, + database: database, + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } + }); + } else { + DSQL_USER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_READ_ONLY_USERNAME, + password: process.env.DSQL_DB_READ_ONLY_PASSWORD, + database: database, + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } + }); + } + /** + * ### Run query Function + * @param {any} results + */ function runQuery(results) { + DSQL_USER.end(); + resolve(JSON.parse(JSON.stringify(results))); + } + /** + * ### Query Error + * @param {any} err + */ function queryError(err) { + DSQL_USER.end(); + resolve({ + error: err.message, + queryStringGenerated: queryString, + queryValuesGenerated: queryValues, + sql: err.sql + }); + } + if (queryValues && Array.isArray(queryValues) && queryValues[0]) { + DSQL_USER.query(queryString, queryValues).then(runQuery).catch(queryError); + } else { + DSQL_USER.query(queryString).then(runQuery).catch(queryError); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + fs.appendFileSync("./.tmp/dbErrorLogs.txt", error.message + "\n" + Date() + "\n\n\n", "utf8"); + resolve({ + error: error.message + }); + } + }); + } catch (/** @type {any} */ error) { + return { + success: false, + error: error.message + }; + } +} +module.exports = DSQL_USER_DB_HANDLER; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/8999.js b/dsql-app/.local_dist/server/chunks/8999.js new file mode 100644 index 0000000..8468b33 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/8999.js @@ -0,0 +1,85 @@ +"use strict"; +exports.id = 8999; +exports.ids = [8999]; +exports.modules = { + +/***/ 8999: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const DB_HANDLER = __webpack_require__(2224); +const serverError = __webpack_require__(2163); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @async + * + * @param {{ + * user: {id:number}, + * confirmedDelegetedUser: any, + * database: string, + * table: string, + * priviledgeRegex: RegExp, + * dbId: number, + * }} params - parameters + * + * @returns {Promise<boolean>} does user have the rights for this operation? true if yes, false if no + */ module.exports = async function checkUserRights({ user , confirmedDelegetedUser , database , table , priviledgeRegex , dbId , }) { + /** + * Fetch user + * + * @description Fetch user from db + */ let userConfirmation, priviledge; + try { + if (confirmedDelegetedUser?.delegated) { + userConfirmation = await DB_HANDLER(`SELECT priviledge FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=? AND \`database\`=? AND \`table\`=?`, [ + confirmedDelegetedUser.rootUserId, + user.id, + database, + table + ]); + priviledge = userConfirmation[0]?.priviledge?.match(priviledgeRegex); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else { + userConfirmation = await DB_HANDLER(`SELECT table_slug FROM user_database_tables WHERE user_id=? AND table_slug=? AND db_id=?`, [ + user.id, + table, + dbId + ]); + priviledge = true; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } + } catch (/** @type {any} */ error) { + serverError({ + component: "checkUserRights", + message: error.message, + user: user + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (userConfirmation && userConfirmation[0] && priviledge) { + return true; + } else { + return false; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9035.js b/dsql-app/.local_dist/server/chunks/9035.js new file mode 100644 index 0000000..75e9827 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9035.js @@ -0,0 +1,2217 @@ +"use strict"; +exports.id = 9035; +exports.ids = [9035,2348]; +exports.modules = { + +/***/ 2943: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ ImportExportEntries) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/inputFileToBase64.js +var inputFileToBase64 = __webpack_require__(3314); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/admin/databases/functions/import-export-handler.js +// @ts-check + + +/** + * Import ot Export Table Data + * ============================================================================== + * @param {Object} param0 + * @param {"import" | "export"} param0.paradigm + * @param {any} [param0.payload] + * @param {any} param0.setLoading + * @param {DSQL_TableSchemaType} param0.table + * @param {DSQL_MYSQL_user_databases_Type} param0.database + */ function importExportHandler({ paradigm , payload , setLoading , table , database , }) { + setLoading(true); + if (paradigm === "import") {} + (0,fetchApi/* default */.Z)("/api/exportTableData", { + method: "POST", + body: { + paradigm, + dbName: database.db_slug, + tableName: table.tableName, + payload: payload + } + }, true).then((res)=>{ + if (res.success) { + if (paradigm == "export") { + const data = res.data; + const jsonString = JSON.stringify(data || [], null, 4); + const blob = new Blob([ + jsonString + ], { + type: "application/json" + }); + const url = URL.createObjectURL(blob); + const a = document.createElement("a"); + a.href = url; + a.style.display = "none"; + a.download = `${database.db_slug}-${table.tableName}-${Date.now()}.json`; + document.body.appendChild(a); + a.click(); + document.body.removeChild(a); + } else if (paradigm == "import") { + window.alert("Data Imported Successfully"); + window.location.reload(); + } + } else if (res.msg) { + window.alert(res.msg); + } + }).catch((error)=>{ + console.log(error); + }).finally(()=>{ + setLoading(false); + }); +} + +;// CONCATENATED MODULE: ./components/admin/databases/ImportExportEntries.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # Import Export Entries + * =================================================== + * @param {object} props + * @param {DSQL_MYSQL_user_databases_Type} props.database + * @param {DSQL_TableSchemaType} props.table + * @returns + */ function ImportExportEntries({ database , table }) { + const [loading, setLoading] = external_react_default().useState(false); + const [inputReady, setInputReady] = external_react_default().useState(true); + /** @type {React.RefObject<HTMLInputElement>} */ const fileRef = external_react_default().useRef(null); + /** @type {React.RefObject<HTMLFormElement>} */ const formRef = external_react_default().useRef(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + function resetForm() { + setInputReady(false); + setTimeout(()=>{ + setInputReady(true); + }, 200); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "relative", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "15px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray", + onClick: (e)=>{ + importExportHandler({ + paradigm: "export", + database, + setLoading, + table + }); + }, + children: "Export" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray", + onClick: (e)=>{ + fileRef.current?.addEventListener("change", (e)=>{ + setLoading(true); + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (!inputEl.files?.[0]) { + window.alert("No FIles selected"); + setLoading(false); + return; + } + (0,inputFileToBase64/* default */.Z)({ + inputFile: inputEl.files[0] + }).then((fileObject)=>{ + if (window.confirm(`Use this file '${fileObject.fileName}' as your import file?`)) { + importExportHandler({ + paradigm: "import", + payload: fileObject.fileBase64, + database, + setLoading, + table + }); + resetForm(); + } else { + setLoading(false); + resetForm(); + } + }); + }); + fileRef.current?.click(); + }, + children: "Import" + }), + inputReady && /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "file", + name: "json_file_input", + id: "json_file_input", + accept: ".json", + className: "hidden", + ref: fileRef + }) + ] + }); +} + + +/***/ }), + +/***/ 3684: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ MoreTableOptions) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var react_tiny_popover__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7076); +/* harmony import */ var react_tiny_popover__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_tiny_popover__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _SyncDataButton__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(436); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # Import Export Entries + * =================================================== + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + * @returns + */ function MoreTableOptions({ database , table , dbSchemaData , query , }) { + const [open, setOpen] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_tiny_popover__WEBPACK_IMPORTED_MODULE_2__.Popover, { + isOpen: open, + onClickOutside: ()=>setOpen(false), + positions: [ + "bottom" + ], + align: "end", + content: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "stack items-stretch bg-white rounded shadow-md gap-0 min-w-[200px]", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_SyncDataButton__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + database, + table, + setOpenPopover: setOpen, + dbSchemaData, + query + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "m-0" + }) + ] + }), + containerClassName: "z-[1000]", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: ()=>{ + setOpen(!open); + }, + className: "outlined gray px-2 py-1.5", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_3__.Ellipsis, {}) + }) + }); +} + + +/***/ }), + +/***/ 436: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ SyncDataButton) +}); + +// UNUSED EXPORTS: SyncDataModalContent + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: ./components/form/FormRadios.jsx +var FormRadios = __webpack_require__(2348); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/general/Modal.jsx +var Modal = __webpack_require__(9471); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./functions/frontend/syncTableDataFormHandler.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {React.FormEvent<HTMLFormElement>} params.e + * @param {React.Dispatch<React.SetStateAction<boolean>>} params.setLoading + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} params.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} params.table + * @param {any} params.query + * + * @requires search-field name attribute + */ function syncTableDataFormHandler({ e , setLoading , database , table , query , }) { + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + const paradigm = formEl["paradigm"]?.value; + const dstDbName = formEl["database"]?.value; + const dstTableName = formEl["table"]?.value; + /** @type {import("@/pages/api/sync-table-data").SyncTableBody} */ const fetchObject = { + paradigm: paradigm, + src: { + db: database.db_slug, + table: table.tableName + }, + dst: { + db: dstDbName, + table: dstTableName + }, + delegated: query.delegated + }; + const alertMsg = paradigm == "Pull" ? "NOTE: This operation will override the current database entries. Continue?" : "NOTE: This operation will override the selected database entries. Continue?"; + if (!window.confirm(alertMsg)) { + setTimeout(()=>{ + setLoading(false); + }, 1000); + return; + } + (0,fetchApi/* default */.Z)("/api/sync-table-data", { + method: "POST", + body: { + ...fetchObject + } + }, true).then((res)=>{ + if (res.success) { + window.alert("Data Sync Successful"); + window.location.reload(); + } else { + if (res.msg) window.alert("ERROR: " + res.msg); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +;// CONCATENATED MODULE: ./components/admin/databases/SyncDataButton.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {React.Dispatch<React.SetStateAction<boolean>>} [props.setOpenPopover] + * @param {any} props.query + */ function SyncDataButton({ database , table , setOpenPopover , dbSchemaData , query , }) { + const [open, setOpen] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ghost p-3 justify-start", + onClick: ()=>{ + setOpen(true); + setTimeout(()=>{ + if (setOpenPopover) setOpenPopover(false); + }, 200); + }, + children: "Sync Data" + }), + /*#__PURE__*/ jsx_runtime_.jsx(Modal/* default */.Z, { + open: open, + setOpen: setOpen, + children: /*#__PURE__*/ jsx_runtime_.jsx(SyncDataModalContent, { + database, + table, + dbSchemaData, + query + }) + }) + ] + }); +} +/** + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + */ function SyncDataModalContent({ database , table , query , dbSchemaData: initialSchema , }) { + /** @type {[ state: import("@/package-shared/types").DSQL_DatabaseSchemaType[], dispatch: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_DatabaseSchemaType[]>> ]} */ // @ts-ignore + const [dbSchemaData, setDbSchemaData] = external_react_default().useState(initialSchema); + const [paradigm, setParadigm] = external_react_default().useState("Push"); + const [targetDb, setTargetDb] = external_react_default().useState(dbSchemaData?.[0]); + const [tables, setTables] = external_react_default().useState(targetDb?.tables); + const [targetTable, setTargetTable] = external_react_default().useState(tables?.[0]); + const [loading, setLoading] = external_react_default().useState(false); + const [isCompatible, setIsCompatible] = external_react_default().useState(false); + external_react_default().useEffect(()=>{ + const isEqual = external_lodash_default().isEqual(table?.fields, targetTable?.fields); + if (isEqual) { + setIsCompatible(true); + } else { + setIsCompatible(false); + } + }, [ + targetTable, + setTargetDb + ]); + external_react_default().useEffect(()=>{ + if (query.delegated) { + (0,fetchApi/* default */.Z)("/api/get-authorized-databases").then((res)=>{ + if (res.success && res.payload) { + setDbSchemaData(res.payload); + } + }); + } + }, []); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "stack gap-2 relative w-full", + children: [ + loading || !dbSchemaData && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg", + children: "Sync Data with another table" + }), + !isCompatible ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "info warning inline", + children: [ + "The selected table is not compatible with", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: table.tableFullName + }) + ] + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "info green inline", + children: [ + "The selected table matches ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: table.tableFullName + }), + " ", + "schema" + ] + }), + dbSchemaData && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + syncTableDataFormHandler({ + e, + database, + setLoading, + table, + query + }); + }, + className: "w-full stack gap-2 items-stretch", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "stack gap-2 my-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormRadios/* default */.Z, { + radioValues: [ + { + title: "Push", + payload: "Push", + default: true + }, + { + title: "Pull", + payload: "Pull" + }, + ], + name: "paradigm", + smallText: true, + flexRow: true, + onChangeHandler: (e)=>{ + setParadigm(e.target.value); + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs text-slate-500 dark:text-slate-400", + children: paradigm == "Push" ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + "Sync data from the current table(", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: table.tableFullName + }), + ") to the selected table below" + ] + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + "Sync data from the selected table below to the current table(", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: table.tableFullName + }), + ")" + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: dbSchemaData.filter((dbObj)=>dbObj.dbFullName !== database.db_full_name).map((dbObj)=>({ + title: dbObj.dbName, + payload: dbObj.dbSlug + })), + name: "database", + onChangeHandler: (e)=>{ + const targetDatabase = dbSchemaData.find((db)=>db.dbSlug == e.target.value); + if (targetDatabase) { + setTargetDb(targetDatabase); + setTables(targetDatabase.tables); + setTargetTable(targetDatabase.tables?.[0]); + } + } + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: tables.map((tbl)=>({ + title: tbl.tableFullName, + payload: tbl.tableName + })), + name: "table", + onChangeHandler: (e)=>{ + const findTable = tables.find((tb)=>tb.tableName === e.target.value); + if (findTable) setTargetTable(findTable); + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: isCompatible ? "" : "disabled", + children: "Sync" + }) + ] + }) + ] + }); +} + + +/***/ }), + +/***/ 6122: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ TableEntriesList) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./components/admin/databases/UpdateEntryForm.jsx + 1 modules +var UpdateEntryForm = __webpack_require__(1985); +// EXTERNAL MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/index.jsx + 1 modules +var _single_table_entries = __webpack_require__(7722); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./components/form/FormInput.jsx + 2 modules +var FormInput = __webpack_require__(7901); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/databases/SearchEntriesSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** @type {any} */ let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} [props.data] + */ function SearchEntriesSection({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { table , entries , activeEntries , setActiveEntries , confirmedDelegetedUser , database , targetField , searchTerm , } = external_react_default().useContext(_single_table_entries.TableEntriesContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const dataTypes = __webpack_require__(9594); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {React.MutableRefObject<HTMLElement | undefined>} */ const searchInputRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + if (searchInputRef.current) searchInputRef.current.focus(); + }, []); + const [count, setCount] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + function search(/** @type {string} */ term) { + setLoading(true); + if (activeEntries) setActiveEntries(null); + if (!term?.toString().match(/./)) { + setTimeout(()=>{ + if (setActiveEntries) setActiveEntries(entries || []); + setLoading(false); + }, 500); + return; + } + window.clearTimeout(timeout); + const targetFieldObject = table?.fields.filter((fld)=>fld.fieldName === targetField?.current); + const operator = (()=>{ + if (targetFieldObject && targetFieldObject[0]) { + if (targetFieldObject[0].dataType?.match(/int/i)) return "equal"; + } + if (targetField?.current?.match(/^id$/)) return "equal"; + return "like"; + })(); + timeout = setTimeout(()=>{ + setLoading(false); + (0,fetchApi/* default */.Z)(`/api/queryEntriesSearchTerm?db=${database?.db_full_name}&table=${table?.tableName}&field=${targetField?.current}&term=${term}&operator=${operator}`).then((res)=>{ + if (typeof res.count == "number") { + setCount(res.count); + } + if (res.success && setActiveEntries) { + setActiveEntries(res.result); + } + setLoading(false); + }); + }, 500); + } + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col items-stretch", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + if (searchTerm?.current) search(searchTerm.current); + }, + className: "flex flex-row items-stretch gap-4 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "max-w-xs", + children: /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + required: true, + selectOptions: table ? table.fields.map((fieldObject)=>{ + return { + title: fieldObject.fieldName || "", + payload: fieldObject.fieldName || "" + }; + }) : [], + name: "database_tables", + onChangeHandler: (e)=>{ + if (targetField) targetField.current = e.target.value; + // setTimeout(() => { + // search(searchTerm); + // }, 500); + }, + title: "Select Field", + defaultValue: targetField?.current, + id: "entries-search-field-select" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "grow", + children: /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + title: "Search Term", + placeholder: "Enter search term that corresponds with the selected field type ...", + onInputHandler: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value?.match(/./) && searchTerm) { + searchTerm.current = inputEl.value; + } else if (searchTerm) { + searchTerm.current = null; + } + search(inputEl.value); + }, + elementRef: searchInputRef, + id: "entries-search-input" + }) + }), + loading && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "relative items-center justify-center", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "relative mt-5 w-6", + children: /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }) + }) + }) + ] + }), + searchTerm?.current?.match(/./) && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "py-4", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-lg", + children: [ + typeof count == "number" ? count > 0 ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("b", { + children: [ + count, + " " + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, { + children: "No " + }) : "... ", + "Search result", + !count || count === 1 ? "" : "s", + " for", + " ", + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("b", { + children: [ + '"', + searchTerm.current, + '"' + ] + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "@mui/icons-material/LibraryAddTwoTone" +var LibraryAddTwoTone_ = __webpack_require__(9438); +var LibraryAddTwoTone_default = /*#__PURE__*/__webpack_require__.n(LibraryAddTwoTone_); +// EXTERNAL MODULE: ./components/admin/databases/ImportExportEntries.jsx + 1 modules +var ImportExportEntries = __webpack_require__(2943); +// EXTERNAL MODULE: ./components/admin/databases/MoreTableOptions.jsx +var MoreTableOptions = __webpack_require__(3684); +// EXTERNAL MODULE: ./components/admin/databases/SyncDataButton.jsx + 1 modules +var SyncDataButton = __webpack_require__(436); +;// CONCATENATED MODULE: ./components/admin/databases/TableEntriesList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any[] | null} props.entries + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {React.Dispatch<React.SetStateAction<any>>} [props.setTargetEntry] + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} props.richTextEditors + * @param {React.MutableRefObject<import("@/package-shared/types").JSONTextEditorsRefArray[]>} props.jsonTextEditors + * @param {any[]} props.dataTypes + * @param {string} [props.title] + * @param {any} [props.confirmedDelegetedUser] + * @param {any} [props.query] + * @param {any} [props.search] + * @param {number} [props.entriesCount] + */ function TableEntriesList({ user , entries , database , table , setTargetEntry , dbSchemaData , richTextEditors , jsonTextEditors , dataTypes , title , confirmedDelegetedUser , query , search , entriesCount , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper gray gray-bg", + children: [ + title && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "justify-between w-full flex-wrap px-4 sm:px-0 pt-4 sm:pt-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: title + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + className: "button flex gap-2 items-center", + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Entry" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(ImportExportEntries/* default */.Z, { + database, + table + }), + /*#__PURE__*/ jsx_runtime_.jsx(MoreTableOptions/* default */.Z, { + database, + table, + dbSchemaData, + query + }) + ] + }) + ] + }), + search && /*#__PURE__*/ jsx_runtime_.jsx(SearchEntriesSection, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col gap-6", + children: [ + entries?.[0] && entries.map((entry)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(UpdateEntryForm/* default */.Z, { + user: user, + database: database, + table: table, + dbSchemaData: dbSchemaData, + richTextEditors: richTextEditors, + dataTypes: dataTypes, + entry: entry, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors + }) + }, entry.id); + }), + !entries && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full h-[300px]", + children: /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative" + }) + }), + entries && !entries?.[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + className: "border-dotted border-slate-200 border-2 p-4 w-full flex-col rounded flex items-center hover:border-primary/50 gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400 text-center", + children: "No Entries Added Yet." + }), + /*#__PURE__*/ jsx_runtime_.jsx((LibraryAddTwoTone_default()), { + className: "opacity-20 my-4", + sx: { + fontSize: 80 + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-center", + children: "Add an Entry to this Table" + }) + ] + }), + entriesCount && entriesCount > 10 ? /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries`, + className: "button outlined gray w-full -mb-4", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "See All Entries" + }) + }) : null, + entries?.[0] && title && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + className: "button flex gap-2 items-center w-full justify-center mt-2 more-padding", + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + style: { + borderStyle: "dotted", + borderWidth: "2px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Entry" + }) + ] + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 1985: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ UpdateEntryForm) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/frontend/defaultFieldsRegexp.js +var defaultFieldsRegexp = __webpack_require__(3907); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./functions/frontend/updateDiskUsage.js +var updateDiskUsage = __webpack_require__(1069); +// EXTERNAL MODULE: ./components/general/ExpandBlock.jsx +var ExpandBlock = __webpack_require__(6169); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/databases/TableEntryField.jsx + 11 modules +var TableEntryField = __webpack_require__(4559); +// EXTERNAL MODULE: external "@mui/material" +var material_ = __webpack_require__(5692); +// EXTERNAL MODULE: external "@mui/icons-material/MoreHoriz" +var MoreHoriz_ = __webpack_require__(5453); +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +// EXTERNAL MODULE: ./components/admin/databases/functions/generateTypeDefinition.js +var generateTypeDefinition = __webpack_require__(5753); +// EXTERNAL MODULE: external "react-tiny-popover" +var external_react_tiny_popover_ = __webpack_require__(7076); +;// CONCATENATED MODULE: ./components/admin/databases/UpdateEntryMoreOptions.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {any} [props.entry] + * @param {string} [props.url] + * @param {any} [props.query] + */ function UpdateEntryMoreOptions({ user , table , entry , url , query , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [openMore, setOpenMore] = external_react_default().useState(false); + const openMoreButtonRef = external_react_default().useRef(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "relative z-[1000]", + children: /*#__PURE__*/ jsx_runtime_.jsx(external_react_tiny_popover_.Popover, { + isOpen: openMore, + onClickOutside: ()=>setOpenMore(false), + containerClassName: "z-[1000]", + positions: [ + "bottom" + ], + align: "end", + content: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "bg-white dark:bg-slate-900 rounded shadow-md cancel-link", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col min-w-[200px] items-stretch gap-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "plain-text justify-start py-3", + onClick: ()=>{ + navigator.clipboard.writeText(JSON.stringify(entry)).then(()=>{ + window.alert("Post Copied"); + setOpenMore(false); + }); + }, + children: "Copy Object" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "plain-text justify-start py-3", + onClick: ()=>{ + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "JavaScript", + table, + query, + user + }); + navigator.clipboard.writeText(txt || "").then(()=>{ + window.alert("JavaScript Type Definition Copied"); + setOpenMore(false); + }); + }, + children: "Copy JS Type Definition" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "plain-text justify-start py-3", + onClick: ()=>{ + const txt = (0,generateTypeDefinition/* default */.Z)({ + paradigm: "TypeScript", + table, + query, + user + }); + navigator.clipboard.writeText(txt || "").then(()=>{ + window.alert("TypeScript Type Definition Copied"); + setOpenMore(false); + }); + }, + children: "Copy TS Type Definition" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "m-0" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: url, + className: "button plain-text justify-start py-3", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "View Entry" + }) + }) + ] + }) + }), + children: /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: ()=>{ + setOpenMore(!openMore); + }, + ref: openMoreButtonRef, + className: "ghost p-2", + children: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.Ellipsis, {}) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/UpdateEntryForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} [props.dbSchemaData] + * @param {React.MutableRefObject<any[]>} props.richTextEditors + * @param {React.MutableRefObject<any[]>} props.jsonTextEditors + * @param {any[]} props.dataTypes + * @param {any} [props.entry] + * @param {boolean} [props.entryPage] + * @param {any} [props.confirmedDelegetedUser] + * @param {any} [props.query] + */ function UpdateEntryForm({ user , database , table , dbSchemaData , richTextEditors , jsonTextEditors , dataTypes , entry , entryPage , confirmedDelegetedUser , query , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const filteredFields = table.fields.filter((field)=>field.fieldName && !field.fieldName.match(defaultFieldsRegexp/* default */.Z)); + const isUUID = table.fields.find((field)=>field.fieldName === "uuid"); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + //////////////////////////////////////// + if (isUUID) { + filteredFields.unshift({ + dataType: "UUID", + fieldName: "uuid", + defaultField: true + }); + } + filteredFields.unshift({ + dataType: "BIGINT", + fieldName: "id", + defaultField: true + }); + filteredFields.push({ + dataType: "VARCHAR(250)", + fieldName: "date_created", + defaultField: true + }); + filteredFields.push({ + dataType: "BIGINT", + fieldName: "date_created_code", + defaultField: true + }); + filteredFields.push({ + dataType: "TIMESTAMP", + fieldName: "date_created_timestamp", + defaultField: true + }); + filteredFields.push({ + dataType: "VARCHAR(250)", + fieldName: "date_updated", + defaultField: true + }); + filteredFields.push({ + dataType: "BIGINT", + fieldName: "date_updated_code", + defaultField: true + }); + filteredFields.push({ + dataType: "TIMESTAMP", + fieldName: "date_updated_timestamp", + defaultField: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [collapse, setCollapse] = external_react_default().useState(true); + const [activeEntry, setActiveEntry] = external_react_default().useState(entry); + const [openMore, setOpenMore] = external_react_default().useState(false); + const openMoreButtonRef = external_react_default().useRef(null); + /** @type {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} */ const currentRichTextEditorForms = external_react_default().useRef([]); + const [url, setUrl] = external_react_default().useState(`/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${activeEntry.id}`); + external_react_default().useEffect(()=>{ + if (confirmedDelegetedUser?.dbUserId && Number(user.id) !== Number(confirmedDelegetedUser.dbUserId)) { + setUrl(`/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${activeEntry.id}` + window.location.search); + } + }, []); + const formButtonId = `${database.db_slug}-${table.tableName}-${activeEntry.id}-submit-button`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card col w-full overflow-hidden", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: url, + onClick: (e)=>{ + /** @type {HTMLElement} */ // @ts-ignore + const targetEl = e.target; + if (targetEl.closest(".cancel-link") || targetEl.closest(".MuiPopover-root")) { + e.preventDefault(); + } + }, + className: "w-full", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full bg-slate-700 text-white py-2 px-4 rounded justify-between flex-wrap hover:bg-slate-800 cursor-pointer relative z-[1000] ", + onClick: (e)=>{ + /** @type {HTMLDivElement} */ // @ts-ignore + const divEl = e.target; + if (divEl.closest(".cancel-link") || divEl.closest(".MuiPopover-root")) return; + if (e.ctrlKey) { + window.open(url, "__blank"); + } else { + window.location.href = url; + } + }, + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + "Entry #", + activeEntry.id + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap cancel-link", + children: [ + (!isDelegated || isDelegated && areEntriesDeletable) && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300 hover:text-fuchsia-200 cursor-pointer" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + if (window.confirm(`Delete Entry #${activeEntry.id}?`)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/deleteTableEntry" + window.location.search, { + method: "post", + body: { + dbFullName: database.db_full_name, + tableName: table.tableName, + entryId: activeEntry.id, + dbSlug: database.db_slug, + dbId: database.id, + delegated: query?.delegated, + confirmedDelegetedUser + } + }, true).then((res)=>{ + if (res.success) { + (0,updateDiskUsage/* default */.Z)().then(()=>{ + window.location.reload(); + }); + } else { + window.alert(res.msg); + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); + } + }, + children: "Delete Entry" + }), + !entryPage && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-20", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300 hover:text-fuchsia-200 cursor-pointer", + onClick: (e)=>{ + if (collapse) { + setCollapse(false); + } else { + setCollapse(true); + } + }, + children: collapse ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Expand" + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Collapse" + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-20", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button ghost px-0", + onClick: (e)=>{ + let duplicateEntry = external_lodash_default().cloneDeep(entry); + delete duplicateEntry["date_created"]; + delete duplicateEntry["date_created_code"]; + delete duplicateEntry["date_created_timestamp"]; + delete duplicateEntry["date_updated"]; + delete duplicateEntry["date_updated_code"]; + delete duplicateEntry["date_updated_timestamp"]; + delete duplicateEntry["id"]; + delete duplicateEntry["uuid"]; + localStorage.setItem("duplicate_entry", JSON.stringify(duplicateEntry)); + window.location.href = `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry?duplicate=true&id=${entry.id}`; + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-300", + children: "Duplicate" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "opacity-20", + children: "|" + }), + /*#__PURE__*/ jsx_runtime_.jsx(UpdateEntryMoreOptions, { + table, + user, + entry, + query, + url + }) + ] + }) + ] + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-stretch gap-8 minimal-scrollbars relative", + style: !entryPage ? { + maxHeight: collapse ? "300px" : "none", + paddingTop: "10px", + paddingBottom: "10px", + overflow: "hidden" + } : {}, + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {any} */ let payload = {}; + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + filteredFields.forEach((field)=>{ + if (!field.fieldName) return; + if (!formEl[field.fieldName]) return; + const isString = typeof formEl[field.fieldName].value !== "string"; + const isNumber = typeof formEl[field.fieldName].value !== "number"; + if (!isString && !isNumber && !formEl[field.fieldName].value) return; + if (formEl[field.fieldName]?.dataset.default) return; + payload[field.fieldName] = formEl[field.fieldName].value; + }); + if (currentRichTextEditorForms.current[0]) { + currentRichTextEditorForms.current.forEach((/** @type {any} */ richTextObject)=>{ + if (!richTextObject?.fieldName || !richTextObject?.ref?.current) return; + payload[richTextObject.fieldName] = richTextObject.ref.current.getContent(); + }); + } + if (jsonTextEditors.current[0]) { + jsonTextEditors.current.forEach((jsonEditor)=>{ + if (!jsonEditor?.fieldName || !jsonEditor?.ref?.current) return; + payload[jsonEditor.fieldName] = jsonEditor.ref.current.getValue(); + }); + } + (0,fetchApi/* default */.Z)("/api/updateTableEntry", { + method: "post", + body: { + dbFullName: database.db_full_name, + dbSlug: database.db_slug, + dbId: database.id, + tableName: table.tableName, + entryId: activeEntry.id, + payload: payload, + tableSchema: table, + delegated: query?.delegated, + confirmedDelegetedUser + } + }, true).then((res)=>{ + if (res.success) { + (0,fetchApi/* default */.Z)(`/api/refreshEntry?table=${table.tableName}&db=${database.db_full_name}&id=${activeEntry.id}&schema=${JSON.stringify(table)}`).then((_res)=>{ + if (_res.success) { + setActiveEntry(_res.entry); + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); + } else { + window.alert(res.msg + "\n" + (res.err || "")); + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); + }, + onKeyUp: (e)=>{ + if (e.ctrlKey && e.key == "Enter") { + const confirm = window.confirm("Update this Form?"); + if (!confirm) return; + document.getElementById(formButtonId)?.click(); + } + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + (collapse && !entryPage ? filteredFields.slice(0, 3) : filteredFields).map((field, index)=>{ + let dataTypeSchema = dataTypes.filter((type)=>type.name === field.dataType?.replace(/\d|\(|\)/g, "")); + return /*#__PURE__*/ jsx_runtime_.jsx(TableEntryField/* default */.Z, { + fieldObject: field, + dataTypeSchema: dataTypeSchema[0], + richTextEditors: richTextEditors, + currentRichTextEditorForms: currentRichTextEditorForms, + entry: activeEntry, + query: query, + entryPage: entryPage, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors, + formButtonId: formButtonId + }, index + 1); + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "" + (loading ? " pointer-events-none opacity-40" : ""), + id: formButtonId, + children: "Update Entry" + }) + ] + }), + !entryPage && /*#__PURE__*/ jsx_runtime_.jsx(ExpandBlock/* default */.Z, { + collapse: collapse, + setCollapse: setCollapse + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 2348: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormRadios) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {{ + * title: string, + * payload: string | boolean, + * default?: boolean, + * jsx?: React.ReactNode, + * onChangeHandler?: (e: any) => void, + * }[]} props.radioValues - array of objects + * @param {string} props.name - form radios collective name + * @param {(e: any) => void} [props.onChangeHandler] - when radios change + * @param {React.Dispatch<React.SetStateAction<any>>} [props.setAlert] - set an external alert dispatch + * @param {boolean} [props.flexRow] - if the radio and label are stacked on each other or side-by-side + * @param {string} [props.labelColor] - Label color using tailwind syntax + * @param {boolean} [props.baseText] - Font size regular + * @param {boolean} [props.smallText] - Font size smaller + * @param {string} [props.className] - Additional class names for the wrapper + */ function FormRadios({ radioValues , name , onChangeHandler , setAlert , flexRow , labelColor , baseText , smallText , className , }) { + try { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex items-start gap-4 flex-wrap " + (flexRow ? "" : " flex-col ") + (className ? className : ""), + children: radioValues.map((value, index)=>{ + const { payload , title , jsx } = value; + const radioPayload = payload === false ? payload : payload ? payload : title ? title : null; + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + className: "m-0" + (baseText ? " w-5 h-5" : smallText ? " w-4 h-4" : " w-6 h-6"), + type: "radio", + defaultChecked: value.default ? true : false, + name: name, + id: name + "_" + radioPayload, + onChange: (e)=>{ + if (setAlert) setAlert(null); + if (value.onChangeHandler) { + value.onChangeHandler(e); + } else if (onChangeHandler) { + onChangeHandler(e); + } + }, + value: typeof radioPayload == "string" ? radioPayload : undefined + }), + jsx ? jsx : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: name + "_" + radioPayload, + className: "text-lg m-0 " + (labelColor ? labelColor : "text-slate-800") + (baseText ? " text-base" : smallText ? " text-sm" : " text-lg"), + children: title + }) + ] + }, index + 1); + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log("ERROR in FormRadio =>", error); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + children: "Form Radio Error" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 7722: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "TableEntriesContext": () => (/* binding */ TableEntriesContext), + "default": () => (/* binding */ TableEntries), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/admin/databases/TableEntriesList.jsx + 1 modules +var TableEntriesList = __webpack_require__(6122); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/ActiveCloneTableBanner.jsx +var ActiveCloneTableBanner = __webpack_require__(8515); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +// EXTERNAL MODULE: ./components/admin/databases/ImportExportEntries.jsx + 1 modules +var ImportExportEntries = __webpack_require__(2943); +// EXTERNAL MODULE: ./components/admin/databases/MoreTableOptions.jsx +var MoreTableOptions = __webpack_require__(3684); +;// CONCATENATED MODULE: ./components/admin/databases/TableEntriesContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ const BATCH_NO = 20; +/** @type {any} */ let refreshTimeout; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function TableEntriesContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , dbSchemaData , setTargetEntry , richTextEditors , jsonTextEditors , query , confirmedDelegetedUser , activeEntries , entriesCount , setActiveEntries , } = external_react_default().useContext(TableEntriesContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const dataTypes = __webpack_require__(9594); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full relative z-50", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "flex items-center flex-wrap gap-2", + children: [ + "All Entries In", + " ", + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "bg-slate-100 dark:bg-slate-800 px-2 py-1 border border-solid border-slate-400 dark:border-slate-600 rounded relative", + children: [ + table.tableFullName, + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-5 -right-4", + children: /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.tableName, + justIcon: true + }) + }) + ] + }), + " ", + "Table" + ] + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full sm:w-auto", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + className: "button flex items-center gap-2 w-full sm:w-auto justify-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Entry" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(ImportExportEntries/* default */.Z, { + database, + table + }), + /*#__PURE__*/ jsx_runtime_.jsx(MoreTableOptions/* default */.Z, { + database, + table, + dbSchemaData, + query + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneTableBanner/* default */.Z, { + table: table, + database: database, + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx(TableEntriesList/* default */.Z, { + user: user, + entries: activeEntries, + database: database, + table: table, + setTargetEntry: setTargetEntry, + dbSchemaData: dbSchemaData, + richTextEditors: richTextEditors, + dataTypes: dataTypes, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors, + search: true + }), + entriesCount > BATCH_NO && /*#__PURE__*/ jsx_runtime_.jsx(InfiniteScroll, { + activeEntries, + setActiveEntries, + database, + table, + entriesCount + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * + * @param {object} props + * @param {any[] | null} props.activeEntries + * @param {React.Dispatch<React.SetStateAction<any[] | null>>} props.setActiveEntries + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {number} props.entriesCount + * @returns + */ function InfiniteScroll({ activeEntries , setActiveEntries , database , table , entriesCount , }) { + const context = external_react_default().useContext(TableEntriesContext); + /** @type {React.RefObject<HTMLDivElement>} */ // @ts-ignore + const infiniteScrollRef = external_react_default().useRef(); + const pageRef = external_react_default().useRef(1); + const totalEntriesDisplayed = BATCH_NO * Number(pageRef.current); + const exhausted = Boolean(totalEntriesDisplayed >= entriesCount); + external_react_default().useEffect(()=>{ + /** @type {IntersectionObserverCallback} */ function ISObserverCb(entries, observer) { + if (entries?.[0]?.isIntersecting) { + /** @type {HTMLInputElement | null} */ // @ts-ignore + const searchInput = document.getElementById("entries-search-input"); + /** @type {HTMLInputElement | null} */ // @ts-ignore + const searchField = document.getElementById("entries-search-field-select"); + /** @type {import("@/pages/api/infiniteScroll").InfiniteScrollBodyObject} */ const fetchObject = { + tableName: table.tableName, + dbName: database.db_slug, + page: pageRef.current, + tableSchema: table, + search: searchInput ? searchInput.value : undefined, + searchField: searchField ? searchField.value : undefined, + delegated: Boolean(context.query.delegated) + }; + (0,fetchApi/* default */.Z)("/api/infiniteScroll", { + method: "POST", + body: fetchObject + }, true).then((/** @type {import("@/pages/api/infiniteScroll").InfiniteScrollAPIRes} */ res)=>{ + if (!res.success) { + return; + } + if (res.page) { + pageRef.current = res.page; + } + window.clearTimeout(refreshTimeout); + refreshTimeout = setTimeout(()=>{ + if (!res.data?.[0]) return; + if (res.data?.[0]) { + setActiveEntries((prev)=>{ + if (!prev) { + return null; + } + return [ + ...prev, + // @ts-ignore + ...res.data, + ]; + }); + } + }, 500); + }).catch((err)=>{ + console.log("Infinite Scroll Error =>", err); + }).finally(()=>{ + console.log("Infinite Scroll Done. Page", pageRef.current); + }); + } + } + /** @type {IntersectionObserverInit} */ const ISObserverOptions = { + rootMargin: "0px 0px 0px 0px" + }; + setTimeout(()=>{ + requestAnimationFrame(()=>{ + const infiniteScrollObserver = new IntersectionObserver(ISObserverCb, ISObserverOptions); + if (infiniteScrollRef.current) infiniteScrollObserver.observe(infiniteScrollRef.current); + }); + }, 1000); + }, []); + if (exhausted) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + } + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex items-center justify-center", + ref: infiniteScrollRef, + children: /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative", + style: { + backgroundColor: "transparent" + }, + width: "20px" + }) + }); +} + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2317); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/ScrollToTopButton.jsx +var ScrollToTopButton = __webpack_require__(9360); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").TableEntriesContextType} */ // @ts-ignore +const init = {}; +const TableEntriesContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any[]} props.entries + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + * @param {number} props.entriesCount + */ function TableEntries({ user , database , table , dbSchemaData , entries , query , confirmedDelegetedUser , entriesCount , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${table.tableFullName} Table Entries | Datasquirel`; + const pageDescription = "All Entries in table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [targetEntry, setTargetEntry] = external_react_default().useState(null); + /** @type {[ state: any[] | null, dispatch: React.Dispatch<React.SetStateAction<any[] | null>> ]} */ // @ts-ignore + const [activeEntries, setActiveEntries] = external_react_default().useState(entries); + const targetField = external_react_default().useRef("title"); + const searchTerm = external_react_default().useRef(null); + /** @type {React.MutableRefObject<any[]>} */ const richTextEditors = external_react_default().useRef([]); + /** @type {React.MutableRefObject<any[]>} */ const jsonTextEditors = external_react_default().useRef([]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(TableEntriesContext.Provider, { + value: { + user, + database, + table, + dbSchemaData, + entries, + targetEntry, + setTargetEntry, + richTextEditors, + jsonTextEditors, + query, + confirmedDelegetedUser, + activeEntries, + setActiveEntries, + targetField, + searchTerm, + entriesCount + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(TableEntriesContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ScrollToTopButton/* default */.Z, { + snug: true + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ /** @type {string} */ // @ts-ignore + const slug = query.single; + const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + databaseSlug: slug, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + throw new Error("No Db Object Found!"); + } + const { dbUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === query.single_table)[0]; + const tableEntries = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM \`${targetTable.tableName}\` ORDER BY id DESC LIMIT 20`, + tableSchema: targetTable + }); + const tableEntriesCount = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT COUNT(id) AS count FROM ${targetTable.tableName}`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + table: targetTable, + dbSchemaData: dbSchemaData, + entries: tableEntries, + query, + confirmedDelegetedUser, + entriesCount: tableEntriesCount?.[0]?.count || 0 + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError_default()({ + component: "[single_table]/entries-page-component/getServerSideProps/catch-error", + message: error.message, + user: user + }); + return { + // redirect: { + // destination: "/login", + // permanent: false + // }, + props: { + user: user, + database: null, + table: null, + entries: [] + } + }; + } +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/913.js b/dsql-app/.local_dist/server/chunks/913.js new file mode 100644 index 0000000..8beba19 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/913.js @@ -0,0 +1,713 @@ +"use strict"; +exports.id = 913; +exports.ids = [913]; +exports.modules = { + +/***/ 5484: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ AdminUserBlock) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/CottageTwoTone" +var CottageTwoTone_ = __webpack_require__(386); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./layouts/components/AdminUserDropdown.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Admin User Dropdown + * ============================================================================== + * @param {object} props + * @param {import("@/package-shared/types").UserType} props.user + */ function AdminUserDropdown({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown right-aligned", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: "/admin", + className: "button outlined gray more-padding relative z-20 mb-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.CircleGauge, { + size: 18, + className: "mr-1" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Dashboard" + }) + ] + }), + false ? /*#__PURE__*/ 0 : null, + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/settings`, + className: "button plain-text more-padding normal-weight", + children: "Settings" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/logout", + className: "button plain-text more-padding normal-weight", + children: "Logout" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./components/general/ThemeSelector.jsx +var ThemeSelector = __webpack_require__(4981); +;// CONCATENATED MODULE: ./layouts/components/AdminLayout/AdminUserBlock.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {import("@/package-shared/types").UserType | null} [props.activeUser] - user object + * @param {boolean} [props.noModeSelector] - Add dark mode toggler or not + */ function AdminUserBlock({ activeUser , noModeSelector }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (!activeUser?.logged_in_status) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}); + } + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-2 flex-col-reverse xl:flex-row gap-y-6 w-full xl:w-auto py-2 whitespace-nowrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "ml-auto dropdown-wrapper p-0 xl:p-4 hover:bg-slate-100 hidden", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${activeUser?.id}/notifications`, + className: "flex items-center justify-center", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/notification-icon.svg", + alt: "Notification Icon", + width: 20, + className: "opacity-50" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown mt-0 xl:-mt-3 gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Notifications" + }), + /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative", + width: "20px" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "ml-auto dropdown-wrapper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "avatar", + style: { + width: "36px", + height: "36px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: activeUser?.image, + alt: "User Image", + width: 35, + className: "w-full h-full object-cover rounded-full" + }), + activeUser?.social_login ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "sub-img", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: (()=>{ + if (activeUser?.social_platform?.match(/facebook/i)) return "/images/facebook.png"; + if (activeUser?.social_platform?.match(/google/i)) return "/images/google.png"; + if (activeUser?.social_platform?.match(/github/i)) return "/images/github.png"; + return "/images/sharing.png"; + })(), + alt: "", + className: "flex dark:hidden" + }), + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: (()=>{ + if (activeUser?.social_platform?.match(/facebook/i)) return "/images/facebook.png"; + if (activeUser?.social_platform?.match(/google/i)) return "/images/google.png"; + if (activeUser?.social_platform?.match(/github/i)) return "/images/github-white.png"; + return "/images/sharing.png"; + })(), + alt: "", + className: "hidden dark:flex" + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "dark:text-white", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("b", { + children: [ + activeUser?.first_name, + " ", + activeUser?.last_name + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronDown, { + size: 20 + }), + /*#__PURE__*/ jsx_runtime_.jsx(AdminUserDropdown, { + user: activeUser + }) + ] + }), + !noModeSelector && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-2", + children: /*#__PURE__*/ jsx_runtime_.jsx(ThemeSelector/* default */.Z, {}) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 5281: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ Footer) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _components_general_Logo__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4017); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + */ function Footer(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("footer", { + className: "p-8 md:p-10 w-full flex flex-col items-center", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "main-container items-start justify-between gap-6 flex-wrap flex-col md:flex-row pt-6", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-6", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_Logo__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-normal max-w-sm text-sm text-left", + children: "Datasquirel is a fast efficient cloud-based data store that takes away the entire hassle of data management." + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0", + children: "Features" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/database-reference/data-types", + className: "text-slate-600", + children: "Database Schema" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/database-reference/querying-data", + className: "text-slate-600", + children: "SQL Queries" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/gui-reference/upload-media", + className: "text-slate-600", + children: "Media Storage" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0", + children: "Docs" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/quick-start", + className: "text-slate-600", + children: "Quick Start Guide" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/api-reference", + className: "text-slate-600", + children: "API Guide" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/gui-reference", + className: "text-slate-600", + children: "GUI Interface" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0", + children: "Company" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/about", + className: "text-slate-600", + children: "About Us" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/terms", + className: "text-slate-600", + children: "Terms and Conditions" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/privacy", + className: "text-slate-600", + children: "Privacy Policy" + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "my-10" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "container", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-sm text-slate-400 dark:text-slate-600", + children: [ + new Date().getFullYear(), + " \xa9 Datasquirel. All rights reserved." + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 7108: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ Header) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _components_general_ThemeSelector__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4981); +/* harmony import */ var _components_general_Logo__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4017); +/* harmony import */ var _AdminLayout_AdminUserBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5484); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - React component props + * @param {import("@/package-shared/types").UserType | null} [props.user] + * @param {boolean} [props.darkBg] + * @param {boolean} [props.transparent] + */ function Header({ user , darkBg , transparent }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [activeUser, setActiveUser] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(user?.logged_in_status ? user : null); + // const [activeUser, setActiveUser] = React.useState(user); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + /** @type {*} */ const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + window.addEventListener("click", (e)=>{ + /** @type {*} */ const clickTarget = e.target; + if (clickTarget?.closest("#main-nav-content-wrapper") || clickTarget?.closest("#main-header-hamburger-button")) return; + if (!mainNavWrapper.classList.contains("hidden")) { + mainNavWrapper.classList.add("hidden"); + } + }); + const navLinks = document.querySelectorAll("nav a"); + navLinks.forEach((/** @type {HTMLAnchorElement | *} */ link)=>{ + if (link.pathname === window.location.pathname) { + if (link.href.match(/#/) || link.pathname.match(/http/)) return; + link.classList.add("active-page-link"); + } + }); + }, []); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (user?.logged_in_status) { + setActiveUser(user); + } + }, [ + user + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("header", { + className: "w-full px-4 md:px-8 flex justify-center gap-4 " + (darkBg ? " shadow-slate-900/20 dark-content" : " shadow-slate-900/5") + (transparent ? "" : " bg-white dark:bg-slate-800 shadow-lg dark:shadow-black/10 z-50") + (user?.logged_in_status ? " py-4" : " py-6"), + style: { + zIndex: 700 + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "container", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("nav", { + className: "w-full flex items-center justify-between gap-4 md:gap-10", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_Logo__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "hidden xl:flex flex-col items-stretch grow fixed xl:static top-0 right-0 p-4 xl:p-0 shadow-xl xl:shadow-none h-screen xl:h-auto overflow-auto xl:overflow-visible w-screen sl:w-auto xl:bg-transparent" + (transparent ? " bg-white xl:bg-transparent" : " bg-white dark:bg-slate-800"), + id: "main-nav-content-wrapper", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "items-center mb-2 flex xl:hidden", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/logo-icon-alt-2.png", + alt: "Logo Icon", + width: 37 + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray ml-auto", + onClick: (e)=>{ + /** @type {*} */ const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + border: "none" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-semibold text-4xl", + children: "✕" + }) + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center grow flex-col-reverse xl:flex-row mb-10 xl:mb-0", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col xl:flex-row w-full gap-y-10 gap-x-6", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper flex items-center gap-1", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/docs/gui-reference", + className: "relative z-10 flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Features" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_5__.ChevronDown, { + size: 20 + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/database-reference/data-types", + className: "button plain-text more-padding normal-weight", + children: "Database Schema" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/database-reference/querying-data", + className: "button plain-text more-padding normal-weight", + children: "Sql Queries" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/gui-reference/upload-media", + className: "button plain-text more-padding normal-weight", + children: "Media Storage" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper flex items-center gap-1", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/docs", + className: "relative z-10 flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Docs" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_5__.ChevronDown, { + size: 20 + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/quick-start", + className: "button plain-text more-padding normal-weight", + children: "Quick Start" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/api-reference", + className: "button plain-text more-padding normal-weight", + children: "Api Guide" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/docs/gui-reference", + className: "button plain-text more-padding normal-weight", + children: "GUI Interface" + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/about", + children: "About Us" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/pricing", + children: "Pricing" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/contact", + children: "Contact Us" + }) + ] + }), + activeUser?.logged_in_status ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_AdminLayout_AdminUserBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + activeUser: activeUser, + noModeSelector: true + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "ml-auto w-full xl:w-auto justify-center", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/login", + className: "button outlined gray hidden xl:flex" + (darkBg ? " light" : ""), + children: "Login" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/login", + className: "button outlined gray flex xl:hidden", + children: "Login" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/create-account", + className: "button", + children: "Get Started" + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "ml-0 xl:-ml-2", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_ThemeSelector__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}) + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("button", { + className: "bg-transparent w-16 p-4 gap-1.5 flex xl:hidden flex-col hover:bg-transparent transition-all", + onClick: (e)=>{ + /** @type {*} */ const mainNavWrapper = document.getElementById("main-nav-content-wrapper"); + mainNavWrapper?.classList.toggle("hidden"); + }, + style: { + minWidth: "50px", + backgroundColor: "transparent" + }, + id: "main-header-hamburger-button", + "aria-label": "Mobile Hambutget Button", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full" + }) + ] + }) + ] + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9132.js b/dsql-app/.local_dist/server/chunks/9132.js new file mode 100644 index 0000000..1aa0409 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9132.js @@ -0,0 +1,57 @@ +"use strict"; +exports.id = 9132; +exports.ids = [9132]; +exports.modules = { + +/***/ 9132: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const serverError = __webpack_require__(3017); +const NO_DB_HANDLER = __webpack_require__(7487); +/** + * Create database from Schema Function + * ============================================================================== + * @param {string} queryString - Query String + * @returns {Promise<any>} + */ module.exports = async function noDatabaseDbHandler(queryString) { + "production"?.match(/dev/) && fs.appendFileSync("./.tmp/sqlQuery.sql", queryString + "\n" + Date() + "\n\n\n", "utf8"); + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + /** ********************* Run Query */ results = await NO_DB_HANDLER(queryString); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "noDatabaseDbHandler", + message: error.message + }); + console.log("ERROR in noDatabaseDbHandler =>", error.message); + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results) { + return results; + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9258.js b/dsql-app/.local_dist/server/chunks/9258.js new file mode 100644 index 0000000..af01db8 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9258.js @@ -0,0 +1,14 @@ +"use strict"; +exports.id = 9258; +exports.ids = [9258]; +exports.modules = { + +/***/ 9258: +/***/ ((module) => { + +module.exports = JSON.parse('{"tableName":"users","tableFullName":"Users","fields":[{"fieldName":"first_name","dataType":"VARCHAR(100)","notNullValue":true},{"fieldName":"last_name","dataType":"VARCHAR(100)","notNullValue":true},{"fieldName":"email","dataType":"VARCHAR(200)","notNullValue":true},{"fieldName":"phone","dataType":"VARCHAR(50)"},{"fieldName":"user_type","dataType":"VARCHAR(20)","defaultValue":"default"},{"fieldName":"username","dataType":"VARCHAR(100)","nullValue":true},{"fieldName":"password","dataType":"VARCHAR(250)","notNullValue":true},{"fieldName":"image","dataType":"VARCHAR(250)","defaultValue":"/images/user_images/user-preset.png"},{"fieldName":"image_thumbnail","dataType":"VARCHAR(250)","defaultValue":"/images/user_images/user-preset-thumbnail.png"},{"fieldName":"address","dataType":"VARCHAR(255)"},{"fieldName":"city","dataType":"VARCHAR(50)"},{"fieldName":"state","dataType":"VARCHAR(50)"},{"fieldName":"country","dataType":"VARCHAR(50)"},{"fieldName":"zip_code","dataType":"VARCHAR(50)"},{"fieldName":"social_login","dataType":"TINYINT","defaultValue":"0"},{"fieldName":"social_platform","dataType":"VARCHAR(50)","nullValue":true},{"fieldName":"social_id","dataType":"VARCHAR(250)","nullValue":true},{"fieldName":"more_user_data","dataType":"BIGINT","defaultValue":"0"},{"fieldName":"verification_status","dataType":"TINYINT","defaultValue":"0"},{"fieldName":"temp_login_code","dataType":"VARCHAR(50)","nullValue":true}]}'); + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9282.js b/dsql-app/.local_dist/server/chunks/9282.js new file mode 100644 index 0000000..289867b --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9282.js @@ -0,0 +1,754 @@ +"use strict"; +exports.id = 9282; +exports.ids = [9282]; +exports.modules = { + +/***/ 2184: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabaseListCard) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_DatabaseSlugCopy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4739); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5472); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(6729); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +/* harmony import */ var _general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5449); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type>>} [props.setTargetDatabase] + * @param {boolean} [props.delegated] + * @param {any} [props.icons] + * @param {import("@/package-shared/types").UserType} props.user + */ function DatabaseListCard({ database , setTargetDatabase , delegated , icons , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const url = `/admin/${user?.id}/databases/${database.db_slug}` + (delegated ? `?delegated=true&dbUserId=${database.user_id}` : ""); + const { active_clone , active_clone_parent_db } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: url, + className: "card", + onClick: (e)=>{ + // @ts-ignore + if (e.target.closest(".db-list-item-actions-block")) { + e.preventDefault(); + } + if (delegated) { + e.preventDefault(); + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)("/api/getDelegatedDatabaseToken", { + method: "post", + body: { + rootUserId: database.user_id, + priviledges: database.user_priviledge, + database: database.db_slug + } + }, true).then((res)=>{ + if (res.success) { + window.location.href = url; + } + }); + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }, + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: database.db_image ? database.db_image : "/images/folder.svg", + alt: "Folder Image", + width: 20, + className: database.db_image ? "avatar" : "avatar opacity-50" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start grow", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "title", + children: database.db_name + }), + active_clone_parent_db && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-xs bg-emerald-100 dark:bg-emerald-100/10 text-emerald-700 dark:text-emerald-200 px-2 py-0.5 rounded-full mb-1", + children: [ + "This Database is an active Clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: active_clone_parent_db.replace(/datasquirel_user_\d+_/, "") + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "-mt-2", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_DatabaseSlugCopy__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + slugText: database.db_slug, + smaller: true + }) + }), + !delegated && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-sm text-slate-400", + children: [ + "Created: ", + database.date_created?.substring(0, 21) + ] + }), + delegated && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center mt-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: database.image_thumbnail, + alt: "", + className: "w-8 h-8 rounded-full object-cover" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start gap-0", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "text-xs text-slate-600", + children: [ + database.first_name, + " ", + database.last_name + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-xs text-slate-400", + children: database.email + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "db-list-item-actions-block flex-wrap", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_ui_ButtonGroup__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + children: [ + !delegated && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined light-gray small-text", + onClick: (e)=>{ + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/edit-database`; + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Edit" + }) + }), + !delegated && !active_clone && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined light-gray small-text", + onClick: (e)=>{ + window.location.href = `/admin/${user?.id}/databases/add-database?duplicate=${database.db_full_name}`; + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Duplicate" + }) + }), + !delegated && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined light-gray small-text", + onClick: (e)=>{ + if (setTargetDatabase) setTargetDatabase(database); + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* .openPopup */ .Mw)("delete-database-confirmation"); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Delete" + }) + }) + ] + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_6__.ChevronRight, { + className: "text-slate-600", + size: 20 + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8744: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabasesContent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _pages_admin_user_id_databases__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2109); +/* harmony import */ var _general_Breadcrumbs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(424); +/* harmony import */ var _general_VerificationBanner__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7946); +/* harmony import */ var _DatabasesList__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6891); +/* harmony import */ var _DelegatedDatabasesSection__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5592); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabasesContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , setTargetDatabase , user } = react__WEBPACK_IMPORTED_MODULE_1___default().useContext(_pages_admin_user_id_databases__WEBPACK_IMPORTED_MODULE_2__.DatabasesContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "text-3xl m-0", + children: "Databases" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: `/admin/${user?.id}/databases/add-database`, + className: "button flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Add Database" + }) + ] + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_Breadcrumbs__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + user: user + }) + ] + }), + user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabasesList__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + databases: databases, + setTargetDatabase: setTargetDatabase, + user: user + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DelegatedDatabasesSection__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + user: user + }) + ] + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_VerificationBanner__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 6891: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DatabasesList) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _DatabaseListCard__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2184); +/* harmony import */ var _mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8193); +/* harmony import */ var _mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(930); +/* harmony import */ var _mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7039); +/* harmony import */ var _mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5050); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_6__); +/* harmony import */ var _mui_icons_material_StorageTwoTone__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(4063); +/* harmony import */ var _mui_icons_material_StorageTwoTone__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_StorageTwoTone__WEBPACK_IMPORTED_MODULE_7__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} [props.databases] - Server props + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type>>} [props.setTargetDatabase] - Section Title + * @param {string} [props.title] - Section Title + * @param {boolean} [props.more] - More button + * @param {import("@/package-shared/types").UserType} [props.user] + */ function DatabasesList({ databases , setTargetDatabase , title , more , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0", + children: title ? title : "Database List" + }), + user && databases && databases[0] && setTargetDatabase && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full grid grid-cols-1 sl:grid-cols-2 xl:grid-cols-3 items-stretch gap-6", + children: databases.map((database)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseListCard__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + database: database, + setTargetDatabase: setTargetDatabase, + icons: { + edit: (_mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_3___default()), + duplicate: (_mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_4___default()), + delete: (_mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_5___default()), + copy: (_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_6___default()) + }, + user: user + }, database.id); + }) + }), + more && databases && databases[0] && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases`, + className: "button w-full more-padding", + children: "See All Databases" + }), + !databases || !databases[0] && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: `/admin/${user?.id}/databases/add-database`, + className: "button outlined gray dashed w-full p-10 flex-col", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-slate-400", + children: "No Databases Created." + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_StorageTwoTone__WEBPACK_IMPORTED_MODULE_7___default()), { + color: "action", + sx: { + fontSize: 80 + }, + className: "opacity-40" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "", + children: "Add Database" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 5592: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DelegatedDatabasesSection) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8193); +/* harmony import */ var _mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(930); +/* harmony import */ var _mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7039); +/* harmony import */ var _mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5050); +/* harmony import */ var _mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5264); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(6729); +/* harmony import */ var _DatabaseListCard__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2184); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + */ function DelegatedDatabasesSection({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const databasesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type { [databases: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[] | null, setDatabases: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[] | null>>] } */ const [databases, setDatabases] = databasesState; + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z)("/api/getDelegatedDatabases").then((res)=>{ + if (res.success) { + setDatabases(res.databases); + setLoading(false); + } + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "Delegated Databases" + }), + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, {}), + user && databases ? databases[0] ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full grid grid-cols-1 sl:grid-cols-2 xl:grid-cols-3 items-stretch gap-6", + children: databases.map((database)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseListCard__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z, { + database: database, + delegated: true, + icons: { + edit: (_mui_icons_material_DriveFileRenameOutlineTwoTone__WEBPACK_IMPORTED_MODULE_2___default()), + duplicate: (_mui_icons_material_DifferenceTwoTone__WEBPACK_IMPORTED_MODULE_3___default()), + delete: (_mui_icons_material_DeleteForeverTwoTone__WEBPACK_IMPORTED_MODULE_4___default()), + copy: (_mui_icons_material_CopyAllTwoTone__WEBPACK_IMPORTED_MODULE_5___default()) + }, + user: user + }, database.id); + }) + }) + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "info gray w-full font-normal justify-center", + children: "No Delegated Databases Yet" + }) + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full justify-center", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + position: "relative", + width: "20px" + }) + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 2109: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "DatabasesContext": () => (/* binding */ DatabasesContext), +/* harmony export */ "default": () => (/* binding */ Databases), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4858); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _components_admin_databases_DatabasesContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8744); +/* harmony import */ var _components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5012); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DbContextType} */ let databaseContextObject = {}; +const DatabasesContext = /*#__PURE__*/ react__WEBPACK_IMPORTED_MODULE_1___default().createContext(databaseContextObject); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user - User Object + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases - Databases + */ function Databases({ user , databases }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Databases | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const targetDatabaseState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(0); + /** @type {[ dbTables: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type | undefined, setDbTables: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type>> ]} */ const [targetDatabase, setTargetDatabase] = targetDatabaseState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(DatabasesContext.Provider, { + value: { + user, + databases, + targetDatabase, + setTargetDatabase + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_databases_DatabasesContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + targetDatabase: targetDatabase + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const databases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT * FROM user_databases WHERE user_id=? ORDER BY id DESC`, [ + user.id + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + databases: databases + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9360.js b/dsql-app/.local_dist/server/chunks/9360.js new file mode 100644 index 0000000..7b81169 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9360.js @@ -0,0 +1,97 @@ +"use strict"; +exports.id = 9360; +exports.ids = [9360]; +exports.modules = { + +/***/ 9360: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ScrollToTopButton) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props + * @param {boolean} [props.snug] + */ function ScrollToTopButton({ snug }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [isVisible, setIsVisible] = react__WEBPACK_IMPORTED_MODULE_2___default().useState(false); + react__WEBPACK_IMPORTED_MODULE_2___default().useEffect(()=>{ + window.addEventListener("scroll", (e)=>{ + if (window.scrollY > 600) { + setIsVisible(true); + } else { + setIsVisible(false); + } + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_2___default().Fragment), { + children: isVisible && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "fixed z-40 w-12 h-12 p-2 rounded-full bg-white dark:bg-slate-600 shadow-xl flex items-center justify-center hover:bg-slate-800 dark:hover:bg-slate-800 text-slate-500 dark:text-slate-200 outline-slate-300 dark:outline-transparent" + (snug ? " bottom-6 right-4" : " bottom-4 md:bottom-10 right-4 md:right-10"), + style: { + outlineStyle: "solid", + outlineWidth: "1px", + zIndex: 2000 + }, + onClick: (e)=>{ + window.scrollTo({ + top: 0, + left: 0, + behavior: "smooth" + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_1__.ChevronUp, { + size: 20 + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9395.js b/dsql-app/.local_dist/server/chunks/9395.js new file mode 100644 index 0000000..e4397b4 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9395.js @@ -0,0 +1,55 @@ +"use strict"; +exports.id = 9395; +exports.ids = [9395]; +exports.modules = { + +/***/ 9395: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +const MASTER = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + database: process.env.DSQL_DB_NAME, + port: process.env.DB_PORT ? Number(process.env.DB_PORT) : undefined, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {string} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ // @ts-ignore +async function DB_HANDLER(...args) { + try { + const results = await MASTER.query(...args); + /** ********************* Clean up */ await MASTER.end(); + return JSON.parse(JSON.stringify(results)); + } catch (/** @type {any} */ error) { + console.log("DB Error =>", error); + return { + success: false, + error: error.message + }; + } +} +module.exports = DB_HANDLER; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9417.js b/dsql-app/.local_dist/server/chunks/9417.js new file mode 100644 index 0000000..14d164b --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9417.js @@ -0,0 +1,344 @@ +"use strict"; +exports.id = 9417; +exports.ids = [9417]; +exports.modules = { + +/***/ 9417: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ TargetUserPreviewPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6729); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _form_FormCheckboxes__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9486); +/* harmony import */ var _form_FormSelect__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4114); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").MYSQL_user_users_table_def | null} props.targetUser + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>>} props.setTargetUser + * @param {import("@/package-shared/types").UserType} props.user + */ function TargetUserPreviewPopup({ targetUser , user , setTargetUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userPriviledges = __webpack_require__(9169); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!targetUser) { + return null; + } + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(true); + /** @type {any} */ const databasesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState([]); + /** @type {[ dbTables: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[], setDbTables: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]>> ]} */ const [databases, setDatabases] = databasesState; + const [allDbSelected, setAllDbSelected] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + /** @type {any} */ const priviledgesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetUser ? targetUser.user_priviledge?.split("|") : []); + /** @type {[ dbTables: string[], setDbTables: React.Dispatch<React.SetStateAction<string[]>> ]} */ const [priviledges, setPriviledges] = priviledgesState; + const [databasesAccess, setDatabasesAccess] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetUser?.database_access ? targetUser.database_access.split("|") : []); + /** @type {any} */ const targetDbsState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetUser ? targetUser.database_access?.split("|")[0] : null); + /** @type {[ dbTables: string | null, setDbTables: React.Dispatch<React.SetStateAction<string | null>> ]} */ const [targetDb, setTargetDb] = targetDbsState; + /** @type {any} */ const dbTablesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState([]); + /** @type {[ dbTables: import("@/package-shared/types").MYSQL_user_database_tables_table_def[] | null, setDbTables: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def[] | null>> ]} */ const [dbTables, setDbTables] = dbTablesState; + /** @type {any} */ const selectedDbTablesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState([]); + /** @type {[ dbTables: string[], setDbTables: React.Dispatch<React.SetStateAction<string[]>> ]} */ const [selectedDbTables, setSlectedDbTables] = selectedDbTablesState; + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z)("/api/getUserDatabases").then((res)=>{ + if (res.success) { + setDatabases(res.databases); + } + }); + }, []); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (!targetUser) return; + if (!targetDb) { + setTargetDb(targetUser.database_access?.split("|")[0] || null); + } else { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z)(`/api/getDatabaseTables?dbSlug=${targetDb}&dbOwnerId=${user.id}&delegatedUserId=${targetUser.invited_user_id}`).then((res)=>{ + if (res.success) { + setDbTables(null); + setTimeout(()=>{ + setDbTables([ + ...res.tables + ]); + }, 200); + } + if (res.accessed_tables && res.accessed_tables[0] && !selectedDbTables[0]) { + setSlectedDbTables(res.accessed_tables.map((/** @type {any} */ acTb)=>`${acTb.database}-${acTb.table}`)); + } + }); + } + }, [ + targetDb + ]); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + setLoading(true); + if (targetUser) { + setPriviledges(targetUser.user_priviledge?.split("|") || []); + setDatabasesAccess(targetUser.database_access?.split("|") || []); + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }, [ + targetUser + ]); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + setTargetDb(databasesAccess?.[0] || null); + }, [ + databasesAccess + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "target-user-popup", + closePopupDispatch: ()=>{ + setTargetUser(null); + }, + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + position: "relative" + }), + !loading && targetUser && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col w-full items-start p-4", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0", + children: [ + "Edit ", + targetUser.first_name, + " ", + targetUser.last_name, + "'s Access" + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + className: "flex flex-col items-start w-full", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z)("/api/updateAdminUserAccess", { + method: "post", + body: { + userObject: targetUser, + user_priviledge: priviledges.join("|"), + database_access: databasesAccess?.join("|"), + db_tables: databasesAccess && databasesAccess[0] ? selectedDbTables.join("|") : "", + inv_user_id: targetUser.invited_user_id + } + }, true).then((res)=>{ + window.location.reload(); + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600", + children: "User Priviledges" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormCheckboxes__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + checkBoxValues: userPriviledges.map((userPriviledge)=>{ + return { + title: userPriviledge, + name: userPriviledge, + default: priviledges.includes(userPriviledge) ? true : false, + onChangeHandler: (e)=>{ + if (priviledges.includes(userPriviledge)) { + let newArray = priviledges.filter((priv)=>priv != userPriviledge); + setPriviledges([ + ...newArray, + ]); + } else { + setPriviledges((prev)=>[ + ...prev, + userPriviledge, + ]); + } + } + }; + }), + smallText: true, + flexRow: true + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "my-6" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "m-0 text-lg font-semibold mb-2 text-slate-600", + children: "Databases Access" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "button outlined gray px-4 py-1 -mt-1 mb-1.5", + onClick: (e)=>{ + if (allDbSelected) { + databases.forEach((db)=>{ + setTimeout(()=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const elt = document.getElementById(db.db_slug); + if (elt?.checked) elt.click(); + }, 200); + }); + setAllDbSelected(false); + } else { + databases.forEach((db)=>{ + setTimeout(()=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const elt = document.getElementById(db.db_slug); + if (!elt.checked) elt.click(); + }, 200); + }); + setAllDbSelected(true); + } + }, + children: allDbSelected ? "Deselect All" : "Select All" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormCheckboxes__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + checkBoxValues: databases.map((db)=>{ + return { + title: db.db_name, + name: db.db_slug, + onChangeHandler: (e)=>{ + if (databasesAccess.includes(db.db_slug)) { + let newArray = databasesAccess.filter((_db)=>_db != db.db_slug); + setDatabasesAccess([ + ...newArray, + ]); + } else { + setDatabasesAccess((prev)=>[ + ...prev, + db.db_slug, + ]); + } + if (databasesAccess.length === databases.length) { + setAllDbSelected(true); + } else { + setAllDbSelected(false); + } + }, + default: databasesAccess.includes(db.db_slug) ? true : false + }; + }), + smallText: true, + flexRow: true + }), + databasesAccess && databasesAccess[0] && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "my-6" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "m-0 text-lg font-semibold mb-2 text-slate-600", + children: "Database Tables" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormSelect__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + required: true, + selectOptions: databases.filter((db)=>databasesAccess.includes(db.db_slug)).map((db)=>{ + return { + title: db.db_name, + payload: db.db_slug + }; + }), + name: "databases", + onChangeHandler: (e)=>{ + setTargetDb(e.target.value); + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "h-2" + }), + dbTables && dbTables[0] && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_form_FormCheckboxes__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + checkBoxValues: dbTables.map((dbTable)=>{ + return { + title: dbTable.table_name, + name: dbTable.table_slug, + onChangeHandler: (e)=>{ + if (selectedDbTables.includes(`${targetDb}-${dbTable.table_slug}`)) { + let newArray = selectedDbTables.filter((table)=>table != `${targetDb}-${dbTable.table_slug}`); + setSlectedDbTables([ + ...newArray, + ]); + } else { + setSlectedDbTables((prev)=>[ + ...prev, + `${targetDb}-${dbTable.table_slug}`, + ]); + } + }, + default: selectedDbTables.includes(`${targetDb}-${dbTable.table_slug}`) ? true : false + }; + }), + smallText: true, + flexRow: true + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "mt-4 w-full", + children: "Update User Access" + }) + ] + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 9169: +/***/ ((module) => { + +module.exports = JSON.parse('["Edit Tables","Update Entries","Create Table","Delete Entries","Delete Tables"]'); + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9471.js b/dsql-app/.local_dist/server/chunks/9471.js new file mode 100644 index 0000000..369c8df --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9471.js @@ -0,0 +1,161 @@ +"use strict"; +exports.id = 9471; +exports.ids = [9471]; +exports.modules = { + +/***/ 9471: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ Modal) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var react_dom_client__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7849); +/* harmony import */ var react_dom_client__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_dom_client__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2423); +/* harmony import */ var lucide_react__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lucide_react__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {React.ReactNode} props.children - React children + * @param {boolean} props.open + * @param {React.Dispatch<React.SetStateAction<boolean>>} [props.setOpen] + * @param {()=>void} [props.onClose] + * @param {string} [props.maxWidth] - Ex "500px" + */ function Modal({ children , open , setOpen , onClose , maxWidth }) { + /** + * Get Contexts + * + * @description { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @description Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (open) { + const modalWrapper = document.createElement("div"); + modalWrapper.className = "modal-wrapper"; + const domNode = (0,react_dom_client__WEBPACK_IMPORTED_MODULE_2__.createRoot)(modalWrapper); + domNode.render(/*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(ModalComponent, { + onClose: onClose, + maxWidth: maxWidth, + children: children + })); + document.body.appendChild(modalWrapper); + } else { + document.querySelectorAll(".modal-wrapper").forEach((modalEl)=>{ + modalEl.parentElement?.removeChild(modalEl); + }); + } + }, [ + open + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ //////////////////////////////////////// + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {}); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @param {Object} props - React component props including { children } + * @param {React.ReactNode} props.children - React children + * @param {()=>void} [props.onClose] + * @param {string} [props.maxWidth] + * @param {boolean} [props.open] + */ function ModalComponent({ children , onClose , maxWidth , open }) { + /** @type {React.Ref<HTMLDivElement>} */ // @ts-ignore + const modalRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + // React.useEffect(() => { + // if (!open) { + // /** @type {HTMLDivElement} */ // @ts-ignore + // const modalEl = modalRef.current?.closest(".modal-wrapper"); + // closeModal({ modalEl }); + // } + // }, [open]); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "modal-cancel", + onClick: (e)=>{ + /** @type {HTMLDivElement} */ // @ts-ignore + const modalEl = e.target.closest(".modal-wrapper"); + closeModal({ + modalEl, + closeFn: onClose + }); + } + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "modal-content", + style: { + maxWidth: maxWidth || undefined + }, + ref: modalRef, + children: [ + children, + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "ghost modal-cancel-button", + onClick: (e)=>{ + /** @type {HTMLDivElement} */ // @ts-ignore + const modalEl = e.target.closest(".modal-wrapper"); + closeModal({ + modalEl, + closeFn: onClose + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(lucide_react__WEBPACK_IMPORTED_MODULE_3__.X, {}) + }) + ] + }) + ] + }); +} +/** + * @param {object} param0 + * @param {HTMLElement} param0.modalEl + * @param {()=>void} [param0.closeFn] + */ function closeModal({ modalEl , closeFn }) { + if (closeFn) closeFn(); + modalEl.parentElement?.removeChild(modalEl); +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9486.js b/dsql-app/.local_dist/server/chunks/9486.js new file mode 100644 index 0000000..902c0b5 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9486.js @@ -0,0 +1,112 @@ +"use strict"; +exports.id = 9486; +exports.ids = [9486]; +exports.modules = { + +/***/ 9486: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ FormCheckboxes) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} [props.name] - Name of checkbox group + * @param {{ + * name?: string, + * title?: string, + * payload?: string, + * onChangeHandler?: (e:any, value:any) => void, + * default?: boolean, + * fixed?: boolean, + * jsx?: React.ReactNode, + * className?: string, + * }[]} props.checkBoxValues - array of objects + * @param {React.Dispatch<React.SetStateAction<string | null>>} [props.setAlert] - set an external alert dispatch + * @param {string} [props.labelColor] - Label color using tailwind syntax + * @param {boolean} [props.flexRow] - if the radio and label are stacked on each other or side-by-side + * @param {boolean} [props.baseText] - Font size regular + * @param {boolean} [props.smallText] - Font size smaller + * @param {string} [props.className] - Additional Class Names for wrapper + */ function FormCheckboxes({ name , checkBoxValues , setAlert , labelColor , flexRow , baseText , smallText , className , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex items-start gap-x-4" + (flexRow ? " flex-row flex-wrap gap-y-2 " : " flex-col gap-y-4 ") + (className ? className : ""), + children: checkBoxValues.map((value, index)=>{ + const { payload , title , onChangeHandler , fixed , jsx } = value; + const chxName = value.name ? `${name}-${value.name}` : payload ? name + "-" + payload : name; + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center" + (value.default && fixed ? " pointer-events-none" : "") + (smallText ? " gap-1 " : " gap-2 ") + (value?.className ? value.className : ""), + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + className: "m-0" + (smallText ? " w-4 h-4" : " w-5 h-5"), + type: "checkbox", + defaultChecked: value.default ? true : false, + name: chxName, + id: chxName, + onChange: (e)=>{ + if (setAlert) setAlert(null); + if (onChangeHandler) onChangeHandler(e, value); + }, + value: payload, + style: { + minWidth: "20px" + } + }), + jsx ? jsx : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: chxName, + className: "m-0 " + (labelColor ? labelColor : "text-slate-800 dark:text-white/80") + (baseText || smallText ? " text-base" : " text-lg"), + children: title + }) + ] + }, index + 1); + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9594.js b/dsql-app/.local_dist/server/chunks/9594.js new file mode 100644 index 0000000..83fdcbe --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9594.js @@ -0,0 +1,14 @@ +"use strict"; +exports.id = 9594; +exports.ids = [9594]; +exports.modules = { + +/***/ 9594: +/***/ ((module) => { + +module.exports = JSON.parse('[{"title":"VARCHAR","name":"VARCHAR","value":"0-255","argument":true,"description":"Varchar is simply letters and numbers within the range 0 - 255","maxValue":255},{"title":"TINYINT","name":"TINYINT","value":"0-100","description":"TINYINT means Integers: 0 to 100","maxValue":127},{"title":"SMALLINT","name":"SMALLINT","value":"0-255","description":"SMALLINT means Integers: 0 to 240933","maxValue":32767},{"title":"MEDIUMINT","name":"MEDIUMINT","value":"0-255","description":"MEDIUMINT means Integers: 0 to 1245568545560","maxValue":8388607},{"title":"INT","name":"INT","value":"0-255","description":"INT means Integers: 0 to 12560","maxValue":2147483647},{"title":"BIGINT","name":"BIGINT","value":"0-255","description":"BIGINT means Integers: 0 to 1245569056767568545560","maxValue":2e+63},{"title":"TINYTEXT","name":"TINYTEXT","value":"0-255","description":"Text with 255 max characters","maxValue":127},{"title":"TEXT","name":"TEXT","value":"0-100","description":"MEDIUMTEXT is just text with max length 16,777,215","maxValue":127},{"title":"MEDIUMTEXT","name":"MEDIUMTEXT","value":"0-255","description":"MEDIUMTEXT is just text with max length 16,777,215","maxValue":127},{"title":"LONGTEXT","name":"LONGTEXT","value":"0-255","description":"LONGTEXT is just text with max length 4,294,967,295","maxValue":127},{"title":"UUID","name":"UUID","valueLiteral":"UUID()","description":"A Unique ID"}]'); + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9788.js b/dsql-app/.local_dist/server/chunks/9788.js new file mode 100644 index 0000000..4c96c7f --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9788.js @@ -0,0 +1,1292 @@ +"use strict"; +exports.id = 9788; +exports.ids = [9788]; +exports.modules = { + +/***/ 4559: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ TableEntryField) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +;// CONCATENATED MODULE: ./functions/frontend/generateFormElementsForEntry.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {DSQL_FieldSchemaType} params.fieldObject + * @param {any} params.dataTypeSchema + * @param {React.MutableRefObject<any>} params.elementRef + * @param {any} params.entry + */ +function generateFormElementsForEntry({ fieldObject , dataTypeSchema , elementRef , entry , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ let formElement; + const titleSlugHandler = (/** @type {any} */ e)=>{ + const parentForm = e.target.closest("form"); + if (!parentForm) return; + const slug = parentForm?.querySelector("#slug"); + if (slug) { + slug.value = e.target.value.toLowerCase().replace(/ /g, "-").replace(/[^a-z\-0-9]/g, ""); + } + }; + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (fieldObject.defaultField) { + formElement = /*#__PURE__*/ jsx_runtime_.jsx("input", { + ref: elementRef, + type: "text", + name: "def_field_" + fieldObject.fieldName, + id: "def_field_" + fieldObject.fieldName, + placeholder: fieldObject.fieldName, + defaultValue: entry && entry[fieldObject.fieldName || ""] ? entry[fieldObject.fieldName || ""] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + readOnly: true, + "data-default": "true" + }); + return formElement; + } + //////////////////////////////////////// + if (fieldObject.dataType?.match(/varchar/i)) { + formElement = /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + ref: elementRef, + name: fieldObject.fieldName, + id: fieldObject.fieldName, + placeholder: fieldObject.fieldName, + required: fieldObject.notNullValue ? true : false, + maxLength: fieldObject.dataType?.match(/\d+/)?.[0] ? parseInt(fieldObject.dataType?.match(/\d+/)?.[0] || "") : undefined, + defaultValue: entry && entry[fieldObject.fieldName || ""] ? entry[fieldObject.fieldName || ""] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + onChange: (e)=>{ + if (fieldObject.fieldName?.match(/^title$/)) titleSlugHandler(e); + } + }); + } + //////////////////////////////////////// + if (fieldObject.dataType?.match(/int$/i)) { + formElement = /*#__PURE__*/ jsx_runtime_.jsx("input", { + ref: elementRef, + type: "number", + name: fieldObject.fieldName, + id: fieldObject.fieldName, + placeholder: fieldObject.fieldName, + required: fieldObject.notNullValue ? true : false, + max: dataTypeSchema.maxValue, + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + defaultValue: entry && entry[fieldObject.fieldName || ""] ? entry[fieldObject.fieldName || ""] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + onChange: (e)=>{} + }); + } + //////////////////////////////////////// + if (fieldObject.dataType?.match(/text$/i)) { + formElement = /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + ref: elementRef, + name: fieldObject.fieldName, + id: fieldObject.fieldName, + placeholder: fieldObject.fieldName, + required: fieldObject.notNullValue ? true : false, + defaultValue: entry && entry[fieldObject.fieldName || ""] ? entry[fieldObject.fieldName || ""] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + rows: 10, + onChange: (e)=>{} + }); + } + //////////////////////////////////////// + if (fieldObject.fieldName?.match(/password|^pass$|^key$/i)) { + formElement = /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + ref: elementRef, + type: "password", + name: fieldObject.fieldName, + id: fieldObject.fieldName, + placeholder: fieldObject.fieldName, + required: fieldObject.notNullValue ? true : false, + max: dataTypeSchema.maxValue, + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + defaultValue: entry && entry[fieldObject.fieldName] ? entry[fieldObject.fieldName] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + onChange: (e)=>{} + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "absolute right-4 cursor-pointer", + onClick: (e)=>{ + let input = e.target// @ts-ignore + .closest("div").querySelector("input"); + if (input.type === "password") { + input.type = "text"; + // @ts-ignore + e.target.innerText = "Hide"; + } else { + input.type = "password"; + // @ts-ignore + e.target.innerText = "Reveal"; + } + }, + children: "Reveal" + }) + ] + }); + } + //////////////////////////////////////// + if (!formElement) formElement = /*#__PURE__*/ jsx_runtime_.jsx("input", { + ref: elementRef, + type: "text", + name: fieldObject.fieldName, + id: fieldObject.fieldName, + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + defaultValue: entry && entry[fieldObject.fieldName || ""] ? entry[fieldObject.fieldName || ""] : fieldObject.defaultValue ? fieldObject.defaultValue : "", + onChange: (e)=>{} + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return formElement; +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/LockOutlined" +var LockOutlined_ = __webpack_require__(399); +var LockOutlined_default = /*#__PURE__*/__webpack_require__.n(LockOutlined_); +// EXTERNAL MODULE: external "@tinymce/tinymce-react" +var tinymce_react_ = __webpack_require__(6451); +// EXTERNAL MODULE: external "react-dom/client" +var client_ = __webpack_require__(7849); +var client_default = /*#__PURE__*/__webpack_require__.n(client_); +;// CONCATENATED MODULE: ./components/general/EmbedPopupContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("tinymce").Editor} props.editor + * @param {HTMLElement} props.rootElement + */ function EmbedPopupContent({ editor , rootElement }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "embed-popup-form-content-wrapper text-sm mt-2 flex-wrap bg-white p-10 rounded max-w-2xl w-full", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + const htmlText = formEl["embed-text-area"].value; + if (!htmlText?.match(/./)) return alert("Please Enter HTML Text to continue."); + editor.insertContent(htmlText); + document.body.removeChild(rootElement); + }, + className: "w-full flex flex-col items-stretch gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-center text-lg", + children: "Enter HTML code" + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: "embed-text-area", + id: "embed-text-area", + cols: 30, + rows: 10, + placeholder: "Paste Code here ..." + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + children: "Embed" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./functions/frontend/handleCopyHTML.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {import("tinymce").Editor} [params.editor] + * + * @requires search-field name attribute + */ function handleCopyHTML({ editor }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ navigator.clipboard.writeText(editor?.getContent() || "").then(()=>{ + alert("Html Copied to Clipboard!"); + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +// EXTERNAL MODULE: external "html-prettify" +var external_html_prettify_ = __webpack_require__(2329); +var external_html_prettify_default = /*#__PURE__*/__webpack_require__.n(external_html_prettify_); +;// CONCATENATED MODULE: ./components/general/EditHTMLPopupContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("tinymce").Editor} props.editor + * @param {HTMLElement} props.rootElement + */ function EditHTMLPopupContent({ editor , rootElement }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const html = editor.getContent(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.RefObject<any>} */ const editorRef = external_react_default().useRef(); + /** @type {React.RefObject<HTMLButtonElement>} */ // @ts-ignore + const saveButtonRef = external_react_default().useRef(); + /** @type {[state: AceAjax.Editor | null, setState: React.Dispatch<React.SetStateAction<AceAjax.Editor | null>>]} */ // @ts-ignore + const [aceEditor, setAceEditor] = external_react_default().useState(null); + external_react_default().useEffect(()=>{ + try { + if (!ace?.edit || !editorRef.current) { + console.log("Ace Editor not found!"); + return; + } + const editor = ace.edit(editorRef.current); + editor.setOptions({ + mode: "ace/mode/html", + value: external_html_prettify_default()(html) + }); + setAceEditor(editor); + try { + const beautify = ace.require("ace/ext/beautify"); + beautify.beautify(editor.session); + } catch (/** @type {any} */ error) {} + } catch (/** @type {any} */ error1) { + console.log("JSON Editor ERROR =>", error1.message); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + onKeyUp: (e)=>{ + if (e.ctrlKey && e.key == "Enter") { + saveButtonRef.current?.click(); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "embed-popup-form-content-wrapper relative flex flex-col items-center justify-center", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "max-w-[1200px] rounded-md overflow-hidden bg-white w-[90vw] items-start justify-start relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + ref: editorRef, + className: "w-full h-[80vh] text-[18px]" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "absolute bottom-4 right-4", + onClick: (e)=>{ + if (aceEditor) { + /** @type {AceAjax.Editor} */ const finalAceEditor = aceEditor; + const content = finalAceEditor.getValue(); + editor.setContent(content); + setTimeout(()=>{ + document.body.removeChild(rootElement); + }, 200); + } + }, + ref: saveButtonRef, + children: "Save" + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "absolute top-4 right-8 rounded-full white", + onClick: ()=>{ + try { + document.body.removeChild(rootElement); + } catch (error) {} + }, + style: { + width: "40px", + height: "40px", + padding: "0", + zIndex: "12039800000" + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.X, {}) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./functions/frontend/handleEditHTML.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {import("tinymce").Editor} [params.editor] + * + * @requires search-field name attribute + */ function handleEditHTML({ editor }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const popupWrapper = document.createElement("div"); + popupWrapper.style.position = "fixed"; + popupWrapper.style.width = "100vw"; + popupWrapper.style.height = "100vh"; + popupWrapper.style.zIndex = "123000000000000000"; + popupWrapper.style.backgroundColor = "rgba(0,0,0,0.8)"; + popupWrapper.style.display = "flex"; + popupWrapper.style.alignItems = "center"; + popupWrapper.style.justifyContent = "center"; + popupWrapper.style.top = "0"; + popupWrapper.style.left = "0"; + document.body.append(popupWrapper); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + popupWrapper.onclick = (e)=>{ + /** @type {HTMLElement} */ // @ts-ignore + const el = e.target; + if (el.closest(".embed-popup-form-content-wrapper")) { + return; + } + document.body.removeChild(popupWrapper); + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (editor) { + const root = client_default().createRoot(popupWrapper); + root.render(/*#__PURE__*/ jsx_runtime_.jsx(EditHTMLPopupContent, { + editor: editor, + rootElement: popupWrapper + })); + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./functions/frontend/handleEmbed.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {import("tinymce").Editor} [params.editor] + * + * @requires search-field name attribute + */ function handleEmbed({ editor }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const popupWrapper = document.createElement("div"); + popupWrapper.style.position = "fixed"; + popupWrapper.style.width = "100vw"; + popupWrapper.style.height = "100vh"; + popupWrapper.style.zIndex = "123000000000000000"; + popupWrapper.style.backgroundColor = "rgba(0,0,0,0.8)"; + popupWrapper.style.display = "flex"; + popupWrapper.style.alignItems = "center"; + popupWrapper.style.justifyContent = "center"; + popupWrapper.style.top = "0"; + popupWrapper.style.left = "0"; + document.body.append(popupWrapper); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + popupWrapper.onclick = (e)=>{ + /** @type {HTMLElement} */ // @ts-ignore + const el = e.target; + if (el.closest(".embed-popup-form-content-wrapper")) { + console.log("Still In Form"); + return; + } + document.body.removeChild(popupWrapper); + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (editor) { + const root = client_default().createRoot(popupWrapper); + root.render(/*#__PURE__*/ jsx_runtime_.jsx(EmbedPopupContent, { + editor: editor, + rootElement: popupWrapper + })); + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./functions/frontend/tinyMCEEditorSetup.js +// @ts-check + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @param {object} params + * @param {import("tinymce").Editor} params.editor + * @param {string} [params.formButtonId] + */ function tinyMCEEditorSetup({ editor , formButtonId }) { + editor.addShortcut("meta+13", "Save Entry.", ()=>{ + const confirm = window.confirm("Update this Form?"); + if (!confirm) return; + if (formButtonId) document.getElementById(formButtonId)?.click(); + }); + editor.addShortcut("meta+shift+e", "Edit Code.", ()=>{ + handleEditHTML({ + editor + }); + }); + editor.addShortcut("meta+shift+d", "Embed Code.", ()=>{ + handleEmbed({ + editor + }); + }); + editor.addShortcut("meta+shift+c", "Copy Code.", ()=>{ + handleCopyHTML({ + editor + }); + }); + editor.ui.registry.addButton("editCode", { + icon: "edit-block", + onAction: (_)=>handleEditHTML({ + editor + }), + tooltip: "Edit HTML Code" + }); + editor.ui.registry.addButton("embedCode", { + icon: "sourcecode", + onAction: (_)=>handleEmbed({ + editor + }), + tooltip: "Embed Code" + }); + editor.ui.registry.addButton("copyCode", { + icon: "copy", + onAction: (_)=>handleCopyHTML({ + editor + }), + tooltip: "Copy HTML" + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/admin/databases/TableRichTextEntryField.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.fieldObject + * @param {any} [props.dataTypeSchema] + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} props.richTextEditors + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} props.currentRichTextEditorForms + * @param {any} props.entry + * @param {boolean} [props.entryPage] + * @param {string} [props.formButtonId] + */ function TableRichTextEntryField({ fieldObject , dataTypeSchema , richTextEditors , entry , currentRichTextEditorForms , entryPage , formButtonId , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [ready, setReady] = external_react_default().useState(false); + const elementRef = external_react_default().useRef(); + /** @type {React.MutableRefObject<import("tinymce").Editor | undefined>} */ const editorRef = external_react_default().useRef(); + const log = ()=>{ + if (editorRef.current) { + console.log(editorRef.current.getContent()); + } + }; + external_react_default().useEffect(()=>{ + setReady(true); + }, []); + external_react_default().useEffect(()=>{ + if (ready) { + richTextEditors.current.push({ + fieldName: fieldObject.fieldName || "", + // @ts-ignore + ref: editorRef + }); + currentRichTextEditorForms.current.push({ + fieldName: fieldObject.fieldName || "", + // @ts-ignore + ref: editorRef + }); + } + }, [ + ready + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0 w-full rich-text-editor-wrapper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("label", { + className: "font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2", + htmlFor: fieldObject.fieldName, + children: [ + fieldObject.encrypted && /*#__PURE__*/ jsx_runtime_.jsx((LockOutlined_default()), { + fontSize: "small", + className: "opacity-50" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: fieldObject.fieldName + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + // @ts-ignore + ref: elementRef, + id: fieldObject.fieldName, + className: "w-full p-0 sm:p-4 flex-col items-stretch bg-slate-100 relative dark:bg-slate-700 border border-solid border-slate-300 dark:border-slate-300/20", + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px" + }, + children: [ + !ready && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + ready && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(tinymce_react_.Editor, { + tinymceScriptSrc: "/tinymce/tinymce.min.js", + onInit: (evt, editor)=>{ + editorRef.current = editor; + }, + initialValue: fieldObject.defaultValue || (entry && fieldObject.fieldName && entry[fieldObject.fieldName] ? entry[fieldObject.fieldName] : ""), + init: { + height: entryPage ? 400 : 300, + width: "100%", + convert_urls: false, + menubar: false, + plugins: [ + "advlist", + "lists", + "link", + "image", + "charmap", + "anchor", + "searchreplace", + "visualblocks", + "code", + "fullscreen", + "insertdatetime", + "media", + "table", + "preview", + "help", + "wordcount", + ], + toolbar: "undo redo | blocks | " + "bold italic forecolor | link image | alignleft aligncenter " + "alignright alignjustify | bullist numlist outdent indent | " + "removeformat help | editCode embedCode copyCode", + placeholder: "Type something ...", + document_base_url: "/", + content_css: fieldObject.cssFiles || undefined, + setup: (editor)=>{ + tinyMCEEditorSetup({ + editor, + formButtonId + }); + } + } + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: external "@monaco-editor/react" +var react_ = __webpack_require__(2587); +;// CONCATENATED MODULE: ./components/admin/databases/fields/text/ace-editor.js +// @ts-check +/** + * # Setup ACE Editor + * @param {object} param0 + * @param {React.MutableRefObject<HTMLDivElement | undefined>} param0.jsonEditorRef + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} param0.fieldObject + * @param {React.Dispatch<React.SetStateAction<number>>} param0.setRefresh + * @param {import("./JSONEditor").AceTextType} param0.typeFinal + * @param {any} param0.entry + * @param {React.MutableRefObject<import("@/package-shared/types").JSONTextEditorsRefArray[]>} param0.jsonTextEditors + * @param {React.MutableRefObject<AceAjax.Editor>} param0.editorRef + */ function aceEditorSetup({ jsonEditorRef , fieldObject , setRefresh , typeFinal , entry , jsonTextEditors , editorRef , }) { + try { + if (!ace?.edit || !jsonEditorRef.current || !fieldObject.fieldName) { + console.log("Ace Editor not found!"); + setTimeout(()=>{ + setRefresh((prev)=>prev + 1); + }, 1000); + return; + } + const editor = ace.edit(jsonEditorRef.current); + editor.setOptions({ + mode: "ace/mode/" + typeFinal, + // theme: "ace/theme/twilight", + value: fieldObject.defaultValue ? fieldObject.defaultValue : entry?.[fieldObject.fieldName] ? (()=>{ + if (typeFinal !== "json") return entry[fieldObject.fieldName]; + try { + return JSON.stringify(JSON.parse(entry[fieldObject.fieldName]), null, 4); + } catch (error) { + return entry[fieldObject.fieldName]; + } + })() : "", + placeholder: typeFinal == "json" ? "{} ..." : "", + enableBasicAutocompletion: true, + enableLiveAutocompletion: true + }); + jsonTextEditors.current.push({ + fieldName: fieldObject.fieldName, + ref: editorRef + }); + editorRef.current = editor; + try { + const beautify = ace.require("ace/ext/beautify"); + beautify.beautify(editor.session); + } catch (/** @type {any} */ error) {} + } catch (/** @type {any} */ error1) { + console.log("JSON Editor ERROR =>", error1.message); + } +} + +;// CONCATENATED MODULE: ./components/admin/databases/fields/text/JSONEditorHeader.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * # JSON editor Header + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.fieldObject + * @param {import("./JSONEditor").AceTextType} props.typeFinal + * @param {boolean} props.isExpanded + * @param {React.Dispatch<React.SetStateAction<number>>} props.setHeight + * @param {number} props.COLLAPSED_HEIGHT + * @param {number} props.EXPANDED_HEIGHT + * @returns + */ function JSONEditorHeader({ fieldObject , typeFinal , isExpanded , setHeight , COLLAPSED_HEIGHT , EXPANDED_HEIGHT , }) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-2 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("label", { + className: "font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2", + htmlFor: fieldObject.fieldName, + children: [ + fieldObject.encrypted && /*#__PURE__*/ jsx_runtime_.jsx((LockOutlined_default()), { + fontSize: "small", + className: "opacity-50" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: fieldObject.fieldName + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "px-4 py-1 bg-secondary text-white rounded-full text-sm font-bold -mt-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: typeFinal + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "ml-auto cursor-pointer gap-1 text-slate-400 hover:text-slate-800 -mt-2 items-center flex", + onClick: (e)=>{ + if (isExpanded) { + setHeight(COLLAPSED_HEIGHT); + } else { + setHeight(EXPANDED_HEIGHT); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-semibold text-sm", + children: isExpanded ? "Collapse" : "Expand" + }), + isExpanded ? /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.CircleMinus, { + size: 18, + className: "mt-[-1px]" + }) : /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.CirclePlus, { + size: 18, + className: "mt-[-1px]" + }) + ] + }) + ] + }); +} + +;// CONCATENATED MODULE: ./components/admin/databases/fields/text/JSONEditor.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {"yaml" | "json" | "html" | "css" | "javascript" | "shell"} AceTextType + */ const COLLAPSED_HEIGHT = 300; +const EXPANDED_HEIGHT = 600; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.fieldObject + * @param {any} [props.dataTypeSchema] + * @param {any | undefined} props.entry + * @param {boolean} [props.entryPage] + * @param {React.MutableRefObject<import("@/package-shared/types").JSONTextEditorsRefArray[]>} props.jsonTextEditors + * @param {AceTextType} [props.type] + */ function JSONEditor({ fieldObject , dataTypeSchema , entry , entryPage , jsonTextEditors , type , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ /** @type {AceTextType} */ const typeFinal = type || "json"; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [refresh, setRefresh] = external_react_default().useState(0); + const [height, setHeight] = external_react_default().useState(COLLAPSED_HEIGHT); + const isExpanded = height !== COLLAPSED_HEIGHT; + /** @type {React.MutableRefObject<HTMLDivElement | undefined>} */ const jsonEditorRef = external_react_default().useRef(); + /** @type {React.MutableRefObject<AceAjax.Editor>} */ // @ts-ignore + const editorRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + aceEditorSetup({ + editorRef, + entry, + fieldObject, + jsonEditorRef, + jsonTextEditors, + setRefresh, + typeFinal + }); + }, [ + refresh + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0 w-full rich-text-editor-wrapper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(JSONEditorHeader, { + fieldObject, + isExpanded, + setHeight, + typeFinal, + COLLAPSED_HEIGHT, + EXPANDED_HEIGHT + }), + /*#__PURE__*/ jsx_runtime_.jsx(JSONContent, { + height: height, + jsonEditorRef: jsonEditorRef + }) + ] + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseShellContent/catch-error-return", + message: error.message + } + }); + }, []); + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Editor Load Error" + }) + }); + } +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * + * @param {Object} props + * @param {number} props.height + * @param {React.MutableRefObject<HTMLDivElement | undefined>} props.jsonEditorRef + * @returns + */ function JSONContent({ height , jsonEditorRef }) { + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full p-0 sm:p-4 flex-col relative dark:bg-slate-700 border border-solid border-slate-300 dark:border-slate-300/20 overflow-hidden", + style: { + borderRadius: "0 5px 5px 5px", + marginTop: "-1px", + height: `${height}px` + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + // @ts-ignore + ref: jsonEditorRef, + className: `w-full text-[18px] h-full` + }) + }); +} + +;// CONCATENATED MODULE: ./components/admin/databases/TableEntryField.jsx +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 2 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [TableEntryForm.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\TableEntryForm.jsx + * `import` Statement Found in [UpdateEntryForm.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\UpdateEntryForm.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.fieldObject + * @param {Object} props.dataTypeSchema + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} props.richTextEditors + * @param {React.MutableRefObject<import("@/package-shared/types").JSONTextEditorsRefArray[]>} props.jsonTextEditors + * @param {any} [props.entry] + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} props.currentRichTextEditorForms + * @param {any} props.confirmedDelegetedUser + * @param {any} [props.query] + * @param {boolean} [props.entryPage] + * @param {string} [props.formButtonId] + */ function TableEntryField({ fieldObject , dataTypeSchema , richTextEditors , jsonTextEditors , entry , currentRichTextEditorForms , confirmedDelegetedUser , query , entryPage , formButtonId , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const elementRef = external_react_default().useRef(); + const formElement = generateFormElementsForEntry({ + fieldObject, + dataTypeSchema, + elementRef, + entry + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (fieldObject.dataType?.match(/text$/i) && fieldObject.richText && !fieldObject.plainText && !fieldObject.fieldName?.match(/^pass|^key$/i) && !fieldObject.encrypted || fieldObject.encrypted && fieldObject.richText) return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(TableRichTextEntryField, { + fieldObject: fieldObject, + dataTypeSchema: dataTypeSchema, + richTextEditors: richTextEditors, + currentRichTextEditorForms: currentRichTextEditorForms, + entry: entry, + entryPage: entryPage, + formButtonId: formButtonId + }) + }); + const isAceEditor = fieldObject.json || fieldObject.yaml || fieldObject.html || fieldObject.css || fieldObject.javascript || fieldObject.shell; + /** + * JSON Return + * + * @abstract Return if Datatype is JSON + */ if (fieldObject.dataType?.match(/text$/i) && isAceEditor && !fieldObject.plainText && !fieldObject.fieldName?.match(/^pass|^key$/i) && !fieldObject.encrypted || fieldObject.encrypted && isAceEditor) { + return /*#__PURE__*/ jsx_runtime_.jsx(JSONEditor, { + fieldObject: fieldObject, + dataTypeSchema: dataTypeSchema, + entry: entry, + entryPage: entryPage, + jsonTextEditors: jsonTextEditors, + type: (()=>{ + if (fieldObject.json) return "json"; + if (fieldObject.yaml) return "yaml"; + if (fieldObject.html) return "html"; + if (fieldObject.css) return "css"; + if (fieldObject.javascript) return "javascript"; + if (fieldObject.shell) return "shell"; + return "json"; + })() + }); + } + //////////////////////////////////////// + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0 w-full" + (fieldObject.defaultField ? " opacity-50" : ""), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("label", { + className: "font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2", + htmlFor: fieldObject.fieldName, + children: [ + fieldObject.encrypted && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx((LockOutlined_default()), { + fontSize: "small", + className: "opacity-50" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: fieldObject.fieldName + }), + fieldObject.defaultField && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "bg-white dark:bg-slate-900 text-primary dark:text-slate-300 font-semibold text-xs px-2 py-0.5 rounded-xs", + children: "Default Field" + }) + ] + }), + formElement + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8515: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ActiveCloneTableBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5557); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {number} [props.activeDbClone] + * @param {import("@/package-shared/types").UserType} props.user + */ function ActiveCloneTableBanner({ table , database , user , activeDbClone , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const cloneParentDb = table?.childTableDbFullName ? table.childTableDbFullName.replace(new RegExp(/datasquirel_user_\d+_/), "") : null; + const isCurrentDb = table.childTableDbFullName === database.db_full_name; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (!cloneParentDb) return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "info small green gap-1" + (database?.active_clone ? " -mt-6" : ""), + style: { + fontWeight: "500" + }, + children: [ + "This Table is an active clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}/tables/${table.childTableName}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: table.childTableName + }) + }), + " ", + "in", + " ", + isCurrentDb ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + children: [ + "this current database(", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: database.db_name + }), + ")." + ] + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: cloneParentDb + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "database." + }) + ] + }), + " ", + database?.active_clone ? "" : "Only Foreign keys and Entries can be updated." + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9922.js b/dsql-app/.local_dist/server/chunks/9922.js new file mode 100644 index 0000000..b9dba03 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9922.js @@ -0,0 +1,65 @@ +"use strict"; +exports.id = 9922; +exports.ids = [9922]; +exports.modules = { + +/***/ 9922: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ clientAuthUser) +/* harmony export */ }); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params - React ref with current value + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").UserType | {} | *>>} params.setUser - React ref with current value + * + * @requires search-field name attribute + */ function clientAuthUser({ setUser }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ let localStorageUser = localStorage.getItem("user"); + if (localStorageUser) { + try { + setUser(JSON.parse(localStorageUser)); + return; + } catch (error) { + setUser({}); + return; + } + } + /** + * Fetch User from server + * + * @description Preventdefault, declare variables + */ (0,_fetchApi__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)("/api/clientSideAuth", { + method: "post", + body: {} + }, true).then((res)=>{ + let finalUser = res.user ? res.user : {}; + setUser(finalUser); + localStorage.setItem("user", JSON.stringify(finalUser)); + // localStorage.setItem("user", JSON.stringify(res.user)); + }).catch((error)=>{ + console.log(error); + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9967.js b/dsql-app/.local_dist/server/chunks/9967.js new file mode 100644 index 0000000..4c874ea --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9967.js @@ -0,0 +1,1472 @@ +"use strict"; +exports.id = 9967; +exports.ids = [9967]; +exports.modules = { + +/***/ 9967: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ExistingFieldEdit) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _MoreOptionsModal__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4209); +/* harmony import */ var _fields_text_JSONTextOption__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4838); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>} props.setTableFields + * @param {any} props.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").UserType} props.user + * @param {React.Dispatch<React.SetStateAction<boolean>>} [props.setActiveEdit] + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + */ function ExistingFieldEdit({ targetField , fieldIndex , tableFields , setTableFields , refreshFieldsListRef , setActiveEdit , database , currentTable , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const varcharDesc = "Varchar is simply letters and numbers within the range 0 - 255"; + let defaultType = targetField?.dataType ? targetField.dataType.replace(/\d|\(|\)/g, "") : null; + let defaultDataTypeValue = targetField?.dataType ? targetField.dataType.replace(/[^\d]/g, "") : "200"; + const dataTypes = __webpack_require__(9594); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.Ref<import("@/package-shared/types").DSQL_FieldSchemaType>} */ const initialField = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(lodash__WEBPACK_IMPORTED_MODULE_4___default().cloneDeep(targetField)); + const newFieldRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + const [fieldData, setFieldData] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetField); + const [fieldName, setFieldName] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetField?.fieldName); + const [dataType, setDataType] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(defaultType); + const [dataTypeValue, setDataTypeValue] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(defaultDataTypeValue); + const [dataTypeDesc, setDataTypeDesc] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(varcharDesc); + const [isRichText, setIsRichText] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetField?.richText && !targetField?.encrypted ? "Yes" : "No"); + const isLiteral = Boolean(dataType?.match(/uuid/i)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full -mt-3 bg-white dark:bg-slate-800 flex-wrap", + // @ts-ignore + ref: newFieldRef, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + className: "flex flex-col xl:flex-row items-start gap-4 w-full justify-between border border-solid p-4 border-slate-200 dark:border-slate-600 rounded rounded-t-none focus:shadow-lg shadow-slate-700 dark:shadow-black relative flex-wrap", + onSubmit: (e)=>{ + e.preventDefault(); + setTableFields((prev)=>{ + let newArray = prev; + newArray[fieldIndex] = fieldData; + return newArray; + }); + refreshFieldsListRef.current((/** @type {any} */ prev)=>prev + 1); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + formEl.closest(".table-field-wrapper")?.querySelector(".edit-table-field-section")?.classList.toggle("hidden"); + }, + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "gap-4 flex-wrap w-full md:w-auto flex-col xl:flex-row items-stretch", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "new_field_name", + children: "Field Name" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "new_field_name", + id: "new_field_name", + placeholder: "Eg. post_title", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + inputEl.value = inputEl.value.toLowerCase().replace(/ /g, "_"); + setFieldData((prev)=>{ + let existingFieldData = prev; + existingFieldData.fieldName = inputEl.value; + existingFieldData.updatedField = true; + if (!existingFieldData.originName) existingFieldData.originName = fieldName; + return existingFieldData; + }); + }, + required: true, + defaultValue: fieldName + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-4 xl:gap-0.5", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-wrap xl:flex-nowrap w-full md:w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "new_field_data_type", + children: "Data Type" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper reversed text-sm items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex", + children: "Info" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "dropdown mt-0 xl:-mt-2", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: dataTypeDesc + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("select", { + name: "new_field_data_type", + id: "new_field_data_type", + className: "w-full xl-w-auto", + onChange: (e)=>{ + /** @type {HTMLSelectElement} */ // @ts-ignore + const selectEl = e.target; + setDataType(selectEl.value); + selectEl.childNodes.forEach((/** @type {any} */ option)=>{ + if (option.value === selectEl.value && option.dataset.desc) { + setDataTypeDesc(option.dataset.desc); + } + if (option.value === selectEl.value && option.dataset.literal) { + fieldData.defaultValueLiteral = option.dataset.literal; + fieldData.nullValue = false; + } else { + delete fieldData.defaultValueLiteral; + } + }); + targetField.dataType = selectEl.value + (selectEl.value.match(/VARCHAR/) ? `(${dataTypeValue ? dataTypeValue : 200})` : ""); + }, + defaultValue: dataType || undefined, + children: dataTypes.map((type, index)=>{ + if (type.name.match(/VARCHAR/)) { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: type.name, + "data-desc": type.description, + children: type.title + "(" + (dataTypeValue ? dataTypeValue : 200) + ")" + }, index + 1); + } else { + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: type.name, + "data-desc": type.description, + "data-literal": type.valueLiteral || undefined, + children: type.title + }, index + 1); + } + }) + }), + dataType?.match(/VARCHAR/) && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "number", + defaultValue: dataTypeValue ? dataTypeValue : 200, + className: "px-2", + style: { + maxWidth: "60px" + }, + max: 255, + min: 5, + onChange: (e)=>{ + setDataTypeValue(e.target.value); + targetField.dataType = dataType + `(${e.target.value})`; + } + }) + ] + }) + ] + }), + dataType?.match(/text/i) && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_fields_text_JSONTextOption__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + targetField: targetField + }) + }), + !targetField.dataType?.match(/text/i) && !isLiteral && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "new_field_required", + children: "Required?" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("select", { + name: "new_field_required", + id: "new_field_required", + className: "px-2", + defaultValue: targetField?.notNullValue ? "Yes" : "No", + onChange: (e)=>{ + console.log(targetField); + if (e.target.value === "Yes") { + targetField.notNullValue = true; + } else { + targetField.notNullValue = false; + delete targetField.notNullValue; + // if (!targetField?.dataType?.match(/text/i)) { + // targetField.nullValue = true; + // } + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }) + ] + }), + !isLiteral && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "new_field_default_value", + children: fieldData?.dataType?.match(/text$/i) ? "Can't Set Default for text values" : "Default Value (optional)" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "new_field_default_value", + id: "new_field_default_value", + className: fieldData?.dataType?.match(/text$/i) ? "pointer-events-none opacity-50" : "", + placeholder: "Default Value", + defaultValue: fieldData?.defaultValue ? fieldData.defaultValue : fieldData?.nullValue ? "NULL" : "", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (fieldData.dataType?.match(/text$/i)) return; + setFieldData((prev)=>{ + let newFieldData = prev; + if (inputEl.value.match(/./)) { + delete newFieldData.notNullValue; + } else { + delete newFieldData.defaultValue; + delete newFieldData.nullValue; + } + if (inputEl.value.match(/^null$/i)) { + delete newFieldData.defaultValue; + newFieldData.nullValue = true; + } else if (inputEl.value.match(/./)) { + delete newFieldData.nullValue; + newFieldData.defaultValue = inputEl.value; + } + return newFieldData; + }); + } + }) + ] + }), + !isLiteral && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_MoreOptionsModal__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + database, + setFieldData, + setTableFields, + tableFields, + targetField, + user, + currentTable, + fieldIndex + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "secondary mt-auto flex-wrap w-full xl:w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + type: "submit", + className: "secondary mt-auto py-3 w-full md:w-auto grow", + children: "Save Updates" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "button outlined gray mt-auto py-2.5 w-full md:w-auto justify-center grow", + onClick: (e)=>{ + if (initialField.current) targetField = lodash__WEBPACK_IMPORTED_MODULE_4___default().cloneDeep(initialField.current); + setTableFields((prev)=>{ + const newFields = lodash__WEBPACK_IMPORTED_MODULE_4___default().cloneDeep(prev); + if (fieldIndex && initialField.current) newFields[fieldIndex] = lodash__WEBPACK_IMPORTED_MODULE_4___default().cloneDeep(initialField.current); + return newFields; + }); + if (setActiveEdit) setActiveEdit(false); + }, + children: "Cancel" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4209: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "Z": () => (/* binding */ MoreOptionsModal) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "@mui/icons-material/Close" +var Close_ = __webpack_require__(4173); +// EXTERNAL MODULE: ./components/form/FormInput.jsx + 2 modules +var FormInput = __webpack_require__(7901); +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/admin/databases/fields/fields-inputs/CSSFiles.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {DSQL_FieldSchemaType} props.targetField - Field object + */ function CSSFiles({ targetField }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!targetField?.richText) return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ state: string[], dispatch: React.Dispatch<React.SetStateAction<string[]>> ]} */ // @ts-ignore + const [cssFiles, setCssFiles] = external_react_default().useState(targetField.cssFiles || []); + /** @type {React.Ref<HTMLInputElement | null>} */ const cssFileInputRef = external_react_default().useRef(null); + external_react_default().useEffect(()=>{ + targetField.cssFiles = cssFiles; + }, [ + cssFiles + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-2 w-full my-4", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "label text-xs text-slate-500", + children: "Add CSS" + }), + cssFiles.map((url, index)=>/*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "relative border border-solid border-slate-300 text-xs px-2 py-1 rounded-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: url + }), + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.X, { + size: 20, + onClick: ()=>{ + setCssFiles((prev)=>prev.filter((ln)=>ln !== url)); + }, + className: "cursor-pointer hover:opacity-60 " + }) + ] + }, index + 1)), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "row w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + name: "css-file", + placeholder: "CSS file URL", + elementRef: cssFileInputRef + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "secondary outlined", + onClick: ()=>{ + const url = cssFileInputRef.current?.value; + if (url?.match(/./)) { + setCssFiles((prev)=>[ + ...new Set([ + ...prev, + url + ]) + ]); + } + }, + children: "Add" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-slate-600", + children: "Add CSS files to your Rich Text field" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/fields/fields-inputs/EncryptionSelect.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let EncryptionSelect_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {DSQL_FieldSchemaType} props.targetField - Field object + * @param {React.Dispatch<React.SetStateAction<DSQL_FieldSchemaType>>} props.setFieldData - React state dispatch function + */ function EncryptionSelect({ targetField , setFieldData }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "encryption_field", + children: "Encrypt?" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "encryption_field", + id: "encryption_field", + className: "px-2", + defaultValue: targetField?.encrypted ? "Yes" : "No", + onChange: (e)=>{ + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + if (e.target.value.match(/yes/i)) { + existingFieldData.encrypted = true; + } else { + existingFieldData.encrypted = false; + delete existingFieldData.encrypted; + } + return existingFieldData; + }); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/fields/fields-inputs/ForeignKey.jsx +var ForeignKey = __webpack_require__(3699); +;// CONCATENATED MODULE: ./components/admin/databases/fields/fields-inputs/AutoIncrement.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let AutoIncrement_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {DSQL_FieldSchemaType} props.targetField - Field object + * @param {React.Dispatch<React.SetStateAction<DSQL_FieldSchemaType>>} [props.setFieldData] - React state dispatch function + */ function AutoIncrement({ targetField , setFieldData }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ return null; + if (!targetField?.dataType?.match(/int$/i)) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "encryption_field", + children: "Auto Increment?" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "encryption_field", + id: "encryption_field", + className: "px-2", + defaultValue: targetField?.autoIncrement ? "Yes" : "No", + onChange: (e)=>{ + if (targetField) { + if (e.target.value?.match(/yes/i)) { + targetField.autoIncrement = true; + } else { + delete targetField.autoIncrement; + } + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/fields/fields-inputs/RegexPattern.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let RegexPattern_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {DSQL_FieldSchemaType} props.targetField - Field object + */ function RegexPattern({ targetField }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-2 w-full", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "encryption_field", + children: "Pattern" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-slate-500", + children: 'This describes a pattern that must be matched for this field to be valid. If you add a pattern and make a db entry that doesn\'t match, the entry will be "NULL" or an empty string or the default value.' + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "Regex Pattern. Eg: '\\\\.[a-z]+'", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl?.value?.length > 0) { + targetField.pattern = inputEl.value; + } else { + delete targetField.pattern; + } + }, + defaultValue: targetField?.pattern + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + placeholder: "Regex Pattern Flags. Eg: igm", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl?.value?.length > 0) { + targetField.patternFlags = inputEl.value; + } else { + delete targetField.patternFlags; + } + }, + defaultValue: targetField?.patternFlags + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +// EXTERNAL MODULE: ./components/general/Modal.jsx +var Modal = __webpack_require__(9471); +;// CONCATENATED MODULE: ./components/admin/databases/fields/fields-inputs/UniqueFieldSelect.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField - Field object + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType>>} props.setFieldData - React state dispatch function + */ function UniqueFieldSelect({ targetField , setFieldData }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "unique_field", + children: "Unique Field?" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "unique_field", + id: "unique_field", + className: "px-2", + defaultValue: targetField?.unique ? "Yes" : "No", + onChange: (e)=>{ + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + if (e.target.value.match(/yes/i)) { + existingFieldData.unique = true; + } else { + existingFieldData.unique = false; + delete existingFieldData.unique; + } + return existingFieldData; + }); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/MoreOptionsModal.jsx +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 2 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [ExistingFieldEdit.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\ExistingFieldEdit.jsx + * `import` Statement Found in [NewFieldTemp.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\NewFieldTemp.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType>>} props.setFieldData + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} [props.tableFields] + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>} [props.setTableFields] + * @param {import("@/package-shared/types").UserType} props.user + * @param {number} props.fieldIndex + */ function MoreOptionsModal({ targetField , currentTable , database , tableFields , setTableFields , setFieldData , user , fieldIndex , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [openExtraOptions, setOpenExtraOptions] = external_react_default().useState(false); + /** @type {React.Ref<import("@/package-shared/types").DSQL_FieldSchemaType>} */ const initialField = external_react_default().useRef(external_lodash_default().cloneDeep(targetField)); + external_react_default().useEffect(()=>{}, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "button outlined gray mt-5 w-full xl:w-auto", + onClick: ()=>{ + setOpenExtraOptions(true); + }, + children: "More" + }), + /*#__PURE__*/ jsx_runtime_.jsx(Modal/* default */.Z, { + open: openExtraOptions, + onClose: ()=>{ + if (initialField.current) { + const oldTargetField = external_lodash_default().cloneDeep(initialField.current); + targetField = oldTargetField; + } + setOpenExtraOptions(false); + }, + maxWidth: "600px", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "m-auto flex flex-col max-w-xl w-full max-h-[90vh] overflow-y-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xl", + children: "More Options" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(CSSFiles, { + targetField: targetField + }), + /*#__PURE__*/ jsx_runtime_.jsx(UniqueFieldSelect, { + targetField: targetField, + setFieldData: setFieldData + }), + /*#__PURE__*/ jsx_runtime_.jsx(EncryptionSelect, { + targetField: targetField, + setFieldData: setFieldData + }), + currentTable && /*#__PURE__*/ jsx_runtime_.jsx(ForeignKey/* default */.Z, { + targetField: targetField, + setFieldData: setFieldData, + database: database, + tableFields: tableFields, + setTableFields: setTableFields, + currentTable: currentTable, + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx(AutoIncrement, { + targetField: targetField, + setFieldData: setFieldData + }), + /*#__PURE__*/ jsx_runtime_.jsx(RegexPattern, { + targetField: targetField + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full outlined more-padding", + onClick: ()=>{ + setOpenExtraOptions(false); + }, + children: "Done" + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3699: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ForeignKey) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6729); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField - DSQL schema field object + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType>>} [props.setFieldData] - React state dispatch function + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} [props.tableFields] - All Fields Array + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>} [props.setTableFields] - React state dispatch function + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database - MYSQL user_databases object + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] - MYSQL user_databases object + * @param {import("@/package-shared/types").UserType} [props.user] - User object + * @param {React.Dispatch<React.SetStateAction<boolean>>} [props.setActiveEdit] - React state dispatch function + * @param {boolean} [props.activeClonedTable] - Is table an active clone? + */ function ForeignKey({ targetField , setFieldData , tableFields , setTableFields , database , currentTable , user , setActiveEdit , activeClonedTable , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [isForeignKey, setIsForeignKey] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(targetField?.foreignKey ? true : false); + /** @type {any} */ const tablesState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type {[import("@/package-shared/types").DSQL_TableSchemaType[] | null, React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_TableSchemaType[]>>]} */ const [tables, setTables] = tablesState; + /** @type {any} */ const foreignKeyTableState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type {[import("@/package-shared/types").DSQL_TableSchemaType | null, React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_TableSchemaType>>]} */ const [foreignKeyTable, setForeignKeyTable] = foreignKeyTableState; + /** @type {any} */ const columnsState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type {[import("@/package-shared/types").DSQL_FieldSchemaType[] | null, React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>]} */ const [columns, setColumns] = columnsState; + /** @type {any} */ const foreignKeyTableColumnState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type {[import("@/package-shared/types").DSQL_FieldSchemaType | null, React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType>>]} */ const [foreignKeyTableColumn, setForeignKeyTableColumn] = foreignKeyTableColumnState; + const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (!isForeignKey && !targetField?.foreignKey) return; + // const fetchUrl =`/api/getUserSchemaData?dbSlug=${database.db_slug}${window.location.search.match("delegated=true") ? "&delegated=true" : ""}`; + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)(`/api/getUserSchemaData`).then((res)=>{ + if (res.success) { + try { + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const userSchemaData = res.schemaData; + const targetDatabase = userSchemaData.filter((db)=>db.dbFullName === database.db_full_name); + const filteredTables = currentTable ? targetDatabase[0].tables.filter((table)=>table.tableName !== currentTable.tableName) : targetDatabase[0].tables; + setTables(filteredTables); + if (targetField?.foreignKey) { + const destinationTargetTable = filteredTables.filter((table)=>table.tableName === targetField?.foreignKey?.destinationTableName); + setForeignKeyTable(destinationTargetTable[0]); + if (destinationTargetTable[0]?.fields) setColumns(destinationTargetTable[0].fields); + } + // const targetTable = targetDatabase[0].tables.filter(table => table.tableName === "") + } catch (/** @type {any} */ error) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/admin/clientError", { + method: "post", + body: { + component: "ForeignKey/fetch-error-getUserSchemaData/lines-65-77", + message: error.message, + user: user + } + }); + } + } + }); + }, [ + isForeignKey + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-2 w-full mt-2 relative", + style: { + minWidth: "70px" + }, + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("label", { + htmlFor: "foreign_key_field", + className: "flex flex-wrap items-center gap-2 mt-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Foreign Key?" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "dropdown-wrapper reversed text-sm items-start", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "px-2 bg-slate-200 rounded-full hover:bg-slate-100 hidden xl:flex text-slate-600", + children: "Info" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "dropdown mt-0 xl:-mt-2", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Foriegn key links the current table to another table" + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("select", { + name: "foreign_key_field", + id: "foreign_key_field", + className: "px-2", + defaultValue: targetField?.foreignKey ? "Yes" : "No", + onChange: (e)=>{ + if (e.target.value.match(/yes/i)) { + setIsForeignKey(true); + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + existingFieldData["foreignKey"] = { + foreignKeyName: undefined, + destinationTableName: undefined, + destinationTableColumnName: undefined, + cascadeDelete: true + }; + return existingFieldData; + }); + } + } else { + setIsForeignKey(false); + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + delete existingFieldData.foreignKey; + return existingFieldData; + }); + } + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "No", + children: "No" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "Yes", + children: "Yes" + }) + ] + }), + isForeignKey && tables && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("select", { + name: "foreign_key_destination_table_name", + id: "foreign_key_destination_table_name", + className: "px-2", + defaultValue: targetField?.foreignKey?.destinationTableName ? targetField.foreignKey.destinationTableName : undefined, + onChange: (e)=>{ + /** @type {HTMLSelectElement} */ const selectEl = e.target; + if (e.target.value?.match(/--/)) { + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + /** @type {import("@/package-shared/types").DSQL_ForeignKeyType|undefined} */ const targetForeignKey = existingFieldData.foreignKey; + if (targetForeignKey) targetForeignKey.destinationTableName = undefined; + return existingFieldData; + }); + } else { + selectEl.dataset.destinationTableName = undefined; + } + return; + } + const targetTable = tables.filter((tb)=>tb.tableName === e.target.value)[0]; + setForeignKeyTable(targetTable); + if (targetTable?.fields) setColumns(targetTable.fields); + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + /** @type {import("@/package-shared/types").DSQL_ForeignKeyType|undefined} */ const targetForeignKey = existingFieldData.foreignKey; + if (targetForeignKey) targetForeignKey.destinationTableName = e.target.value; + return existingFieldData; + }); + } else { + e.target.dataset.destinationTableName = e.target.value; + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "--", + children: "--Select Table--" + }), + tables.map((table, index)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: table.tableName, + children: table.tableFullName + }, index + 1); + }) + ] + }) + }), + foreignKeyTable && columns && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("select", { + name: "foreign_key_destination_table_column_name", + id: "foreign_key_destination_table_column_name", + className: "px-2", + defaultValue: targetField?.foreignKey?.destinationTableColumnName ? targetField.foreignKey.destinationTableColumnName : undefined, + onChange: (e)=>{ + try { + const targetColumn = columns.filter((column)=>column.fieldName === e.target.value)[0]; + setForeignKeyTableColumn(targetColumn); + if (e.target.value?.match(/--/)) { + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + /** @type {import("@/package-shared/types").DSQL_ForeignKeyType|undefined} */ const targetForeignKey = existingFieldData.foreignKey; + if (targetForeignKey) targetForeignKey.destinationTableColumnName = undefined; + return existingFieldData; + }); + } + return; + } + const keyName = `dsql_${database.user_id}_${database.db_slug}_${Date.now()}`; + if (setFieldData) { + setFieldData((prev)=>{ + let existingFieldData = prev; + existingFieldData.dataType = targetColumn.dataType; + /** @type {import("@/package-shared/types").DSQL_ForeignKeyType|undefined} */ const targetForeignKey = existingFieldData.foreignKey; + if (targetForeignKey) { + targetForeignKey.destinationTableColumnName = targetColumn.fieldName; + targetForeignKey.destinationTableColumnType = targetColumn.dataType; + targetForeignKey.foreignKeyName = keyName; + } + return existingFieldData; + }); + } else { + e.target.dataset.dataType = targetColumn.dataType; + e.target.dataset.destinationTableColumnName = targetColumn.fieldName; + // e.target.dataset.foreignKeyName = `dsql_${user.id}_${tableName}_table_${targetField?.fieldName ? targetField.fieldName : "{{__tmp_field_name}}"}_${foreignKeyTable.tableName}_${targetColumn.fieldName}_ref`; + e.target.dataset.foreignKeyName = keyName; + } + } catch (/** @type {any} */ error) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/admin/clientError", { + method: "post", + body: { + component: "ForeignKey/lines-232-264", + message: error.message, + user: user + } + }); + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "--", + children: "--Select Column--" + }), + columns.map((field, index)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: field.fieldName, + children: field.fieldName + }, index + 1); + }) + ] + }), + activeClonedTable && foreignKeyTableColumn && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "secondary w-full", + onClick: (e)=>{ + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)("/api/updateClonedTableForeignKeys", { + method: "post", + body: { + tableData: currentTable, + database: database.db_full_name, + dbSlug: database.db_slug, + delegated: window.location?.search?.match(/delegated=true/i) ? true : false + } + }, true).then((res)=>{ + if (res.success) { + window.alert("Foreign Key Added Successfully!"); + } else { + window.alert("Update Failed, Please Try again."); + } + setTimeout(()=>{ + if (setActiveEdit) setActiveEdit(false); + }, 1000); + }); + }, + children: "Add Foreign Key" + }) + ] + }), + activeClonedTable && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "light-gray w-full", + onClick: (e)=>{ + delete targetField.foreignKey; + setActiveEdit && setActiveEdit(false); + }, + children: "Cancel" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4838: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ JSONTextOption) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField - Field object + */ function JSONTextOption({ targetField }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "rich_text_option", + children: "Text Type" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("select", { + name: "rich_text_option", + id: "rich_text_option", + className: "px-2", + onChange: (e)=>{ + delete targetField.json; + delete targetField.richText; + delete targetField.yaml; + delete targetField.html; + delete targetField.javascript; + delete targetField.shell; + switch(e.target.value){ + case "plain": + break; + case "rte": + targetField.richText = true; + break; + case "json": + targetField.json = true; + break; + case "yaml": + targetField.yaml = true; + break; + case "html": + targetField.html = true; + break; + case "css": + targetField.css = true; + break; + case "javascript": + targetField.javascript = true; + break; + case "shell": + targetField.shell = true; + break; + default: + break; + } + }, + defaultValue: (()=>{ + if (targetField.richText) return "rte"; + if (targetField.json) return "json"; + if (targetField.yaml) return "yaml"; + if (targetField.html) return "html"; + if (targetField.javascript) return "javascript"; + if (targetField.shell) return "shell"; + if (targetField.css) return "css"; + return "plain"; + })(), + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "plain", + children: "Plain Text" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "rte", + children: "Rich Text" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "json", + children: "JSON" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "yaml", + children: "YAML" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "html", + children: "HTML" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "css", + children: "CSS" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "javascript", + children: "Javascript" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("option", { + value: "shell", + children: "Shell" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/9971.js b/dsql-app/.local_dist/server/chunks/9971.js new file mode 100644 index 0000000..a8bf815 --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/9971.js @@ -0,0 +1,231 @@ +exports.id = 9971; +exports.ids = [9971]; +exports.modules = { + +/***/ 6069: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +"use strict"; +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +const { hashPassword , } = __webpack_require__(5382); +const serverError = __webpack_require__(2163); +const httpsRequest = __webpack_require__(722); +const DB_HANDLER = __webpack_require__(2224); +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * + * @typedef {object} GithubUserPayload + * @property {string} login - Full name merged eg. "JohnDoe" + * @property {number} id - github user id + * @property {string} node_id - Some other id + * @property {string} avatar_url - profile picture + * @property {string} gravatar_id - some other id + * @property {string} url - Github user URL + * @property {string} html_url - User html URL - whatever that means + * @property {string} followers_url - Followers URL + * @property {string} following_url - Following URL + * @property {string} gists_url - Gists URL + * @property {string} starred_url - Starred URL + * @property {string} subscriptions_url - Subscriptions URL + * @property {string} organizations_url - Organizations URL + * @property {string} repos_url - Repositories URL + * @property {string} received_events_url - Received Events URL + * @property {string} type - Common value => "User" + * @property {boolean} site_admin - Is site admin or not? Boolean + * @property {string} name - More like "username" + * @property {string} company - User company + * @property {string} blog - User blog URL + * @property {string} location - User Location + * @property {string} email - User Email + * @property {string} hireable - Is user hireable + * @property {string} bio - User bio + * @property {string} twitter_username - User twitter username + * @property {number} public_repos - Number of public repositories + * @property {number} public_gists - Number of public gists + * @property {number} followers - Number of followers + * @property {number} following - Number of following + * @property {string} created_at - Date created + * @property {string} updated_at - Date updated + */ /** + * Login/signup a github user + * ============================================================================== + * @async + * + * @param {Object} params - foundUser if any + * @param {string} params.code - github auth token + * @param {string} params.clientId - github client Id + * @param {string} params.clientSecret - github client Secret + * + * @returns {Promise<GithubUserPayload|null|undefined>} + */ module.exports = async function githubLogin({ code , clientId , clientSecret }) { + /** @type {GithubUserPayload | undefined} */ let gitHubUser; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ // const response = await fetch(`https://github.com/login/oauth/access_token?client_id=${process.env.DSQL_GITHUB_ID}`); + const response = await httpsRequest({ + method: "POST", + hostname: "github.com", + path: `/login/oauth/access_token?client_id=${clientId}&client_secret=${clientSecret}&code=${code}`, + headers: { + Accept: "application/json", + "User-Agent": "*" + }, + scheme: "https" + }); + // `https://github.com/login/oauth/access_token?client_id=${process.env.DSQL_GITHUB_ID}&client_secret=${process.env.DSQL_GITHUB_SECRET}&code=${code}`, + // body: JSON.stringify({ + // client_id: process.env.DSQL_GITHUB_ID, + // client_secret: process.env.DSQL_GITHUB_SECRET, + // code: code, + // }), + const accessTokenObject = JSON.parse(response); + if (!accessTokenObject?.access_token) { + return gitHubUser; + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const userDataResponse = await httpsRequest({ + method: "GET", + hostname: "api.github.com", + path: "/user", + headers: { + Authorization: `Bearer ${accessTokenObject.access_token}`, + "User-Agent": "*" + }, + scheme: "https" + }); + gitHubUser = JSON.parse(userDataResponse); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (!gitHubUser?.email && gitHubUser) { + const existingGithubUser = await DB_HANDLER(`SELECT email FROM users WHERE social_login='1' AND social_platform='github' AND social_id='${gitHubUser.id}'`); + if (existingGithubUser && existingGithubUser[0]) { + gitHubUser.email = existingGithubUser[0].email; + } + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + console.log("ERROR in githubLogin.js backend function =>", error.message); + // serverError({ + // component: "/api/social-login/github-auth/catch-error", + // message: error.message, + // user: user, + // }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + return gitHubUser; +}; + + +/***/ }), + +/***/ 5382: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +// @ts-check +const { createHmac } = __webpack_require__(6113); +// +/** + * # Password Hash function + * @param {string} password + * @returns + */ function hashPassword(password) { + const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD || ""); + hmac.update(password); + let hashed = hmac.digest("base64"); + return hashed; +} +exports.hashPassword = hashPassword; // export const comparePasswords = async (password) => { + // const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD); + // hmac.update(password); + // let hashed = hmac.digest("base64"); + // let dbPass = await global.DB_HANDLER(`SELECT * FROM users WHERE password = '${hashed}'`); + // console.log(dbPass); + // return dbPass; + // }; + + +/***/ }), + +/***/ 2127: +/***/ ((module) => { + +"use strict"; +// @ts-check +/** + * Convert Camel Joined Text to Camel Spaced Text + * ============================================================================== + * @description this function takes a camel cased text without spaces, and returns + * a camel-case-spaced text + * + * @param {string} text - text string without spaces + * + * @returns {string | null} + */ +module.exports = function camelJoinedtoCamelSpace(text) { + if (!text?.match(/./)) { + return ""; + } + if (text?.match(/ /)) { + return text; + } + if (text) { + let textArray = text.split(""); + let capIndexes = []; + for(let i = 0; i < textArray.length; i++){ + const char = textArray[i]; + if (i === 0) continue; + if (char.match(/[A-Z]/)) { + capIndexes.push(i); + } + } + let textChunks = [ + `${textArray[0].toUpperCase()}${text.substring(1, capIndexes[0])}`, + ]; + for(let j = 0; j < capIndexes.length; j++){ + const capIndex = capIndexes[j]; + if (capIndex === 0) continue; + const startIndex = capIndex + 1; + const endIndex = capIndexes[j + 1]; + textChunks.push(`${textArray[capIndex].toUpperCase()}${text.substring(startIndex, endIndex)}`); + } + return textChunks.join(" "); + } else { + return null; + } +}; + + +/***/ }) + +}; +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/chunks/font-manifest.json b/dsql-app/.local_dist/server/chunks/font-manifest.json new file mode 100644 index 0000000..048107a --- /dev/null +++ b/dsql-app/.local_dist/server/chunks/font-manifest.json @@ -0,0 +1,14 @@ +[ + { + "url": "https://fonts.googleapis.com/css?family=Poppins", + "content": "@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + }, + { + "url": "https://fonts.googleapis.com/css?family=Inter", + "content": "@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + }, + { + "url": "https://fonts.googleapis.com/css?family=IBM+Plex+Mono", + "content": "@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + } +] \ No newline at end of file diff --git a/dsql-app/.local_dist/server/font-manifest.json b/dsql-app/.local_dist/server/font-manifest.json new file mode 100644 index 0000000..048107a --- /dev/null +++ b/dsql-app/.local_dist/server/font-manifest.json @@ -0,0 +1,14 @@ +[ + { + "url": "https://fonts.googleapis.com/css?family=Poppins", + "content": "@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + }, + { + "url": "https://fonts.googleapis.com/css?family=Inter", + "content": "@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + }, + { + "url": "https://fonts.googleapis.com/css?family=IBM+Plex+Mono", + "content": "@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}" + } +] \ No newline at end of file diff --git a/dsql-app/.local_dist/server/middleware-build-manifest.js b/dsql-app/.local_dist/server/middleware-build-manifest.js new file mode 100644 index 0000000..4c0a7ce --- /dev/null +++ b/dsql-app/.local_dist/server/middleware-build-manifest.js @@ -0,0 +1 @@ +self.__BUILD_MANIFEST={polyfillFiles:["static/chunks/polyfills-c67a75d1b6f99dc8.js"],devFiles:[],ampDevFiles:[],lowPriorityFiles:["static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js","static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js"],rootMainFiles:[],pages:{"/":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/3935-eea593fa60dfd620.js","static/css/65efe10b506f9812.css","static/chunks/pages/index-c2ab88c2111475dd.js"],"/404":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/404-d04d8d42f75218d9.js"],"/500":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/500-7db225cc6b4dea2c.js"],"/_app":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/css/c83c1473ba7928cd.css","static/chunks/pages/_app-881c4f419bb13dab.js"],"/_error":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/_error-f2496e8b9fdedb89.js"],"/about":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/3935-eea593fa60dfd620.js","static/chunks/pages/about-76deaa37497c062c.js"],"/admin":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/3181-e628e642754b0f35.js","static/chunks/5667-9e7b94f8ce529764.js","static/chunks/pages/admin-81e2733c0d783481.js"],"/admin/[user_id]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/3181-e628e642754b0f35.js","static/chunks/5667-9e7b94f8ce529764.js","static/chunks/pages/admin/[user_id]-e36cc5d13c2aa929.js"],"/admin/[user_id]/api-keys":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/pages/admin/[user_id]/api-keys-ad926df40536b287.js"],"/admin/[user_id]/connect":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/pages/admin/[user_id]/connect-8973f4ea35b17adf.js"],"/admin/[user_id]/databases":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/3181-e628e642754b0f35.js","static/chunks/pages/admin/[user_id]/databases-2ede91ae9bfe108a.js"],"/admin/[user_id]/databases/[single]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/pages/admin/[user_id]/databases/[single]-35266a148b439139.js"],"/admin/[user_id]/databases/[single]/connect":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/pages/admin/[user_id]/databases/[single]/connect-6fe32fdcf255139c.js"],"/admin/[user_id]/databases/[single]/edit-database":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/9967-c027b915261dae19.js","static/chunks/8887-5917115e54cd417b.js","static/chunks/pages/admin/[user_id]/databases/[single]/edit-database-a60b50dd21c29ae2.js"],"/admin/[user_id]/databases/[single]/schema":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/8473-1a1faf3d4d34beef.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9967-c027b915261dae19.js","static/chunks/8887-5917115e54cd417b.js","static/chunks/7200-4c384098300f07db.js","static/chunks/pages/admin/[user_id]/databases/[single]/schema-7b76b5c228e273d4.js"],"/admin/[user_id]/databases/[single]/shell":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/3795-b7a314b891092ea4.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/pages/admin/[user_id]/databases/[single]/shell-cb2910aa3bd12a22.js"],"/admin/[user_id]/databases/[single]/tables":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables-512e452212994e35.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/94726e6d-f5320de901b4c44f.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/9572-f67b1194a0e6ae72.js","static/chunks/1502-965711da5f99a5c8.js","static/chunks/8446-a36a685092b53a06.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9967-c027b915261dae19.js","static/chunks/4893-e30c16360c86c67d.js","static/chunks/9788-84477f8e20625988.js","static/chunks/9035-b11038b244e852f0.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]-0d9a8a82c8b584d3.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/94726e6d-f5320de901b4c44f.js","static/chunks/9572-f67b1194a0e6ae72.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9967-c027b915261dae19.js","static/chunks/4893-e30c16360c86c67d.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table-4d03eae9a64fe6a7.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/1502-965711da5f99a5c8.js","static/chunks/8446-a36a685092b53a06.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9788-84477f8e20625988.js","static/chunks/9035-b11038b244e852f0.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries-3a14a471d2dc7b00.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/1502-965711da5f99a5c8.js","static/chunks/8446-a36a685092b53a06.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9788-84477f8e20625988.js","static/chunks/9035-b11038b244e852f0.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]-a15e553c68e1ca23.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/1502-965711da5f99a5c8.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9788-84477f8e20625988.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry-0ecd226005afec57.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/fields":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/94726e6d-f5320de901b4c44f.js","static/chunks/9572-f67b1194a0e6ae72.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9967-c027b915261dae19.js","static/chunks/4893-e30c16360c86c67d.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields-ab993bc50ce1e800.js"],"/admin/[user_id]/databases/[single]/tables/add-table":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/94726e6d-f5320de901b4c44f.js","static/chunks/9572-f67b1194a0e6ae72.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/9967-c027b915261dae19.js","static/chunks/4893-e30c16360c86c67d.js","static/chunks/pages/admin/[user_id]/databases/[single]/tables/add-table-09cebcb0b429f6de.js"],"/admin/[user_id]/databases/[single]/users":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/5949-b1c68b62cd5dbfee.js","static/chunks/pages/admin/[user_id]/databases/[single]/users-0afdf841aae9f757.js"],"/admin/[user_id]/databases/[single]/users/[user]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/2870-8e302171aed920f8.js","static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]-f7cdffc0b0c094c6.js"],"/admin/[user_id]/databases/[single]/users/[user]/change-password":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]/change-password-21db218c89054e75.js"],"/admin/[user_id]/databases/[single]/users/add-social-logins":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/2870-8e302171aed920f8.js","static/chunks/9719-14cc8b76a1deed3c.js","static/chunks/pages/admin/[user_id]/databases/[single]/users/add-social-logins-3e4d353e902f53ae.js"],"/admin/[user_id]/databases/[single]/users/add-user":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/2870-8e302171aed920f8.js","static/chunks/9719-14cc8b76a1deed3c.js","static/chunks/pages/admin/[user_id]/databases/[single]/users/add-user-36cc73c2fdadfc25.js"],"/admin/[user_id]/databases/add-database":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/9967-c027b915261dae19.js","static/chunks/8887-5917115e54cd417b.js","static/chunks/pages/admin/[user_id]/databases/add-database-e3a5509e700b0e80.js"],"/admin/[user_id]/media":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/4156-a7c42d729046e9bc.js","static/chunks/pages/admin/[user_id]/media-922d349166d14d18.js"],"/admin/[user_id]/media/[...folder]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/4156-a7c42d729046e9bc.js","static/chunks/pages/admin/[user_id]/media/[...folder]-773d7108b2688df4.js"],"/admin/[user_id]/schema":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/8473-1a1faf3d4d34beef.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7200-4c384098300f07db.js","static/chunks/pages/admin/[user_id]/schema-d264203c84a34e72.js"],"/admin/[user_id]/settings":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/9967-c027b915261dae19.js","static/chunks/3181-e628e642754b0f35.js","static/chunks/8374-f28680e628b18bd5.js","static/chunks/5667-9e7b94f8ce529764.js","static/chunks/5114-a70f18877cc7f8bc.js","static/chunks/pages/admin/[user_id]/settings-7a69db8bd70bed09.js"],"/admin/[user_id]/users":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/5949-b1c68b62cd5dbfee.js","static/chunks/pages/admin/[user_id]/users-8b4f68a1fd38c9b3.js"],"/admin/[user_id]/users/add-user":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/pages/admin/[user_id]/users/add-user-c50fb941e687320a.js"],"/admin/[user_id]/users/databases":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/5949-b1c68b62cd5dbfee.js","static/chunks/pages/admin/[user_id]/users/databases-ee8daf5a492656f7.js"],"/admin/[user_id]/users/databases/[database]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/5949-b1c68b62cd5dbfee.js","static/chunks/pages/admin/[user_id]/users/databases/[database]-28052313a8523fc1.js"],"/admin/[user_id]/users/databases/[database]/[user]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/9365-101d5c9d637cef9a.js","static/chunks/2870-8e302171aed920f8.js","static/chunks/pages/admin/[user_id]/users/databases/[database]/[user]-1922bb43b40f7cbb.js"],"/blog":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/blog-be6db5dd2389f8c4.js"],"/contact":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/contact-513427eea0db408d.js"],"/create-account":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/8374-f28680e628b18bd5.js","static/chunks/5114-a70f18877cc7f8bc.js","static/chunks/pages/create-account-c97da041b7809649.js"],"/docs":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/docs-de42203d30b1880d.js"],"/docs/[page]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/docs/[page]-3602862f9a9542f8.js"],"/docs/[page]/[sub-page]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/docs/[page]/[sub-page]-b3641ae1942e2312.js"],"/email-verification":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/email-verification-2643dd10f1b54d59.js"],"/login":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/8374-f28680e628b18bd5.js","static/chunks/pages/login-5453e8ec28f13db7.js"],"/logout":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/logout-043abd512c88b3d5.js"],"/pricing":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/pricing-e193043fd895ccd5.js"],"/privacy":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/privacy-6a6371ab4eda9c15.js"],"/redirect":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/redirect-f189e8f0d6ae1482.js"],"/reset-password":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/pages/reset-password-a754110c3b3e20fb.js"],"/send-password-reset-link":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/send-password-reset-link-62def12808387ec7.js"],"/su":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/3695-c03f5685e1b79345.js","static/chunks/pages/su-0929bdda8a625d2f.js"],"/su/backups":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/pages/su/backups-4a9e96c30acc4626.js"],"/su/console":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/ed150ef9-713e0b995a8779c6.js","static/chunks/493-ec86d71e0fece010.js","static/chunks/5313-e7700a25826b1c4d.js","static/css/85fa6dafca566008.css","static/chunks/pages/su/console-46c6d0d0303e04b9.js"],"/su/docs":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/5622-0b01b71a2de3acf8.js","static/chunks/pages/su/docs-b48cfe163578ba42.js"],"/su/docs/create-page":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/2452-ed265b549204d978.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/2378-3a97fbefe0f48bac.js","static/chunks/pages/su/docs/create-page-9be0d237216b00cd.js"],"/su/docs/edit-page":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/2452-ed265b549204d978.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/2378-3a97fbefe0f48bac.js","static/chunks/pages/su/docs/edit-page-4892c3a874c645b3.js"],"/su/docs/pages":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/5622-0b01b71a2de3acf8.js","static/chunks/pages/su/docs/pages-5eee4e47bc092505.js"],"/su/docs/pages/[id]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/2452-ed265b549204d978.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/2378-3a97fbefe0f48bac.js","static/chunks/pages/su/docs/pages/[id]-abedeaddb98ac372.js"],"/su/envar":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/pages/su/envar-42f3065b06c71be8.js"],"/su/error-logs":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/3695-c03f5685e1b79345.js","static/chunks/pages/su/error-logs-5c9265bc2ac8176f.js"],"/su/login":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/su/login-522c70b6952cc65b.js"],"/su/users":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/pages/su/users-464900047fbc0228.js"],"/su/users/[single]":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/8473-1a1faf3d4d34beef.js","static/chunks/3795-b7a314b891092ea4.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/pages/su/users/[single]-65b1051395f52052.js"],"/su/users/new":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/pages/su/users/new-6cf4001cfdd2ec66.js"],"/terms":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/terms-da8c5b5b6b17b132.js"],"/unsubscribe":["static/chunks/webpack-309fbebe2073f18c.js","static/chunks/framework-4ed89e9640adfb9e.js","static/chunks/main-fd9fe2eccf11c307.js","static/chunks/pages/unsubscribe-b9517fbaaacff29b.js"]},ampFirstPages:[]}; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/middleware-manifest.json b/dsql-app/.local_dist/server/middleware-manifest.json new file mode 100644 index 0000000..57712aa --- /dev/null +++ b/dsql-app/.local_dist/server/middleware-manifest.json @@ -0,0 +1,6 @@ +{ + "sortedMiddleware": [], + "middleware": {}, + "functions": {}, + "version": 2 +} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/middleware-react-loadable-manifest.js b/dsql-app/.local_dist/server/middleware-react-loadable-manifest.js new file mode 100644 index 0000000..bebba06 --- /dev/null +++ b/dsql-app/.local_dist/server/middleware-react-loadable-manifest.js @@ -0,0 +1 @@ +self.__REACT_LOADABLE_MANIFEST={}; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages-manifest.json b/dsql-app/.local_dist/server/pages-manifest.json new file mode 100644 index 0000000..f597922 --- /dev/null +++ b/dsql-app/.local_dist/server/pages-manifest.json @@ -0,0 +1,192 @@ +{ + "/_app": "pages/_app.js", + "/_error": "pages/_error.js", + "/_document": "pages/_document.js", + "/404": "pages/404.html", + "/500": "pages/500.html", + "/api/acceptUserInvitation": "pages/api/acceptUserInvitation.js", + "/api/addAdminUserUser": "pages/api/addAdminUserUser.js", + "/api/addApiKey": "pages/api/addApiKey.js", + "/api/addDbUser": "pages/api/addDbUser.js", + "/api/addNewMediaFolder": "pages/api/addNewMediaFolder.js", + "/api/addSocialLogin": "pages/api/addSocialLogin.js", + "/api/addTableEntry": "pages/api/addTableEntry.js", + "/api/addUserTable": "pages/api/addUserTable.js", + "/api/admin/clearErrorLogs": "pages/api/admin/clearErrorLogs.js", + "/api/addUserUser": "pages/api/addUserUser.js", + "/api/admin/clientError": "pages/api/admin/clientError.js", + "/api/admin/addUserBackup": "pages/api/admin/addUserBackup.js", + "/api/admin/createNewBackup": "pages/api/admin/createNewBackup.js", + "/api/admin/docs/[action]": "pages/api/admin/docs/[action].js", + "/api/addUsersTableToDatabase": "pages/api/addUsersTableToDatabase.js", + "/api/admin/getUserBackups": "pages/api/admin/getUserBackups.js", + "/api/admin/getUserData": "pages/api/admin/getUserData.js", + "/api/admin/getTablesForUserDatabase": "pages/api/admin/getTablesForUserDatabase.js", + "/api/admin/grabErrorLogs": "pages/api/admin/grabErrorLogs.js", + "/api/admin/grabBackups": "pages/api/admin/grabBackups.js", + "/api/admin/loginSuUser": "pages/api/admin/loginSuUser.js", + "/api/admin/grabFile": "pages/api/admin/grabFile.js", + "/api/admin/runUserDbQuery": "pages/api/admin/runUserDbQuery.js", + "/api/changeDbUserPassword": "pages/api/changeDbUserPassword.js", + "/api/admin/updateEnv": "pages/api/admin/updateEnv.js", + "/api/checkDuplicateData": "pages/api/checkDuplicateData.js", + "/api/clientSideAuth": "pages/api/clientSideAuth.js", + "/api/checkExistingFolder": "pages/api/checkExistingFolder.js", + "/api/connect/disconnect": "pages/api/connect/disconnect.js", + "/api/connect/handshake": "pages/api/connect/handshake.js", + "/api/connect/verify": "pages/api/connect/verify.js", + "/api/connect": "pages/api/connect.js", + "/api/contact": "pages/api/contact.js", + "/api/deleteApiKey": "pages/api/deleteApiKey.js", + "/api/createUserDatabase": "pages/api/createUserDatabase.js", + "/api/deleteDbUser": "pages/api/deleteDbUser.js", + "/api/deleteInvitation": "pages/api/deleteInvitation.js", + "/api/deleteMediaFolder": "pages/api/deleteMediaFolder.js", + "/api/deleteUser": "pages/api/deleteUser.js", + "/api/deleteTableEntry": "pages/api/deleteTableEntry.js", + "/api/deleteUserDatabase": "pages/api/deleteUserDatabase.js", + "/api/deleteUserMedia": "pages/api/deleteUserMedia.js", + "/api/deleteUserTable": "pages/api/deleteUserTable.js", + "/api/deleteUserUser": "pages/api/deleteUserUser.js", + "/api/exportDatabase": "pages/api/exportDatabase.js", + "/api/downloadDatabaseSchema": "pages/api/downloadDatabaseSchema.js", + "/api/get-authorized-databases": "pages/api/get-authorized-databases.js", + "/api/fetch-entries-basic": "pages/api/fetch-entries-basic.js", + "/api/getDatabaseTables": "pages/api/getDatabaseTables.js", + "/api/getDelegatedDatabaseToken": "pages/api/getDelegatedDatabaseToken.js", + "/api/getDiskUsage": "pages/api/getDiskUsage.js", + "/api/getUserDatabases": "pages/api/getUserDatabases.js", + "/api/getDelegatedDatabases": "pages/api/getDelegatedDatabases.js", + "/api/getUserMedia": "pages/api/getUserMedia.js", + "/api/getUserDatabaseTables": "pages/api/getUserDatabaseTables.js", + "/api/getUserSchemaData": "pages/api/getUserSchemaData.js", + "/api/healthcheck": "pages/api/healthcheck.js", + "/api/importDatabaseSchema": "pages/api/importDatabaseSchema.js", + "/api/importDatabase": "pages/api/importDatabase.js", + "/api/infiniteScroll": "pages/api/infiniteScroll.js", + "/api/media/addPrivateMedia": "pages/api/media/addPrivateMedia.js", + "/api/logoutUser": "pages/api/logoutUser.js", + "/api/purgeDb": "pages/api/purgeDb.js", + "/api/media/getPrivateMedia": "pages/api/media/getPrivateMedia.js", + "/api/query/get-schema": "pages/api/query/get-schema.js", + "/api/query/get": "pages/api/query/get.js", + "/api/queryEntriesSearchTerm": "pages/api/queryEntriesSearchTerm.js", + "/api/reAuthenticateUser": "pages/api/reAuthenticateUser.js", + "/api/loginUser": "pages/api/loginUser.js", + "/api/query/update-schema-from-single-database": "pages/api/query/update-schema-from-single-database.js", + "/api/refreshEntry": "pages/api/refreshEntry.js", + "/api/registerUser": "pages/api/registerUser.js", + "/api/renameMedia": "pages/api/renameMedia.js", + "/api/resetDelegatedDatabaseToken": "pages/api/resetDelegatedDatabaseToken.js", + "/api/resetPassword": "pages/api/resetPassword.js", + "/api/runUserDbQuery": "pages/api/runUserDbQuery.js", + "/api/sendEmailVerificationLink": "pages/api/sendEmailVerificationLink.js", + "/api/sendPasswordResetLink": "pages/api/sendPasswordResetLink.js", + "/api/social-login/facebook-auth": "pages/api/social-login/facebook-auth.js", + "/api/social-login/github-auth": "pages/api/social-login/github-auth.js", + "/api/social-login/google-auth": "pages/api/social-login/google-auth.js", + "/api/social-login/utils/checkSocialId": "pages/api/social-login/utils/checkSocialId.js", + "/api/social-login/utils/getEmailFromSocialId": "pages/api/social-login/utils/getEmailFromSocialId.js", + "/api/social-login/utils/checkEmail": "pages/api/social-login/utils/checkEmail.js", + "/api/sql-users/delete": "pages/api/sql-users/delete.js", + "/api/sql-users/create": "pages/api/sql-users/create.js", + "/api/sql-users/update": "pages/api/sql-users/update.js", + "/api/stream/[path]": "pages/api/stream/[path].js", + "/api/sync-table-data": "pages/api/sync-table-data.js", + "/api/test/cors": "pages/api/test/cors.js", + "/api/test/mail": "pages/api/test/mail.js", + "/api/unsubscribe": "pages/api/unsubscribe.js", + "/api/updateAdminUserAccess": "pages/api/updateAdminUserAccess.js", + "/api/updateClonedTableForeignKeys": "pages/api/updateClonedTableForeignKeys.js", + "/api/updateDbSchemaDataForUser": "pages/api/updateDbSchemaDataForUser.js", + "/api/updateDbUser": "pages/api/updateDbUser.js", + "/api/updateTableEntry": "pages/api/updateTableEntry.js", + "/api/updateUserDatabase": "pages/api/updateUserDatabase.js", + "/api/updateUserUser": "pages/api/updateUserUser.js", + "/api/updateUser": "pages/api/updateUser.js", + "/api/updateUserTable": "pages/api/updateUserTable.js", + "/api/user/delete-user": "pages/api/user/delete-user.js", + "/api/user-schema/replace-database-schema": "pages/api/user-schema/replace-database-schema.js", + "/api/user/add-user": "pages/api/user/add-user.js", + "/api/user/get-user": "pages/api/user/get-user.js", + "/api/user/github-login": "pages/api/user/github-login.js", + "/api/user/google-login": "pages/api/user/google-login.js", + "/api/user/grab-google-user-from-token": "pages/api/user/grab-google-user-from-token.js", + "/api/user/login-user": "pages/api/user/login-user.js", + "/api/user/reauth-user": "pages/api/user/reauth-user.js", + "/api/user/update-user": "pages/api/user/update-user.js", + "/api/user/send-email-code": "pages/api/user/send-email-code.js", + "/api/webhooks/github-push": "pages/api/webhooks/github-push.js", + "/": "pages/index.html", + "/privacy": "pages/privacy.html", + "/redirect": "pages/redirect.html", + "/terms": "pages/terms.html", + "/admin/[user_id]/api-keys": "pages/admin/[user_id]/api-keys.js", + "/about": "pages/about.html", + "/admin/[user_id]/databases/[single]/edit-database": "pages/admin/[user_id]/databases/[single]/edit-database.js", + "/admin/[user_id]/databases/[single]": "pages/admin/[user_id]/databases/[single].js", + "/admin/[user_id]/databases/[single]/shell": "pages/admin/[user_id]/databases/[single]/shell.js", + "/admin/[user_id]/databases/[single]/connect": "pages/admin/[user_id]/databases/[single]/connect.js", + "/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table": "pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js", + "/admin/[user_id]/connect": "pages/admin/[user_id]/connect.js", + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry": "pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js", + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]": "pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js", + "/admin/[user_id]/databases/[single]/tables/[single_table]/fields": "pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js", + "/admin/[user_id]/databases/[single]/tables/[single_table]/entries": "pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js", + "/admin/[user_id]/databases/[single]/tables/[single_table]": "pages/admin/[user_id]/databases/[single]/tables/[single_table].js", + "/admin/[user_id]/databases/[single]/tables/add-table": "pages/admin/[user_id]/databases/[single]/tables/add-table.js", + "/admin/[user_id]/databases/[single]/users/[user]/change-password": "pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js", + "/admin/[user_id]/databases/[single]/tables": "pages/admin/[user_id]/databases/[single]/tables.js", + "/admin/[user_id]/databases/[single]/users/add-social-logins": "pages/admin/[user_id]/databases/[single]/users/add-social-logins.js", + "/admin/[user_id]/databases/[single]/users/[user]": "pages/admin/[user_id]/databases/[single]/users/[user].js", + "/admin/[user_id]/databases/[single]/users/add-user": "pages/admin/[user_id]/databases/[single]/users/add-user.js", + "/admin/[user_id]/databases/[single]/users": "pages/admin/[user_id]/databases/[single]/users.js", + "/admin/[user_id]/databases": "pages/admin/[user_id]/databases.js", + "/admin/[user_id]/databases/add-database": "pages/admin/[user_id]/databases/add-database.js", + "/admin/[user_id]": "pages/admin/[user_id].js", + "/admin/[user_id]/schema": "pages/admin/[user_id]/schema.js", + "/admin/[user_id]/databases/[single]/schema": "pages/admin/[user_id]/databases/[single]/schema.js", + "/admin/[user_id]/media": "pages/admin/[user_id]/media.js", + "/admin/[user_id]/media/[...folder]": "pages/admin/[user_id]/media/[...folder].js", + "/admin/[user_id]/settings": "pages/admin/[user_id]/settings.js", + "/admin/[user_id]/users/databases/[database]/[user]": "pages/admin/[user_id]/users/databases/[database]/[user].js", + "/admin/[user_id]/users/add-user": "pages/admin/[user_id]/users/add-user.js", + "/admin/[user_id]/users/databases/[database]": "pages/admin/[user_id]/users/databases/[database].js", + "/admin": "pages/admin.js", + "/admin/[user_id]/users/databases": "pages/admin/[user_id]/users/databases.js", + "/api/exportTableData": "pages/api/exportTableData.js", + "/admin/[user_id]/users": "pages/admin/[user_id]/users.js", + "/api/query/add-file": "pages/api/query/add-file.js", + "/api/addUserMedia": "pages/api/addUserMedia.js", + "/api/query/add-image": "pages/api/query/add-image.js", + "/api/query/delete-file": "pages/api/query/delete-file.js", + "/api/query/get-private-file": "pages/api/query/get-private-file.js", + "/api/query/post": "pages/api/query/post.js", + "/blog": "pages/blog.html", + "/contact": "pages/contact.html", + "/docs": "pages/docs.js", + "/create-account": "pages/create-account.js", + "/docs/[page]": "pages/docs/[page].js", + "/docs/[page]/[sub-page]": "pages/docs/[page]/[sub-page].js", + "/login": "pages/login.js", + "/pricing": "pages/pricing.html", + "/email-verification": "pages/email-verification.js", + "/su/console": "pages/su/console.js", + "/logout": "pages/logout.js", + "/su/backups": "pages/su/backups.js", + "/send-password-reset-link": "pages/send-password-reset-link.js", + "/su/docs/create-page": "pages/su/docs/create-page.js", + "/reset-password": "pages/reset-password.js", + "/su/docs/edit-page": "pages/su/docs/edit-page.js", + "/su/docs": "pages/su/docs.js", + "/su/docs/pages": "pages/su/docs/pages.js", + "/su/envar": "pages/su/envar.js", + "/su": "pages/su.js", + "/su/error-logs": "pages/su/error-logs.js", + "/su/docs/pages/[id]": "pages/su/docs/pages/[id].js", + "/su/users": "pages/su/users.js", + "/su/users/[single]": "pages/su/users/[single].js", + "/su/users/new": "pages/su/users/new.js", + "/su/login": "pages/su/login.js", + "/unsubscribe": "pages/unsubscribe.js" +} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/404.html b/dsql-app/.local_dist/server/pages/404.html new file mode 100644 index 0000000..d1a572b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/404.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/404-d04d8d42f75218d9.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/404","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/404.js.nft.json b/dsql-app/.local_dist/server/pages/404.js.nft.json new file mode 100644 index 0000000..c6cdfd1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/404.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/RailwayAlertTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/500.html b/dsql-app/.local_dist/server/pages/500.html new file mode 100644 index 0000000..dd9f508 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/500.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/500-7db225cc6b4dea2c.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/500","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/500.js.nft.json b/dsql-app/.local_dist/server/pages/500.js.nft.json new file mode 100644 index 0000000..3e76c01 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/500.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_app.js b/dsql-app/.local_dist/server/pages/_app.js new file mode 100644 index 0000000..69f1919 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_app.js @@ -0,0 +1,300 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2888; +exports.ids = [2888]; +exports.modules = { + +/***/ 7218: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ DataSquirel) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./node_modules/next/script.js +var script = __webpack_require__(4298); +var script_default = /*#__PURE__*/__webpack_require__.n(script); +// EXTERNAL MODULE: external "next/head" +var head_ = __webpack_require__(968); +var head_default = /*#__PURE__*/__webpack_require__.n(head_); +// EXTERNAL MODULE: external "@mui/material/styles" +var styles_ = __webpack_require__(8442); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./layouts/GeneralLayout.jsx + 1 modules +var GeneralLayout = __webpack_require__(6217); +// EXTERNAL MODULE: ./components/general/PageHeadTags.jsx +var PageHeadTags = __webpack_require__(4097); +;// CONCATENATED MODULE: ./components/ErrorBoundary.jsx +// @ts-check + + + + + +class ErrorBoundary extends (external_react_default()).Component { + constructor(/** @type {any} */ props){ + super(props); + // Define a state variable to track whether is an error or not + this.state = { + hasError: false + }; + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Error | Datasquirel"; + const pageDescription = "Datasquirel is a fast and efficient cloud-based SQL data management system that takes away the entire hassle of dealing with data both locally and across different platforms."; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx(PageHeadTags/* default */.Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + // @ts-ignore + this.state.head = head; + } + static getDerivedStateFromError() { + return { + hasError: true + }; + } + componentDidCatch(/** @type {any} */ error, /** @type {any} */ errorInfo) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "ErrorBoundary-class-component", + message: error.message + " ==== Error Info => " + errorInfo, + user: {} + } + }); + } + render() { + // Check if the error is thrown + if (this.state.hasError) { + // You can render any custom fallback UI + return /*#__PURE__*/ jsx_runtime_.jsx(GeneralLayout/* default */.Z, { + // @ts-ignore + head: this.state.head, + user: null, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper items-center px-20", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-base text-slate-400 m-0", + children: "Application Error!" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-2xl m-0 mb-4", + children: "Please try again!" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/", + className: "button outlined", + children: "Home" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + window.history.back(); + }, + children: "Go Back" + }) + ] + }) + ] + }) + }); + } + // Return children components in case of no error + return this.props.children; + } +} +/* harmony default export */ const components_ErrorBoundary = (ErrorBoundary); + +;// CONCATENATED MODULE: ./functions/theme.js +// @ts-check + +const theme = (0,styles_.createTheme)({ + typography: { + fontFamily: "inherit", + fontSize: 14 + }, + palette: { + primary: { + main: "#00948a" + }, + secondary: { + main: "#107ab8" + }, + light: { + main: "#c48ff0" + }, + white: { + main: "#ffffff" + }, + grey: { + // @ts-ignore + main: "#64748b" + }, + gray: { + main: "#64748b" + }, + dark: { + main: "#1e293b" + } + } +}); +/* harmony default export */ const functions_theme = (theme); + +;// CONCATENATED MODULE: ./pages/_app.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +// import "../styles/main.css"; + + + + +// require()(); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * App Component + * ============================================================================== + * @param {import("next/app").AppProps} props + */ function DataSquirel({ Component , pageProps }) { + /** + * React Hooks + * + * @description { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((head_default()), { + children: /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "viewport", + content: "width=device-width, initial-scale=1" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(components_ErrorBoundary, { + children: /*#__PURE__*/ jsx_runtime_.jsx(styles_.ThemeProvider, { + theme: functions_theme, + children: /*#__PURE__*/ jsx_runtime_.jsx(Component, { + ...pageProps + }) + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx((script_default()), { + src: "/scripts/main.js", + strategy: "afterInteractive" + }) + ] + }); +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8442: +/***/ ((module) => { + +module.exports = require("@mui/material/styles"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 2796: +/***/ ((module) => { + +module.exports = require("next/dist/shared/lib/head-manager-context.js"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4298,4017,8313,5264,6729,5449,913,9360,6217,4097], () => (__webpack_exec__(7218))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_app.js.nft.json b/dsql-app/.local_dist/server/pages/_app.js.nft.json new file mode 100644 index 0000000..ecfa10c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_app.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4298.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/@mui/material/styles/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/material/node/styles/index.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createStyles.js","../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useTheme.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../node_modules/@mui/material/node/styles/withStyles.js","../../../node_modules/@mui/material/node/styles/withTheme.js","../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_document.js b/dsql-app/.local_dist/server/pages/_document.js new file mode 100644 index 0000000..e9bf052 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_document.js @@ -0,0 +1,229 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 660; +exports.ids = [660]; +exports.modules = { + +/***/ 4065: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Document) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var next_document__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6859); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function Document(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(next_document__WEBPACK_IMPORTED_MODULE_2__.Html, { + lang: "en", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(next_document__WEBPACK_IMPORTED_MODULE_2__.Head, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "author", + content: "Datasquirel" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "Copyright", + content: `Copyright (c) ${new Date().getFullYear()} Datasquirel` + }), + "dev_dev"?.match(/dev/) && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "robots", + content: "noindex,nofollow" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "preconnect", + href: "https://fonts.googleapis.com/", + crossOrigin: "anonymous" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "preconnect", + href: "https://fonts.gstatic.com", + crossOrigin: "anonymous" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "stylesheet", + href: "https://fonts.googleapis.com/css?family=Poppins" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "stylesheet", + href: "https://fonts.googleapis.com/css?family=Inter" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "stylesheet", + href: "https://fonts.googleapis.com/css?family=IBM+Plex+Mono" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "/scripts/themeSelector.js" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + httpEquiv: "Content-Type", + content: "text/html; charset=UTF-8" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:site_name", + content: "DATASQUIREL" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:type", + content: "website" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "twitter:card", + content: "summary" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + property: "og:image", + content: "https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + itemProp: "image", + content: "https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "twitter:image", + content: "https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", { + rel: "stylesheet", + href: "/styles/prism.css" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "/scripts/prism.js", + async: true + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + dangerouslySetInnerHTML: { + __html: "var DSQL = {}" + } + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("body", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(next_document__WEBPACK_IMPORTED_MODULE_2__.Main, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(next_document__WEBPACK_IMPORTED_MODULE_2__.NextScript, {}) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4140: +/***/ ((module) => { + +module.exports = require("next/dist/server/get-page-files.js"); + +/***/ }), + +/***/ 9716: +/***/ ((module) => { + +module.exports = require("next/dist/server/htmlescape.js"); + +/***/ }), + +/***/ 6368: +/***/ ((module) => { + +module.exports = require("next/dist/server/utils.js"); + +/***/ }), + +/***/ 6724: +/***/ ((module) => { + +module.exports = require("next/dist/shared/lib/constants.js"); + +/***/ }), + +/***/ 8743: +/***/ ((module) => { + +module.exports = require("next/dist/shared/lib/html-context.js"); + +/***/ }), + +/***/ 8524: +/***/ ((module) => { + +module.exports = require("next/dist/shared/lib/is-plain-object.js"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [6859], () => (__webpack_exec__(4065))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_document.js.nft.json b/dsql-app/.local_dist/server/pages/_document.js.nft.json new file mode 100644 index 0000000..20f649c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_document.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/6859.js","../../package.json","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/constants.js","../../../node_modules/next/dist/shared/lib/html-context.js","../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../node_modules/next/dist/server/get-page-files.js","../../../node_modules/next/dist/server/utils.js","../../../node_modules/next/dist/server/htmlescape.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js","../../../node_modules/next/dist/shared/lib/page-path/normalize-page-path.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js","../../../node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/next/dist/shared/lib/router/utils/index.js","../../../node_modules/next/dist/shared/lib/router/utils/sorted-routes.js","../../../node_modules/next/dist/shared/lib/router/utils/is-dynamic.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_error.js b/dsql-app/.local_dist/server/pages/_error.js new file mode 100644 index 0000000..bd0b3fe --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_error.js @@ -0,0 +1,148 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4820; +exports.ids = [4820]; +exports.modules = { + +/***/ 2648: +/***/ ((__unused_webpack_module, exports) => { + +var __webpack_unused_export__; + +__webpack_unused_export__ = ({ + value: true +}); +exports.Z = _interopRequireDefault; +function _interopRequireDefault(obj) { + return obj && obj.__esModule ? obj : { + default: obj + }; +} + + +/***/ }), + +/***/ 9185: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + + +Object.defineProperty(exports, "__esModule", ({ + value: true +})); +exports["default"] = void 0; +var _interop_require_default = (__webpack_require__(2648)/* ["default"] */ .Z); +var _react = _interop_require_default(__webpack_require__(6689)); +var _head = _interop_require_default(__webpack_require__(4957)); +const statusCodes = { + 400: "Bad Request", + 404: "This page could not be found", + 405: "Method Not Allowed", + 500: "Internal Server Error" +}; +function _getInitialProps({ res , err }) { + const statusCode = res && res.statusCode ? res.statusCode : err ? err.statusCode : 404; + return { + statusCode + }; +} +const styles = { + error: { + fontFamily: '-apple-system, BlinkMacSystemFont, Roboto, "Segoe UI", "Fira Sans", Avenir, "Helvetica Neue", "Lucida Grande", sans-serif', + height: "100vh", + textAlign: "center", + display: "flex", + flexDirection: "column", + alignItems: "center", + justifyContent: "center" + }, + desc: { + display: "inline-block", + textAlign: "left", + lineHeight: "49px", + height: "49px", + verticalAlign: "middle" + }, + h1: { + display: "inline-block", + margin: 0, + marginRight: "20px", + padding: "0 23px 0 0", + fontSize: "24px", + fontWeight: 500, + verticalAlign: "top", + lineHeight: "49px" + }, + h2: { + fontSize: "14px", + fontWeight: "normal", + lineHeight: "49px", + margin: 0, + padding: 0 + } +}; +var _Component; +class Error extends (_Component = _react.default.Component) { + render() { + const { statusCode , withDarkMode =true } = this.props; + const title = this.props.title || statusCodes[statusCode] || "An unexpected error has occurred"; + return /*#__PURE__*/ _react.default.createElement("div", { + style: styles.error + }, /*#__PURE__*/ _react.default.createElement(_head.default, null, /*#__PURE__*/ _react.default.createElement("title", null, statusCode ? `${statusCode}: ${title}` : "Application error: a client-side exception has occurred")), /*#__PURE__*/ _react.default.createElement("div", null, /*#__PURE__*/ _react.default.createElement("style", { + dangerouslySetInnerHTML: { + __html: ` + body { margin: 0; color: #000; background: #fff; } + .next-error-h1 { + border-right: 1px solid rgba(0, 0, 0, .3); + } + + ${withDarkMode ? `@media (prefers-color-scheme: dark) { + body { color: #fff; background: #000; } + .next-error-h1 { + border-right: 1px solid rgba(255, 255, 255, .3); + } + }` : ""}` + } + }), statusCode ? /*#__PURE__*/ _react.default.createElement("h1", { + className: "next-error-h1", + style: styles.h1 + }, statusCode) : null, /*#__PURE__*/ _react.default.createElement("div", { + style: styles.desc + }, /*#__PURE__*/ _react.default.createElement("h2", { + style: styles.h2 + }, this.props.title || statusCode ? title : /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, "Application error: a client-side exception has occurred (see the browser console for more information)"), ".")))); + } +} +Error.displayName = "ErrorPage"; +Error.getInitialProps = _getInitialProps; +Error.origGetInitialProps = _getInitialProps; +exports["default"] = Error; //# sourceMappingURL=_error.js.map + + +/***/ }), + +/***/ 4957: +/***/ ((module) => { + +module.exports = require("next/dist/shared/lib/head.js"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = (__webpack_exec__(9185)); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/_error.js.nft.json b/dsql-app/.local_dist/server/pages/_error.js.nft.json new file mode 100644 index 0000000..bbbb90e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/_error.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../../package.json","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/about.html b/dsql-app/.local_dist/server/pages/about.html new file mode 100644 index 0000000..22e02f6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/about.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/3935-eea593fa60dfd620.js" defer=""></script><script src="/_next/static/chunks/pages/about-76deaa37497c062c.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/about","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/about.js.nft.json b/dsql-app/.local_dist/server/pages/about.js.nft.json new file mode 100644 index 0000000..26d8c4b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/about.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/8095.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/ArticleTwoTone.js","../../../node_modules/@mui/icons-material/CloudDoneTwoTone.js","../../../node_modules/@mui/icons-material/ThumbUpAltTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin.js b/dsql-app/.local_dist/server/pages/admin.js new file mode 100644 index 0000000..394a234 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin.js @@ -0,0 +1,346 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6964; +exports.ids = [6964,133,4135]; +exports.modules = { + +/***/ 1174: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "DashboardContext": () => (/* binding */ DashboardContext), +/* harmony export */ "default": () => (/* binding */ Dashboard), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4858); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _components_admin_dashboard_DashboardContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8124); +/* harmony import */ var _components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5012); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DashboardContextType} */ let DashboardContextObject = {}; +const DashboardContext = /*#__PURE__*/ react__WEBPACK_IMPORTED_MODULE_1___default().createContext(DashboardContextObject); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases - Server props + * @param {import("@/package-shared/types").MetricsType} props.metrics - Server props + */ function Dashboard({ user , databases , metrics }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {*} */ const targetDbState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type { [ targetDatabase: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type | undefined, setTargetDatabase: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_MYSQL_user_databases_Type>> ] } */ const [targetDatabase, setTargetDatabase] = targetDbState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_AdminLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(DashboardContext.Provider, { + value: { + user, + databases, + targetDatabase, + setTargetDatabase, + metrics + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_dashboard_DashboardContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_admin_databases_DeleteDatabaseConfirmationPopup__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + targetDatabase: targetDatabase + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + return { + redirect: { + destination: `/admin/${user.id}`, + permanent: false + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,7946,1500,75,9282,7926], () => (__webpack_exec__(1174))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin.js.nft.json b/dsql-app/.local_dist/server/pages/admin.js.nft.json new file mode 100644 index 0000000..416f2a5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/424.js","../chunks/4858.js","../chunks/5472.js","../chunks/7946.js","../chunks/1500.js","../chunks/75.js","../chunks/9282.js","../chunks/7926.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id].js b/dsql-app/.local_dist/server/pages/admin/[user_id].js new file mode 100644 index 0000000..ca0f5d8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id].js @@ -0,0 +1,207 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4135; +exports.ids = [4135,133]; +exports.modules = { + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,7946,1500,75,9282,7926], () => (__webpack_exec__(1457))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id].js.nft.json new file mode 100644 index 0000000..bfd3182 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5449.js","../../chunks/5304.js","../../chunks/913.js","../../chunks/9395.js","../../chunks/370.js","../../chunks/424.js","../../chunks/4858.js","../../chunks/5472.js","../../chunks/7946.js","../../chunks/1500.js","../../chunks/75.js","../../chunks/9282.js","../../chunks/7926.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/mysql/index.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js new file mode 100644 index 0000000..45b978c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js @@ -0,0 +1,1027 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6057; +exports.ids = [6057]; +exports.modules = { + +/***/ 3406: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "ApiKeysContext": () => (/* binding */ ApiKeysContext), + "default": () => (/* binding */ Dashboard), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/VerificationBanner.jsx +var VerificationBanner = __webpack_require__(7946); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +;// CONCATENATED MODULE: ./components/admin/api-keys/ApiKeyListCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").ApiKeyDef} props.apiKeyObject + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").ApiKeyDef>>} props.setTargetApiKey + */ function ApiKeyListCard({ apiKeyObject , setTargetApiKey }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover justify-between items-center" + (apiKeyObject.scope.match(/fullAccess/) ? " green" : ""), + onClick: (e)=>{ + // @ts-ignore + if (e.target?.closest("button")) return; + setTargetApiKey(apiKeyObject); + (0,GeneralPopup/* openPopup */.Mw)("target-media-popup"); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "text-sm flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: apiKeyObject.scope.match(/readOnly/) ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "notification" + }) : apiKeyObject.scope.match(/fullAccess/) ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "notification success" + }) : "No Scope" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "title text-xl", + style: { + fontSize: "16px" + }, + children: apiKeyObject.name + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-slate-400 ", + children: [ + "Created: ", + apiKeyObject.date_created.substring(0, 24) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined light-gray small-text", + onClick: (e)=>{ + alert(apiKeyObject.apiKeyPayload); + }, + children: "Reveal Api Key" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined light-gray small-text", + onClick: (e)=>{ + // document.execCommand("copy", false, apiKeyObject.apiKeyPayload); + navigator.clipboard.writeText(apiKeyObject.apiKeyPayload).then(()=>{ + alert("Api Key Copied To Clipboard"); + }); + }, + children: "Copy Api Key" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined light-gray small-text" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + setLoading(true); + if (window.confirm(`Delete this Api Key?`)) { + (0,fetchApi/* default */.Z)("/api/deleteApiKey", { + method: "post", + body: apiKeyObject + }, true).then((res)=>{}).finally(()=>{ + window.location.reload(); + }); + } else { + setLoading(false); + } + }, + children: "Delete Api Key" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: external "@mui/icons-material/HttpsTwoTone" +const HttpsTwoTone_namespaceObject = require("@mui/icons-material/HttpsTwoTone"); +var HttpsTwoTone_default = /*#__PURE__*/__webpack_require__.n(HttpsTwoTone_namespaceObject); +;// CONCATENATED MODULE: ./components/admin/api-keys/ApiKeysList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {import("@/package-shared/types").ApiKeyDef[]} props.apiKeys + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").ApiKeyDef>>} props.setTargetApiKey + */ function ApiKeysList({ user , apiKeys , setTargetApiKey }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "p-0 items-start gap-4 overflow-visible bg-transparent border-transparent", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex-col items-stretch gap-4", + children: apiKeys && apiKeys[0] && apiKeys.map((apiKeyObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(ApiKeyListCard, { + apiKeyObject: apiKeyObject, + setTargetApiKey: setTargetApiKey + }, index); + }) + }), + !apiKeys || !apiKeys[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray dashed w-full p-10 flex-col", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("add-new-api-key-popup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "No Api Keys Added." + }), + /*#__PURE__*/ jsx_runtime_.jsx((HttpsTwoTone_default()), { + color: "action", + sx: { + fontSize: 80 + }, + className: "opacity-40" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Add Api Key" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/api-keys/ApiKeysContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function ApiKeysContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , apiKeys , setApiKeys , setTargetApiKey } = external_react_default().useContext(ApiKeysContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Api Keys" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex items-center gap-2", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("add-new-api-key-popup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Api Key" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ jsx_runtime_.jsx(ApiKeysList, { + apiKeys: apiKeys, + setTargetApiKey: setTargetApiKey, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(VerificationBanner/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/api-keys/TargetApiKeyPreviewPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").ApiKeyDef} props.targetApiKey + */ function TargetApiKeyPreviewPopup({ targetApiKey }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(GeneralPopup/* default */.ZP, { + title: "target-api-key-preview-popup", + noContainer: true, + fullPage: true, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + targetApiKey && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Target Api Key" + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/checkUniqueField.js +var checkUniqueField = __webpack_require__(4105); +;// CONCATENATED MODULE: ./components/admin/api-keys/AddNewApiKeyPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ var timeout; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {*} [props.targetApiKey] + */ function AddNewApiKeyPopup({ targetApiKey }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ async function checkDuplicateSlug(/** @type {string} */ value) { + const duplicate = await (0,checkUniqueField/* default */.Z)({ + tableName: "api_keys", + columnName: "slug", + value: value + }); + return duplicate; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [alert, setAlert] = external_react_default().useState(/** @type {string | null} */ null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(GeneralPopup/* default */.ZP, { + title: "add-new-api-key-popup", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h4", { + className: "m-0", + children: "Add New Api Key" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-stretch gap-2", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement | *} */ const formElement = e.target; + const api_key_name = formElement["api_key_name"].value; + const api_key_slug = formElement["api_key_slug"].value; + const api_key_scope = formElement["api_key_scope"].value; + /** @type {import("@/package-shared/types").AddApiKeyRequestBody} */ const formBody = { + api_key_name, + api_key_slug, + api_key_scope, + target_database: formElement["target_database"]?.value || undefined, + target_table: formElement["target_table"]?.value || undefined + }; + (0,fetchApi/* default */.Z)("/api/addApiKey", { + method: "post", + body: formBody + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + setTimeout(()=>{ + setLoading(false); + }, 2000); + } + }); + }, + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: alert + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "api_key_name", + children: "Api Key Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "api_key_name", + id: "api_key_name", + placeholder: "Api Key Name", + onInput: (e)=>{ + /** @type {HTMLInputElement | *} */ const inputarget = e.target; + if (inputarget) { + inputarget.closest("form")["api_key_slug"].value = inputarget.value.toLowerCase().replace(/ /g, "_").replace(/[^a-zA-Z0-9-_]/g, ""); + } + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "api_key_slug", + children: "Api Key Slug" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "api_key_slug", + id: "api_key_slug", + placeholder: "Api Key Slug", + onInput: (e)=>{ + /** @type {HTMLInputElement & *} */ const inputarget = e.target; + if (inputarget?.value.match(/./)) { + inputarget?.classList.remove("warning"); + setAlert(null); + } else { + inputarget?.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + checkDuplicateSlug(inputarget.value).then((res)=>{ + if (res.result) { + inputarget?.classList.add("warning"); + // @ts-ignore + setAlert("Duplicate Table Name"); + } else { + inputarget?.classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "api_key_scope", + children: "Api Scope" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper reversed", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 py-1 bg-slate-100 rounded-full text-xs font-semibold", + children: "Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown always left-aligned -ml-10 -mb-2", + style: { + minWidth: "300px" + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-2 text-sm leading-snug", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Scope is the range of access the API Key can have" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("ul", { + className: "ml-0 pl-4 flex flex-col gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("li", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "Read Only:" + }), + " Can only read from databases" + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("li", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "Full Access:" + }), + " Can read and Write to databases" + ] + }) + }) + ] + }) + ] + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "api_key_scope", + id: "api_key_scope", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "readOnly", + children: "Read Only" + }), + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "fullAccess", + children: "Full Access" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "target_database", + children: "Target Databases" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "target_database", + id: "target_database", + placeholder: "Target Databases (optional). Comma Separated" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "target_table", + children: "Target Tables" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "target_table", + id: "target_table", + placeholder: "Target Tables (optional). Comma Separated" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: loading ? " pointer-events-none opacity-40" : "", + children: "Create New Api Key" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./package-shared/functions/backend/decrypt.js +var decrypt = __webpack_require__(5304); +var decrypt_default = /*#__PURE__*/__webpack_require__.n(decrypt); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/api-keys/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").ApiKeysContextType} */ // @ts-ignore +const init = {}; +const ApiKeysContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any[]} props.fetchedApiKeys + */ function Dashboard({ user , fetchedApiKeys }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Api Keys | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [apiKeys, setApiKeys] = external_react_default().useState(fetchedApiKeys); + const [newApiKey, setNewApiKey] = external_react_default().useState(null); + const [targetApiKey, setTargetApiKey] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ApiKeysContext.Provider, { + value: { + user, + apiKeys, + setApiKeys, + targetApiKey, + setTargetApiKey, + newApiKey, + setNewApiKey + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(ApiKeysContent, {}), + targetApiKey && /*#__PURE__*/ jsx_runtime_.jsx(TargetApiKeyPreviewPopup, { + targetApiKey: targetApiKey + }), + /*#__PURE__*/ jsx_runtime_.jsx(AddNewApiKeyPopup, {}) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const apiKeys = await DB_HANDLER_default()(`SELECT * FROM api_keys WHERE user_id='${user.id}'`); + let apiKeysWithPayloads = []; + if (apiKeys && apiKeys[0]) { + for(let i = 0; i < apiKeys.length; i++){ + const apiKey = apiKeys[i]; + const apiKeyPayload = decrypt_default()(apiKey.key); + apiKeysWithPayloads.push({ + ...apiKey, + apiKeyPayload + }); + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + fetchedApiKeys: apiKeysWithPayloads + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,7946,4105], () => (__webpack_exec__(3406))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js.nft.json new file mode 100644 index 0000000..f88d004 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/api-keys.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../chunks/7946.js","../../../chunks/4105.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/HttpsTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js new file mode 100644 index 0000000..ba01d4d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js @@ -0,0 +1,1559 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3095; +exports.ids = [3095]; +exports.modules = { + +/***/ 5782: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "ConnectContext": () => (/* binding */ ConnectContext), + "default": () => (/* binding */ DatabaseSchema), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +;// CONCATENATED MODULE: external "@mui/icons-material/ContentCopyOutlined" +const ContentCopyOutlined_namespaceObject = require("@mui/icons-material/ContentCopyOutlined"); +var ContentCopyOutlined_default = /*#__PURE__*/__webpack_require__.n(ContentCopyOutlined_namespaceObject); +;// CONCATENATED MODULE: external "@mui/icons-material/SystemUpdateAltOutlined" +const SystemUpdateAltOutlined_namespaceObject = require("@mui/icons-material/SystemUpdateAltOutlined"); +var SystemUpdateAltOutlined_default = /*#__PURE__*/__webpack_require__.n(SystemUpdateAltOutlined_namespaceObject); +;// CONCATENATED MODULE: ./components/admin/connect/ConnectionInfo.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function ConnectionInfo(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , query , mariadbUserCred } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "You can connect to your database remotely using any MySQL/Mariadb client. Use these credentials to connect:" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("ul", { + className: "m-0", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Server:", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "172.72.0.32" || 0 + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Username: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: mariadbUserCred.mariadb_user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Host: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: mariadbUserCred.mariadb_host + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Password: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "*****************" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ghost inline-block -my-4", + onClick: (e)=>{ + navigator.clipboard.writeText(mariadbUserCred.mariadb_pass || "").then(()=>{ + window.alert("Copied Password!"); + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((ContentCopyOutlined_default()), {}) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("li", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex", + children: [ + "SSL Certificate:", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "flex items-center gap-2", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: "https://datasquirel.com/documents/ssl/ca-cert.pem", + className: "flex items-center gap-2 border-none hover:opacity-60", + target: "_blank", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((SystemUpdateAltOutlined_default()), { + className: "-mt-[3px]" + }), + "Download" + ] + }) + }) + }) + ] + }) + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: external "@mui/icons-material/EditNoteOutlined" +const EditNoteOutlined_namespaceObject = require("@mui/icons-material/EditNoteOutlined"); +var EditNoteOutlined_default = /*#__PURE__*/__webpack_require__.n(EditNoteOutlined_namespaceObject); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/DeleteOutlineOutlined" +var DeleteOutlineOutlined_ = __webpack_require__(8757); +var DeleteOutlineOutlined_default = /*#__PURE__*/__webpack_require__.n(DeleteOutlineOutlined_); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/admin/connect/MariaDBUserCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").MYSQL_mariadb_users_table_def} props.mariadbUser + */ function MariaDBUserCard({ mariadbUser }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { setTargetMariadbUser } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isPrimary = String(mariadbUser.primary)?.match(/1/) ? true : false; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card w-full col" + (isPrimary ? " green" : ""), + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "25px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between h-auto md:h-8 flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "title", + children: [ + mariadbUser.username, + "@", + mariadbUser.host + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + isPrimary && /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "info small w-auto", + children: "Primary User" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ghost", + title: "Edit User", + onClick: (e)=>{ + setTargetMariadbUser(mariadbUser); + (0,GeneralPopup/* openPopup */.Mw)("edit-mariadb-user-popup"); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((EditNoteOutlined_default()), {}) + }), + !isPrimary && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ghost -ml-6", + title: "Edit User", + onClick: (e)=>{ + if (window.confirm("Are you sure you want to delete this User?")) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/sql-users/delete", { + method: "POST", + body: { + id: mariadbUser.id + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else if (res.msg) { + window.alert(res.msg); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((DeleteOutlineOutlined_default()), {}) + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("ul", { + className: "m-0", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Username: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: mariadbUser.username + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Host: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: mariadbUser.host + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "info gray font-normal", + children: "% is a wildcard. Example: 192.168.1.%" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("li", { + children: [ + "Password: ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "*****************" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ghost inline-block -my-4", + onClick: (e)=>{ + navigator.clipboard.writeText(mariadbUser.password || "").then(()=>{ + window.alert("Copied Password!"); + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx((ContentCopyOutlined_default()), { + className: "text-[15px] -ml-2" + }) + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/MariaDBUsers.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function MariaDBUsers(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { mariadbUsers } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "SQL Users" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("new-mariadb-user-popup"); + }, + children: "Add SQL User" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "You can customize your SQL users and permissions here. You can add up to 10 hosts/IP addresses (including your primary host)" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "grid w-full grid-cols-1 xl:grid-cols-2 gap-6", + children: mariadbUsers.map((mdbUser, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(MariaDBUserCard, { + mariadbUser: mdbUser + }, index + 1); + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/ConnectContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function ConnectContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , query , mariadbUserCred } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "", + children: /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Connect" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(ConnectionInfo, {}), + /*#__PURE__*/ jsx_runtime_.jsx(MariaDBUsers, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/MariDBUserFormGrantsSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {Object} APIDatabase + * @property {string | number} id + * @property {string} db_full_name + * @property {string} db_name + * @property {string} db_slug + */ /** + * @typedef {Object} APITable + * @property {string | number} id + * @property {string} table_name + * @property {string} table_slug + */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/shell/mariadb-users/handleGrants").GrantType[]} props.grants + * @param {React.Dispatch<React.SetStateAction<import("@/shell/mariadb-users/handleGrants").GrantType[]>> } props.setGrants + * @param {boolean} [props.edit] + */ function MariDBUserFormGrantsSection({ grants , setGrants , edit , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , targetMariadbUser } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ /** @type {import("@/shell/mariadb-users/handleGrants").GrantType[]} */ const grantsArray = []; + /** @type {string[]} */ const permissionsArray = [ + "ALL PRIVILEGES", + "ALTER", + "ALTER ROUTINE", + "CREATE", + "CREATE ROUTINE", + "CREATE TEMPORARY TABLES", + "CREATE VIEW", + "DELETE", + "DROP", + "EVENT", + "EXECUTE", + "FILE", + "INDEX", + "INSERT", + "LOCK TABLES", + "PROCESS", + "REFERENCES", + "RELOAD", + "REPLICATION CLIENT", + "REPLICATION SLAVE", + "SELECT", + "SHOW VIEW", + "SUPER", + "TRIGGER", + "UPDATE", + "USAGE", + ]; + const isPrimary = Boolean(String(targetMariadbUser?.primary).match(/1/)) && edit; + const isAllDatabasesGranted = Boolean(grants.find((grant)=>grant.database == "*")); + const isAllTablesGranted = Boolean(grants.find((grant)=>grant.table == "*")); + const isPrivilegesGranted = Boolean(grants.find((grant)=>grant.privileges.includes("ALL PRIVILEGES"))); + const isAllGranted = isAllDatabasesGranted && isAllTablesGranted && isPrivilegesGranted; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ state: APIDatabase[], dispatch: React.Dispatch<React.SetStateAction<APIDatabase[]>> ]} */ // @ts-ignore + const [databases, setDatabases] = external_react_default().useState([]); + /** @type {[ state: APIDatabase, dispatch: React.Dispatch<React.SetStateAction<APIDatabase>> ]} */ // @ts-ignore + const [targetDatabase, setTargetDatabase] = external_react_default().useState({}); + /** @type {[ state: APITable[], dispatch: React.Dispatch<React.SetStateAction<APITable[]>> ]} */ // @ts-ignore + const [tables, setTables] = external_react_default().useState([]); + /** @type {[ state: APITable, dispatch: React.Dispatch<React.SetStateAction<APITable>> ]} */ // @ts-ignore + const [targetTable, setTargetTable] = external_react_default().useState({}); + const [permissions, setPermissions] = external_react_default().useState([ + "ALL PRIVILEGES" + ]); + /** @type {[ state: string, dispatch: React.Dispatch<React.SetStateAction<string>> ]} */ // @ts-ignore + const [targetPermission, setTargetPermission] = external_react_default().useState("ALL PRIVILEGES"); + const [newGrant, setNewGrant] = external_react_default().useState(false); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/getUserDatabases").then((res)=>{ + if (res.databases) { + setDatabases(res.databases); + } + }); + }, []); + external_react_default().useEffect(()=>{ + if (!targetDatabase?.id) return; + (0,fetchApi/* default */.Z)(`/api/getUserDatabaseTables?dbId=${targetDatabase.id}`).then((res)=>{ + if (res.tables) { + setTables(res.tables); + } + }); + }, [ + targetDatabase + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + id: "grant-select-block", + className: "flex flex-col items-stretch w-full p-6 border border-slate-200 border-solid rounded", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h4", { + className: "m-0 text-lg", + children: "Grants" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "This section determines fine grained access of this user to databases and tables" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-wrap", + children: grants?.[0] ? grants.map((grant, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "text-sm pr-10 bg-secondary text-white px-3 py-2 rounded flex-wrap relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: grant.privileges + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "=" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + " ", + grant.database.replace(/datasquirel_user_\d+_/, "") + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "." + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: grant.table + }), + !isPrimary && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button white absolute top-1.5 right-1.5 p-2 w-6 h-6", + onClick: (e)=>{ + const newGrants = [ + ...grants + ]; + newGrants.splice(index, 1); + setGrants(newGrants); + }, + children: "x" + }) + ] + }); + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400 px-4 py-2 bg-slate-100 w-full flex items-center justify-center", + children: "No Grants" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + isAllGranted ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-slate-500", + children: 'All Privileges have been granted! Delete "ALL PRIVILEGES on *.*" to add fine-grained privileges' + }) : newGrant ? /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, { + children: isPrimary ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Primary users have full control over all databases." + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "grants-database", + children: "Database" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "grants-database", + id: "grants-database", + className: "text-sm", + onChange: (e)=>{ + const selectedDatabase = e.target.value; + if (selectedDatabase == "NULL") { + return; + } + const selectedDatabaseObject = databases.find((db)=>db.db_full_name == selectedDatabase); + if (selectedDatabaseObject) { + setTargetDatabase(selectedDatabaseObject); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "*", + children: "--ALL-DATABASES--" + }), + databases.map((database, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: database.db_full_name, + children: database.db_name + }, index + 1); + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "grants-table", + children: "Table" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "grants-table", + id: "grants-table", + className: "text-sm", + onChange: (e)=>{ + const selectedTable = e.target.value; + if (selectedTable == "NULL") { + return; + } + const selectedTableObject = tables.find((table)=>table.table_slug == selectedTable); + if (selectedTableObject) { + setTargetTable(selectedTableObject); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "*", + children: "--ALL-TABLES--" + }), + tables?.[0] && tables.map((table, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: table.table_slug, + children: table.table_name + }, index + 1); + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "grants-databases", + children: "Permissions" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-wrap gap-y-2 mb-1", + children: permissions?.[0] ? permissions.map((permission, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-xs px-2 py-1 border border-solid border-slate-200 rounded", + children: [ + permission, + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "cursor-pointer p-2 hover:opacity-50", + onClick: (e)=>{ + const newPermissions = [ + ...permissions, + ]; + newPermissions.splice(index, 1); + setPermissions(newPermissions); + }, + children: "x" + }) + ] + }); + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs px-3 py-1 bg-slate-100 text-slate-400", + children: "No Permissions Selected" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full items-stretch", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "grants-databases", + id: "grants-databases", + className: "text-sm", + onChange: (e)=>{ + const selectedPermission = e.target.value; + setTargetPermission(selectedPermission); + }, + children: permissionsArray.map((permission, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: permission, + children: permission + }, index); + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray text-2xl", + onClick: (e)=>{ + if (permissions.includes(targetPermission)) return; + if (permissions.includes("ALL PRIVILEGES")) { + alert("ALL PRIVILEGES already covers for the rest. Remove ALL PRIVILEGES permission to add others"); + return; + } + setPermissions([ + ...permissions, + targetPermission, + ]); + }, + children: "+" + }) + ] + }) + ] + }), + !isPrimary && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined secondary", + onClick: (e)=>{ + if (!permissions?.[0]) { + alert("Please select atleast 1 permission. *REMEMBER to click the + button to add the permission to the list"); + return; + } + /** + * @type {import("@/shell/mariadb-users/handleGrants").GrantType} + */ const newGrant = { + database: targetDatabase.db_full_name || "*", + privileges: permissions, + table: targetTable.table_slug || "*" + }; + const newGrants = [ + ...grants, + newGrant + ]; + setGrants(newGrants); + setNewGrant(false); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-2xl h-6 flex items-center justify-center", + children: "+" + }), + "\xa0Add Grant" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray", + onClick: ()=>{ + setNewGrant(false); + }, + children: "Cancel" + }) + ] + }) + }) : isPrimary ? /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Primary users have full control over all databases." + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray", + onClick: (e)=>{ + setNewGrant(true); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-2xl h-6 flex items-center justify-center", + children: "+" + }), + "\xa0Add Grant" + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/MariDBUserForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").MYSQL_mariadb_users_table_def} [props.mariaDBUser] + * @param {boolean} [props.edit] + * @param {string} [props.username] + */ function MariDBUserForm({ mariaDBUser , edit , username }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const formFields = mariaDBUser ? Object.keys(mariaDBUser) : [ + "username", + "host", + "password" + ]; + const KEYS_REGEXP = /username|host|password/; + const UNEDITABLE_REGEXP = edit ? /username/ : /username/; + const REQUIRED_REGEXP = /host/; + const existingGrants = (()=>{ + try { + if (edit && mariaDBUser?.grants) return JSON.parse(mariaDBUser.grants); + return null; + } catch (error) { + return null; + } + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ state: import("@/shell/mariadb-users/handleGrants").GrantType[], dispatch: React.Dispatch<React.SetStateAction<import("@/shell/mariadb-users/handleGrants").GrantType[]>> ]} */ // @ts-ignore + const [grants, setGrants] = external_react_default().useState(existingGrants ? existingGrants : [ + { + database: "*", + table: "*", + privileges: [ + "ALL PRIVILEGES" + ] + }, + ]); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + console.log("form clicked"); + /** + * @type {HTMLFormElement} + */ // @ts-ignore + const formEl = e.target; + const formFields = Array.from(formEl); + /** + * @type any + */ const formData = {}; + formFields.forEach((el)=>{ + if (el.nodeName != "INPUT") return; + /** + * @type {HTMLInputElement} + */ // @ts-ignore + const inputEl = el; + formData[inputEl.name] = inputEl.value; + }); + if (edit) { + delete formData.username; + } + if (!grants?.[0]) { + alert("Please add at least one grant"); + return; + } + setLoading(true); + const fetchUrl = edit ? "/api/sql-users/update" : "/api/sql-users/create"; + (0,fetchApi/* default */.Z)(fetchUrl, { + method: "POST", + body: { + data: formData, + edit: Boolean(edit), + prev: mariaDBUser, + grants + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else if (res.msg) { + window.alert(res.msg); + setLoading(false); + } + }); + }, + className: "w-full gap-4 flex flex-col", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "25px" + }), + formFields.map((key, index)=>{ + /** @type {string | null} */ const existingValue = mariaDBUser ? mariaDBUser[key] : key == "username" ? `dsql_user_${user.id}` : null; + const isReadOnly = UNEDITABLE_REGEXP.test(key); + const isRequired = REQUIRED_REGEXP.test(key); + if (!key.match(KEYS_REGEXP)) return null; + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: key, + children: key + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: key.match("password") ? "password" : "text", + name: key, + id: key, + defaultValue: existingValue || undefined, + readOnly: isReadOnly, + className: "" + (isReadOnly ? "bg-slate-100 opacity-50 pointer-events-none" : ""), + placeholder: key, + required: isRequired + }) + ] + }, index + 1); + }), + /*#__PURE__*/ jsx_runtime_.jsx(MariDBUserFormGrantsSection, { + grants: grants, + setGrants: setGrants, + edit: edit + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + children: edit ? "Update User" : "Create SQL User" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/EditMariadbUserPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditMariadbUserPopup(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { targetMariadbUser } = external_react_default().useContext(ConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [ready, setReady] = external_react_default().useState(false); + external_react_default().useEffect(()=>{ + setReady(false); + setTimeout(()=>{ + setReady(true); + }, 200); + }, [ + targetMariadbUser + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(GeneralPopup/* default */.ZP, { + title: "edit-mariadb-user-popup", + children: ready && targetMariadbUser ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Edit" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "info inline w-auto text-xl green", + children: [ + targetMariadbUser.username, + "@", + targetMariadbUser.host + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx(MariDBUserForm, { + mariaDBUser: targetMariadbUser, + edit: true + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "p-20", + children: /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "25px" + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/connect/NewMariadbUserPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function NewMariadbUserPopup(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(GeneralPopup/* default */.ZP, { + title: "new-mariadb-user-popup", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + children: "New MariaDB User" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx(MariDBUserForm, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/functions/backend/decrypt.js +var decrypt = __webpack_require__(5304); +var decrypt_default = /*#__PURE__*/__webpack_require__.n(decrypt); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/connect/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").ConnectContextType} */ // @ts-ignore +const init = {}; +const ConnectContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.query + * @param {import("@/package-shared/types").MariaDBUserCredType} props.mariadbUserCred + * @param {import("@/package-shared/types").MYSQL_mariadb_users_table_def[]} props.mariadbUsers + */ function DatabaseSchema({ user , query , mariadbUserCred , mariadbUsers , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "SQL Connect | Datasquirel"; + const pageDescription = "Connect to your database remotely"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ state: import("@/package-shared/types").MYSQL_mariadb_users_table_def | null, dispatch: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_mariadb_users_table_def | null>> ]} */ // @ts-ignore + const [targetMariadbUser, setTargetMariadbUser] = external_react_default().useState(null); + /** @type {[ state: number, dispatch: React.Dispatch<React.SetStateAction<number>> ]} */ // @ts-ignore + const [refresh, setRefresh] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + aceEditor: true, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ConnectContext.Provider, { + value: { + user, + query, + mariadbUserCred, + mariadbUsers, + targetMariadbUser, + setTargetMariadbUser, + refresh, + setRefresh + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(ConnectContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(EditMariadbUserPopup, {}), + /*#__PURE__*/ jsx_runtime_.jsx(NewMariadbUserPopup, {}) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const mariadbUserCredArray = await DB_HANDLER_default()(`SELECT mariadb_user, mariadb_host, mariadb_pass FROM users WHERE id = ?`, [ + user.id + ]); + const mariadbUserCred = mariadbUserCredArray?.[0] || {}; + if (mariadbUserCred?.mariadb_pass) { + mariadbUserCred.mariadb_pass = decrypt_default()(mariadbUserCred.mariadb_pass); + } + //////////////////////////////////////// + const mariadbUsers = await DB_HANDLER_default()(`SELECT * FROM mariadb_users WHERE user_id = ?`, [ + user.id + ]); + if (mariadbUsers?.[0]) { + for(let i = 0; i < mariadbUsers.length; i++){ + const mariaDBUser = mariadbUsers[i]; + mariaDBUser.password = decrypt_default()(mariaDBUser.password); + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + query, + mariadbUserCred, + mariadbUsers + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8757: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteOutlineOutlined"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472], () => (__webpack_exec__(5782))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js.nft.json new file mode 100644 index 0000000..07b6eef --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/connect.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteOutlineOutlined.js","../../../../../node_modules/@mui/icons-material/ContentCopyOutlined.js","../../../../../node_modules/@mui/icons-material/SystemUpdateAltOutlined.js","../../../../../node_modules/@mui/icons-material/EditNoteOutlined.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js new file mode 100644 index 0000000..84eac45 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js @@ -0,0 +1,207 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 133; +exports.ids = [133,4135]; +exports.modules = { + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,7946,1500,75,9282], () => (__webpack_exec__(2109))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js.nft.json new file mode 100644 index 0000000..2bbd1cf --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../chunks/7946.js","../../../chunks/1500.js","../../../chunks/75.js","../../../chunks/9282.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js new file mode 100644 index 0000000..8026811 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js @@ -0,0 +1,764 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6930; +exports.ids = [6930,8105,133,4135]; +exports.modules = { + +/***/ 366: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleDatabaseContext": () => (/* binding */ SingleDatabaseContext), + "default": () => (/* binding */ SingleDatabase), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/databases/DeleteDatabaseConfirmationPopup.jsx +var DeleteDatabaseConfirmationPopup = __webpack_require__(5012); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/DatabaseSlugCopy.jsx +var DatabaseSlugCopy = __webpack_require__(4739); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/SendToMobileTwoTone" +var SendToMobileTwoTone_ = __webpack_require__(6500); +var SendToMobileTwoTone_default = /*#__PURE__*/__webpack_require__.n(SendToMobileTwoTone_); +// EXTERNAL MODULE: ./functions/frontend/downloadApiStream.js +var downloadApiStream = __webpack_require__(7851); +;// CONCATENATED MODULE: ./components/admin/databases/SingleDatabasesContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleDatabasesContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , tables , setTargetTable , confirmedDelegetedUser , query , user , } = external_react_default().useContext(SingleDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full relative z-50", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap gap-y-0", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + database.db_name.replace(/ database$/i, ""), + " ", + "Database" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabaseSlugCopy/* default */.Z, { + slugText: database.db_slug, + outlined: true + }), + !isDelegated && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "button small-text outlined gray", + onClick: (e)=>{ + (0,downloadApiStream/* default */.Z)({ + url: `/api/exportDatabase?dbName=${database.db_full_name}`, + fileName: `${database.db_full_name}.sql`, + setLoading: setLoading + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((SendToMobileTwoTone_default()), { + fontSize: "small", + color: "action", + className: "opacity-50", + sx: { + fontSize: 14 + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Export" + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-wrap flex-col md:flex-row items-stretch md:items-center w-full md:w-auto", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + !isDelegated && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/add-table`, + className: "button flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Table" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables`, + className: "button secondary", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "All Tables" + }) + }), + !isDelegated && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users`, + className: "button dark", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Users" + }) + }), + !isDelegated && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper my-4 xl:my-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "hidden xl:flex button outlined gray", + children: "More" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mobile-transform right-aligned mt-0 xl:-mt-2 gap-2 items-stretch", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + column: true, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/edit-database`, + className: "button outlined gray more-padding", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Edit Database" + }) + }), + !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray more-padding", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("delete-database-confirmation"); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Delete Database" + }) + }), + !isDelegated && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray more-padding", + onClick: (e)=>{ + (0,downloadApiStream/* default */.Z)({ + url: `/api/exportDatabase?dbName=${database.db_full_name}`, + fileName: `${database.db_full_name}.sql`, + setLoading: setLoading + }); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Export Database" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/add-user?db=${database.db_slug}`, + className: "button outlined secondary more-padding", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add User" + }) + ] + }) + ] + }) + }) + ] + }) + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query.delegated, + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* default */.Z, { + database: database, + tables: tables, + setTargetTable: setTargetTable, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + user: user + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper green", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Triggers" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Coming Soon ..." + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper primary", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Stored Proceedures" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-slate-400", + children: "Coming Soon ..." + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/DeleteTableConfirmationPopup.jsx +var DeleteTableConfirmationPopup = __webpack_require__(1674); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").SingleDatabaseContextType} */ // @ts-ignore +const init = {}; +const SingleDatabaseContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def[]} props.tables + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function SingleDatabase({ user , database , tables , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${database.db_name} Database | Datasquirel`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ targetTable: import("@/package-shared/types").MYSQL_user_database_tables_table_def | null, setTargetTable: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def | null>> ]} */ // @ts-ignore + const [targetTable, setTargetTable] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(SingleDatabaseContext.Provider, { + value: { + user, + database, + tables, + targetTable, + setTargetTable, + query, + confirmedDelegetedUser + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SingleDatabasesContent, {}), + !confirmedDelegetedUser?.delegated && /*#__PURE__*/ jsx_runtime_.jsx(DeleteDatabaseConfirmationPopup/* default */.Z, { + targetDatabase: database + }), + (!confirmedDelegetedUser?.delegated || confirmedDelegetedUser?.delegated && confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i)) && /*#__PURE__*/ jsx_runtime_.jsx(DeleteTableConfirmationPopup/* default */.Z, { + targetTable: targetTable, + database: database + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Check delegated user token + * + * @description Check delegated user token + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + // @ts-ignore + databaseSlug: query.single, + query + }); + const dbuserDataObj = dbUserData; + if (!dbuserDataObj) return { + redirect: { + destination: "/admin", + permanent: false + } + }; + const { dbUserId , rootUserId } = dbuserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + // const databaseTablesInfo = await noDatabaseDbHandler(`SELECT * FROM information_schema.tables WHERE TABLE_SCHEMA = '${database[0].db_full_name}'`); + const tables = rootUserId ? await DB_HANDLER_default()(` + SELECT + delegated_user_tables.database,delegated_user_tables.table,user_database_tables.* + FROM + delegated_user_tables INNER JOIN user_database_tables ON delegated_user_tables.root_user_id=user_database_tables.user_id AND delegated_user_tables.table=user_database_tables.table_slug AND delegated_user_tables.database=user_database_tables.db_slug + WHERE + delegated_user_tables.delegated_user_id='${user.id}' AND delegated_user_tables.root_user_id='${rootUserId}' AND delegated_user_tables.database='${database[0].db_slug}' + `) : await DB_HANDLER_default()(`SELECT * FROM user_database_tables WHERE user_id='${user.id}' AND db_id='${database[0].id}'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0] ? database[0] : null, + tables: tables, + query, + confirmedDelegetedUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,5116,8345,4986,8264,1500,75,1674], () => (__webpack_exec__(366))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js.nft.json new file mode 100644 index 0000000..6dda745 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/913.js","../../../../chunks/9395.js","../../../../chunks/370.js","../../../../chunks/424.js","../../../../chunks/4858.js","../../../../chunks/5472.js","../../../../chunks/1781.js","../../../../chunks/4941.js","../../../../chunks/5116.js","../../../../chunks/8345.js","../../../../chunks/4986.js","../../../../chunks/8264.js","../../../../chunks/1500.js","../../../../chunks/75.js","../../../../chunks/1674.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js new file mode 100644 index 0000000..1d266bf --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js @@ -0,0 +1,863 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3952; +exports.ids = [3952,8105]; +exports.modules = { + +/***/ 2279: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "DatabaseConnectContext": () => (/* binding */ DatabaseConnectContext), + "default": () => (/* binding */ DatabaseConnectPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/form/FormInput.jsx + 2 modules +var FormInput = __webpack_require__(7901); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/form/FormRadios.jsx +var FormRadios = __webpack_require__(2348); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +;// CONCATENATED MODULE: ./components/admin/databases/connect/ConnectForm.jsx +// @ts-check + + + + + + + +/** + * @param {object} props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType} props.targetDbSchema + * @param {import("@/package-shared/types").UserType} props.user + * @returns + */ function ConnectForm({ database , targetDbSchema , user }) { + const [isValid, setIsValid] = external_react_default().useState(false); + const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ state: "pull" | "push", dispatch: React.Dispatch<React.SetStateAction<"pull" | "push">> ]} */ // @ts-ignore + const [type, setType] = external_react_default().useState("pull"); + /** @type {[ state: import("@/package-shared/types").DbConnectType | null, dispatch: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DbConnectType | null>> ]} */ // @ts-ignore + const [connectPayload, setConnectPayload] = external_react_default().useState(null); + if (isValid && connectPayload) { + return /*#__PURE__*/ jsx_runtime_.jsx(SelectRemoteDbAndFinalizeForm, { + payload: connectPayload, + setConnectPayload: setConnectPayload, + setIsValid: setIsValid, + user: user + }); + } + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + verifyFormSubmitHandler({ + e, + setLoading, + database, + type, + targetDbSchema, + setIsValid, + setConnectPayload + }); + }, + className: "w-full flex flex-col items-start justify-start gap-4 static", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + type?.match(/pull/) ? /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "info warning", + children: "NOTE: This will override your current Database Schema" + }) : /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "info green", + children: "NOTE: The remote database will be updated with this Database Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "This Feature links this current database to a remote database schema" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-2 justify-start p-6 bg-slate-100 w-full rounded", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold", + children: "Select the connection type" + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormRadios/* default */.Z, { + radioValues: [ + { + title: "Pull", + payload: "pull", + default: true + }, + { + title: "Push", + payload: "push", + default: false + }, + ], + flexRow: true, + onChangeHandler: (e)=>{ + setType(e.target.value); + }, + name: "type-radio" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + type.match(/pull/i) && /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "A pull connection imposes the remote database on your current database" + }), + type.match(/push/i) && /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "A push connection imposes your current database to the remote" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + placeholder: "Eg. https://domain.com", + title: "Remote Origin Address", + name: "remote-address", + required: true + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormInput/* default */.Z, { + placeholder: "Eg. ab81XFogyWe4yc51Agjve52cUQ5XW75m2hLFVzGeoDZT2ob6hC", + title: "Remote API key (Full Access)", + name: "remote-key", + required: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full", + children: "Verify Remote" + }) + ] + }); +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ### VErify Form Submit Handler Function + * @param {object} params + * @param {React.FormEvent<HTMLFormElement>} params.e + * @param {React.Dispatch<React.SetStateAction<boolean>>} params.setLoading + * @param {"pull" | "push"} params.type + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} params.database + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType} params.targetDbSchema + * @param {React.Dispatch<React.SetStateAction<boolean>>} params.setIsValid + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DbConnectType | null>>} params.setConnectPayload + */ function verifyFormSubmitHandler({ e , setLoading , database , type , targetDbSchema , setIsValid , setConnectPayload , }) { + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + setLoading(true); + /** @type {import("@/package-shared/types").DbConnectType} */ const postBody = { + url: formEl["remote-address"].value, + key: formEl["remote-key"].value, + database, + dbSchema: targetDbSchema, + type + }; + (0,fetchApi/* default */.Z)("/api/connect/verify", { + method: "POST", + body: postBody + }, true).then((res)=>{ + if (res.success) { + setIsValid(true); + setConnectPayload({ + ...postBody, + remoteDbs: res.payload + }); + } else { + console.log(res); + setTimeout(()=>{ + setLoading(false); + }, 2000); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 2000); + }); +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ## Final Submit Form + * @param {object} props + * @param {import("@/package-shared/types").DbConnectType | null} props.payload + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setIsValid + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DbConnectType | null>>} props.setConnectPayload + * @param {import("@/package-shared/types").UserType} props.user + * @returns + */ function SelectRemoteDbAndFinalizeForm({ payload , setConnectPayload , setIsValid , user , }) { + const [loading, setLoading] = external_react_default().useState(false); + if (!payload?.remoteDbs?.[0]) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Databases Available on this Remote server." + }); + } + const remoteDatabases = payload.remoteDbs; + if (!remoteDatabases?.[0]) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "The only Database Available here is this current Database" + }); + } + const [targetDb, setTargetDb] = external_react_default().useState(remoteDatabases[0]); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + if (!window.confirm("Connect these Databases?")) return; + setLoading(true); + (0,fetchApi/* default */.Z)(`/api/connect/handshake`, { + method: "POST", + body: { + ...payload, + targetDb + } + }, true).then((res)=>{ + if (res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${payload.database.db_slug}`; + } else { + console.log(res); + alert(res?.msg || "Something Went Wrong"); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + }, + className: "w-full gap-4 flex flex-col items-start justify-start", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h2", { + className: "text-xl font-normal", + children: [ + "Select Database from", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + className: "text-black dark:text-white", + children: payload.url + }), + " ", + "Remote Server" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: remoteDatabases.map((db)=>{ + return { + payload: db.dbFullName, + title: db.dbName + }; + }), + onChangeHandler: (e)=>{ + /** @type {string | null} */ const targetDbName = e.target.value; + if (targetDbName) { + const targetDbObject = remoteDatabases.find((db)=>db.dbFullName == targetDbName); + if (targetDbObject) { + setTargetDb(targetDbObject); + } else { + alert("Failed to Select Target Database. Please reload the page and try again."); + } + } + } + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + "Connection type:", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + className: "info inline small " + (payload.type?.match(/pull/i) ? "warning" : "green"), + children: payload.type + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full", + children: "Connect Database" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray w-full", + onClick: (e)=>{ + setIsValid(false); + setConnectPayload(null); + }, + children: "Reset" + }) + ] + }); +} + +;// CONCATENATED MODULE: ./components/admin/databases/connect/DatabaseConnectContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabaseConnectContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , user , targetDbSchema , query } = external_react_default().useContext(DatabaseConnectContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!user) { + return null; + } + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + database?.db_name, + " Database Connect" + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "paper w-full", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex max-w-5xl w-full flex-col items-start gap-4", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Connect External Database Schema" + }), + /*#__PURE__*/ jsx_runtime_.jsx(ConnectForm, { + database, + targetDbSchema, + user + }) + ] + }) + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseShellContent/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name + }), + "\xa0", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Connect" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Db connect unavailable at this time." + }) + }) + ] + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(2527); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/connect.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DbConnectContextType} */ // @ts-ignore +const databaseShellInit = {}; +const DatabaseConnectContext = /*#__PURE__*/ external_react_default().createContext(databaseShellInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType} props.targetDbSchema + */ function DatabaseConnectPage({ user , database , query , targetDbSchema , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Database Shell | Datasquirel"; + const pageDescription = "Database Shell"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx("link", { + rel: "stylesheet", + href: "/styles/shell-page.css" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + aceEditor: true, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseConnectContext.Provider, { + value: { + user, + database, + targetDbSchema, + query + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseConnectContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database?.[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + if (Number(database[0].remote_connected) == 1) { + return { + redirect: { + destination: `/admin/${user?.id}/databases/${query.single}`, + permanent: false + } + }; + } + const tables = await varDatabaseDbHandler_default()({ + queryString: `SHOW TABLES`, + database: database[0].db_full_name + }); + const dbSchemaData = (0,grabUserSchemaData/* default */.Z)({ + userId: user.id + }); + if (!dbSchemaData?.[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const targetDbSchema = dbSchemaData.find((db)=>db.dbFullName == database[0].db_full_name); + if (!targetDbSchema) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + query, + targetDbSchema + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,1781,4941,7023,7901,4114,8682,2317,1206,3314,2348], () => (__webpack_exec__(2279))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js.nft.json new file mode 100644 index 0000000..f282a09 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/connect.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/7023.js","../../../../../chunks/7901.js","../../../../../chunks/4114.js","../../../../../chunks/8682.js","../../../../../chunks/2317.js","../../../../../chunks/1206.js","../../../../../chunks/3314.js","../../../../../chunks/2348.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../package.json","../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js new file mode 100644 index 0000000..d5c7e9c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js @@ -0,0 +1,636 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2657; +exports.ids = [2657,8105,3316]; +exports.modules = { + +/***/ 4417: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ EditDatabaseForm) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _pages_admin_user_id_databases_single_edit_database__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8538); +/* harmony import */ var _DatabaseForm__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3121); +/* harmony import */ var _DatabaseImage__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1933); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditDatabaseForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , dbImage , setDbImage , database } = react__WEBPACK_IMPORTED_MODULE_1___default().useContext(_pages_admin_user_id_databases_single_edit_database__WEBPACK_IMPORTED_MODULE_3__.EditDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const imagePreviewRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + // React.useEffect(() => { + // if (!dbImage?.imageBase64Full) { + // const presetImage = document.createElement("img"); + // presetImage.src = "/images/database-placeholder.png"; + // imageNodeToBase64SpecificWidth({ imageNode: presetImage, maxWidth: 400, mimeType: "image/png" }).then((res) => { + // setDbImage({ ...res, imageName: "Preset-db-image" }) + // }) + // } + // }, []) + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("section", { + className: "paper", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full grid grid-cols-1 xl:grid-cols-2 gap-6 items-stretch", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start w-full xl:w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "Update Database Information" + }), + user && dbImage ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseForm__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage, + database: database, + setLoading: setLoading + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "No User and Database Image present" + }) + ] + }), + user && dbImage && setDbImage ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseImage__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage, + database: database + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Database Image could not be rendered" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8538: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "EditDatabaseContext": () => (/* binding */ EditDatabaseContext), + "default": () => (/* binding */ EditDatabase), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/databases/UserMediaPopup.jsx +var UserMediaPopup = __webpack_require__(9310); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/databases/AddDatabaseForm.jsx +var AddDatabaseForm = __webpack_require__(3726); +// EXTERNAL MODULE: ./components/admin/databases/EditDatabaseForm.jsx +var EditDatabaseForm = __webpack_require__(4417); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +;// CONCATENATED MODULE: ./components/admin/databases/EditDatabaseContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditDatabaseContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , user } = external_react_default().useContext(EditDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Edit", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + database?.active_clone && user ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(EditDatabaseForm/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/edit-database.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").EditDbContextType} */ const editDbInit = {}; +const EditDatabaseContext = /*#__PURE__*/ external_react_default().createContext(editDbInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + */ function EditDatabase({ user , database , query }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Add Database | Datasquirel"; + const pageDescription = "Add a database"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const dbImageState = external_react_default().useState(database.db_image); + /** @type {[ dbImage: string | import("@/package-shared/types").ImageObjectType | null, setDbImage: React.Dispatch<React.SetStateAction<string | import("@/package-shared/types").ImageObjectType | null>> ]} */ const [dbImage, setDbImage] = dbImageState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(EditDatabaseContext.Provider, { + value: { + user, + database, + dbImage, + setDbImage + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(EditDatabaseContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UserMediaPopup/* default */.Z, { + setDbImage: setDbImage + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + query + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,7901,4986,6718,9594,9471,9486,7037,9967,4105,3974], () => (__webpack_exec__(8538))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js.nft.json new file mode 100644 index 0000000..2c3d823 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/edit-database.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/5472.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/7023.js","../../../../../chunks/7901.js","../../../../../chunks/4986.js","../../../../../chunks/6718.js","../../../../../chunks/9594.js","../../../../../chunks/9471.js","../../../../../chunks/9486.js","../../../../../chunks/7037.js","../../../../../chunks/9967.js","../../../../../chunks/4105.js","../../../../../chunks/3974.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lodash/package.json","../../../../../../../node_modules/react-dom/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lodash/lodash.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/react-dom/index.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react-dom/client.js","../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/scheduler/package.json","../../../../../../../node_modules/scheduler/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js new file mode 100644 index 0000000..b5766d6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js @@ -0,0 +1,1795 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3293; +exports.ids = [3293,2657,8105,133,3316,4135,4105,3314,2434]; +exports.modules = { + +/***/ 4417: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ EditDatabaseForm) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _pages_admin_user_id_databases_single_edit_database__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8538); +/* harmony import */ var _DatabaseForm__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3121); +/* harmony import */ var _DatabaseImage__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1933); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditDatabaseForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , dbImage , setDbImage , database } = react__WEBPACK_IMPORTED_MODULE_1___default().useContext(_pages_admin_user_id_databases_single_edit_database__WEBPACK_IMPORTED_MODULE_3__.EditDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const imagePreviewRef = react__WEBPACK_IMPORTED_MODULE_1___default().useRef(); + // React.useEffect(() => { + // if (!dbImage?.imageBase64Full) { + // const presetImage = document.createElement("img"); + // presetImage.src = "/images/database-placeholder.png"; + // imageNodeToBase64SpecificWidth({ imageNode: presetImage, maxWidth: 400, mimeType: "image/png" }).then((res) => { + // setDbImage({ ...res, imageName: "Preset-db-image" }) + // }) + // } + // }, []) + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("section", { + className: "paper", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full grid grid-cols-1 xl:grid-cols-2 gap-6 items-stretch", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col items-start w-full xl:w-auto", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "Update Database Information" + }), + user && dbImage ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseForm__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage, + database: database, + setLoading: setLoading + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "No User and Database Image present" + }) + ] + }), + user && dbImage && setDbImage ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_DatabaseImage__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + user: user, + dbImage: dbImage, + setDbImage: setDbImage, + database: database + }) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Database Image could not be rendered" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 7947: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* unused harmony export default */ +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * editorRef: { current: any }, + * readOnly: boolean, + * executeFunction: (editor: AceAjax.Editor) => void, + * content: string, + * placeholder?: string, + * mode?: string, + * fontSize?: string, + * }} props - React component props including { children } + */ function AceEditor({ editorRef , readOnly , executeFunction , content , placeholder , mode , fontSize , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.LegacyRef<HTMLDivElement | undefined>} */ const editorElementRef = React.useRef(); + /** @type {React.MutableRefObject<AceAjax.Editor | undefined>} */ const editorRefInstance = React.useRef(); + const [loading, setLoading] = React.useState(false); + const [refresh, setRefresh] = React.useState(0); + React.useEffect(()=>{ + if (!ace?.edit || !editorElementRef.current) { + setTimeout(()=>{ + setRefresh((prev)=>prev + 1); + }, 1000); + return; + } + const editor = ace.edit(editorElementRef.current); + editor.setOptions({ + mode: `ace/mode/${mode ? mode : "javascript"}`, + theme: "ace/theme/nord_dark", + // theme: "ace/theme/twilight", + value: content, + placeholder: placeholder ? placeholder : "", + enableBasicAutocompletion: true, + enableLiveAutocompletion: true, + readOnly: readOnly ? true : false, + fontSize: fontSize ? fontSize : null + }); + editor.commands.addCommand({ + name: "myCommand", + bindKey: { + win: "Ctrl-Enter", + mac: "Command-Enter" + }, + exec: function(editor) { + if (executeFunction) executeFunction(editor); + }, + readOnly: true + }); + editorRefInstance.current = editor; + if (editorRef) editorRef.current = editor; + }, [ + refresh + ]); + React.useEffect(()=>{ + if (!editorRefInstance.current) return; + editorRefInstance.current.setValue(content, -1); + }, [ + content + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ _jsx(React.Fragment, { + children: /*#__PURE__*/ _jsx("div", { + className: "p-4 w-full h-full block rounded-md", + style: { + backgroundColor: "#2e3440" + }, + children: /*#__PURE__*/ _jsx("div", { + // @ts-ignore + ref: editorElementRef, + className: "ace-editor-wrapper w-full h-full minimal-scrollbars all-children" + }) + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + React.useEffect(()=>{ + fetchApi("/api/admin/clientError", { + method: "post", + body: { + component: "AceEditor/main-catch-error", + message: error.message, + user: {} + } + }); + }, []); + return /*#__PURE__*/ _jsx(React.Fragment, { + children: /*#__PURE__*/ _jsx("h2", { + className: "text-xl m-0", + children: "Editor Error" + }) + }); + } +} + + +/***/ }), + +/***/ 1095: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ CodeBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6843); +/* harmony import */ var _mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9174); +/* harmony import */ var _mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * content: string, + * language: string, + * style?: React.CSSProperties, + * }} props - React component props including { children } + */ function CodeBlock({ content , language , style }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const [open, setOpen] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const handleClick = ()=>{ + setOpen(true); + }; + /** + * ## Handle Close + * @param {*} event + * @param {*} reason + * @returns + */ const handleClose = (event, reason)=>{ + if (reason === "clickaway") { + return; + } + setOpen(false); + }; + const action = /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined gray", + style: { + border: "none", + padding: "2px", + width: "20px", + height: "20px", + color: "white" + }, + // @ts-ignore + onClick: handleClose, + children: "✖" + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("pre", { + className: `language-${language ? language : "javascript"} w-full overflow-hidden code-block relative max-w-4xl`, + style: style ? style : {}, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("code", { + className: `w-full`, + style: { + wordBreak: "break-all" + }, + children: content + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined absolute top-2 right-2 z-20 copy-code hover:opacity-50", + style: { + padding: "2px", + border: "none" + }, + onClick: (/** @type {any} */ e)=>{ + navigator.clipboard.writeText(content).then(()=>{ + handleClick(); + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_icons_material_ContentCopy__WEBPACK_IMPORTED_MODULE_2___default()), { + fontSize: "small", + color: "action" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((_mui_material_Snackbar__WEBPACK_IMPORTED_MODULE_3___default()), { + open: open, + autoHideDuration: 2000, + onClose: handleClose, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "h-full text-white px-4 py-2 justify-between rounded", + style: { + maxWidth: "250px", + width: "250px", + backgroundColor: "#0b8862" + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Code Copied!" + }), + action + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 2527: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ grabUserSchemaData) +/* harmony export */ }); +// @ts-check +const serverError = __webpack_require__(2317); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * @param {Object} params + * @param {string | number} params.userId + * @returns {DSQL_DatabaseSchemaType[] | null} + */ function grabUserSchemaData({ userId }) { + try { + const userSchemaFilePath = path.resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${userId}/main.json`); + const userSchemaData = JSON.parse(fs.readFileSync(userSchemaFilePath, "utf-8")); + return userSchemaData; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/grabUserSchemaData", + message: error.message + }); + return null; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4105: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ checkUniqueField) +/* harmony export */ }); +/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6405); +/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_dom__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +let timeout; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} params + * @param {string} params.tableName + * @param {string} params.columnName + * @param {string} params.value + * @param {string} [params.dbFullName] + * @param {any} [params.dispatch] + * @param {number} [params.userId] + * @param {number} [params.dbId] + */ async function checkUniqueField({ tableName , columnName , value , dbFullName , dispatch , userId , dbId , }) { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const duplicate = await (0,_fetchApi__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)(`/api/checkDuplicateData?tableName=${tableName}&type=${columnName}&value=${value}${dbFullName ? "&dbFullName=" + dbFullName : ""}${userId ? "&userId=" + userId : ""}${dbId ? "&dbId=" + dbId : ""}`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return duplicate; +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8538: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "EditDatabaseContext": () => (/* binding */ EditDatabaseContext), + "default": () => (/* binding */ EditDatabase), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/databases/UserMediaPopup.jsx +var UserMediaPopup = __webpack_require__(9310); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/databases/AddDatabaseForm.jsx +var AddDatabaseForm = __webpack_require__(3726); +// EXTERNAL MODULE: ./components/admin/databases/EditDatabaseForm.jsx +var EditDatabaseForm = __webpack_require__(4417); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +;// CONCATENATED MODULE: ./components/admin/databases/EditDatabaseContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditDatabaseContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , user } = external_react_default().useContext(EditDatabaseContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Edit", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + database?.active_clone && user ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(EditDatabaseForm/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/edit-database.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").EditDbContextType} */ const editDbInit = {}; +const EditDatabaseContext = /*#__PURE__*/ external_react_default().createContext(editDbInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + */ function EditDatabase({ user , database , query }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Add Database | Datasquirel"; + const pageDescription = "Add a database"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const dbImageState = external_react_default().useState(database.db_image); + /** @type {[ dbImage: string | import("@/package-shared/types").ImageObjectType | null, setDbImage: React.Dispatch<React.SetStateAction<string | import("@/package-shared/types").ImageObjectType | null>> ]} */ const [dbImage, setDbImage] = dbImageState; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(EditDatabaseContext.Provider, { + value: { + user, + database, + dbImage, + setDbImage + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(EditDatabaseContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UserMediaPopup/* default */.Z, { + setDbImage: setDbImage + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + query + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 3104: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "DatabaseSchemaContext": () => (/* binding */ DatabaseSchemaContext), + "default": () => (/* binding */ DatabaseSchema), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/databases/EditDatabaseForm.jsx +var EditDatabaseForm = __webpack_require__(4417); +// EXTERNAL MODULE: ./components/form/FormCheckboxes.jsx +var FormCheckboxes = __webpack_require__(9486); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseTablesTablePreview.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabaseTablesTablePreview(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , dbSchemaData , tables , user } = external_react_default().useContext(DatabaseSchemaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Database Tables" + }), + tables && tables[0] && tables.map((table, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "card light-gray w-full", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: table.tableSlug + }) + }, index + 1); + }) + ] + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseTablesPreview/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name + }), + "\xa0", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Schema" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Error in generating Tables Table" + }) + }) + ] + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseSchemaVisualizer.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabaseSchemaVisualizer(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , dbSchemaData , tables , user } = external_react_default().useContext(DatabaseSchemaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const targetDb = dbSchemaData?.filter((db)=>db.dbFullName === database?.db_full_name)[0]; + if (!targetDb) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Database Schema Found" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h3", { + className: "m-0 text-xl", + children: [ + targetDb.dbName, + " Database Tables" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "my-0" + }), + targetDb.tables.map((table, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-4 left-border pl-6 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "w-full xl:w-auto font-bold text-lg sticky top-0 px-3 py-1 bg-slate-800 text-white -ml-6", + children: table.tableFullName + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Fields" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start left-border pl-6 w-full", + children: table.fields.map((field, _index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold", + children: field.fieldName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs", + children: field.dataType + }) + ] + }, _index + 1); + }) + }) + ] + }), + table.indexes && table.indexes[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Indexes" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start left-border pl-6 w-full", + children: table.indexes.map((index, _index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold text-secondary", + children: index.indexName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs", + children: index.indexType + }) + ] + }, _index + 1); + }) + }) + ] + }) + ] + }, index + 1); + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseSchemaVisualizer/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: "Nothing to See here" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/AceEditor.jsx +var AceEditor = __webpack_require__(7947); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/CodeBlock.jsx +var CodeBlock = __webpack_require__(1095); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseSchemaContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabaseSchemaContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , dbSchemaData , tables , user } = external_react_default().useContext(DatabaseSchemaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!dbSchemaData) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Database Schema Found!" + }); + } + const targetDb = dbSchemaData.filter((db)=>db.dbFullName === database?.db_full_name)[0]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [dbTables, setDbTables] = external_react_default().useState(targetDb.tables); + const [targetTable, setTargetTable] = external_react_default().useState(null); + /** @type {any} */ const [previewObject, setPreviewObject] = external_react_default().useState(targetDb); + external_react_default().useEffect(()=>{ + if (targetTable) { + try { + const targetTableObject = dbTables.filter((table)=>table.tableName === targetTable)[0]; + setPreviewObject(targetTableObject); + } catch (/** @type {any} */ error) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseSchemaContent/main-return", + message: error.message, + user: user + } + }); + } + } else { + setDbTables(targetDb.tables); + setPreviewObject(targetDb); + } + }, [ + targetTable + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!database) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Database Record Found" + }); + } + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database.db_name + }), + "\xa0", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Schema" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Database SCHEMA JSON" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: dbTables && dbTables[0] && /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + required: true, + selectOptions: [ + { + title: "All Tables", + payload: "none" + }, + ...dbTables.map((table, index)=>{ + return { + title: table.tableFullName, + payload: table.tableName, + name: table.tableName + }; + }), + ], + name: "database_tables", + onChangeHandler: (e)=>{ + if (e.target.value?.match(/^none$/)) { + setTargetTable(null); + } else { + setTargetTable(e.target.value); + } + } + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "grid grid-cols-1 xl:grid-cols-2 items-stretch w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "relative w-full block", + children: /*#__PURE__*/ jsx_runtime_.jsx(CodeBlock/* default */.Z, { + content: JSON.stringify(previewObject, null, 4), + language: "javascript" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabaseSchemaVisualizer, {}) + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabaseTablesTablePreview, {}) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseSchemaContent/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name || null + }), + "\xa0", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Schema" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Error in generating Preview" + }) + }) + ] + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(2527); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/schema.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DbSchemaContextType} */ // @ts-ignore +const dbSchemaContextInit = {}; +const DatabaseSchemaContext = /*#__PURE__*/ external_react_default().createContext(dbSchemaContextInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any[]} props.tables + */ function DatabaseSchema({ user , database , query , dbSchemaData , tables , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Add Database | Datasquirel"; + const pageDescription = "Add a database"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [dbImage, setDbImage] = external_react_default().useState(database.db_image); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + aceEditor: true, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseSchemaContext.Provider, { + value: { + user, + database, + dbImage, + setDbImage, + dbSchemaData, + tables + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseSchemaContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + /** @type {any} */ const tables = await varDatabaseDbHandler_default()({ + queryString: `SHOW TABLES`, + database: database[0].db_full_name + }); + const dbSchemaData = (0,grabUserSchemaData/* default */.Z)({ + userId: user.id + }); + if (!dbSchemaData) throw new Error("User schema data not found!"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + query, + dbSchemaData: dbSchemaData ? dbSchemaData : [], + tables: tables && tables[0] ? tables.map((/** @type {any} */ table)=>{ + const title = Object.keys(table)[0]; + return { + tableSlug: table[title] + }; + }) : [] + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log(error); + return { + redirect: { + destination: "/", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 6843: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ContentCopy"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 9174: +/***/ ((module) => { + +module.exports = require("@mui/material/Snackbar"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,7901,4114,8682,2317,1206,8345,4986,6718,9594,8264,9471,9486,7037,9967,3974], () => (__webpack_exec__(3104))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js.nft.json new file mode 100644 index 0000000..25d8e71 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/schema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/5472.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/7023.js","../../../../../chunks/7901.js","../../../../../chunks/4114.js","../../../../../chunks/8682.js","../../../../../chunks/2317.js","../../../../../chunks/1206.js","../../../../../chunks/8345.js","../../../../../chunks/4986.js","../../../../../chunks/6718.js","../../../../../chunks/9594.js","../../../../../chunks/8264.js","../../../../../chunks/9471.js","../../../../../chunks/9486.js","../../../../../chunks/7037.js","../../../../../chunks/9967.js","../../../../../chunks/3974.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lodash/package.json","../../../../../../../node_modules/react-dom/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/@mui/material/Snackbar/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lodash/lodash.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/react-dom/index.js","../../../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ContentCopy.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react-dom/client.js","../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/base/node/index.js","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/scheduler/package.json","../../../../../../../node_modules/scheduler/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/react-transition-group/package.json","../../../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../../../node_modules/@popperjs/core/package.json","../../../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/dom-helpers/package.json","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@floating-ui/dom/package.json","../../../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/@floating-ui/core/package.json","../../../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../package.json","../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js new file mode 100644 index 0000000..9917e41 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js @@ -0,0 +1,882 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7403; +exports.ids = [7403,8105]; +exports.modules = { + +/***/ 2495: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "DatabaseShellContext": () => (/* binding */ DatabaseShellContext), + "default": () => (/* binding */ DatabaseShellPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: external "@mui/material/styles" +var styles_ = __webpack_require__(8442); +// EXTERNAL MODULE: external "@mui/material/Table" +var Table_ = __webpack_require__(9181); +var Table_default = /*#__PURE__*/__webpack_require__.n(Table_); +// EXTERNAL MODULE: external "@mui/material/TableBody" +var TableBody_ = __webpack_require__(8823); +var TableBody_default = /*#__PURE__*/__webpack_require__.n(TableBody_); +// EXTERNAL MODULE: external "@mui/material/TableCell" +var TableCell_ = __webpack_require__(5612); +var TableCell_default = /*#__PURE__*/__webpack_require__.n(TableCell_); +// EXTERNAL MODULE: external "@mui/material/TableContainer" +var TableContainer_ = __webpack_require__(443); +var TableContainer_default = /*#__PURE__*/__webpack_require__.n(TableContainer_); +// EXTERNAL MODULE: external "@mui/material/TableHead" +var TableHead_ = __webpack_require__(5953); +var TableHead_default = /*#__PURE__*/__webpack_require__.n(TableHead_); +// EXTERNAL MODULE: external "@mui/material/TableRow" +var TableRow_ = __webpack_require__(4848); +var TableRow_default = /*#__PURE__*/__webpack_require__.n(TableRow_); +// EXTERNAL MODULE: external "@mui/material/Paper" +var Paper_ = __webpack_require__(1168); +var Paper_default = /*#__PURE__*/__webpack_require__.n(Paper_); +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseShellQueryResult.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ const StyledTableCell = (0,styles_.styled)((TableCell_default()))(({ theme })=>({ + [`&.${TableCell_.tableCellClasses.head}`]: { + backgroundColor: "var(--slate-800)", + color: "white" + }, + [`&.${TableCell_.tableCellClasses.body}`]: { + } + })); +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + * @param {import("@/package-shared/types").UserType} props.user + */ function DatabaseShellQueryResult({ data , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const headers = Object.keys(data[0]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "p-4 bg-slate-200 rounded-md overflow-hidden", + children: /*#__PURE__*/ jsx_runtime_.jsx((TableContainer_default()), { + component: (Paper_default()), + sx: { + width: "100%" + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)((Table_default()), { + sx: { + minWidth: 650 + }, + "aria-label": "simple table", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((TableHead_default()), { + children: /*#__PURE__*/ jsx_runtime_.jsx((TableRow_default()), { + children: headers && headers[0] && headers.map((header, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(StyledTableCell, { + align: "left", + children: header + }, index + 1); + }) + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx((TableBody_default()), { + children: data && data[0] && data.map((/** @type {any} */ dataObject, /** @type {number} */ index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx((TableRow_default()), { + sx: { + "&:last-child td, &:last-child th": { + border: 0 + } + }, + children: headers.map((header, _index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(StyledTableCell, { + align: "left", + children: dataObject[header] + }, _index + 1); + }) + }, index + 1); + }) + }) + ] + }) + }) + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseShellQueryResult/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No results" + }) + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/DatabaseShellContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DatabaseShellContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , dbSchemaData , tables , user } = external_react_default().useContext(DatabaseShellContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!user) { + return null; + } + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const sqlEditorRef = external_react_default().useRef(); + /** @type {React.MutableRefObject<AceAjax.Editor | undefined>} */ const editorRef = external_react_default().useRef(); + const [loading, setLoading] = external_react_default().useState(false); + const [data, setData] = external_react_default().useState(false); + const [refresh, setRefresh] = external_react_default().useState(0); + function runQuery() { + setLoading(true); + /** @type {string|null} */ const query = editorRef.current ? editorRef.current.getValue() : null; + if (!query?.match(/./)) return; + const formattedQuery = query.replace(/^--.*/gm, "").replace(/\n|\r|\n\r/gm, "").replace(/ {2,}/g, " "); + (0,fetchApi/* default */.Z)("/api/runUserDbQuery", { + method: "post", + body: { + database: database?.db_slug, + query: formattedQuery, + tables: tables?.map((tbl)=>tbl.tableSlug) + } + }, true).then((res)=>{ + if (res.success) { + setData(res.result); + } else if (res.msg) { + window.alert(res.msg); + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + } + external_react_default().useEffect(()=>{ + if (!ace?.edit) { + setTimeout(()=>{ + setRefresh((prev)=>prev + 1); + }, 1000); + return; + } + /** @type {AceAjax.Editor} */ const editor = ace.edit("ace-editor-wrapper"); + editor.setOptions({ + mode: "ace/mode/mysql", + theme: "ace/theme/twilight", + value: `SELECT * FROM ${tables?.[0] ? tables[0].tableSlug : "no_tables_yet"}`, + placeholder: "Type an SQL query", + enableBasicAutocompletion: true, + enableLiveAutocompletion: true + }); + editor.commands.addCommand({ + name: "myCommand", + bindKey: { + win: "Ctrl-Enter", + mac: "Command-Enter" + }, + exec: function(editor) { + runQuery(); + }, + readOnly: true + }); + editorRef.current = editor; + }, [ + refresh + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + database?.db_name, + " Database Shell" + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + // @ts-ignore + ref: sqlEditorRef, + id: "ace-editor-wrapper" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "absolute right-4 bottom-4" + (loading ? " pointer-events-none opacity-70" : ""), + onClick: (e)=>{ + runQuery(); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative", + width: "15px", + borderWidth: "3px", + style: { + backgroundColor: "transparent" + } + }), + loading ? "Running Query ..." : "Run Query" + ] + }) + ] + }), + data && !loading && /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col items-start overflow-x-scroll", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl", + children: "Query Results" + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabaseShellQueryResult, { + data: data, + user: user + }) + ] + }) + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "DatabaseShellContent/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-100 dark:bg-white/10 border border-solid border-slate-300 dark:border-slate-300/20 rounded py-1", + children: database?.db_name + }), + "\xa0", + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Shell" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Shell not available at this time" + }) + }) + ] + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(2527); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/shell.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DbShellContextType} */ const databaseShellInit = {}; +const DatabaseShellContext = /*#__PURE__*/ external_react_default().createContext(databaseShellInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any[]} props.tables + */ function DatabaseShellPage({ user , database , query , dbSchemaData , tables , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Database Shell | Datasquirel"; + const pageDescription = "Database Shell"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx("link", { + rel: "stylesheet", + href: "/styles/shell-page.css" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [dbImage, setDbImage] = external_react_default().useState(database.db_image); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + aceEditor: true, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseShellContext.Provider, { + value: { + user, + database, + dbImage, + setDbImage, + dbSchemaData, + tables + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(DatabaseShellContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const tables = await varDatabaseDbHandler_default()({ + queryString: `SHOW TABLES`, + database: database[0].db_full_name + }); + const dbSchemaData = (0,grabUserSchemaData/* default */.Z)({ + userId: user.id + }); + if (!dbSchemaData) throw new Error("User schema data not found!"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + query, + dbSchemaData: dbSchemaData ? dbSchemaData : [], + tables: tables && tables[0] ? tables.map((/** @type {any} */ table)=>{ + const title = Object.keys(table)[0]; + return { + tableSlug: table[title] + }; + }) : [] + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log(error); + return { + redirect: { + destination: "/", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 1168: +/***/ ((module) => { + +module.exports = require("@mui/material/Paper"); + +/***/ }), + +/***/ 9181: +/***/ ((module) => { + +module.exports = require("@mui/material/Table"); + +/***/ }), + +/***/ 8823: +/***/ ((module) => { + +module.exports = require("@mui/material/TableBody"); + +/***/ }), + +/***/ 5612: +/***/ ((module) => { + +module.exports = require("@mui/material/TableCell"); + +/***/ }), + +/***/ 443: +/***/ ((module) => { + +module.exports = require("@mui/material/TableContainer"); + +/***/ }), + +/***/ 5953: +/***/ ((module) => { + +module.exports = require("@mui/material/TableHead"); + +/***/ }), + +/***/ 4848: +/***/ ((module) => { + +module.exports = require("@mui/material/TableRow"); + +/***/ }), + +/***/ 8442: +/***/ ((module) => { + +module.exports = require("@mui/material/styles"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,1781,4941,7023,8682,2317,1206,3314], () => (__webpack_exec__(2495))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js.nft.json new file mode 100644 index 0000000..6ac5d2d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/shell.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/7023.js","../../../../../chunks/8682.js","../../../../../chunks/2317.js","../../../../../chunks/1206.js","../../../../../chunks/3314.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/@mui/material/styles/package.json","../../../../../../../node_modules/@mui/material/Paper/package.json","../../../../../../../node_modules/@mui/material/Table/package.json","../../../../../../../node_modules/@mui/material/TableBody/package.json","../../../../../../../node_modules/@mui/material/TableCell/package.json","../../../../../../../node_modules/@mui/material/TableContainer/package.json","../../../../../../../node_modules/@mui/material/TableHead/package.json","../../../../../../../node_modules/@mui/material/TableRow/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../package.json","../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js new file mode 100644 index 0000000..130cd39 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js @@ -0,0 +1,675 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6618; +exports.ids = [6618,8105,133,4135]; +exports.modules = { + +/***/ 6522: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "TablesContext": () => (/* binding */ TablesContext), + "default": () => (/* binding */ Tables), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/admin/databases/DeleteDatabaseConfirmationPopup.jsx +var DeleteDatabaseConfirmationPopup = __webpack_require__(5012); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +// EXTERNAL MODULE: ./components/admin/databases/TablesList.jsx + 3 modules +var TablesList = __webpack_require__(6734); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +;// CONCATENATED MODULE: ./components/admin/databases/TablesContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function TablesContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { tables , setTargetTable , database , query , confirmedDelegetedUser , user , } = external_react_default().useContext(TablesContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-2 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap gap-6", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0 flex flex-wrap gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "inline", + children: "All Tables in" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "inline relative", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}`, + className: "p-2 bg-white dark:bg-slate-800 rounded border border-solid border-slate-200 dark:border-slate-600 text-primary hover:text-primary_dark relative inline", + onClick: (e)=>{ + /** @type {HTMLAnchorElement} */ // @ts-ignore + const linkEl = e.target; + if (linkEl.closest(".copy-slug-span")) { + e.preventDefault(); + } + }, + style: { + wordBreak: "break-all" + }, + children: [ + database.db_name, + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-4 -right-4", + children: /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: database.db_slug, + justIcon: true + }) + }) + ] + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full md:w-auto", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + (!isDelegated || isDelegated && isTableCreatable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/add-table`, + className: "button flex items-center gap-2 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Table" + }) + ] + }), + !isDelegated && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users`, + className: "button dark", + children: "Users" + }) + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TablesList/* default */.Z, { + database: database, + tables: tables, + setTargetTable: setTargetTable, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + user: user + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/DeleteTableConfirmationPopup.jsx +var DeleteTableConfirmationPopup = __webpack_require__(1674); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").TablesContextType} */ // @ts-ignore +const init = {}; +const TablesContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def[]} props.tables + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function Tables({ user , database , tables , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `Tables For ${database.db_name} Database | Datasquirel`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ targetTable: import("@/package-shared/types").MYSQL_user_database_tables_table_def | null, setTargetTable: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def | null>> ]} */ // @ts-ignore + const [targetTable, setTargetTable] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(TablesContext.Provider, { + value: { + user, + database, + tables, + targetTable, + setTargetTable, + query, + confirmedDelegetedUser + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(TablesContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DeleteDatabaseConfirmationPopup/* default */.Z, { + targetDatabase: database + }), + /*#__PURE__*/ jsx_runtime_.jsx(DeleteTableConfirmationPopup/* default */.Z, { + database: database, + targetTable: targetTable + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Check delegated user token + * + * @description Check delegated user token + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + databaseSlug: query.single?.toString() || "", + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const { dbUserId , rootUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const tables = rootUserId ? await DB_HANDLER_default()(` + SELECT + delegated_user_tables.database,delegated_user_tables.table,user_database_tables.* + FROM + delegated_user_tables INNER JOIN user_database_tables ON delegated_user_tables.root_user_id=user_database_tables.user_id AND delegated_user_tables.table=user_database_tables.table_slug AND delegated_user_tables.database=user_database_tables.db_slug + WHERE + delegated_user_tables.delegated_user_id='${user.id}' AND delegated_user_tables.root_user_id='${rootUserId}' AND delegated_user_tables.database='${database[0].db_slug}' + `) : await DB_HANDLER_default()(`SELECT * FROM user_database_tables WHERE user_id='${user.id}' AND db_id='${database[0].id}'`); + if (!tables || !tables[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases/${database[0].db_slug}`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + tables: tables, + query, + confirmedDelegetedUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,5116,8345,4986,8264,1500,1674], () => (__webpack_exec__(6522))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js.nft.json new file mode 100644 index 0000000..9c21e8e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/5472.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/5116.js","../../../../../chunks/8345.js","../../../../../chunks/4986.js","../../../../../chunks/8264.js","../../../../../chunks/1500.js","../../../../../chunks/1674.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js new file mode 100644 index 0000000..5724878 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js @@ -0,0 +1,2458 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8848; +exports.ids = [8848,372,8105,133,4135,464,3314,1674]; +exports.modules = { + +/***/ 1674: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DeleteTableConfirmationPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_Breadcrumbs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(424); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5472); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def | null} [props.targetTable] + */ function DeleteTableConfirmationPopup({ targetTable , database , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .ZP, { + title: "delete-table-confirmation", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0", + children: [ + "Delete '", + targetTable?.table_name ? targetTable.table_name : "This Database", + "' Table?" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/deleteUserTable", { + method: "post", + body: { + database: database, + table: targetTable + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Yes" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Cancel" + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 5753: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ generateTypeDefinition) +/* harmony export */ }); +/* harmony import */ var _functions_frontend_defaultFieldsRegexp__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3907); +// @ts-check + +/** + * Generate a type definition for a query + * ============================================================================== + * @param {object} param0 + * @param {"JavaScript" | "TypeScript" | undefined} param0.paradigm + * @param {import("@/package-shared/types").DSQL_TableSchemaType} param0.table + * @param {any} param0.query + * @param {import("@/package-shared/types").UserType} [param0.user] + + * @returns {string | null} + */ function generateTypeDefinition({ paradigm , table , query , user , }) { + /** @type {string | null} */ let typeDefinition = ``; + try { + const tdName = `DSQL_${query.single}_${query.single_table}`.toUpperCase(); + const fields = table.fields; + function typeMap(/** @type {string} */ type) { + if (type?.match(/int/i)) { + return "number"; + } + if (type?.match(/text|varchar|timestamp/i)) { + return "string"; + } + return "string"; + } + const typesArrayTypeScript = []; + const typesArrayJavascript = []; + typesArrayTypeScript.push(`type ${tdName} = {`); + typesArrayJavascript.push(`/**\n * @typedef {object} ${tdName}`); + fields.forEach((field)=>{ + const nullValue = field.nullValue ? "?" : field.fieldName?.match(_functions_frontend_defaultFieldsRegexp__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z) ? "?" : ""; + typesArrayTypeScript.push(` ${field.fieldName}${nullValue}: ${typeMap(field.dataType || "")};`); + typesArrayJavascript.push(` * @property {${typeMap(field.dataType || "")}${nullValue}} ${field.fieldName}`); + }); + typesArrayTypeScript.push(`}`); + typesArrayJavascript.push(` */`); + if (paradigm?.match(/javascript/i)) { + typeDefinition = typesArrayJavascript.join("\n"); + } + if (paradigm?.match(/typescript/i)) { + typeDefinition = typesArrayTypeScript.join("\n"); + } + } catch (/** @type {any} */ error) { + console.log(error.message); + typeDefinition = null; + } + return typeDefinition; +} + + +/***/ }), + +/***/ 6169: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ExpandBlock) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {boolean} props.collapse + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setCollapse + */ function ExpandBlock({ collapse , setCollapse }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "collapse-block" + (collapse ? " -mt-16 -mb-6 pt-10" : " mt-0 mb-0 p-0"), + onClick: (e)=>{ + if (collapse) { + setCollapse(false); + } else { + setCollapse(true); + } + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: collapse ? "Expand" : "Collapse" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/down-arrow-dark.svg", + alt: "Down Arrow", + width: 16, + className: "dark:hidden opacity-30 " + (collapse ? "" : "rotate-180") + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/down-arrow-white.svg", + alt: "Down Arrow", + width: 16, + className: "opacity-30 hidden dark:flex " + (collapse ? "" : "rotate-180") + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 7809: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ grabTableSchemaData) +/* harmony export */ }); +/* harmony import */ var http__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3685); +/* harmony import */ var http__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(http__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2317); +/* harmony import */ var _serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5116); +/* harmony import */ var _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _grabUserSchemaData__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2527); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1206); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} grabTableSchemaDataReturn + * @property {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} [database] + * @property {import("@/package-shared/types").DSQL_TableSchemaType} [table] + * @property {import("@/package-shared/types").MYSQL_user_database_tables_table_def} [props.tableRecord] + * @property {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} [props.dbSchemaData] + * @property {any[]} [props.entries] + * @property {any} [props.query] + * @property {any} [props.confirmedDelegetedUser] + * @property {number} [props.entriesCount] + */ /** + * @param {object} params + * @param {http.IncomingMessage & { cookies: import("next/dist/server/api-utils").NextApiRequestCookies }} params.req - Database name slug + * @param {{ id: number, first_name: string, last_name: string }} params.user - user object + * @param {any} params.query - query params + * + * @returns {Promise<grabTableSchemaDataReturn | null>} new user auth object payload + */ async function grabTableSchemaData({ req , user , query }) { + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ const dbUserData = await _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default()({ + request: req, + user: user, + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + return null; + } + const { dbUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database?.[0]) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ let dbSchemaData = (0,_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)({ + userId: dbUserId + }); + if (!dbSchemaData) { + throw new Error("DB Schema not found!"); + } + /** @type {import("@/package-shared/types").DSQL_TableSchemaType[]| undefined} */ const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables?.filter((table)=>table.tableName === query.single_table)[0]; + const targetTableRecord = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT * FROM user_database_tables WHERE user_id='${dbUserId}' AND db_id='${database[0].id}' AND table_slug='${query.single_table}'`); + const tableEntries = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM ${targetTable?.tableName} ORDER BY id DESC LIMIT 10`, + tableSchema: targetTable + }); + const tableEntriesCount = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + database: database[0].db_full_name, + queryString: `SELECT COUNT(id) AS count FROM ${targetTable?.tableName}`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (confirmedDelegetedUser.rootUserId) { + const filteredDbSchema = dbSchemaData.filter((db)=>db.dbFullName == database[0].db_full_name); + let targetFilteredDb = filteredDbSchema[0]; + const filteredTables = targetFilteredDb.tables.filter(// @ts-ignore + (tbl)=>tbl.tableName === targetTable?.tableName); + targetFilteredDb.tables = filteredTables; + dbSchemaData = [ + targetFilteredDb + ]; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + confirmedDelegetedUser: confirmedDelegetedUser || null, + database: database[0] || null, + dbSchemaData: dbSchemaData || null, + entries: tableEntries || null, + entriesCount: tableEntriesCount?.[0]?.count || 0, + query, + table: targetTable, + tableRecord: targetTableRecord[0] || {} + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "[single_table]/index-page-component/getServerSideProps/catch-error]", + message: error.message, + user: user + }); + return {}; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 2527: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ grabUserSchemaData) +/* harmony export */ }); +// @ts-check +const serverError = __webpack_require__(2317); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * @param {Object} params + * @param {string | number} params.userId + * @returns {DSQL_DatabaseSchemaType[] | null} + */ function grabUserSchemaData({ userId }) { + try { + const userSchemaFilePath = path.resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${userId}/main.json`); + const userSchemaData = JSON.parse(fs.readFileSync(userSchemaFilePath, "utf-8")); + return userSchemaData; + } catch (/** @type {any} */ error) { + serverError({ + component: "/functions/backend/grabUserSchemaData", + message: error.message + }); + return null; + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 3907: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +// @ts-check +/** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const defaultFieldsRegexp = /^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (defaultFieldsRegexp); + + +/***/ }), + +/***/ 8382: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ updateTableAfterFieldsUpdateFunctionExt) +/* harmony export */ }); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params - Single object parameters + * @param {{delegated: boolean}} [params.query] - Query object + * @param {DSQL_TableSchemaType} params.table - Target table object + * @param {DSQL_MYSQL_user_databases_Type} params.database - Target MYSQL database record object + * @param {DSQL_DatabaseSchemaType[]} params.dbSchemaData - DSQL db schema + * @param {DSQL_FieldSchemaType[]} [params.tableFields] - Table Fields + * @param {DSQL_IndexSchemaType[]} [params.tableIndexes] - Table INdexes + * @param {React.Dispatch<React.SetStateAction<boolean>>} [params.setLoading] + */ function updateTableAfterFieldsUpdateFunctionExt({ query , table , database , dbSchemaData , tableFields , tableIndexes , setLoading , }) { + /** + * @description Initialize + */ let newDbSchemaData = [ + ...dbSchemaData + ]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + const dbIndex = newDbSchemaData.findIndex((db)=>db.dbFullName === database.db_full_name); + const targetDb = newDbSchemaData[dbIndex]; + const targetTableIndex = targetDb.tables.findIndex((_table)=>_table.tableName === table.tableName); + newDbSchemaData[dbIndex].tables[targetTableIndex].fields = tableFields ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableFields) : []; + newDbSchemaData[dbIndex].tables[targetTableIndex].indexes = tableIndexes ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableIndexes) : []; + const tempField = newDbSchemaData[dbIndex].tables[targetTableIndex].fields.find((fld)=>fld.newTempField); + if (tempField) { + window.alert("Please resolve all open fields before you save"); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } + (0,_fetchApi__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)("/api/updateDbSchemaDataForUser", { + method: "post", + body: { + schema: newDbSchemaData, + database: database.db_slug, + table: table, + delegated: query?.delegated + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert(res.msg || "Operation Failed. Please check permissions."); + } + }).finally(()=>{ + if (setLoading) { + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + } catch (/** @type {any} */ error) { + window.alert(error.message); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 4769: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleTableContext": () => (/* binding */ SingleTableContext), + "default": () => (/* binding */ SingleTable), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/admin/databases/DeleteTableConfirmationPopup.jsx +var DeleteTableConfirmationPopup = __webpack_require__(1674); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/databases/TableEntriesList.jsx + 1 modules +var TableEntriesList = __webpack_require__(6122); +// EXTERNAL MODULE: ./components/admin/databases/TableFields.jsx + 7 modules +var TableFields = __webpack_require__(4893); +;// CONCATENATED MODULE: ./functions/frontend/addNewTemplateIndex.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {DSQL_IndexSchemaType[]} params.tableIndexes + * @param {React.Dispatch<React.SetStateAction<DSQL_IndexSchemaType[]>>} params.setTableIndexes + * @param {React.Dispatch<React.SetStateAction<number>>} [params.setRefresh] + * @param {React.Dispatch<React.SetStateAction<number>>} [params.setPageRefresh] + * + * @requires search-field name attribute + */ function addNewTemplateIndex({ tableIndexes , setTableIndexes , setRefresh , setPageRefresh , }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ let newArray = tableIndexes && tableIndexes[0] ? tableIndexes : []; + newArray.push({ + newTempIndex: true + }); + setTableIndexes(newArray); + // setRefresh && setRefresh((prev) => prev + 1); + // setPageRefresh && setPageRefresh((prev) => prev + 1); + if (setRefresh) setRefresh((prev)=>prev + 1); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./functions/frontend/addNewIndex.js +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 1 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [NewIndexFieldTemp.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\NewIndexFieldTemp.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {number} params.fieldIndex + * @param {React.Dispatch<React.SetStateAction<DSQL_IndexSchemaType[]>>} params.setTableIndexes + * @param {React.Dispatch<React.SetStateAction<number>>} params.setRefresh + * @param {DSQL_IndexSchemaType} params.payload + * @requires search-field name attribute + */ function addNewIndex({ fieldIndex , setTableIndexes , setRefresh , payload , }) { + /** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ setTableIndexes((prev)=>{ + let newArray = prev; + newArray.splice(fieldIndex, 1, payload); + return newArray; + }); + // setRefresh && setRefresh((prev) => prev + 1); + // setPageRefresh && setPageRefresh((prev) => prev + 1); + if (setRefresh) setRefresh((prev)=>prev + 1); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +;// CONCATENATED MODULE: ./components/admin/databases/NewIndexFieldTemp.jsx +// @ts-check +/** # MODULE TRACE +====================================================================== + * Detected 1 files that call this module. The files are listed below: +====================================================================== + * `import` Statement Found in [TableIndexes.jsx] => file:///d:\GitHub\datasquirel\components\admin\databases\TableIndexes.jsx +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_IndexSchemaType} [props.tableIndex] + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {import("@/package-shared/types").DSQL_IndexSchemaType[]} [props.tableIndexes] + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexSchemaType[]>>} props.setTableIndexes + * @param {React.Dispatch<React.SetStateAction<number>>} props.setRefresh + * @param {import("@/package-shared/types").UserType} props.user + * @param {string|number} props.tableUniqueId + */ function NewIndexFieldTemp({ tableIndex , fieldIndex , currentTable , tableFields , tableIndexes , setTableIndexes , setRefresh , user , tableUniqueId , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const columnDesc = "Select Columns to be indexed. NB the order matters"; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [indexType, setIndexType] = external_react_default().useState("regular"); + /** @type {any} */ const indexTableFieldsState = external_react_default().useState(0); + /** @type {[ indexTableFields: import("@/package-shared/types").DSQL_IndexTableFieldType[], setIndexTableFields: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexTableFieldType[]>> ]} */ const [indexTableFields, setIndexTableFields] = indexTableFieldsState; + /** @type {React.LegacyRef<HTMLElement | undefined>} */ const newFieldRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + newFieldRef.current?.scrollIntoView({ + block: "center", + behavior: "smooth" + }); + newFieldRef.current?.querySelector("input")?.focus(); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full mt-1 xl:flex-nowrap flex-wrap", + // @ts-ignore + ref: newFieldRef, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-row items-start gap-4 w-full justify-between border border-solid p-4 pt-6 border-slate-400 rounded focus:shadow-lg shadow-slate-700/40 relative flex-wrap xl:flex-nowrap shadow-xl", + onSubmit: (e)=>{ + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + let new_index_name = formEl["new_index_name"].value.replace(/_index/, "").replace(/_{1,}$/, "") + "_index"; + if (!indexTableFields || !indexTableFields[0]) { + alert("Please Select at least 1 table column name"); + return; + } + /** @type {import("@/package-shared/types").DSQL_IndexSchemaType} */ let newIndexObject = { + indexType: indexType, + indexName: new_index_name, + indexTableFields, + alias: tableUniqueId + "_" + new_index_name + }; + addNewIndex({ + fieldIndex, + setTableIndexes, + payload: newIndexObject, + setRefresh + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "absolute -top-2 text-sm bg-fuchsia-600 text-white px-2 rounded-full", + children: "New Index" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-4 flex-wrap xl:flex-nowrap flex-col xl:flex-row items-stretch w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_required", + children: "Type" + }), + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "new_field_required", + id: "new_field_required", + className: "px-2", + onChange: (e)=>{ + setIndexType(e.target.value); + }, + children: indexType?.match(/regular/i) ? /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "regular", + children: "Default" + }) : /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "fullText", + children: "Full Text" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_index_name", + children: "Index Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "new_index_name", + id: "new_index_name", + placeholder: "Eg. title_index", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + inputEl.value = inputEl.value.toLowerCase().replace(/ /g, "_"); + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-4 xl:gap-0.5", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_data_type", + children: "Table Column(s)" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper reversed text-sm items-start gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex", + children: "Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mt-0 xl:-mt-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: columnDesc + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-auto flex flex-row items-stretch gap-4", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "new_field_data_type", + id: "new_field_data_type", + className: "w-full xl:w-auto", + onChange: (e)=>{ + if (e.target.value.match(/--/)) return; + const targetOption = Array.from(e.target.options).filter((option)=>option.value === e.target.value); + const dataType = targetOption[0].dataset.type; + if (dataType?.match(/text/i)) { + setIndexType("fullText"); + setIndexTableFields([ + { + value: e.target.value, + dataType: dataType + }, + ]); + } else { + try { + const existingTextDataType = indexTableFields.filter((obj)=>obj.dataType.match(/text/i)); + if (existingTextDataType[0]) throw new Error("TEXT type exists"); + let existingFieldsArray = indexTableFields; + if (existingFieldsArray.findIndex((obj)=>obj.value === e.target.value) >= 0 || e.target.value.match(/^--$/)) { + return; + } + if (dataType) { + existingFieldsArray.push({ + value: e.target.value, + dataType + }); + setIndexTableFields([ + ...existingFieldsArray, + ]); + } else { + window.alert("Datatype not provided. Please recheck fields."); + } + } catch (/** @type {any} */ error) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "NewIndexFieldTemp/lines-177-190", + message: error.message, + user: user + } + }); + if (dataType) { + setIndexTableFields([ + { + value: e.target.value, + dataType: dataType + }, + ]); + } else { + window.alert("Couldn't set Index Fields"); + } + } + setIndexType("regular"); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "--", + children: "--" + }), + tableFields.filter((field)=>!field?.fieldName?.match(/^id$|^date_/) && !field.foreignKey).map((field, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: field.fieldName, + "data-type": field.dataType, + children: field.fieldName + }, index + 1); + }) + ] + }), + indexTableFields && indexTableFields[0] && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "px-3 py-1 bg-slate-100 dark:bg-slate-500/10 rounded", + children: indexTableFields.map((field, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm px-3 py-1 bg-white dark:bg-slate-700 rounded-full shadow-lg font-bold flex items-center justify-center gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: field.value + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-normal w-5 h-5 rounded-full flex items-center justify-center cursor-pointer bg-slate-200 dark:bg-slate-600 text-xs hover:bg-slate-400", + onClick: (e)=>{ + let updatedArray = indexTableFields.filter((_field)=>!_field.value.match(new RegExp(`^${external_lodash_default().escapeRegExp(field.value)}$`))); + setIndexTableFields([ + ...updatedArray, + ]); + }, + children: "✖" + }) + ] + }, index + 1); + }) + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "secondary mt-auto flex-wrap xl:flex-nowrap w-full xl:w-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "secondary mt-auto py-3 w-full sm:w-auto justify-center grow", + children: "Add Index" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray mt-auto py-2.5 w-full sm:w-auto justify-center grow", + onClick: (e)=>{ + setTableIndexes((prev)=>prev.filter((field, index)=>index != fieldIndex)); + }, + children: "Cancel" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/defaultFieldsRegexp.js +var defaultFieldsRegexp = __webpack_require__(3907); +;// CONCATENATED MODULE: ./components/admin/databases/indexes/indexSelectChange.js +// @ts-check + +/** + * + * @param {object} param0 + * @param {any} param0.e + * @param {import("@/package-shared/types").DSQL_IndexTableFieldType[]} param0.indexTableFields + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexTableFieldType[]>>} param0.setIndexTableFields + * @param {React.Dispatch<React.SetStateAction<string>>} param0.setIndexType + * @param {import("@/package-shared/types").UserType} param0.user + * @returns + */ function indexSelectChange({ e , indexTableFields , setIndexTableFields , setIndexType , user , }) { + if (e.target.value.match(/--/)) return; + const targetOption = Array.from(e.target.options).filter((option)=>option.value === e.target.value); + const dataType = targetOption[0].dataset.type; + if (dataType.match(/text/i)) { + setIndexType("fullText"); + setIndexTableFields([ + { + value: e.target.value, + dataType: dataType + }, + ]); + } else { + try { + const existingTextDataType = indexTableFields.filter((obj)=>obj.dataType.match(/text/i)); + if (existingTextDataType[0]) throw new Error("TEXT type exists"); + let existingFieldsArray = indexTableFields; + if (existingFieldsArray.findIndex((obj)=>obj.value === e.target.value) >= 0 || e.target.value.match(/^--$/)) { + return; + } + existingFieldsArray.push({ + value: e.target.value, + dataType + }); + setIndexTableFields([ + ...existingFieldsArray + ]); + } catch (/** @type {any} */ error) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "ExistingIndexEdit/lines-184-197", + message: error.message, + user: user + } + }); + setIndexTableFields([ + { + value: e.target.value, + dataType: dataType + }, + ]); + } + setIndexType("regular"); + } +} + +;// CONCATENATED MODULE: ./components/admin/databases/ExistingIndexEdit.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_IndexSchemaType} props.targetIndexObject + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.MutableRefObject<React.Dispatch<React.SetStateAction<number>>>} [props.refreshFieldsListRef] + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexSchemaType[]>>} props.setTableIndexes + * @param {React.Dispatch<React.SetStateAction<number>>} props.setRefresh + * @param {React.Dispatch<React.SetStateAction<boolean>>} props.setActiveEdit + * @param {import("@/package-shared/types").UserType} props.user + * @param {string|number} props.tableUniqueId + */ function ExistingIndexEdit({ targetIndexObject , fieldIndex , tableFields , refreshFieldsListRef , setTableIndexes , setRefresh , setActiveEdit , user , tableUniqueId , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const columnDesc = "Select Columns to be indexed. NB the order matters"; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [indexData, setIndexData] = external_react_default().useState(targetIndexObject); + const [indexType, setIndexType] = external_react_default().useState(indexData.indexType || "regular"); + const [indexTableFields, setIndexTableFields] = external_react_default().useState(indexData.indexTableFields ? [ + ...indexData.indexTableFields + ] : []); + /** @type {React.MutableRefObject<HTMLElement | undefined>} */ const newFieldRef = external_react_default().useRef(); + external_react_default().useEffect(()=>{ + newFieldRef.current?.scrollIntoView({ + block: "center", + behavior: "smooth" + }); + newFieldRef.current?.querySelector("input")?.focus(); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full -mt-3 flex-wrap", + // @ts-ignore + ref: newFieldRef, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-col xl:flex-row items-start gap-4 w-full justify-between p-4 relative xl:flex-nowrap flex-wrap border border-t-0 border-slate-200 dark:border-slate-600 border-solid rounded-b", + onSubmit: (e)=>{ + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + let new_index_name = formEl["new_index_name"].value.replace(/_index/, "").replace(/_{1,}$/, "") + "_index"; + let newDataObject = indexData; + newDataObject.indexName = new_index_name; + newDataObject.alias = tableUniqueId + "_" + new_index_name, newDataObject.indexTableFields = indexTableFields; + setTableIndexes((prev)=>{ + let newArray = prev; + newArray[fieldIndex] = newDataObject; + return newArray; + }); + setActiveEdit(false); + setRefresh((prev)=>prev + 1); + }, + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-4 xl:flex-nowrap flex-wrap flex-col xl:flex-row items-stretch w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + style: { + minWidth: "70px" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_required", + children: "Type" + }), + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "new_field_required", + id: "new_field_required", + className: "px-2", + onChange: (e)=>{ + setIndexType(e.target.value); + setIndexData((prev)=>{ + let existingIndexData = prev; + existingIndexData.indexType = e.target.value; + return existingIndexData; + }); + }, + defaultValue: indexType, + children: indexType?.match(/regular/i) ? /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "regular", + children: "Default" + }) : /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "fullText", + children: "Full Text" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_index_name", + children: "Index Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "new_index_name", + id: "new_index_name", + placeholder: "Eg. title_index", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + inputEl.value = inputEl.value.toLowerCase().replace(/ /g, "_"); + }, + required: true, + defaultValue: indexData.indexName + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-4 xl:gap-0.5", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "new_field_data_type", + children: "Table Column(s)" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper reversed text-sm items-start gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex", + children: "Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mt-0 xl:-mt-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: columnDesc + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-auto flex flex-row items-stretch gap-4", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("select", { + name: "new_field_data_type", + id: "new_field_data_type", + className: "w-full xl:w-auto", + onChange: (e)=>{ + indexSelectChange({ + e, + indexTableFields, + setIndexTableFields, + setIndexType, + user + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "--", + children: "--" + }), + tableFields.filter((field)=>!field?.fieldName?.match(/^id$|^date_/) && !field.foreignKey).map((field, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: field.fieldName, + "data-type": field.dataType, + children: field.fieldName + }, index + 1); + }) + ] + }), + indexTableFields && indexTableFields[0] && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "card no-hover px-3 py-1 items-center", + children: indexTableFields.map((field, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm px-3 py-1 bg-white dark:bg-slate-700 rounded-full shadow-lg font-bold flex items-center justify-center gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: field.value + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-normal w-5 h-5 rounded-full flex items-center justify-center cursor-pointer bg-slate-200 text-xs hover:bg-slate-400", + onClick: (e)=>{ + let updatedArray = indexTableFields.filter((_field)=>!_field.value.match(new RegExp(`^${external_lodash_default().escapeRegExp(field.value)}$`))); + setIndexTableFields([ + ...updatedArray, + ]); + }, + children: "✖" + }) + ] + }, index + 1); + }) + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "secondary mt-auto xl:flex-nowrap flex-wrap w-full xl:w-auto", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "secondary mt-auto py-3 w-full md:w-auto grow", + children: "Save Updates" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray mt-auto py-2.5 w-full md:w-auto justify-center grow", + onClick: (e)=>{ + // const originIndexFields = targetIndexObject.indexTableFields + // setIndexTableFields([...originIndexFields]) + // setIndexData(targetIndexObject) + setActiveEdit(false); + }, + children: "Cancel" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +;// CONCATENATED MODULE: ./components/admin/databases/SingleTableIndexCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let SingleTableIndexCard_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_IndexSchemaType} props.tableIndex + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_IndexSchemaType[]} [props.tableIndexes] + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexSchemaType[]>>} props.setTableIndexes + * @param {React.MutableRefObject<React.Dispatch<React.SetStateAction<number>>>} [props.refreshFieldsListRef] + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} [props.currentTable] + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch<React.SetStateAction<number>>} props.setRefresh + * @param {any} props.confirmedDelegetedUser + * @param {import("@/package-shared/types").UserType} props.user + * @param {string|number} props.tableUniqueId + */ function SingleTableIndexCard({ tableIndex , fieldIndex , tableIndexes , setTableIndexes , refreshFieldsListRef , database , currentTable , tableFields , setRefresh , confirmedDelegetedUser , user , tableUniqueId , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [indexData, setindexData] = external_react_default().useState(tableIndex); + const [activeEdit, setActiveEdit] = external_react_default().useState(false); + const [refreshComp, setRefreshComp] = external_react_default().useState(0); + // React.useEffect(() => { + // setindexData(tableIndex) + // setRefreshComp(prev => prev + 1); + // }, [activeEdit]) + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full" + (activeEdit ? " shadow-xl shadow-slate-300/40 dark:shadow-black/30 relative z-50" : ""), + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover items-center w-full py-4" + (activeEdit ? " rounded-t" : " rounded") + (indexData.indexName?.match(defaultFieldsRegexp/* default */.Z) ? " text-slate-400 pointer-events-none border-slate-200 border" : ""), + onClick: (e)=>{ + // setTargetField(field); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold dark:text-white", + children: indexData.indexName + }), + !indexData.indexName?.match(defaultFieldsRegexp/* default */.Z) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "ml-0 md:ml-auto flex-wrap", + children: (!isDelegated || isDelegated && isTableEditable) && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(ButtonGroup/* default */.Z, { + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined gray smallest", + onClick: (e)=>{ + if (window.confirm(`Delete "${tableIndex.indexName}"?`)) { + setTableIndexes((prev)=>prev.filter((field, index)=>index != fieldIndex)); + } + }, + style: { + color: "var(--slate-500)" + }, + children: "Delete" + }) + }) + }) + }) + ] + }), + activeEdit && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full", + children: /*#__PURE__*/ jsx_runtime_.jsx(ExistingIndexEdit, { + fieldIndex: fieldIndex, + // tableIndexes={tableIndexes} + setTableIndexes: setTableIndexes, + refreshFieldsListRef: refreshFieldsListRef, + // targetField={tableIndex} + setActiveEdit: setActiveEdit, + // database={database} + // currentTable={currentTable} + tableFields: tableFields, + targetIndexObject: indexData, + setRefresh: setRefresh, + user: user, + tableUniqueId: tableUniqueId + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/TableIndexes.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let reactKey = 1; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {string|number} props.tableUniqueId + * @param {import("@/package-shared/types").DSQL_IndexSchemaType[]} props.tableIndexes + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexSchemaType[]>>} props.setTableIndexes + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {(setLoading?: React.Dispatch<React.SetStateAction<boolean>>) => void} props.updateTableAfterFieldsUpdateFunction + * @param {any} props.confirmedDelegetedUser + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + */ function TableIndexes({ user , table , tableUniqueId , tableIndexes , setTableIndexes , tableFields , updateTableAfterFieldsUpdateFunction , confirmedDelegetedUser , database , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const indexes = table.indexes; + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [refresh, setRefresh] = external_react_default().useState(0); + const [loading, setLoading] = external_react_default().useState(false); + const [collapse, setCollapse] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (isDelegated && !isTableEditable) { + return /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}); + } + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper blue", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + table.childTable ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left title", + children: "Indexes" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Table indexes are inherited from parent table" + }), + tableIndexes && tableIndexes[0] && tableIndexes.map((tableIndex, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card w-full light-gray py-4 no-hover items-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: tableIndex.indexName + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "info small gray grow-0 ml-auto w-auto", + children: [ + tableIndex.indexType, + " index" + ] + }) + ] + }, index); + }) + ] + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left title", + children: "Indexes" + }), + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button secondary outlined flex items-center gap-2", + onClick: (e)=>{ + if (collapse) setCollapse(false); + addNewTemplateIndex({ + tableIndexes, + setTableIndexes, + setRefresh + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Index" + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full", + style: collapse ? { + maxHeight: "200px" + } : {}, + children: [ + tableIndexes && tableIndexes[0] && tableIndexes.map((tableIndex, index)=>{ + reactKey++; + if (tableIndex.newTempIndex) { + return /*#__PURE__*/ jsx_runtime_.jsx(NewIndexFieldTemp, { + fieldIndex: index, + tableIndex: tableIndex, + currentTable: table, + tableIndexes: tableIndexes, + setTableIndexes: setTableIndexes, + tableFields: tableFields, + setRefresh: setRefresh, + user: user, + tableUniqueId: tableUniqueId + }, reactKey); + } else { + return /*#__PURE__*/ jsx_runtime_.jsx(SingleTableIndexCard, { + fieldIndex: index, + tableIndex: tableIndex, + database: database, + currentTable: table, + tableIndexes: tableIndexes, + setTableIndexes: setTableIndexes, + tableFields: tableFields, + setRefresh: setRefresh, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user, + tableUniqueId: tableUniqueId + }, reactKey); + } + }), + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "button outlined gray w-full justify-center more-padding", + style: { + borderStyle: "dashed" + }, + onClick: (e)=>{ + addNewTemplateIndex({ + tableIndexes, + setTableIndexes, + setRefresh + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Index" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button w-full blue", + onClick: (e)=>{ + setLoading(true); + updateTableAfterFieldsUpdateFunction && updateTableAfterFieldsUpdateFunction(setLoading); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Update Table Indexes" + }) + }) + ] + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/ActiveCloneTableBanner.jsx +var ActiveCloneTableBanner = __webpack_require__(8515); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/databases/SingleTableContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleTableContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , tableRecord , dbSchemaData , targetField , setTargetField , refreshFieldsListRef , setTableFields , tableFields , tableIndexes , setTableIndexes , updateTableAfterFieldsUpdateFunction , entries , targetEntry , setTargetEntry , richTextEditors , jsonTextEditors , query , confirmedDelegetedUser , entriesCount , } = external_react_default().useContext(SingleTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!database || !user || !tableRecord || !table) return; + const dataTypes = __webpack_require__(9594); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const { active_clone , active_clone_parent_db , remote_connected } = database; + const tableUniqueId = `dsql${user.id}${database.id}${tableRecord.id}`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-4 xl:gap-0 w-full relative z-50", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + table.tableFullName.replace(/ table/i, ""), + " ", + "Table" + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.tableName, + outlined: true + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-wrap flex-col md:flex-row w-full md:w-auto items-stretch md:items-center", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + className: "button flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Table Entry" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries`, + className: "button secondary flex items-center gap-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Entries" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/fields`, + className: "button outlined secondary flex items-center gap-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "All Fields" + }) + }), + (!isDelegated || isDelegated && (isTableEditable || isTableDeletable)) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "dropdown-wrapper mt-4 xl:mt-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "hidden xl:flex button outlined gray", + children: "More" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "dropdown mobile-transform right-aligned mt-0 xl:-mt-2 gap-2", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + column: true, + className: "w-full", + children: [ + (!isDelegated || isDelegated && isTableEditable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("a", { + className: "button outlined-gray more-padding w-full", + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/edit-table`, + children: "Edit Table" + }), + (!isDelegated || isDelegated && isTableDeletable) && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined-gray more-padding w-full", + onClick: (e)=>{ + if (window.confirm(`Delete "${table.tableFullName}" table?`)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/deleteUserTable", { + method: "post", + body: { + database: database, + table: { + table_slug: table.tableName + } + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }); + } + }, + children: "Delete Table" + }) + ] + }) + }) + ] + }) + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneTableBanner/* default */.Z, { + table: table, + database: database, + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx(TableFields/* default */.Z, { + user: user, + tableFields: tableFields, + setTableFields: setTableFields, + setTargetField: setTargetField, + refreshFieldsListRef: refreshFieldsListRef, + updateTable: true, + updateTableAfterFieldsUpdateFunction: updateTableAfterFieldsUpdateFunction, + collapsed: true, + database: database, + table: table, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query + }), + /*#__PURE__*/ jsx_runtime_.jsx(TableIndexes, { + user: user, + table: table, + tableUniqueId: tableUniqueId, + // dbSchemaData={dbSchemaData} + tableIndexes: tableIndexes, + setTableIndexes: setTableIndexes, + database: database, + tableFields: tableFields, + updateTableAfterFieldsUpdateFunction: updateTableAfterFieldsUpdateFunction, + confirmedDelegetedUser: confirmedDelegetedUser + }), + entries && dbSchemaData && richTextEditors && jsonTextEditors && /*#__PURE__*/ jsx_runtime_.jsx(TableEntriesList/* default */.Z, { + user: user, + entries: entries, + database: database, + table: table, + setTargetEntry: setTargetEntry, + dbSchemaData: dbSchemaData, + richTextEditors: richTextEditors, + dataTypes: dataTypes, + title: "Entries", + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors, + entriesCount: entriesCount + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/frontend/updateTableAfterFieldsUpdateFunctionExt.js +var updateTableAfterFieldsUpdateFunctionExt = __webpack_require__(8382); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2317); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./functions/backend/grabTableSchemaData.js +var grabTableSchemaData = __webpack_require__(7809); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/ScrollToTopButton.jsx +var ScrollToTopButton = __webpack_require__(9360); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").SingleTableContextType} */ // @ts-ignore +const init = {}; +const SingleTableContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def} props.tableRecord + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any[]} props.entries + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + * @param {number} props.entriesCount + */ function SingleTable({ user , database , table , tableRecord , dbSchemaData , entries , query , confirmedDelegetedUser , entriesCount , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${table.tableFullName} Table | Datasquirel`; + const pageDescription = "Single Table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [tableFields, setTableFields] = external_react_default().useState(table.fields); + /** @type {any} */ const tableIndexesState = external_react_default().useState(table.indexes); + /** @type {[ targetField: import("@/package-shared/types").DSQL_IndexSchemaType[], setTargetField: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_IndexSchemaType[]>> ]} */ const [tableIndexes, setTableIndexes] = tableIndexesState; + /** @type {any} */ const targetFieldState = external_react_default().useState(null); + /** @type {[ targetField: import("@/package-shared/types").DSQL_FieldSchemaType | null, setTargetField: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType | null>> ]} */ const [targetField, setTargetField] = targetFieldState; + const [targetEntry, setTargetEntry] = external_react_default().useState(null); + /** @type {React.MutableRefObject<React.Dispatch<React.SetStateAction<number>>>} */ // @ts-ignore + const refreshFieldsListRef = external_react_default().useRef(null); + // const targetFieldIndex = targetField ? tableFields.findIndex((field) => field.fieldName === targetField.fieldName) : 1; + const richTextEditors = external_react_default().useRef([]); + const jsonTextEditors = external_react_default().useRef([]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * + * @param {React.Dispatch<React.SetStateAction<boolean>>} [setLoading] + */ function updateTableAfterFieldsUpdateFunction(setLoading) { + (0,updateTableAfterFieldsUpdateFunctionExt/* default */.Z)({ + query, + table, + database, + dbSchemaData, + tableFields, + tableIndexes, + setLoading + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(SingleTableContext.Provider, { + value: { + user, + database, + table, + tableRecord, + dbSchemaData, + targetField, + setTargetField, + refreshFieldsListRef, + tableFields, + setTableFields, + tableIndexes, + setTableIndexes, + updateTableAfterFieldsUpdateFunction, + entries, + targetEntry, + setTargetEntry, + richTextEditors, + jsonTextEditors, + query, + confirmedDelegetedUser, + entriesCount + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SingleTableContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DeleteTableConfirmationPopup/* default */.Z, { + database: database, + targetTable: tableRecord + }), + /*#__PURE__*/ jsx_runtime_.jsx(ScrollToTopButton/* default */.Z, { + snug: true + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ const data = await (0,grabTableSchemaData/* default */.Z)({ + req, + query, + user + }); + if (!data) { + throw new Error("Data Fetching Error!"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + ...data + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError_default()({ + component: "[single_table]/index-page-component/getServerSideProps/catch-error]", + message: error.message, + user: user + }); + return { + redirect: { + destination: req.url ? req.url.replace(/\/[^\/]+$/, "") + (query?.delegated ? "?delegated=true" : "") : "/", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 2587: +/***/ ((module) => { + +module.exports = require("@monaco-editor/react"); + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 9438: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LibraryAddTwoTone"); + +/***/ }), + +/***/ 399: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 5453: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MoreHoriz"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 4287: +/***/ ((module) => { + +module.exports = require("gsap"); + +/***/ }), + +/***/ 2700: +/***/ ((module) => { + +module.exports = require("gsap/Flip"); + +/***/ }), + +/***/ 2329: +/***/ ((module) => { + +module.exports = require("html-prettify"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 7076: +/***/ ((module) => { + +module.exports = require("react-tiny-popover"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,9360,4941,7023,7901,4114,8682,2317,1206,5116,8345,4986,9594,8264,9471,9967,4893,9788,9035], () => (__webpack_exec__(4769))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js.nft.json new file mode 100644 index 0000000..5f854d0 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/9360.js","../../../../../../chunks/4941.js","../../../../../../chunks/7023.js","../../../../../../chunks/7901.js","../../../../../../chunks/4114.js","../../../../../../chunks/8682.js","../../../../../../chunks/2317.js","../../../../../../chunks/1206.js","../../../../../../chunks/5116.js","../../../../../../chunks/8345.js","../../../../../../chunks/4986.js","../../../../../../chunks/9594.js","../../../../../../chunks/8264.js","../../../../../../chunks/9471.js","../../../../../../chunks/9967.js","../../../../../../chunks/4893.js","../../../../../../chunks/9788.js","../../../../../../chunks/9035.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lodash/package.json","../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../node_modules/gsap/package.json","../../../../../../../../node_modules/html-prettify/package.json","../../../../../../../../node_modules/react-tiny-popover/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/@monaco-editor/react/package.json","../../../../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../node_modules/gsap/dist/gsap.js","../../../../../../../../node_modules/html-prettify/src/index.js","../../../../../../../../node_modules/react-tiny-popover/dist/Popover.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/@mui/material/node/index.js","../../../../../../../../node_modules/@monaco-editor/react/dist/index.js","../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../node_modules/gsap/Flip.js","../../../../../../../../node_modules/@mui/icons-material/LibraryAddTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LockOutlined.js","../../../../../../../../node_modules/@mui/icons-material/MoreHoriz.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../node_modules/gsap/utils/matrix.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/react-tiny-popover/dist/PopoverPortal.js","../../../../../../../../node_modules/react-tiny-popover/dist/util.js","../../../../../../../../node_modules/react-tiny-popover/dist/useMemoizedArray.js","../../../../../../../../node_modules/react-tiny-popover/dist/useHandlePrevValues.js","../../../../../../../../node_modules/react-tiny-popover/dist/usePopover.js","../../../../../../../../node_modules/react-tiny-popover/dist/ArrowContainer.js","../../../../../../../../node_modules/react-tiny-popover/dist/useArrowContainer.js","../../../../../../../../node_modules/html-prettify/src/utils/addIndentation.js","../../../../../../../../node_modules/html-prettify/src/utils/toLines.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../../../../node_modules/@mui/material/node/List/index.js","../../../../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../../../../node_modules/react-tiny-popover/dist/useElementRef.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/base/node/index.js","../../../../../../../../node_modules/@monaco-editor/loader/package.json","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/index.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../../../../node_modules/@mui/material/node/List/List.js","../../../../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/loader/index.js","../../../../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../../../../node_modules/@mui/base/Portal/package.json","../../../../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/material/node/className/index.js","../../../../../../../../node_modules/@mui/base/utils/package.json","../../../../../../../../node_modules/@mui/base/Popper/package.json","../../../../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/_virtual/_rollupPluginBabelHelpers.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/config/index.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/validators/index.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/compose.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/deepMerge.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/makeCancelable.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../../../../node_modules/react-transition-group/package.json","../../../../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/curry.js","../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/isObject.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/state-local/package.json","../../../../../../../../node_modules/state-local/lib/cjs/state-local.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../../../../node_modules/@popperjs/core/package.json","../../../../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/dom-helpers/package.json","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@floating-ui/dom/package.json","../../../../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/@floating-ui/core/package.json","../../../../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../package.json","../../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js new file mode 100644 index 0000000..347eba4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js @@ -0,0 +1,1138 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4504; +exports.ids = [4504,8105,133,3316,4135]; +exports.modules = { + +/***/ 8515: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ActiveCloneTableBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5557); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {number} [props.activeDbClone] + * @param {import("@/package-shared/types").UserType} props.user + */ function ActiveCloneTableBanner({ table , database , user , activeDbClone , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const cloneParentDb = table?.childTableDbFullName ? table.childTableDbFullName.replace(new RegExp(/datasquirel_user_\d+_/), "") : null; + const isCurrentDb = table.childTableDbFullName === database.db_full_name; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (!cloneParentDb) return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "info small green gap-1" + (database?.active_clone ? " -mt-6" : ""), + style: { + fontWeight: "500" + }, + children: [ + "This Table is an active clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}/tables/${table.childTableName}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: table.childTableName + }) + }), + " ", + "in", + " ", + isCurrentDb ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + children: [ + "this current database(", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: database.db_name + }), + ")." + ] + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: cloneParentDb + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "database." + }) + ] + }), + " ", + database?.active_clone ? "" : "Only Foreign keys and Entries can be updated." + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 8382: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ updateTableAfterFieldsUpdateFunctionExt) +/* harmony export */ }); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params - Single object parameters + * @param {{delegated: boolean}} [params.query] - Query object + * @param {DSQL_TableSchemaType} params.table - Target table object + * @param {DSQL_MYSQL_user_databases_Type} params.database - Target MYSQL database record object + * @param {DSQL_DatabaseSchemaType[]} params.dbSchemaData - DSQL db schema + * @param {DSQL_FieldSchemaType[]} [params.tableFields] - Table Fields + * @param {DSQL_IndexSchemaType[]} [params.tableIndexes] - Table INdexes + * @param {React.Dispatch<React.SetStateAction<boolean>>} [params.setLoading] + */ function updateTableAfterFieldsUpdateFunctionExt({ query , table , database , dbSchemaData , tableFields , tableIndexes , setLoading , }) { + /** + * @description Initialize + */ let newDbSchemaData = [ + ...dbSchemaData + ]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + const dbIndex = newDbSchemaData.findIndex((db)=>db.dbFullName === database.db_full_name); + const targetDb = newDbSchemaData[dbIndex]; + const targetTableIndex = targetDb.tables.findIndex((_table)=>_table.tableName === table.tableName); + newDbSchemaData[dbIndex].tables[targetTableIndex].fields = tableFields ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableFields) : []; + newDbSchemaData[dbIndex].tables[targetTableIndex].indexes = tableIndexes ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableIndexes) : []; + const tempField = newDbSchemaData[dbIndex].tables[targetTableIndex].fields.find((fld)=>fld.newTempField); + if (tempField) { + window.alert("Please resolve all open fields before you save"); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } + (0,_fetchApi__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)("/api/updateDbSchemaDataForUser", { + method: "post", + body: { + schema: newDbSchemaData, + database: database.db_slug, + table: table, + delegated: query?.delegated + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert(res.msg || "Operation Failed. Please check permissions."); + } + }).finally(()=>{ + if (setLoading) { + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + } catch (/** @type {any} */ error) { + window.alert(error.message); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 8239: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "EditTableContext": () => (/* binding */ EditTableContext), + "default": () => (/* binding */ EditTable), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/checkUniqueField.js +var checkUniqueField = __webpack_require__(4105); +// EXTERNAL MODULE: ./components/admin/databases/TableFields.jsx + 7 modules +var TableFields = __webpack_require__(4893); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/FormAlertBlock.jsx +var FormAlertBlock = __webpack_require__(7037); +;// CONCATENATED MODULE: ./components/admin/databases/EditTableForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditTableForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , table , tableFields , database , query , confirmedDelegetedUser , } = external_react_default().useContext(EditTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * ## Check Duplicate Slug Function + * @param {string} value + */ async function checkDuplicateSlug(value) { + const duplicate = await (0,checkUniqueField/* default */.Z)({ + tableName: "user_database_tables", + columnName: "table_slug", + value: value, + userId: user.id + }); + return duplicate; + } + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const alertState = external_react_default().useState(null); + /** @type {[ alert: string | null, setAlert: React.Dispatch<React.SetStateAction<string | null>> ]} */ const [alert, setAlert] = alertState; + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: (!isDelegated || isDelegated && isTableEditable) && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "Update Table Information" + }), + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-start gap-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + const table_name_full = formEl["table_name"].value; + const table_name = formEl["table_slug"].value; + const table_description = formEl["table_description"].value; + const tableObject = { + tableName: table_name, + tableFullName: table_name_full, + tableDescription: table_description + }; + // submitNewDatabaseForm({ e, setLoading }) + (0,fetchApi/* default */.Z)("/api/updateUserTable", { + method: "post", + body: { + dbFullName: database.db_full_name, + dbSlug: database.db_slug, + dbId: database.id, + tableNameOld: table.tableName, + payload: tableObject, + delegated: query?.delegated + } + }, true).then((res)=>{ + if (res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/tables` + window.location.search; + } else { + window.alert("Failed to update Table! Please Try again."); + window.location.reload(); + } + }); + }, + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx(FormAlertBlock/* default */.Z, { + message: alert + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_name", + children: "Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "table_name", + id: "table_name", + placeholder: "Table Name", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + /** @type {HTMLFormElement} */ // @ts-ignore + const form = inputEl.closest("form"); + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + form["table_slug"].value = inputEl.value.toLowerCase().replace(/ /g, "_").replace(/[^a-zA-Z0-9-_]/g, ""); + let slugValue = form["table_slug"].value; + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + checkDuplicateSlug(slugValue).then((res)=>{ + if (res.result && slugValue !== table.tableName) { + form["table_slug"].classList.add("warning"); + setAlert("Duplicate Table Name"); + } else { + form["table_slug"].classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + }, + required: true, + defaultValue: table.tableFullName + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_slug", + children: "Slug" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "table_slug", + id: "table_slug", + placeholder: "Table Slug", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + /** @type {HTMLFormElement} */ // @ts-ignore + const form = inputEl.closest("form"); + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + checkDuplicateSlug(inputEl.value).then((res)=>{ + if (res.result) { + inputEl.classList.add("warning"); + setAlert("Duplicate Table Slug"); + } else { + inputEl.classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + }, + required: true, + defaultValue: table.tableName + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_description", + children: "Description (optional)" + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: "table_description", + id: "table_description", + placeholder: "Short Description of Table", + defaultValue: table.tableDescription + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "w-full" + (loading ? " pointer-events-none opacity-40" : ""), + id: "create-new-table-form-submit-button", + children: "Update Table Info" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/updateTableAfterFieldsUpdateFunctionExt.js +var updateTableAfterFieldsUpdateFunctionExt = __webpack_require__(8382); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/ActiveCloneTableBanner.jsx +var ActiveCloneTableBanner = __webpack_require__(8515); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/databases/EditTableContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function EditTableContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , tableFields , setTableFields , setTargetField , refreshFieldsListRef , dbSchemaData , query , confirmedDelegetedUser , } = external_react_default().useContext(EditTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ function updateTableAfterFieldsUpdateFunction() { + (0,updateTableAfterFieldsUpdateFunctionExt/* default */.Z)({ + query, + table, + database, + dbSchemaData, + tableFields, + tableIndexes: table.indexes + }); + } + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Edit" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}`, + className: "p-2 bg-white dark:bg-slate-800 rounded border border-solid border-slate-200 dark:border-slate-600 ml-2 text-primary hover:text-primary_dark", + children: table.tableFullName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "ml-2", + children: "Table" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneTableBanner/* default */.Z, { + table: table, + database: database, + user: user + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(EditTableForm, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TableFields/* default */.Z, { + user: user, + tableFields: tableFields, + setTableFields: setTableFields, + setTargetField: setTargetField, + refreshFieldsListRef: refreshFieldsListRef, + updateTable: true, + database: database, + updateTableAfterFieldsUpdateFunction: updateTableAfterFieldsUpdateFunction, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + table: table + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(2527); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").EditTableContextType} */ // @ts-ignore +const init = {}; +const EditTableContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function EditTable({ user , database , table , dbSchemaData , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `Edit Table | Datasquirel`; + const pageDescription = "Edit Table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [tableFields, setTableFields] = external_react_default().useState(table.fields); + /** @type {[ targetField: import("@/package-shared/types").DSQL_FieldSchemaType | null, setTargetField: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType | null>> ]} */ // @ts-ignore + const [targetField, setTargetField] = external_react_default().useState(null); + const [pageRefresh, setPageRefresh] = external_react_default().useState(0); + const refreshFieldsListRef = external_react_default().useRef(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(EditTableContext.Provider, { + value: { + user, + database, + table, + tableFields, + setTableFields, + targetField, + setTargetField, + pageRefresh, + setPageRefresh, + refreshFieldsListRef, + dbSchemaData, + query, + confirmedDelegetedUser + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(EditTableContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Check delegated user token + * + * @description Check delegated user token + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + // @ts-ignore + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + throw new Error("No Db Object Found!"); + } + const { dbUserId , rootUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + const dbSchemaData = (0,grabUserSchemaData/* default */.Z)({ + userId: dbUserId + }); + if (!dbSchemaData) throw new Error("User schema data not found!"); + /** @type {import("@/package-shared/types").DSQL_TableSchemaType[] | undefined} */ const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)?.[0]?.tables; + const targetTable = tables?.filter((table)=>table.tableName === query.single_table)[0]; + if (!tables || !targetTable) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + dbSchemaData: dbSchemaData, + table: targetTable, + query, + confirmedDelegetedUser + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + return { + redirect: { + destination: "/", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 4287: +/***/ ((module) => { + +module.exports = require("gsap"); + +/***/ }), + +/***/ 2700: +/***/ ((module) => { + +module.exports = require("gsap/Flip"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7901,2317,5116,8345,4986,9594,8264,9471,7037,9967,464,4105,3314,4893], () => (__webpack_exec__(8239))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js.nft.json new file mode 100644 index 0000000..59e402e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../webpack-runtime.js","../../../../../../../chunks/4017.js","../../../../../../../chunks/8313.js","../../../../../../../chunks/5264.js","../../../../../../../chunks/6729.js","../../../../../../../chunks/5449.js","../../../../../../../chunks/5304.js","../../../../../../../chunks/913.js","../../../../../../../chunks/9395.js","../../../../../../../chunks/370.js","../../../../../../../chunks/424.js","../../../../../../../chunks/4858.js","../../../../../../../chunks/5472.js","../../../../../../../chunks/1781.js","../../../../../../../chunks/4941.js","../../../../../../../chunks/7901.js","../../../../../../../chunks/2317.js","../../../../../../../chunks/5116.js","../../../../../../../chunks/8345.js","../../../../../../../chunks/4986.js","../../../../../../../chunks/9594.js","../../../../../../../chunks/8264.js","../../../../../../../chunks/9471.js","../../../../../../../chunks/7037.js","../../../../../../../chunks/9967.js","../../../../../../../chunks/464.js","../../../../../../../chunks/4105.js","../../../../../../../chunks/3314.js","../../../../../../../chunks/4893.js","../../../../../../../../package.json","../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../node_modules/lodash/package.json","../../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../../node_modules/gsap/package.json","../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../../node_modules/gsap/dist/gsap.js","../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../node_modules/next/head.js","../../../../../../../../../node_modules/next/package.json","../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../../node_modules/gsap/Flip.js","../../../../../../../../../node_modules/react/package.json","../../../../../../../../../node_modules/react/index.js","../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../../node_modules/gsap/utils/matrix.js","../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../../package.json","../../../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js new file mode 100644 index 0000000..977f7d4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js @@ -0,0 +1,326 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 372; +exports.ids = [372,8105,133,4135]; +exports.modules = { + +/***/ 2587: +/***/ ((module) => { + +module.exports = require("@monaco-editor/react"); + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 9438: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LibraryAddTwoTone"); + +/***/ }), + +/***/ 399: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 5453: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MoreHoriz"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2329: +/***/ ((module) => { + +module.exports = require("html-prettify"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 7076: +/***/ ((module) => { + +module.exports = require("react-tiny-popover"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,9360,4941,7023,7901,4114,8682,2317,1206,5116,8345,4986,9594,8264,9471,464,9788,9035], () => (__webpack_exec__(7722))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js.nft.json new file mode 100644 index 0000000..7f8a98b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../webpack-runtime.js","../../../../../../../chunks/4017.js","../../../../../../../chunks/8313.js","../../../../../../../chunks/5264.js","../../../../../../../chunks/6729.js","../../../../../../../chunks/5449.js","../../../../../../../chunks/5304.js","../../../../../../../chunks/913.js","../../../../../../../chunks/9395.js","../../../../../../../chunks/370.js","../../../../../../../chunks/424.js","../../../../../../../chunks/4858.js","../../../../../../../chunks/5472.js","../../../../../../../chunks/1781.js","../../../../../../../chunks/9360.js","../../../../../../../chunks/4941.js","../../../../../../../chunks/7023.js","../../../../../../../chunks/7901.js","../../../../../../../chunks/4114.js","../../../../../../../chunks/8682.js","../../../../../../../chunks/2317.js","../../../../../../../chunks/1206.js","../../../../../../../chunks/5116.js","../../../../../../../chunks/8345.js","../../../../../../../chunks/4986.js","../../../../../../../chunks/9594.js","../../../../../../../chunks/8264.js","../../../../../../../chunks/9471.js","../../../../../../../chunks/464.js","../../../../../../../chunks/9788.js","../../../../../../../chunks/9035.js","../../../../../../../../package.json","../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../node_modules/lodash/package.json","../../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../../node_modules/html-prettify/package.json","../../../../../../../../../node_modules/react-tiny-popover/package.json","../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../node_modules/@monaco-editor/react/package.json","../../../../../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../../node_modules/html-prettify/src/index.js","../../../../../../../../../node_modules/react-tiny-popover/dist/Popover.js","../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../node_modules/@mui/material/node/index.js","../../../../../../../../../node_modules/@monaco-editor/react/dist/index.js","../../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../node_modules/next/head.js","../../../../../../../../../node_modules/next/package.json","../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LibraryAddTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LockOutlined.js","../../../../../../../../../node_modules/@mui/icons-material/MoreHoriz.js","../../../../../../../../../node_modules/react/package.json","../../../../../../../../../node_modules/react/index.js","../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../node_modules/react-tiny-popover/dist/PopoverPortal.js","../../../../../../../../../node_modules/react-tiny-popover/dist/util.js","../../../../../../../../../node_modules/react-tiny-popover/dist/useMemoizedArray.js","../../../../../../../../../node_modules/react-tiny-popover/dist/useHandlePrevValues.js","../../../../../../../../../node_modules/react-tiny-popover/dist/usePopover.js","../../../../../../../../../node_modules/react-tiny-popover/dist/ArrowContainer.js","../../../../../../../../../node_modules/react-tiny-popover/dist/useArrowContainer.js","../../../../../../../../../node_modules/html-prettify/src/utils/addIndentation.js","../../../../../../../../../node_modules/html-prettify/src/utils/toLines.js","../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../../../../../node_modules/@mui/material/node/List/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../../../../../node_modules/react-tiny-popover/dist/useElementRef.js","../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../node_modules/@mui/base/node/index.js","../../../../../../../../../node_modules/@monaco-editor/loader/package.json","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/index.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../../../../../node_modules/@mui/material/node/List/List.js","../../../../../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/loader/index.js","../../../../../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../../../../../node_modules/@mui/base/Portal/package.json","../../../../../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../node_modules/@mui/material/node/className/index.js","../../../../../../../../../node_modules/@mui/base/utils/package.json","../../../../../../../../../node_modules/@mui/base/Popper/package.json","../../../../../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/_virtual/_rollupPluginBabelHelpers.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/config/index.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/validators/index.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/compose.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/deepMerge.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/makeCancelable.js","../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../../../../../node_modules/react-transition-group/package.json","../../../../../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/curry.js","../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/isObject.js","../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../node_modules/state-local/package.json","../../../../../../../../../node_modules/state-local/lib/cjs/state-local.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../../../../../node_modules/@popperjs/core/package.json","../../../../../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../node_modules/dom-helpers/package.json","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../node_modules/@floating-ui/dom/package.json","../../../../../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../node_modules/@floating-ui/core/package.json","../../../../../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js new file mode 100644 index 0000000..757a4f3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js @@ -0,0 +1,938 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6306; +exports.ids = [6306,372,8105,133,4135]; +exports.modules = { + +/***/ 3285: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleEntryContext": () => (/* binding */ SingleEntryContext), + "default": () => (/* binding */ SingleEntry), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/admin/databases/TableEntriesList.jsx + 1 modules +var TableEntriesList = __webpack_require__(6122); +// EXTERNAL MODULE: ./components/admin/databases/UpdateEntryForm.jsx + 1 modules +var UpdateEntryForm = __webpack_require__(1985); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +;// CONCATENATED MODULE: ./components/admin/databases/SingleEntryPrevNext.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleEntryPrevNext(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { prevEntry , nextEntry , database , table , user } = external_react_default().useContext(SingleEntryContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "row gap-3 flex-wrap", + children: [ + prevEntry && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${prevEntry.id}`, + className: "button outlined gray", + children: "Prev" + }), + nextEntry && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${nextEntry.id}`, + className: "button outlined gray", + children: "Next" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +;// CONCATENATED MODULE: ./components/admin/databases/SelectNewEntry.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SelectNewEntry(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { entry , targetEntry , database , table , user } = external_react_default().useContext(SingleEntryContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [entries, setEntries] = external_react_default().useState([]); + const defaultField = (()=>{ + const fields = Object.keys(entry); + if (fields[1].match(/uuid/i)) return fields[2]; + return fields[1]; + })(); + external_react_default().useEffect(()=>{ + /** @type {import("@/pages/api/fetch-entries-basic").FetchEntriesBasicBody} */ const fetchBody = { + dbId: database.id, + dbSlug: database.db_slug, + tableName: table.tableName, + isTitle: Boolean(entry.title), + isSlug: Boolean(entry.slug), + isFullName: Boolean(entry.first_name) && Boolean(entry.last_name), + defaultField: defaultField + }; + (0,fetchApi/* default */.Z)("/api/fetch-entries-basic", { + method: "POST", + body: fetchBody + }, true).then((res)=>{ + if (res.entries?.[0]) setEntries(res.entries); + }).catch((err)=>console.log(err)); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!entries?.[0]) return null; + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "row gap-3 flex-wrap min-w-[80px]", + children: /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: entries.map((/** @type {any} */ basicEntry)=>({ + title: basicEntry.title || basicEntry.slug || basicEntry.full_name || basicEntry[defaultField] || basicEntry.id, + payload: basicEntry.id, + default: entry.id == basicEntry.id + })), + onChangeHandler: (e)=>{ + const newUrl = `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${e.target.value}`; + window.location.href = `${newUrl}${window.location.search}`; + } + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/SingleEntryContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleEntryContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , dbSchemaData , entry , setTargetEntry , richTextEditors , jsonTextEditors , query , confirmedDelegetedUser , } = external_react_default().useContext(SingleEntryContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const dataTypes = __webpack_require__(9594); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full relative z-50", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "inline-block", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "bg-slate-100 dark:bg-slate-800 px-2 py-1 border border-solid border-slate-400 dark:border-slate-600 rounded relative", + children: [ + table?.tableFullName, + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-5 -right-4", + children: table?.tableName && /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.tableName, + justIcon: true + }) + }) + ] + }), + " ", + "Table Entry #" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: entry.id + }) + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + database && table ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + className: "button flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Entry" + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Db and Table" + }), + /*#__PURE__*/ jsx_runtime_.jsx(SingleEntryPrevNext, {}), + /*#__PURE__*/ jsx_runtime_.jsx(SelectNewEntry, {}) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database?.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UpdateEntryForm/* default */.Z, { + user: user, + database: database, + table: table, + dbSchemaData: dbSchemaData, + richTextEditors: richTextEditors, + dataTypes: dataTypes, + entry: entry, + entryPage: true, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2317); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./layouts/components/GeneralLayout/ScrollToTopButton.jsx +var ScrollToTopButton = __webpack_require__(9360); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").SingleEntryContextType} */ // @ts-ignore +const init = {}; +const SingleEntryContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.entry + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + * @param {any} props.prevEntry + * @param {any} props.nextEntry + */ function SingleEntry({ user , database , table , dbSchemaData , entry , query , confirmedDelegetedUser , prevEntry , nextEntry , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${table.tableFullName} Table | Datasquirel`; + const pageDescription = "Single Table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [targetEntry, setTargetEntry] = external_react_default().useState(entry); + const richTextEditors = external_react_default().useRef([]); + const jsonTextEditors = external_react_default().useRef([]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + aceEditor: true, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(SingleEntryContext.Provider, { + value: { + user, + database, + table, + dbSchemaData, + entry, + richTextEditors, + jsonTextEditors, + targetEntry, + setTargetEntry, + query, + confirmedDelegetedUser, + prevEntry, + nextEntry + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SingleEntryContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ScrollToTopButton/* default */.Z, { + snug: true + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ /** @type {string} */ // @ts-ignore + const dbSlug = query.single; + const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + databaseSlug: dbSlug, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + throw new Error("No Db Object Found!"); + } + const { dbUserId , rootUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === query.single_table)[0]; + //////////////////////////////////////// + const targetEntryQuery = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM ${targetTable.tableName} WHERE id='${query.single_entry}'`, + tableSchema: targetTable + }); + if (!targetEntryQuery?.[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases/${database[0].db_slug}/tables/${targetTable.tableName}/entries`, + permanent: false + } + }; + } + const targetEntry = targetEntryQuery[0]; + const nextEntry = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT id FROM ${targetTable.tableName} WHERE id > '${query.single_entry}' LIMIT 1`, + tableSchema: targetTable + }); + const prevEntry = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT id FROM ${targetTable.tableName} WHERE id < '${query.single_entry}' ORDER BY id DESC LIMIT 1`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + table: targetTable, + dbSchemaData: dbSchemaData, + entry: targetEntry, + query, + confirmedDelegetedUser, + nextEntry: nextEntry?.[0] || null, + prevEntry: prevEntry?.[0] || null + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError_default()({ + component: "[single_entry]-page-component/getServerSideProps/catch-error", + message: error.message, + user: user + }); + return { + // redirect: { + // destination: "/login", + // permanent: false + // }, + props: { + user: user, + database: null, + table: null, + entry: null + } + }; + } +} + + +/***/ }), + +/***/ 2587: +/***/ ((module) => { + +module.exports = require("@monaco-editor/react"); + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 9438: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LibraryAddTwoTone"); + +/***/ }), + +/***/ 399: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 5453: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MoreHoriz"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2329: +/***/ ((module) => { + +module.exports = require("html-prettify"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 7076: +/***/ ((module) => { + +module.exports = require("react-tiny-popover"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,9360,4941,7023,7901,4114,8682,2317,1206,5116,8345,4986,9594,8264,9471,464,9788,9035], () => (__webpack_exec__(3285))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js.nft.json new file mode 100644 index 0000000..1303a6b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../../webpack-runtime.js","../../../../../../../../chunks/4017.js","../../../../../../../../chunks/8313.js","../../../../../../../../chunks/5264.js","../../../../../../../../chunks/6729.js","../../../../../../../../chunks/5449.js","../../../../../../../../chunks/5304.js","../../../../../../../../chunks/913.js","../../../../../../../../chunks/9395.js","../../../../../../../../chunks/370.js","../../../../../../../../chunks/424.js","../../../../../../../../chunks/4858.js","../../../../../../../../chunks/5472.js","../../../../../../../../chunks/1781.js","../../../../../../../../chunks/9360.js","../../../../../../../../chunks/4941.js","../../../../../../../../chunks/7023.js","../../../../../../../../chunks/7901.js","../../../../../../../../chunks/4114.js","../../../../../../../../chunks/8682.js","../../../../../../../../chunks/2317.js","../../../../../../../../chunks/1206.js","../../../../../../../../chunks/5116.js","../../../../../../../../chunks/8345.js","../../../../../../../../chunks/4986.js","../../../../../../../../chunks/9594.js","../../../../../../../../chunks/8264.js","../../../../../../../../chunks/9471.js","../../../../../../../../chunks/464.js","../../../../../../../../chunks/9788.js","../../../../../../../../chunks/9035.js","../../../../../../../../../package.json","../../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../../node_modules/lodash/package.json","../../../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../../../node_modules/html-prettify/package.json","../../../../../../../../../../node_modules/react-tiny-popover/package.json","../../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../../node_modules/@monaco-editor/react/package.json","../../../../../../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../../../node_modules/html-prettify/src/index.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/Popover.js","../../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../../node_modules/@mui/material/node/index.js","../../../../../../../../../../node_modules/@monaco-editor/react/dist/index.js","../../../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../../node_modules/next/head.js","../../../../../../../../../../node_modules/next/package.json","../../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/LibraryAddTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/LockOutlined.js","../../../../../../../../../../node_modules/@mui/icons-material/MoreHoriz.js","../../../../../../../../../../node_modules/react/package.json","../../../../../../../../../../node_modules/react/index.js","../../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/PopoverPortal.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/util.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/useMemoizedArray.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/useHandlePrevValues.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/usePopover.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/ArrowContainer.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/useArrowContainer.js","../../../../../../../../../../node_modules/html-prettify/src/utils/addIndentation.js","../../../../../../../../../../node_modules/html-prettify/src/utils/toLines.js","../../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../../../../../../node_modules/@mui/material/node/List/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../../../../../../node_modules/react-tiny-popover/dist/useElementRef.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../../node_modules/@mui/base/node/index.js","../../../../../../../../../../node_modules/@monaco-editor/loader/package.json","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/index.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../../../../../../node_modules/@mui/material/node/List/List.js","../../../../../../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/loader/index.js","../../../../../../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../../../../../../node_modules/@mui/base/Portal/package.json","../../../../../../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../../node_modules/@mui/material/node/className/index.js","../../../../../../../../../../node_modules/@mui/base/utils/package.json","../../../../../../../../../../node_modules/@mui/base/Popper/package.json","../../../../../../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/_virtual/_rollupPluginBabelHelpers.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/config/index.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/validators/index.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/compose.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/deepMerge.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/makeCancelable.js","../../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../../../../../../node_modules/react-transition-group/package.json","../../../../../../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/curry.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/isObject.js","../../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../../node_modules/state-local/package.json","../../../../../../../../../../node_modules/state-local/lib/cjs/state-local.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../../../../../../node_modules/@popperjs/core/package.json","../../../../../../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../../node_modules/dom-helpers/package.json","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../../node_modules/@floating-ui/dom/package.json","../../../../../../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../../node_modules/@floating-ui/core/package.json","../../../../../../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js new file mode 100644 index 0000000..66b347a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js @@ -0,0 +1,932 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4565; +exports.ids = [4565,8105,133,4135]; +exports.modules = { + +/***/ 3907: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (__WEBPACK_DEFAULT_EXPORT__) +/* harmony export */ }); +// @ts-check +/** + * Check for user in local storage + * + * @description Preventdefault, declare variables + */ const defaultFieldsRegexp = /^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (defaultFieldsRegexp); + + +/***/ }), + +/***/ 7535: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddTableEntryContext": () => (/* binding */ AddTableEntryContext), + "default": () => (/* binding */ AddTableEntry), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./functions/frontend/defaultFieldsRegexp.js +var defaultFieldsRegexp = __webpack_require__(3907); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/databases/TableEntryField.jsx + 11 modules +var TableEntryField = __webpack_require__(4559); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./functions/frontend/updateDiskUsage.js +var updateDiskUsage = __webpack_require__(1069); +;// CONCATENATED MODULE: ./functions/frontend/newEntryHandler.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params + * @param {React.FormEvent<HTMLFormElement>} params.e + * @param {React.Dispatch<React.SetStateAction<boolean>>} params.setLoading + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} params.filteredFields + * @param {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} params.currentRichTextEditorForms + * @param {React.MutableRefObject<import("@/package-shared/types").JSONTextEditorsRefArray[]>} params.jsonTextEditors + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} params.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} params.table + * @param {any} params.query + * + * @requires search-field name attribute + */ function newEntryHandler({ e , setLoading , filteredFields , currentRichTextEditorForms , jsonTextEditors , database , table , query , }) { + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + /** @type {any} */ let payload = {}; + filteredFields.forEach((field)=>{ + if (!field?.fieldName) return; + if (!formEl[field.fieldName]?.value) return; + payload[field.fieldName] = formEl[field.fieldName].value; + }); + if (currentRichTextEditorForms.current[0]) { + currentRichTextEditorForms.current.forEach((richTextObject)=>{ + if (!richTextObject?.fieldName || !richTextObject?.ref?.current) return; + payload[richTextObject.fieldName] = richTextObject.ref.current.getContent(); + }); + } + if (jsonTextEditors.current[0]) { + jsonTextEditors.current.forEach((jsonEditor)=>{ + if (!jsonEditor?.fieldName || !jsonEditor?.ref?.current) return; + payload[jsonEditor.fieldName] = jsonEditor.ref.current.getValue(); + }); + } + /** @type {import("@/pages/api/addTableEntry").AddTableEntryRequestBody} */ const fetchBody = { + dbSlug: database.db_slug, + dbId: database.id, + tableName: table.tableName, + payload: payload, + tableSchema: table, + delegated: query?.delegated + }; + (0,fetchApi/* default */.Z)("/api/addTableEntry", { + method: "post", + body: fetchBody + }, true).then((res)=>{ + if (res.success) { + (0,updateDiskUsage/* default */.Z)().then(()=>{ + window.location.pathname = window.location.pathname.replace(/\/add-entry.*?/, ""); + }); + } else { + window.alert(res.msg + "\n" + (res.err || "")); + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/admin/databases/TableEntryForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function TableEntryForm({}) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , dbSchemaData , richTextEditors , query , confirmedDelegetedUser , jsonTextEditors , duplicateEntry , } = external_react_default().useContext(AddTableEntryContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const filteredFields = table.fields.filter((field)=>!field.fieldName?.match(defaultFieldsRegexp/* default */.Z)); + const dataTypes = __webpack_require__(9594); + const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {React.MutableRefObject<import("@/package-shared/types").RichTextEditorsRefArray[]>} */ const currentRichTextEditorForms = external_react_default().useRef([]); + /** @type {[ state: any, dispatch: React.Dispatch<React.SetStateAction<any>> ]} */ const [existingEntry, setExistingEntry] = external_react_default().useState(duplicateEntry || null); + external_react_default().useEffect(()=>{ + if (query.duplicate) { + try { + const localExistingEntry = localStorage.getItem("duplicate_entry"); + const existingEntry = JSON.parse(localExistingEntry || "{}"); + setExistingEntry(existingEntry); + } catch (error) {} + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 mb-4", + children: "Form Fields" + }), + query?.duplicate && duplicateEntry && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "info gray", + children: [ + "This post is a duplicate of", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/${duplicateEntry.id}`, + target: "_blank", + children: duplicateEntry.title || `Entry #${duplicateEntry.id}` + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-stretch gap-8", + onSubmit: (e)=>{ + newEntryHandler({ + e, + currentRichTextEditorForms, + database, + filteredFields, + jsonTextEditors, + query, + setLoading, + table + }); + }, + onKeyUp: (e)=>{ + if (e.ctrlKey && e.key == "Enter") { + const confirm = window.confirm("Add this Entry?"); + if (!confirm) return; + document.getElementById("add-entry-button")?.click(); + } + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + filteredFields.map((field, index)=>{ + let dataTypeSchema = dataTypes.filter((type)=>type.name === field.dataType?.replace(/\d|\(|\)/g, "")); + if (existingEntry && field.fieldName) { + field.defaultValue = existingEntry[field.fieldName]; + field.defaultValueLiteral = existingEntry[field.fieldName]; + } + if (field.defaultValueLiteral && !existingEntry) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}, index + 1); + } + return /*#__PURE__*/ jsx_runtime_.jsx(TableEntryField/* default */.Z, { + fieldObject: field, + dataTypeSchema: dataTypeSchema[0], + richTextEditors: richTextEditors, + currentRichTextEditorForms: currentRichTextEditorForms, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + jsonTextEditors: jsonTextEditors + }, index + 1); + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "" + (loading ? " pointer-events-none opacity-40" : ""), + id: "add-entry-button", + children: "Add Entry" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/ActiveCloneTableBanner.jsx +var ActiveCloneTableBanner = __webpack_require__(8515); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/databases/AddTableEntryContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddTableEntryContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , dbSchemaData , query , confirmedDelegetedUser , } = external_react_default().useContext(AddTableEntryContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const areEntriesEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Entries/i); + const areEntriesDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Entries/i); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full relative z-50", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "flex gap-y-2 flex-wrap gap-x-2 items-center", + children: [ + "Add New Entry To", + " ", + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "bg-slate-100 dark:bg-slate-800 px-2 py-1 border border-solid border-slate-400 dark:border-slate-600 rounded relative", + children: [ + table.tableFullName, + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-5 -right-4", + children: /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.tableName, + justIcon: true + }) + }) + ] + }), + " ", + "Table" + ] + }) + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneTableBanner/* default */.Z, { + table: table, + database: database, + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx(TableEntryForm, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2317); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AddEntryContextType} */ // @ts-ignore +const init = {}; +const AddTableEntryContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + * @param {any} props.duplicateEntry + * @param {any} props.confirmedDelegetedUser + */ function AddTableEntry({ user , database , table , dbSchemaData , query , confirmedDelegetedUser , duplicateEntry , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${table.tableFullName} Table New Entry | Datasquirel`; + const pageDescription = "Single Table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const richTextEditors = external_react_default().useRef([]); + const jsonTextEditors = external_react_default().useRef([]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(AddTableEntryContext.Provider, { + value: { + user, + database, + table, + dbSchemaData, + richTextEditors, + jsonTextEditors, + query, + confirmedDelegetedUser, + duplicateEntry + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(AddTableEntryContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ /** @type {string} */ // @ts-ignore + const slug = query.single; + const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + databaseSlug: slug, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + throw new Error("No Db Object Found!"); + } + const { dbUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === query.single_table)[0]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let duplicateEntry; + if (query.duplicate && query.id) { + const dbName = database[0].db_full_name; + const tableName = targetTable.tableName; + const targetDuplicateEntry = await varDatabaseDbHandler_default()({ + database: dbName, + queryString: `SELECT * FROM ${tableName} WHERE id='${query.id}'`, + tableSchema: targetTable + }); + duplicateEntry = targetDuplicateEntry?.[0]; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + table: targetTable, + dbSchemaData: dbSchemaData, + query, + confirmedDelegetedUser, + duplicateEntry: duplicateEntry || null + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError_default()({ + component: "add-entry-page-component/getServerSideProps/catch-error", + message: error.message, + user: user + }); + return { + props: { + user: user, + database: null, + table: null + } + }; + } +} + + +/***/ }), + +/***/ 2587: +/***/ ((module) => { + +module.exports = require("@monaco-editor/react"); + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 399: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2329: +/***/ ((module) => { + +module.exports = require("html-prettify"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,8682,2317,1206,5116,8345,4986,9594,8264,9788], () => (__webpack_exec__(7535))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js.nft.json new file mode 100644 index 0000000..0071d68 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../../webpack-runtime.js","../../../../../../../../chunks/4017.js","../../../../../../../../chunks/8313.js","../../../../../../../../chunks/5264.js","../../../../../../../../chunks/6729.js","../../../../../../../../chunks/5449.js","../../../../../../../../chunks/5304.js","../../../../../../../../chunks/913.js","../../../../../../../../chunks/9395.js","../../../../../../../../chunks/370.js","../../../../../../../../chunks/424.js","../../../../../../../../chunks/4858.js","../../../../../../../../chunks/5472.js","../../../../../../../../chunks/1781.js","../../../../../../../../chunks/4941.js","../../../../../../../../chunks/7023.js","../../../../../../../../chunks/8682.js","../../../../../../../../chunks/2317.js","../../../../../../../../chunks/1206.js","../../../../../../../../chunks/5116.js","../../../../../../../../chunks/8345.js","../../../../../../../../chunks/4986.js","../../../../../../../../chunks/9594.js","../../../../../../../../chunks/8264.js","../../../../../../../../chunks/9788.js","../../../../../../../../../package.json","../../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../../../node_modules/html-prettify/package.json","../../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../../node_modules/@monaco-editor/react/package.json","../../../../../../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../../node_modules/html-prettify/src/index.js","../../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../../node_modules/@monaco-editor/react/dist/index.js","../../../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../../node_modules/next/head.js","../../../../../../../../../../node_modules/next/package.json","../../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../../../node_modules/@mui/icons-material/LockOutlined.js","../../../../../../../../../../node_modules/react/package.json","../../../../../../../../../../node_modules/react/index.js","../../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../../node_modules/html-prettify/src/utils/addIndentation.js","../../../../../../../../../../node_modules/html-prettify/src/utils/toLines.js","../../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../../node_modules/@monaco-editor/loader/package.json","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/index.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/loader/index.js","../../../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/_virtual/_rollupPluginBabelHelpers.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/config/index.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/validators/index.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/compose.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/deepMerge.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/makeCancelable.js","../../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/curry.js","../../../../../../../../../../node_modules/@monaco-editor/loader/lib/cjs/utils/isObject.js","../../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../../node_modules/state-local/package.json","../../../../../../../../../../node_modules/state-local/lib/cjs/state-local.js","../../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js new file mode 100644 index 0000000..3d8262f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js @@ -0,0 +1,1176 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6941; +exports.ids = [6941,8105,133,4135,1674]; +exports.modules = { + +/***/ 1674: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ DeleteTableConfirmationPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_Breadcrumbs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(424); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5472); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").MYSQL_user_database_tables_table_def | null} [props.targetTable] + */ function DeleteTableConfirmationPopup({ targetTable , database , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .ZP, { + title: "delete-table-confirmation", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("h4", { + className: "m-0", + children: [ + "Delete '", + targetTable?.table_name ? targetTable.table_name : "This Database", + "' Table?" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "outlined" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/deleteUserTable", { + method: "post", + body: { + database: database, + table: targetTable + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } + }); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Yes" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_3__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Cancel" + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 8515: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ ActiveCloneTableBanner) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5557); +/* harmony import */ var _mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_mui_icons_material_MenuBookTwoTone__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {number} [props.activeDbClone] + * @param {import("@/package-shared/types").UserType} props.user + */ function ActiveCloneTableBanner({ table , database , user , activeDbClone , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const cloneParentDb = table?.childTableDbFullName ? table.childTableDbFullName.replace(new RegExp(/datasquirel_user_\d+_/), "") : null; + const isCurrentDb = table.childTableDbFullName === database.db_full_name; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ if (!cloneParentDb) return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + className: "info small green gap-1" + (database?.active_clone ? " -mt-6" : ""), + style: { + fontWeight: "500" + }, + children: [ + "This Table is an active clone of", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}/tables/${table.childTableName}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: table.childTableName + }) + }), + " ", + "in", + " ", + isCurrentDb ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + children: [ + "this current database(", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: database.db_name + }), + ")." + ] + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: `/admin/${user?.id}/databases/${cloneParentDb}`, + target: "_blank", + className: "button gray outlined small-text", + style: { + display: "inline-block", + fontSize: "12px", + padding: "3px 7px" + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: cloneParentDb + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "database." + }) + ] + }), + " ", + database?.active_clone ? "" : "Only Foreign keys and Entries can be updated." + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 7809: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ grabTableSchemaData) +/* harmony export */ }); +/* harmony import */ var http__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3685); +/* harmony import */ var http__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(http__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2317); +/* harmony import */ var _serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5116); +/* harmony import */ var _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _grabUserSchemaData__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2527); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1206); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} grabTableSchemaDataReturn + * @property {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} [database] + * @property {import("@/package-shared/types").DSQL_TableSchemaType} [table] + * @property {import("@/package-shared/types").MYSQL_user_database_tables_table_def} [props.tableRecord] + * @property {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} [props.dbSchemaData] + * @property {any[]} [props.entries] + * @property {any} [props.query] + * @property {any} [props.confirmedDelegetedUser] + * @property {number} [props.entriesCount] + */ /** + * @param {object} params + * @param {http.IncomingMessage & { cookies: import("next/dist/server/api-utils").NextApiRequestCookies }} params.req - Database name slug + * @param {{ id: number, first_name: string, last_name: string }} params.user - user object + * @param {any} params.query - query params + * + * @returns {Promise<grabTableSchemaDataReturn | null>} new user auth object payload + */ async function grabTableSchemaData({ req , user , query }) { + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ const dbUserData = await _grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default()({ + request: req, + user: user, + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + return null; + } + const { dbUserId } = dbUserDataObj; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database?.[0]) { + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ let dbSchemaData = (0,_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)({ + userId: dbUserId + }); + if (!dbSchemaData) { + throw new Error("DB Schema not found!"); + } + /** @type {import("@/package-shared/types").DSQL_TableSchemaType[]| undefined} */ const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables?.filter((table)=>table.tableName === query.single_table)[0]; + const targetTableRecord = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT * FROM user_database_tables WHERE user_id='${dbUserId}' AND db_id='${database[0].id}' AND table_slug='${query.single_table}'`); + const tableEntries = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM ${targetTable?.tableName} ORDER BY id DESC LIMIT 10`, + tableSchema: targetTable + }); + const tableEntriesCount = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + database: database[0].db_full_name, + queryString: `SELECT COUNT(id) AS count FROM ${targetTable?.tableName}`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (confirmedDelegetedUser.rootUserId) { + const filteredDbSchema = dbSchemaData.filter((db)=>db.dbFullName == database[0].db_full_name); + let targetFilteredDb = filteredDbSchema[0]; + const filteredTables = targetFilteredDb.tables.filter(// @ts-ignore + (tbl)=>tbl.tableName === targetTable?.tableName); + targetFilteredDb.tables = filteredTables; + dbSchemaData = [ + targetFilteredDb + ]; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + confirmedDelegetedUser: confirmedDelegetedUser || null, + database: database[0] || null, + dbSchemaData: dbSchemaData || null, + entries: tableEntries || null, + entriesCount: tableEntriesCount?.[0]?.count || 0, + query, + table: targetTable, + tableRecord: targetTableRecord[0] || {} + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "[single_table]/index-page-component/getServerSideProps/catch-error]", + message: error.message, + user: user + }); + return {}; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 8382: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ updateTableAfterFieldsUpdateFunctionExt) +/* harmony export */ }); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _fetchApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6729); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Auth user on client side + * ============================================================================== + * @param {object} params - Single object parameters + * @param {{delegated: boolean}} [params.query] - Query object + * @param {DSQL_TableSchemaType} params.table - Target table object + * @param {DSQL_MYSQL_user_databases_Type} params.database - Target MYSQL database record object + * @param {DSQL_DatabaseSchemaType[]} params.dbSchemaData - DSQL db schema + * @param {DSQL_FieldSchemaType[]} [params.tableFields] - Table Fields + * @param {DSQL_IndexSchemaType[]} [params.tableIndexes] - Table INdexes + * @param {React.Dispatch<React.SetStateAction<boolean>>} [params.setLoading] + */ function updateTableAfterFieldsUpdateFunctionExt({ query , table , database , dbSchemaData , tableFields , tableIndexes , setLoading , }) { + /** + * @description Initialize + */ let newDbSchemaData = [ + ...dbSchemaData + ]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + const dbIndex = newDbSchemaData.findIndex((db)=>db.dbFullName === database.db_full_name); + const targetDb = newDbSchemaData[dbIndex]; + const targetTableIndex = targetDb.tables.findIndex((_table)=>_table.tableName === table.tableName); + newDbSchemaData[dbIndex].tables[targetTableIndex].fields = tableFields ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableFields) : []; + newDbSchemaData[dbIndex].tables[targetTableIndex].indexes = tableIndexes ? lodash__WEBPACK_IMPORTED_MODULE_0__.cloneDeep(tableIndexes) : []; + const tempField = newDbSchemaData[dbIndex].tables[targetTableIndex].fields.find((fld)=>fld.newTempField); + if (tempField) { + window.alert("Please resolve all open fields before you save"); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } + (0,_fetchApi__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)("/api/updateDbSchemaDataForUser", { + method: "post", + body: { + schema: newDbSchemaData, + database: database.db_slug, + table: table, + delegated: query?.delegated + } + }, true).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert(res.msg || "Operation Failed. Please check permissions."); + } + }).finally(()=>{ + if (setLoading) { + setTimeout(()=>{ + setLoading(false); + }, 1000); + } + }); + } catch (/** @type {any} */ error) { + window.alert(error.message); + setTimeout(()=>{ + setLoading?.(false); + }, 1000); + return; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 325: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "TableFieldsContext": () => (/* binding */ TableFieldsContext), + "default": () => (/* binding */ TableFieldsPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/admin/databases/DeleteTableConfirmationPopup.jsx +var DeleteTableConfirmationPopup = __webpack_require__(1674); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/CopySlug.jsx +var CopySlug = __webpack_require__(9230); +// EXTERNAL MODULE: ./components/admin/databases/TableFields.jsx + 7 modules +var TableFields = __webpack_require__(4893); +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/ActiveCloneTableBanner.jsx +var ActiveCloneTableBanner = __webpack_require__(8515); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/databases/TableFieldsContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function TableFieldsContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , tableFields , setTableFields , setTargetField , refreshFieldsListRef , updateTableAfterFieldsUpdateFunction , query , confirmedDelegetedUser , } = external_react_default().useContext(TableFieldsContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const isDelegated = confirmedDelegetedUser?.delegated; + const isTableEditable = confirmedDelegetedUser?.priviledges?.match(/Edit Tables/i); + const isTableDeletable = confirmedDelegetedUser?.priviledges?.match(/Delete Tables/i); + const isTableCreatable = confirmedDelegetedUser?.priviledges?.match(/Create Tables/i); + const cloneParentDb = table?.childTable ? table.childTableDbFullName?.replace(new RegExp(/datasquirel_user_\d+_/), "") : null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "All Fields in" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "inline relative", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}`, + className: "p-2 bg-white dark:bg-slate-800 rounded border border-solid border-slate-200 dark:border-slate-600 ml-2 text-primary hover:text-primary_dark relative", + onClick: (e)=>{ + /** @type {HTMLAnchorElement} */ // @ts-ignore + const linkEl = e.target; + if (linkEl.closest(".copy-slug-span")) { + e.preventDefault(); + } + }, + children: [ + table.tableFullName, + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "absolute -top-4 -right-4", + children: /*#__PURE__*/ jsx_runtime_.jsx(CopySlug/* default */.Z, { + slugText: table.tableName, + justIcon: true + }) + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "ml-2", + children: "Table" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/tables/${table.tableName}/entries/add-entry`, + className: "button flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New Table Entry" + }) + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + confirmedDelegetedUser: query?.delegated, + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneTableBanner/* default */.Z, { + table: table, + database: database, + user: user + }), + /*#__PURE__*/ jsx_runtime_.jsx(TableFields/* default */.Z, { + user: user, + tableFields: tableFields, + setTableFields: setTableFields, + setTargetField: setTargetField, + refreshFieldsListRef: refreshFieldsListRef, + updateTable: true, + updateTableAfterFieldsUpdateFunction: updateTableAfterFieldsUpdateFunction, + database: database, + confirmedDelegetedUser: confirmedDelegetedUser, + query: query, + table: table + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/updateTableAfterFieldsUpdateFunctionExt.js +var updateTableAfterFieldsUpdateFunctionExt = __webpack_require__(8382); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2317); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./functions/backend/grabTableSchemaData.js +var grabTableSchemaData = __webpack_require__(7809); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").FieldsContextType} */ // @ts-ignore +const init = {}; +const TableFieldsContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function TableFieldsPage({ user , database , table , dbSchemaData , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${table.tableFullName} Table | Datasquirel`; + const pageDescription = "Single Table"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ tableFields: import("@/package-shared/types").DSQL_FieldSchemaType[], setTableFields: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>> ]} */ // @ts-ignore + const [tableFields, setTableFields] = external_react_default().useState(table.fields); + /** @type {[ targetField: import("@/package-shared/types").DSQL_FieldSchemaType | null, setTargetField: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType | null>> ]} */ // @ts-ignore + const [targetField, setTargetField] = external_react_default().useState(null); + /** @type {React.MutableRefObject<React.Dispatch<React.SetStateAction<number>> | undefined>} */ const refreshFieldsListRef = external_react_default().useRef(); + // const targetFieldIndex = targetField ? tableFields.findIndex((field) => field.fieldName === targetField.fieldName) : 1; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * + * @param {React.Dispatch<React.SetStateAction<boolean>>} [setLoading] + */ function updateTableAfterFieldsUpdateFunction(setLoading) { + (0,updateTableAfterFieldsUpdateFunctionExt/* default */.Z)({ + query, + table, + database, + dbSchemaData, + tableFields, + tableIndexes: table.indexes, + setLoading + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(TableFieldsContext.Provider, { + value: { + user, + database, + table, + dbSchemaData, + targetField, + setTargetField, + refreshFieldsListRef, + tableFields, + setTableFields, + updateTableAfterFieldsUpdateFunction, + query, + confirmedDelegetedUser + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(TableFieldsContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DeleteTableConfirmationPopup/* default */.Z, { + database: database + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + try { + /** + * Check delegated user token + * + * @description Check delegated user token + */ const data = await (0,grabTableSchemaData/* default */.Z)({ + req, + query, + user + }); + if (!data || !data?.table) { + throw new Error("Data Fetching Error!"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + ...data + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError_default()({ + component: "fields-page-component/getServerSideProps/catch-error", + message: error.message, + user: user + }); + return { + // redirect: { + // destination: "/login", + // permanent: false + // }, + props: { + user: user, + database: null, + table: null + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 4287: +/***/ ((module) => { + +module.exports = require("gsap"); + +/***/ }), + +/***/ 2700: +/***/ ((module) => { + +module.exports = require("gsap/Flip"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,7901,8682,2317,1206,5116,8345,4986,9594,8264,9471,9967,464,3314,4893], () => (__webpack_exec__(325))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js.nft.json new file mode 100644 index 0000000..cd5c037 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../webpack-runtime.js","../../../../../../../chunks/4017.js","../../../../../../../chunks/8313.js","../../../../../../../chunks/5264.js","../../../../../../../chunks/6729.js","../../../../../../../chunks/5449.js","../../../../../../../chunks/5304.js","../../../../../../../chunks/913.js","../../../../../../../chunks/9395.js","../../../../../../../chunks/370.js","../../../../../../../chunks/424.js","../../../../../../../chunks/4858.js","../../../../../../../chunks/5472.js","../../../../../../../chunks/1781.js","../../../../../../../chunks/4941.js","../../../../../../../chunks/7023.js","../../../../../../../chunks/7901.js","../../../../../../../chunks/8682.js","../../../../../../../chunks/2317.js","../../../../../../../chunks/1206.js","../../../../../../../chunks/5116.js","../../../../../../../chunks/8345.js","../../../../../../../chunks/4986.js","../../../../../../../chunks/9594.js","../../../../../../../chunks/8264.js","../../../../../../../chunks/9471.js","../../../../../../../chunks/9967.js","../../../../../../../chunks/464.js","../../../../../../../chunks/3314.js","../../../../../../../chunks/4893.js","../../../../../../../../package.json","../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../node_modules/lodash/package.json","../../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../../node_modules/gsap/package.json","../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../../node_modules/gsap/dist/gsap.js","../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../node_modules/next/head.js","../../../../../../../../../node_modules/next/package.json","../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../../../node_modules/gsap/Flip.js","../../../../../../../../../node_modules/react/package.json","../../../../../../../../../node_modules/react/index.js","../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../../node_modules/gsap/utils/matrix.js","../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../../package.json","../../../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js new file mode 100644 index 0000000..ae270fb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js @@ -0,0 +1,1310 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3828; +exports.ids = [3828,8105,3316]; +exports.modules = { + +/***/ 3532: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddTableContext": () => (/* binding */ AddTableContext), + "default": () => (/* binding */ AddTable), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/databases/TableFields.jsx + 7 modules +var TableFields = __webpack_require__(4893); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/FormAlertBlock.jsx +var FormAlertBlock = __webpack_require__(7037); +// EXTERNAL MODULE: ./functions/frontend/checkUniqueField.js +var checkUniqueField = __webpack_require__(4105); +;// CONCATENATED MODULE: ./components/admin/databases/NewTableNameSlugAndDescSection.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {React.Dispatch<React.SetStateAction<any>>} props.setAlert + */ function NewTableNameSlugAndDescSection({ setAlert }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database } = external_react_default().useContext(AddTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + * @param {string} value + */ async function checkDuplicateSlug(value) { + const duplicate = await (0,checkUniqueField/* default */.Z)({ + tableName: "user_database_tables", + columnName: "table_slug", + value: value, + dbId: database?.id, + userId: user?.id + }); + return duplicate; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_name", + children: "Name" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "table_name", + id: "table_name", + placeholder: "Table Name", + onInput: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const form = inputEl.closest("form"); + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + if (form) { + form["table_slug"].value = inputEl.value.toLowerCase().replace(/ /g, "_").replace(/[^a-zA-Z0-9-_]/g, ""); + let slugValue = form["table_slug"].value; + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + checkDuplicateSlug(slugValue).then((res)=>{ + if (res.result) { + form?.["table_slug"].classList.add("warning"); + setAlert("Duplicate Table Name"); + } else { + form["table_slug"].classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + } + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_slug", + children: "Slug" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "table_slug", + id: "table_slug", + placeholder: "Table Slug", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const form = inputEl.closest("form"); + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + checkDuplicateSlug(inputEl.value).then((res)=>{ + if (res.result) { + inputEl.classList.add("warning"); + setAlert("Duplicate Table Name"); + } else { + inputEl.classList.remove("warning"); + setAlert(null); + } + }); + }, 300); + }, + required: true + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "table_description", + children: "Description (optional)" + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: "table_description", + id: "table_description", + placeholder: "Short Description of Table" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/NewTableForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let NewTableForm_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function NewTableForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , tableFields , database , setTableFields , setTargetField , refreshFieldsListRef , query , } = external_react_default().useContext(AddTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [alert, setAlert] = external_react_default().useState(null); + const [cloneTable, setCloneTable] = external_react_default().useState(false); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "New Table Information" + }), + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-start gap-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + let table_name_full = formEl["table_name"].value; + let table_name = formEl["table_slug"].value; + /** @type {string|null} */ let table_description = formEl["table_description"]?.value?.match(/./) ? formEl["table_description"].value : null; + const tableObject = { + tableName: table_name, + tableFullName: table_name_full, + fields: tableFields + }; + if (table_description) { + // @ts-ignore + tableObject["description"] = table_description; + } + // submitNewDatabaseForm({ e, setLoading }) + (0,fetchApi/* default */.Z)("/api/addUserTable", { + method: "post", + body: { + dbFullName: database?.db_full_name, + dbId: database?.id, + dbSlug: database?.db_slug, + payload: tableObject + } + }, true).then((res)=>{ + if (res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${database?.db_slug}/tables`; + } else { + window.alert("Table Creation Failed! Please Try again."); + window.location.reload(); + } + }); + }, + id: "create-new-table-form", + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx(FormAlertBlock/* default */.Z, { + message: alert + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewTableNameSlugAndDescSection, { + setAlert: setAlert + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + className: "w-full hidden", + id: "create-new-table-form-submit-button", + children: "Create Table" + }) + ] + }), + user && tableFields && setTableFields && setTargetField && database && refreshFieldsListRef && /*#__PURE__*/ jsx_runtime_.jsx(TableFields/* default */.Z, { + user: user, + tableFields: tableFields, + setTableFields: setTableFields, + setTargetField: setTargetField, + refreshFieldsListRef: refreshFieldsListRef, + database: database, + query: query + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full p-4" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + document.getElementById("create-new-table-form-submit-button")?.click(); + }, + children: "Create Table" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/CloneTableForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let CloneTableForm_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function CloneTableForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , tableFields , database , dbSchemaData , query } = external_react_default().useContext(AddTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!dbSchemaData) { + return null; + } + const clone = query?.clone; + const clone_db = query?.clone_db; + const clone_table = query?.clone_table; + const initialTargetDb = clone_db ? dbSchemaData.find((db)=>db.dbSlug === clone_db) : null; + const initialTargetTables = initialTargetDb ? initialTargetDb.tables : null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [alert, setAlert] = external_react_default().useState(null); + const [loading, setLoading] = external_react_default().useState(false); + const [keepTableUpdated, setKeepTableUpdated] = external_react_default().useState(false); + const [targetDb, setTargetDb] = external_react_default().useState(initialTargetDb || { + ...dbSchemaData[0] + }); + const [tables, setTables] = external_react_default().useState(initialTargetTables || [ + ...dbSchemaData[0].tables + ]); + const [targetTable, setTargetTable] = external_react_default().useState(initialTargetTables ? initialTargetTables.find((table)=>table.tableName === clone_table) : dbSchemaData[0].tables[0] ? { + ...dbSchemaData[0].tables[0] + } : null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0 text-left w-full", + children: "Clone Existing Table" + }), + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-start gap-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + if (!targetTable) { + window.alert("No Table Selected!"); + setLoading(false); + return; + } + /** @type {HTMLFormElement} */ // @ts-ignore + const form = e.target; + let table_name_full = form["table_name"].value; + let table_name = form["table_slug"].value; + let table_description = form["table_description"]?.value?.match(/./) ? form["table_description"].value : null; + const tableObject = { + ...targetTable + }; + tableObject["tableName"] = table_name; + tableObject["tableFullName"] = table_name_full; + if (keepTableUpdated) { + tableObject["childTable"] = true; + tableObject["childTableName"] = targetTable.tableName; + tableObject["childTableDbFullName"] = targetDb.dbFullName; + } + if (table_description) tableObject["tableDescription"] = table_description; + tableObject.fields.forEach((/** @type {any} */ fieldObject)=>{ + delete fieldObject["foreignKey"]; + }); + delete tableObject.childrenTables; + if (database) { + (0,fetchApi/* default */.Z)("/api/addUserTable", { + method: "post", + body: { + dbFullName: database.db_full_name, + dbId: database.id, + dbSlug: database.db_slug, + parentDatabase: targetDb.dbFullName, + parentTable: targetTable.tableName, + payload: tableObject + } + }, true).then((res)=>{ + if (res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/tables`; + } else { + window.alert("Table Clonning Failed! Please Try again."); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + } else { + window.alert("Database record data not found!"); + } + }, + id: "create-new-table-form", + children: [ + alert && /*#__PURE__*/ jsx_runtime_.jsx(FormAlertBlock/* default */.Z, { + message: alert + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "w-full opacity-40" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "text-base m-0 font-semibold text-slate-600", + children: "Enter New Table Info" + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewTableNameSlugAndDescSection, { + setAlert: setAlert + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "w-full opacity-40" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "text-base m-0 font-semibold text-slate-600", + children: "Select Existing Table To Clone" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "select_root_database", + children: "Database" + }), + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "select_root_database", + id: "select_root_database", + onChange: (e)=>{ + const targetDb = dbSchemaData.filter((/** @type {any} */ dbObject)=>dbObject.dbName === e.target.value)[0]; + setTargetDb({ + ...targetDb + }); + setTables([ + ...targetDb.tables + ]); + if (targetDb.tables[0]) { + setTargetTable({ + ...targetDb.tables[0] + }); + } else { + setTargetTable(null); + } + }, + children: dbSchemaData.filter((db)=>!db.childDatabase).map((dbObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: dbObject.dbName, + selected: clone_db && clone_db == dbObject.dbSlug ? true : undefined, + children: dbObject.dbName + }, index + 1); + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-col items-start gap-0.5 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "select_root_table", + children: "Table" + }), + /*#__PURE__*/ jsx_runtime_.jsx("select", { + name: "select_root_table", + id: "select_root_table", + onChange: (e)=>{ + setTargetTable({ + ...tables.filter((table)=>table.tableName === e.target.value)[0] + }); + }, + children: tables && tables[0] ? tables.filter((tbl)=>!tbl.childTable).map((tableObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: tableObject.tableName, + selected: clone_table && clone_table == tableObject.tableName ? true : undefined, + children: tableObject.tableFullName + }, index + 1); + }) : /*#__PURE__*/ jsx_runtime_.jsx("option", { + value: "null", + children: "-- No Tables --" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-1", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "checkbox", + name: "toggle-update-table", + id: "toggle-update-table", + className: "w-4 h-4", + onChange: (e)=>{ + if (e.target.checked) { + setKeepTableUpdated(true); + } else { + setKeepTableUpdated(false); + } + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "toggle-update-table", + className: "text-base text-slate-600 dark:text-slate-100", + children: "Keep New Table Updated?" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm italic text-slate-600 dark:text-slate-400", + children: "By checking this box the new Table stays up to date with changes to the structure of the parent Table" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full p-4" + (loading ? " pointer-events-none opacity-40" : ""), + onClick: (e)=>{ + document.getElementById("create-new-table-form-submit-button")?.click(); + }, + children: "Clone Table" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/AddTableForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let AddTableForm_timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddTableForm(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , query } = external_react_default().useContext(AddTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const clone = query?.clone; + const clone_db = query?.clone_db; + const clone_table = query?.clone_table; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [cloneTable, setCloneTable] = external_react_default().useState(Boolean(clone)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-1 w-full bg-blue-100 dark:bg-blue-100/10 text-white p-2 rounded", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "checkbox", + name: "toggle-clone-table", + id: "toggle-clone-table", + className: "w-5 h-5", + onChange: (e)=>{ + if (e.target.checked) { + setCloneTable(true); + } else { + setCloneTable(false); + } + }, + defaultChecked: cloneTable + }), + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: "toggle-clone-table", + className: "text-base text-slate-600", + children: "Clone Another Table" + }) + ] + }), + cloneTable ? /*#__PURE__*/ jsx_runtime_.jsx(CloneTableForm, {}) : /*#__PURE__*/ jsx_runtime_.jsx(NewTableForm, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/databases/AddTableContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddTableContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , user } = external_react_default().useContext(AddTableContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ if (!database) return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add A New Table To" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}`, + className: "p-2 bg-white dark:bg-slate-800 rounded border border-solid border-slate-200 dark:border-slate-700 ml-2 text-primary hover:text-primary_dark", + children: database.db_name + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex-col", + children: /*#__PURE__*/ jsx_runtime_.jsx(AddTableForm, {}) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/admin/databases/ExistingFieldEdit.jsx +var ExistingFieldEdit = __webpack_require__(9967); +;// CONCATENATED MODULE: ./components/admin/databases/EditFieldPopup.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_FieldSchemaType} props.targetField + * @param {number} props.fieldIndex + * @param {import("@/package-shared/types").DSQL_FieldSchemaType[]} props.tableFields + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>} props.setTableFields + * @param {any} props.refreshFieldsListRef + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").UserType} props.user + */ function EditFieldPopup({ targetField , fieldIndex , tableFields , setTableFields , refreshFieldsListRef , database , user , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(GeneralPopup/* default */.ZP, { + title: "edit-field-popup", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + "Edit", + " ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + className: "bg-slate-100 px-3 py-1.5 rounded-full border border-slate-300 border-solid", + children: targetField?.fieldName + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(ExistingFieldEdit/* default */.Z, { + fieldIndex: fieldIndex, + tableFields: tableFields, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + targetField: targetField, + database: database, + user: user + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(2527); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/tables/add-table.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type { import("@/package-shared/types").AddTableContextType } */ // @ts-ignore +const addTableInit = {}; +const AddTableContext = /*#__PURE__*/ external_react_default().createContext(addTableInit); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType[]} props.tables + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {any} props.query + */ function AddTable({ user , database , tables , dbSchemaData , query , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `Add Table To ${database.db_name}| Datasquirel`; + const pageDescription = "Add a database"; + const defaultFields = __webpack_require__(550); + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {any} */ const tableFieldsState = external_react_default().useState(defaultFields); + /** @type { [import("@/package-shared/types").DSQL_FieldSchemaType[], React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType[]>>] } */ const [tableFields, setTableFields] = tableFieldsState; + /** @type {any} */ const targetFieldState = external_react_default().useState(); + /** @type { [import("@/package-shared/types").DSQL_FieldSchemaType|null, React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_FieldSchemaType|null>>] } */ const [targetField, setTargetField] = targetFieldState; + /** @type {any} */ const pageRefreshState = external_react_default().useState(null); + /** @type { [number|null, React.Dispatch<React.SetStateAction<number>>] } */ const [pageRefresh, setPageRefresh] = pageRefreshState; + /** @type {React.MutableRefObject<React.Dispatch<React.SetStateAction<number>>>} */ // @ts-ignore + const refreshFieldsListRef = external_react_default().useRef(); + const targetFieldIndex = targetField && tableFields ? tableFields.findIndex((field)=>field.fieldName === targetField.fieldName) : 1; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(AddTableContext.Provider, { + value: { + user, + dbSchemaData, + database, + tables, + tableFields, + setTableFields, + targetField, + setTargetField, + pageRefresh, + setPageRefresh, + refreshFieldsListRef, + query + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(AddTableContent, {}), + targetField && tableFields && /*#__PURE__*/ jsx_runtime_.jsx(EditFieldPopup, { + targetField: targetField, + fieldIndex: targetFieldIndex, + tableFields: tableFields, + setTableFields: setTableFields, + refreshFieldsListRef: refreshFieldsListRef, + database: database, + user: user + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const tables = await DB_HANDLER_default()(`SELECT * FROM user_database_tables WHERE user_id='${user.id}' AND db_id='${database[0].id}'`); + const dbSchemaData = (0,grabUserSchemaData/* default */.Z)({ + userId: user.id + }); + if (!dbSchemaData) throw new Error("User schema data not found!"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + tables: tables, + dbSchemaData, + query + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log(error); + return { + redirect: { + destination: "/", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 4287: +/***/ ((module) => { + +module.exports = require("gsap"); + +/***/ }), + +/***/ 2700: +/***/ ((module) => { + +module.exports = require("gsap/Flip"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 550: +/***/ ((module) => { + +module.exports = JSON.parse('[{"fieldName":"id","dataType":"BIGINT","notNullValue":true,"primaryKey":true,"autoIncrement":true},{"fieldName":"uuid","dataType":"UUID","defaultValueLiteral":"UUID()"},{"fieldName":"date_created","dataType":"VARCHAR(250)","nullValue":true},{"fieldName":"date_created_code","dataType":"BIGINT","nullValue":true},{"fieldName":"date_created_timestamp","dataType":"TIMESTAMP","defaultValueLiteral":"CURRENT_TIMESTAMP"},{"fieldName":"date_updated","dataType":"VARCHAR(250)","nullValue":true},{"fieldName":"date_updated_code","dataType":"BIGINT","nullValue":true},{"fieldName":"date_updated_timestamp","dataType":"TIMESTAMP","defaultValueLiteral":"CURRENT_TIMESTAMP","onUpdateLiteral":"CURRENT_TIMESTAMP"}]'); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7901,2317,9594,9471,7037,9967,464,4105,3314,4893], () => (__webpack_exec__(3532))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js.nft.json new file mode 100644 index 0000000..31e51c6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/tables/add-table.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/4941.js","../../../../../../chunks/7901.js","../../../../../../chunks/2317.js","../../../../../../chunks/9594.js","../../../../../../chunks/9471.js","../../../../../../chunks/7037.js","../../../../../../chunks/9967.js","../../../../../../chunks/464.js","../../../../../../chunks/4105.js","../../../../../../chunks/3314.js","../../../../../../chunks/4893.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lodash/package.json","../../../../../../../../node_modules/react-dom/package.json","../../../../../../../../node_modules/gsap/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lodash/lodash.js","../../../../../../../../node_modules/gsap/dist/gsap.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/react-dom/index.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../../../node_modules/gsap/Flip.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react-dom/client.js","../../../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../../../node_modules/gsap/utils/matrix.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/scheduler/package.json","../../../../../../../../node_modules/scheduler/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../jsonData/dbSchemas/defaultFields.json","../../../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../../../package.json","../../../../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js new file mode 100644 index 0000000..08f7cf7 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js @@ -0,0 +1,798 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6153; +exports.ids = [6153,8105,133,4135]; +exports.modules = { + +/***/ 4726: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "UsersContext": () => (/* binding */ UsersContext), + "default": () => (/* binding */ Dashboard), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/users/TargetUserPreviewPopup.jsx +var TargetUserPreviewPopup = __webpack_require__(9417); +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/users/UserListCard.jsx +var UserListCard = __webpack_require__(3863); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/users/DbUsersList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>>} [props.setTargetUser] + * @param {import("@/package-shared/types").MYSQL_user_users_table_def[]} props.users + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + */ function DbUsersList({ user , table , setTargetUser , users , database , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const { active_clone , active_clone_parent_db , remote_connected } = database; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + users && users[0] ? /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: users.map((userObject, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users/${userObject.id}`, + className: "card", + onClick: (e)=>{ + // @ts-ignore + if (e.target.closest("button")) return e.preventDefault(); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: userObject.image_thumbnail, + alt: "", + className: "w-10 h-10 rounded-full object-cover bg-slate-200" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-1", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "font-bold", + children: [ + userObject.first_name, + " ", + userObject.last_name + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs text-slate-500", + children: userObject.date_created?.substring(0, 16) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ml-auto outlined gray pointer-events-none", + children: "Edit User" + }) + ] + }, index + 1); + }) + }) : table?.tableName ? /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Users Added Yet" + }) + }) : /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No User Table Present" + }) + }), + !table?.tableName && !active_clone_parent_db && !remote_connected && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "gap-4 py-3", + onClick: (e)=>{ + if (window.confirm(`Add users table to ${database.db_name}?`)) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/addUsersTableToDatabase", { + method: "post", + body: { + dbFullName: database.db_full_name, + dbSlug: database.db_slug, + dbId: database.id + } + }, true).then((res)=>{ + console.log(res); + if (res.success) { + window.location.reload(); + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + } + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add User Table" + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ActiveCloneDbBanner.jsx +var ActiveCloneDbBanner = __webpack_require__(4986); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: ./components/admin/databases/DatabasesTablesList.jsx +var DatabasesTablesList = __webpack_require__(8264); +;// CONCATENATED MODULE: ./components/admin/users/DbUsersContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DbUsersContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , users , table , setTargetUser , database } = external_react_default().useContext(UsersContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Users in ", + database.db_name + ] + }) + ] + }), + table?.tableName && /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users/add-user`, + className: "gap-2 button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New User" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: `/admin/${user?.id}/databases/${database.db_slug}/users/add-social-logins`, + className: "gap-2 button outlined", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Social Logins" + }) + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + database.active_clone ? /*#__PURE__*/ jsx_runtime_.jsx(ActiveCloneDbBanner/* default */.Z, { + database: database, + user: user + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + database.remote_connected ? /*#__PURE__*/ jsx_runtime_.jsx(DatabasesTablesList/* ConnectedDatabaseBanner */.w, { + database: database + }) : /*#__PURE__*/ jsx_runtime_.jsx(jsx_runtime_.Fragment, {}), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full grid grid-cols-1 items-start justify-start", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-stretch justify-start", + children: /*#__PURE__*/ jsx_runtime_.jsx(DbUsersList, { + setTargetUser: setTargetUser, + user: user, + users: users, + table: table, + database: database + }) + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/users/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").UserUsersContextType} */ // @ts-ignore +const init = {}; +const UsersContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {import("@/package-shared/types").MYSQL_user_users_table_def[]} props.users + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function Dashboard({ user , database , table , dbSchemaData , users , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Users | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [newUser, setNewUser] = external_react_default().useState(null); + /** @type {[ targetUser: import("@/package-shared/types").MYSQL_user_users_table_def, setTargetUser: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>> ]} */ // @ts-ignore + const [targetUser, setTargetUser] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(UsersContext.Provider, { + value: { + user, + users, + targetUser, + setTargetUser, + database, + table, + dbSchemaData, + query, + confirmedDelegetedUser + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(DbUsersContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TargetUserPreviewPopup/* default */.Z, { + targetUser: targetUser, + user: user, + setTargetUser: setTargetUser + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + // @ts-ignore + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + throw new Error("No Db Object Found!"); + } + const { dbUserId , rootUserId } = dbUserDataObj; + const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === "users")[0]; + const users = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM users LIMIT 20`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + table: targetTable ? targetTable : {}, + dbSchemaData: dbSchemaData, + users: users?.error ? [] : users, + query, + confirmedDelegetedUser + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + console.log("Db Users Error =>", error.message); + return { + redirect: { + destination: `/admin`, + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 1522: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTableTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 3851: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TableViewTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,4114,8682,1206,5116,8345,4986,8264,9486,9417,3863], () => (__webpack_exec__(4726))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js.nft.json new file mode 100644 index 0000000..5e43925 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/5472.js","../../../../../chunks/1781.js","../../../../../chunks/4941.js","../../../../../chunks/7023.js","../../../../../chunks/4114.js","../../../../../chunks/8682.js","../../../../../chunks/1206.js","../../../../../chunks/5116.js","../../../../../chunks/8345.js","../../../../../chunks/4986.js","../../../../../chunks/8264.js","../../../../../chunks/9486.js","../../../../../chunks/9417.js","../../../../../chunks/3863.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../node_modules/@mui/icons-material/TableViewTwoTone.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../jsonData/userPriviledges.json","../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js new file mode 100644 index 0000000..5c56afe --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js @@ -0,0 +1,214 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8105; +exports.ids = [8105]; +exports.modules = { + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,8682,1206,5116,6718,2733,7531], () => (__webpack_exec__(7531))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js.nft.json new file mode 100644 index 0000000..8bce592 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/4941.js","../../../../../../chunks/7023.js","../../../../../../chunks/8682.js","../../../../../../chunks/1206.js","../../../../../../chunks/5116.js","../../../../../../chunks/6718.js","../../../../../../chunks/2733.js","../../../../../../chunks/7531.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js new file mode 100644 index 0000000..7b62c97 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js @@ -0,0 +1,502 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4970; +exports.ids = [4970,8105]; +exports.modules = { + +/***/ 9494: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ DatabaseSingleUserPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./pages/admin/[user_id]/databases/[single]/users/[user]/index.jsx + 1 modules +var _user_ = __webpack_require__(7531); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/users/ChangeDbUserPassword.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props + * @param {import("@/package-shared/types").MYSQL_user_users_table_def} props.singleUser + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").UserType} props.user + */ function ChangeDbUserPassword({ singleUser , database , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Change Password For", + " ", + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("u", { + children: [ + singleUser.first_name, + " ", + singleUser.last_name + ] + }) + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex-col items-stretch", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-col items-stretch gap-4", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLInputElement} */ // @ts-ignore + const password = document.getElementById("password"); + /** @type {HTMLInputElement} */ // @ts-ignore + const passwordRepeat = document.getElementById("password-repeat"); + const passwordRegexp = new RegExp(`${password.value}`); + if (!passwordRepeat?.value?.match(passwordRegexp)) { + window.alert("Passwords dont Match!"); + return; + } + if (!window.confirm("change this User's password?")) { + setLoading(false); + return; + } + (0,fetchApi/* default */.Z)("/api/changeDbUserPassword", { + method: "POST", + body: { + userId: singleUser.id, + password: password.value, + dbId: database.id + } + }, true).then((res)=>{ + if (res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/users/${singleUser.id}`; + } + }).catch((/** @type {any} */ error)=>{ + console.log(error.message); + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 2000); + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + id: "password", + name: "password", + type: "password", + placeholder: "New Password", + required: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + id: "password-repeat", + name: "password-repeat", + type: "password", + placeholder: "Repeat New Password", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const password = document.getElementById("password"); + /** @type {HTMLInputElement} */ // @ts-ignore + const passwordRepeat = document.getElementById("password-repeat"); + const passwordRegexp = password?.value ? new RegExp(`${password.value}`) : null; + if (!passwordRegexp) { + return; + } + if (!passwordRepeat?.value?.match(passwordRegexp)) { + passwordRepeat.classList.add("warning"); + } else { + passwordRepeat.classList.remove("warning"); + } + }, + required: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: "Change Password" + }) + ] + }) + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/users/[user]/change-password.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + * @param {import("@/package-shared/types").MYSQL_user_users_table_def} props.singleUser + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function DatabaseSingleUserPage({ user , database , table , dbSchemaData , singleUser , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${singleUser.first_name} ${singleUser.last_name} Users | Datasquirel"`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(ChangeDbUserPassword, { + singleUser: singleUser, + database: database, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ const getServerSideProps = _user_.getServerSideProps; + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,8682,1206,5116,6718,2733,7531], () => (__webpack_exec__(9494))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js.nft.json new file mode 100644 index 0000000..2450ecb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/[user]/change-password.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../../webpack-runtime.js","../../../../../../../chunks/4017.js","../../../../../../../chunks/8313.js","../../../../../../../chunks/5264.js","../../../../../../../chunks/6729.js","../../../../../../../chunks/5449.js","../../../../../../../chunks/5304.js","../../../../../../../chunks/913.js","../../../../../../../chunks/9395.js","../../../../../../../chunks/370.js","../../../../../../../chunks/424.js","../../../../../../../chunks/4858.js","../../../../../../../chunks/5472.js","../../../../../../../chunks/1781.js","../../../../../../../chunks/4941.js","../../../../../../../chunks/7023.js","../../../../../../../chunks/8682.js","../../../../../../../chunks/1206.js","../../../../../../../chunks/5116.js","../../../../../../../chunks/6718.js","../../../../../../../chunks/2733.js","../../../../../../../chunks/7531.js","../../../../../../../../package.json","../../../../../../../../../ssl/ca-cert.pem","../../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../../node_modules/next/head.js","../../../../../../../../../node_modules/next/package.json","../../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../../node_modules/react/package.json","../../../../../../../../../node_modules/react/index.js","../../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../../node_modules/mysql/index.js","../../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../../node_modules/mysql/package.json","../../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../../node_modules/clsx/package.json","../../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../../node_modules/react-is/package.json","../../../../../../../../../node_modules/react-is/index.js","../../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../../node_modules/isarray/package.json","../../../../../../../../../node_modules/isarray/index.js","../../../../../../../../../node_modules/inherits/package.json","../../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../../node_modules/stylis/package.json","../../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js new file mode 100644 index 0000000..a9ce39c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js @@ -0,0 +1,742 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5668; +exports.ids = [5668,8105]; +exports.modules = { + +/***/ 9053: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddSocialLoginsContext": () => (/* binding */ AddSocialLoginsContext), + "default": () => (/* binding */ AddSocialLogins), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/users/DbCreateDbUserForm.jsx +var DbCreateDbUserForm = __webpack_require__(1926); +// EXTERNAL MODULE: ./components/form/FormRadios.jsx +var FormRadios = __webpack_require__(2348); +// EXTERNAL MODULE: ./components/form/FormCheckboxes.jsx +var FormCheckboxes = __webpack_require__(9486); +;// CONCATENATED MODULE: ./components/admin/users/SocialLoginsContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SocialLoginsContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , socialLogins } = external_react_default().useContext(AddSocialLoginsContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const availablePlatforms = [ + "Github", + "Google" + ]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ paradigm: string | null, setParadigm: React.Dispatch<React.SetStateAction<string | null>> ]} */ // @ts-ignore + const [paradigm, setParadigm] = external_react_default().useState(socialLogins && socialLogins[0]?.paradigm?.match(/personal/i) ? "personal" : "datasquirel"); + const [platforms, setPlatforms] = external_react_default().useState(socialLogins && socialLogins[0] ? socialLogins : []); + const infoText = (()=>{ + if (paradigm?.match(/datasquirel/i)) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + children: [ + "All social media logins on your site will be done using datasquirel credentials. Please note that you ", + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "MUST" + }), + " ", + "add your domain for this to work." + ] + }); + } + if (paradigm?.match(/personal/i)) { + return /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "You need to setup your credentials in respective providers and put those credentials in the appropriate fields provided." + }); + } + return ""; + })(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Add Social Logins to ", + database.db_name + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + screen: true + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormRadios/* default */.Z, { + radioValues: [ + { + title: "Use Datasquirel Credentials", + payload: "datasquirel", + default: paradigm?.match(/datasquirel/i) ? true : false + }, + { + title: "Use Your Own Credentials", + payload: "personal", + default: paradigm?.match(/personal/i) ? true : false + }, + ], + flexRow: true, + name: "select-paradigm", + onChangeHandler: (e)=>{ + setParadigm(null); + setTimeout(()=>{ + setParadigm(e.target.value); + }, 500); + } + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "max-w-2xl w-full flex-col items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "info gray font-normal mb-4", + children: infoText + }), + paradigm ? /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + checkBoxValues: availablePlatforms.map((platform, index)=>{ + const existingLoginDetails = socialLogins?.filter((scObj)=>scObj.platform === platform.toLocaleLowerCase()); + const targetExistingSocial = existingLoginDetails && existingLoginDetails[0] ? existingLoginDetails[0] : null; + return { + title: platform, + payload: platform.toLowerCase(), + className: "w-full", + jsx: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card grow", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: `/images/${platform.toLowerCase()}.png`, + alt: `${platform} icon`, + className: "avatar small" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "content", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "title", + children: platform + }), + paradigm?.match(/personal/) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: `${platform.toLowerCase()}-client-id`, + id: `${platform.toLowerCase()}-client-id`, + placeholder: "Client Id", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let targetPlatformFilterArray = platforms.filter((obj)=>obj.platform === platform.toLocaleLowerCase()); + if (targetPlatformFilterArray && targetPlatformFilterArray[0]) { + targetPlatformFilterArray[0].clientId = inputEl.value; + } + }, + defaultValue: targetExistingSocial?.clientId ? targetExistingSocial.clientId : undefined + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: `${platform.toLowerCase()}-client-secret`, + id: `${platform.toLowerCase()}-client-secret`, + placeholder: "Client Secret", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let targetPlatformFilterArray = platforms.filter((obj)=>obj.platform === platform.toLocaleLowerCase()); + if (targetPlatformFilterArray && targetPlatformFilterArray[0]) { + targetPlatformFilterArray[0].clientSecret = inputEl.value; + } + }, + defaultValue: targetExistingSocial?.clientSecret ? targetExistingSocial.clientSecret : undefined + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: `${platform.toLowerCase()}-callback-url`, + id: `${platform.toLowerCase()}-callback-url`, + placeholder: "Callback URL", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let targetPlatformFilterArray = platforms.filter((obj)=>obj.platform === platform.toLocaleLowerCase()); + if (targetPlatformFilterArray && targetPlatformFilterArray[0]) { + targetPlatformFilterArray[0].callbackUrl = inputEl.value; + } + }, + defaultValue: targetExistingSocial?.callbackUrl ? targetExistingSocial.callbackUrl : undefined + }) + ] + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: `${platform.toLowerCase()}-domain-1`, + id: `${platform.toLowerCase()}-domain-1`, + placeholder: "Domain 1", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let targetPlatformFilterArray = platforms.filter((obj)=>obj.platform === platform.toLocaleLowerCase()); + if (targetPlatformFilterArray && targetPlatformFilterArray[0]) { + targetPlatformFilterArray[0].domain1 = inputEl.value; + } + }, + defaultValue: targetExistingSocial?.domain1 ? targetExistingSocial.domain1 : undefined + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: `${platform.toLowerCase()}-domain-2`, + id: `${platform.toLowerCase()}-domain-2`, + placeholder: "Domain 2", + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + let targetPlatformFilterArray = platforms.filter((obj)=>obj.platform === platform.toLocaleLowerCase()); + if (targetPlatformFilterArray && targetPlatformFilterArray[0]) { + targetPlatformFilterArray[0].domain2 = inputEl.value; + } + }, + defaultValue: targetExistingSocial?.domain2 ? targetExistingSocial.domain2 : undefined + }) + ] + }) + ] + }) + ] + }), + onChangeHandler: (e)=>{ + const clientId = e.target.parentNode.querySelector(`input[name='${platform.toLowerCase()}-client-id']`)?.value; + const clientSecret = e.target.parentNode.querySelector(`input[name='${platform.toLowerCase()}-client-secret']`)?.value; + const callbackUrl = e.target.parentNode.querySelector(`input[name='${platform.toLowerCase()}-callback-url']`)?.value; + const domain1 = e.target.parentNode.querySelector(`input[name='${platform.toLowerCase()}-domain-1']`)?.value; + const domain2 = e.target.parentNode.querySelector(`input[name='${platform.toLowerCase()}-domain2']`)?.value; + const platformObject = { + platform: platform.toLowerCase(), + clientId: clientId, + clientSecret: clientSecret, + callbackUrl: callbackUrl, + domain1: domain1, + domain2: domain2 + }; + if (e.target.checked) { + setPlatforms((prev)=>[ + ...prev, + platformObject, + ]); + } else { + setPlatforms((prev)=>prev.filter((obj)=>obj.platform !== platformObject.platform)); + } + }, + default: targetExistingSocial ? true : false + }; + }), + name: "social-platforms", + className: "w-full" + }) : /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full p-10", + children: /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative", + width: "20px" + }) + }), + platforms && platforms[0] && /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "w-full more-padding", + onClick: (e)=>{ + setLoading(true); + const fetchObject = { + dbFullName: database.db_full_name, + dbSlug: database.db_slug, + paradigm: paradigm, + platforms: platforms + }; + (0,fetchApi/* default */.Z)("/api/addSocialLogin", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (res?.success) { + window.location.reload(); + } else { + window.alert(res.msg); + } + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + }, + children: "Add Social Logins" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/users/add-social-logins.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AddSocialLoginContextType} */ // @ts-ignore +const init = {}; +const AddSocialLoginsContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {any} props.query + * @param {import("@/package-shared/types").SocialLoginObjectType[]} props.socialLogins + */ function AddSocialLogins({ user , database , query , socialLogins , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Social Logins | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(AddSocialLoginsContext.Provider, { + value: { + user, + database, + query, + socialLogins + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(SocialLoginsContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + try { + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${user.id}/main.json`, "utf-8")); + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const userEnvFilePath = `./jsonData/dbSchemas/users/user-${user.id}/env.json`; + if (!fs.existsSync(userEnvFilePath)) { + // const envPreset = fs.readFileSync(`./jsonData/dbSchemas/presets/env.json`, "utf-8"); + fs.writeFileSync(userEnvFilePath, "{}", "utf-8"); + } + /** @type {import("@/package-shared/types").SocialLoginObjectType} */ const socialLogins = JSON.parse(fs.readFileSync(userEnvFilePath, "utf-8"))[database[0].db_full_name]?.social; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + socialLogins: socialLogins ? socialLogins : [], + query + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log("Error in 'add-social-logins; page component =>", error.message); + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7901,6718,9486,7037,2733,1926,2348], () => (__webpack_exec__(9053))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js.nft.json new file mode 100644 index 0000000..d2f0a2d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-social-logins.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/4941.js","../../../../../../chunks/7901.js","../../../../../../chunks/6718.js","../../../../../../chunks/9486.js","../../../../../../chunks/7037.js","../../../../../../chunks/2733.js","../../../../../../chunks/1926.js","../../../../../../chunks/2348.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js new file mode 100644 index 0000000..e84da05 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js @@ -0,0 +1,639 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5926; +exports.ids = [5926,8105]; +exports.modules = { + +/***/ 4437: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddNewDbUserContext": () => (/* binding */ AddNewDbUserContext), + "default": () => (/* binding */ AddUserPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/admin/users/DbCreateDbUserForm.jsx +var DbCreateDbUserForm = __webpack_require__(1926); +;// CONCATENATED MODULE: ./components/admin/users/DbAddNewUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DbAddNewUserContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , database , table , query , confirmedDelegetedUser } = external_react_default().useContext(AddNewDbUserContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userPriviledges = __webpack_require__(9169); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [paradigm, setParadigm] = external_react_default().useState("invitation"); + const [loading, setLoading] = external_react_default().useState(false); + const [allDbSelected, setAllDbSelected] = external_react_default().useState(false); + const [priviledges, setPriviledges] = external_react_default().useState([ + "Edit" + ]); + /** @type {[ targetDb: string, setTargetDb: React.Dispatch<React.SetStateAction<string>> ]} */ // @ts-ignore + const [targetDb, setTargetDb] = external_react_default().useState(database.db_slug); + const [alert, setAlert] = external_react_default().useState(null); + /** @type {[ userImage: any, setUserImage: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [userImage, setUserImage] = external_react_default().useState(null); + const [dbTables, setDbTables] = external_react_default().useState([]); + const [selectedDbTables, setSlectedDbTables] = external_react_default().useState([]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Add A New User to ", + database.db_name + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const form = e.target; + const formFields = Array.from(form); + /** @type {any} */ const formFieldsObject = {}; + formFields.forEach((/** @type {any} */ field)=>{ + if (field.nodeName?.match(/button/i)) return; + if (!field.name || !field.value?.match(/./)) return; + formFieldsObject[field.name] = field.value; + }); + const fetchObject = { + payload: formFieldsObject, + dbFullName: database.db_full_name, + dbId: database.id + }; + (0,fetchApi/* default */.Z)("/api/addDbUser", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (res.success) { + if (userImage) { + userImage["imageName"] = `${targetDb}-user-${res.newUserId}`; + userImage["mimeType"] = "jpeg"; + delete userImage["imageBase64Full"]; + (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + userImage + ], + folder: targetDb.replace(/_/g, "-"), + type: "image" + } + }, true).then((_res)=>{ + (0,fetchApi/* default */.Z)("/api/updateDbUser", { + method: "post", + body: { + dbFullName: database.db_full_name, + payload: { + id: res.newUserId, + image: _res.mediaData[0].media_url, + image_thumbnail: _res.mediaData[0].media_thumbnail_url + } + } + }, true).then((__res)=>{ + if (__res.success) { + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/users`; + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + }); + } else { + window.location.pathname = `/admin/${user?.id}/databases/${database.db_slug}/users`; + } + } else { + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); + }, + className: "w-full flex flex-col items-stretch gap-4", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(DbCreateDbUserForm/* default */.Z, { + user: user, + targetDb: database.db_full_name, + database: database, + userImage: userImage, + setUserImage: setUserImage + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: "Add User" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/functions/backend/varDatabaseDbHandler.js +var varDatabaseDbHandler = __webpack_require__(1206); +var varDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(varDatabaseDbHandler); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(5116); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/databases/[single]/users/add-user.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AddUserUserContextType} */ // @ts-ignore +const init = {}; +const AddNewDbUserContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + * @param {import("@/package-shared/types").DSQL_TableSchemaType} props.table + * @param {any} props.query + * @param {any} props.confirmedDelegetedUser + */ function AddUserPage({ user , database , table , query , confirmedDelegetedUser , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Users | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + extraHeaderContent: /*#__PURE__*/ jsx_runtime_.jsx(ExtraContentDatabase/* default */.Z, { + database: database, + query: query, + confirmedDelegetedUser: confirmedDelegetedUser, + user: user + }), + children: /*#__PURE__*/ jsx_runtime_.jsx(AddNewDbUserContext.Provider, { + value: { + user, + database, + table, + query, + confirmedDelegetedUser + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(DbAddNewUserContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const dbUserData = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + // @ts-ignore + databaseSlug: query.single, + query + }); + const dbUserDataObj = dbUserData; + if (!dbUserDataObj) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const { dbUserId , rootUserId } = dbUserDataObj; + const database = await DB_HANDLER_default()(`SELECT * FROM user_databases WHERE user_id='${dbUserId}' AND db_slug='${query.single}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/databases`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Confirm delegated User + * + * @description Confirm delegated User + */ let confirmedDelegetedUser = dbUserData; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchemaData = JSON.parse(fs.readFileSync(`./jsonData/dbSchemas/users/user-${dbUserId}/main.json`, "utf-8")); + const tables = dbSchemaData.filter((db)=>db.dbFullName === database[0].db_full_name)[0]?.tables; + const targetTable = tables.filter((table)=>table.tableName === "users")[0]; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await varDatabaseDbHandler_default()({ + database: database[0].db_full_name, + queryString: `SELECT * FROM users LIMIT 20`, + tableSchema: targetTable + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + database: database[0], + table: targetTable ? targetTable : {}, + query, + confirmedDelegetedUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9169: +/***/ ((module) => { + +module.exports = JSON.parse('["Edit Tables","Update Entries","Create Table","Delete Entries","Delete Tables"]'); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4941,7023,7901,8682,1206,5116,6718,7037,2733,1926], () => (__webpack_exec__(4437))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js.nft.json new file mode 100644 index 0000000..b98f284 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/[single]/users/add-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/4941.js","../../../../../../chunks/7023.js","../../../../../../chunks/7901.js","../../../../../../chunks/8682.js","../../../../../../chunks/1206.js","../../../../../../chunks/5116.js","../../../../../../chunks/6718.js","../../../../../../chunks/7037.js","../../../../../../chunks/2733.js","../../../../../../chunks/1926.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../jsonData/userPriviledges.json","../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js new file mode 100644 index 0000000..b574aa3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js @@ -0,0 +1,207 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3316; +exports.ids = [3316]; +exports.modules = { + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 6405: +/***/ ((module) => { + +module.exports = require("react-dom"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,7023,7901,6718,9594,9471,9486,7037,9967,4105,3974], () => (__webpack_exec__(6706))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js.nft.json new file mode 100644 index 0000000..7dffe3e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/databases/add-database.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/913.js","../../../../chunks/9395.js","../../../../chunks/370.js","../../../../chunks/424.js","../../../../chunks/4858.js","../../../../chunks/5472.js","../../../../chunks/1781.js","../../../../chunks/7023.js","../../../../chunks/7901.js","../../../../chunks/6718.js","../../../../chunks/9594.js","../../../../chunks/9471.js","../../../../chunks/9486.js","../../../../chunks/7037.js","../../../../chunks/9967.js","../../../../chunks/4105.js","../../../../chunks/3974.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lodash/package.json","../../../../../../node_modules/react-dom/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lodash/lodash.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/react-dom/index.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react-dom/client.js","../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/scheduler/package.json","../../../../../../node_modules/scheduler/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js new file mode 100644 index 0000000..8dc2393 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js @@ -0,0 +1,616 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3400; +exports.ids = [3400]; +exports.modules = { + +/***/ 8333: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "MediaContext": () => (/* binding */ MediaContext), + "default": () => (/* binding */ Dashboard), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/VerificationBanner.jsx +var VerificationBanner = __webpack_require__(7946); +// EXTERNAL MODULE: ./components/admin/media/MediaList.jsx + 5 modules +var MediaList = __webpack_require__(7604); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +;// CONCATENATED MODULE: ./components/admin/media/MediaContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function MediaContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { media , setTargetMedia , user , folders , staticHost } = external_react_default().useContext(MediaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Media" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex items-center gap-2", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("choose-media-type-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Media" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex items-center gap-2 outlined gray", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("add-folder-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Folder" + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(MediaList/* default */.Z, { + media: media, + setTargetMedia: setTargetMedia, + folders: folders, + staticHost: staticHost, + user: user + }), + media && media[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + className: "border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("choose-media-type-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Add Media" + }) + ] + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx(VerificationBanner/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/UploadImageComponent.jsx +var UploadImageComponent = __webpack_require__(3770); +// EXTERNAL MODULE: ./components/admin/media/NewMediaPopup.jsx + 3 modules +var NewMediaPopup = __webpack_require__(4891); +// EXTERNAL MODULE: ./components/admin/media/TargetMediaPreviewPopup.jsx +var TargetMediaPreviewPopup = __webpack_require__(3428); +// EXTERNAL MODULE: ./components/admin/media/NewFolderPopup.jsx +var NewFolderPopup = __webpack_require__(1597); +// EXTERNAL MODULE: ./components/general/UploadFileComponent.jsx +var UploadFileComponent = __webpack_require__(8916); +// EXTERNAL MODULE: ./components/admin/media/ChooseMediaTypePopup.jsx +var ChooseMediaTypePopup = __webpack_require__(9201); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: external "path" +var external_path_ = __webpack_require__(1017); +var external_path_default = /*#__PURE__*/__webpack_require__.n(external_path_); +// EXTERNAL MODULE: ./components/general/UploadVideoComponent.jsx +var UploadVideoComponent = __webpack_require__(7525); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/media/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").MediaContextType} */ // @ts-ignore +const init = {}; +const MediaContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").MYSQL_user_media_table_def[]} props.media + * @param {string[]} props.folders + * @param {string} props.staticHost + */ function Dashboard({ user , media , folders , staticHost }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ newMedia: import("@/package-shared/types").ImageObjectType[] | null, setNewMedia: React.Dispatch<React.SetStateAction<import("@/package-shared/types").ImageObjectType[] | null>> ]} */ // @ts-ignore + const [newMedia, setNewMedia] = external_react_default().useState(null); + /** @type {[ newFile: any | null, setNewFile: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [newFile, setNewFile] = external_react_default().useState(null); + /** @type {[ newFile: any | null, setNewFile: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [newVideo, setNewVideo] = external_react_default().useState(null); + const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ targetMedia: import("@/package-shared/types").MYSQL_user_media_table_def | null, setTargetMedia: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_media_table_def | null>> ]} */ // @ts-ignore + const [targetMedia, setTargetMedia] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(MediaContext.Provider, { + value: { + user, + media, + targetMedia, + setTargetMedia, + folders, + staticHost + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + screen: true, + title: "Processing Files ..." + }), + /*#__PURE__*/ jsx_runtime_.jsx(MediaContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UploadImageComponent/* default */.Z, { + setNewMedia: setNewMedia, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(UploadFileComponent/* default */.Z, { + setNewFile: setNewFile, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(UploadVideoComponent/* default */.Z, { + setNewVideo: setNewVideo, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewMediaPopup/* default */.Z, { + newMedia: newMedia, + setNewMedia: setNewMedia, + newFile: newFile, + setNewFile: setNewFile, + newVideo: newVideo, + setNewVideo: setNewVideo + }), + /*#__PURE__*/ jsx_runtime_.jsx(TargetMediaPreviewPopup/* default */.Z, { + targetMedia: targetMedia, + setTargetMedia: setTargetMedia, + staticHost: staticHost, + media: media + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewFolderPopup/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx(ChooseMediaTypePopup/* default */.Z, { + user: user + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const media = await DB_HANDLER_default()(`SELECT * FROM user_media WHERE user_id='${user.id}' AND folder IS NULL`); + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const folderPath = external_path_default().join(STATIC_ROOT, `images/user-images/user-${user.id}/`); + if (!fs.existsSync(folderPath)) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const folders = fs.readdirSync(folderPath).filter((name)=>!name.match(/\..{3,4}$/)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + media: media, + folders: folders, + staticHost: process.env.DSQL_STATIC_HOST || "" + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 9765: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AssignmentTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8757: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteOutlineOutlined"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 8398: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/FolderCopyTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 8083: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOpenOutlined"); + +/***/ }), + +/***/ 4624: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonRounded"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 5580: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PermMediaTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 871: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/VideoCameraBackTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,8345,6718,7946,6390], () => (__webpack_exec__(8333))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js.nft.json new file mode 100644 index 0000000..b447a89 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/media.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../chunks/8345.js","../../../chunks/6718.js","../../../chunks/7946.js","../../../chunks/6390.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/AssignmentTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteOutlineOutlined.js","../../../../../node_modules/@mui/icons-material/FolderCopyTwoTone.js","../../../../../node_modules/@mui/icons-material/LockOpenOutlined.js","../../../../../node_modules/@mui/icons-material/LockPersonRounded.js","../../../../../node_modules/@mui/icons-material/PermMediaTwoTone.js","../../../../../node_modules/@mui/icons-material/VideoCameraBackTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js new file mode 100644 index 0000000..9d30083 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js @@ -0,0 +1,724 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2759; +exports.ids = [2759]; +exports.modules = { + +/***/ 3345: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** + * Imports: Handle imports + */ /** + * Grab Paths Function + * ============================================================================== + * @description Description + * + * @param {object} params - An object containing the function parameters. + * @param {boolean} [params.isPrivate] - Is this file private or not? + * @param {any} params.user - User object + * @param {string} [params.folder] - Folder, if available + * @param {boolean} [params.video] - Video, if available + * @param {boolean} [params.pathOnly] - Just generate the directories' paths + * + * @returns {{ fileRootPath: string, urlRootPath: string, relativePath: string } | null} + */ module.exports = function grabPaths({ isPrivate , user , folder , video , pathOnly , }) { + /** + * Initialize variables + */ const isProduction = "production".match(/production/); + const userId = user?.id || user?.user_id; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return null; + } + const relativePath = isPrivate ? `@/${video ? "videos" : "media"}/${folder ? folder + "/" : ""}` : video ? `/videos/user-videos/user-${userId}/${folder ? folder + "/" : ""}` : `/images/user-images/user-${userId}/${folder ? folder + "/" : ""}`; + const fileRootPath = isPrivate ? `./jsonData/dbSchemas/users/user-${userId}/media/${folder ? folder + "/" : ""}` : path.join(STATIC_ROOT, relativePath); + if (!fs.existsSync(fileRootPath) && !pathOnly) { + fs.mkdirSync(fileRootPath, { + recursive: true + }); + } + const urlRootPath = isPrivate ? `@/media/${folder ? folder + "/" : ""}` : `${process.env.DSQL_STATIC_HOST}${relativePath}`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return { + fileRootPath: fileRootPath, + urlRootPath: urlRootPath, + relativePath + }; +}; + + +/***/ }), + +/***/ 3947: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "MediaContext": () => (/* binding */ MediaContext), + "default": () => (/* binding */ Dashboard), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/UploadImageComponent.jsx +var UploadImageComponent = __webpack_require__(3770); +// EXTERNAL MODULE: ./components/admin/media/NewMediaPopup.jsx + 3 modules +var NewMediaPopup = __webpack_require__(4891); +// EXTERNAL MODULE: ./components/admin/media/TargetMediaPreviewPopup.jsx +var TargetMediaPreviewPopup = __webpack_require__(3428); +// EXTERNAL MODULE: ./components/admin/media/NewFolderPopup.jsx +var NewFolderPopup = __webpack_require__(1597); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/VerificationBanner.jsx +var VerificationBanner = __webpack_require__(7946); +// EXTERNAL MODULE: ./components/admin/media/MediaList.jsx + 5 modules +var MediaList = __webpack_require__(7604); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +// EXTERNAL MODULE: external "@mui/icons-material/FolderCopyTwoTone" +var FolderCopyTwoTone_ = __webpack_require__(8398); +var FolderCopyTwoTone_default = /*#__PURE__*/__webpack_require__.n(FolderCopyTwoTone_); +;// CONCATENATED MODULE: ./components/admin/media/MediaFolderContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function MediaFolderContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { media , setTargetMedia , user , folders , query , staticHost , folder } = external_react_default().useContext(MediaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx((FolderCopyTwoTone_default()), { + className: "opacity-40" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: query.folder[query.folder.length - 1] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex items-center gap-2", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("choose-media-type-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Media" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "flex items-center gap-2 outlined gray", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("add-folder-popoup", (popupElement)=>{ + popupElement?.querySelector("input")?.focus(); + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add Folder" + }) + ] + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(MediaList/* default */.Z, { + media: media, + setTargetMedia: setTargetMedia, + folders: folders, + folder: folder, + staticHost: staticHost, + user: user + }), + media && media[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + className: "border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("choose-media-type-popoup"); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "", + children: "Add Media" + }) + ] + }) + ] + }) : /*#__PURE__*/ jsx_runtime_.jsx(VerificationBanner/* default */.Z, {}) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/UploadFileComponent.jsx +var UploadFileComponent = __webpack_require__(8916); +// EXTERNAL MODULE: ./components/admin/media/ChooseMediaTypePopup.jsx +var ChooseMediaTypePopup = __webpack_require__(9201); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: external "path" +var external_path_ = __webpack_require__(1017); +var external_path_default = /*#__PURE__*/__webpack_require__.n(external_path_); +// EXTERNAL MODULE: ./components/general/UploadVideoComponent.jsx +var UploadVideoComponent = __webpack_require__(7525); +// EXTERNAL MODULE: ./functions/backend/grabPaths.js +var grabPaths = __webpack_require__(3345); +var grabPaths_default = /*#__PURE__*/__webpack_require__.n(grabPaths); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/media/[...folder].jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").MediaFolderPageContextType} */ // @ts-ignore +const init = {}; +const MediaContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any[]} props.media + * @param {any[]} props.folders + * @param {any} props.query + * @param {string} props.staticHost + * @param {string} props.folderNameFull + */ function Dashboard({ user , media , folders , query , staticHost , folderNameFull , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ newMedia: any, setNewMedia: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [newMedia, setNewMedia] = external_react_default().useState(null); + /** @type {[ newFile: any, setNewFile: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [newFile, setNewFile] = external_react_default().useState(null); + /** @type {[ newFile: any, setNewFile: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [newVideo, setNewVideo] = external_react_default().useState(null); + const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ targetMedia: import("@/package-shared/types").MYSQL_user_media_table_def | null, setTargetMedia: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_media_table_def | null>> ]} */ // @ts-ignore + const [targetMedia, setTargetMedia] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(MediaContext.Provider, { + value: { + user, + media, + targetMedia, + setTargetMedia, + folders, + query, + staticHost, + folder: folderNameFull + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + screen: true, + title: "Processing Files ..." + }), + /*#__PURE__*/ jsx_runtime_.jsx(MediaFolderContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UploadImageComponent/* default */.Z, { + setNewMedia: setNewMedia, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(UploadFileComponent/* default */.Z, { + setNewFile: setNewFile, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(UploadVideoComponent/* default */.Z, { + setNewVideo: setNewVideo, + setLoading: setLoading + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewMediaPopup/* default */.Z, { + newMedia: newMedia, + setNewMedia: setNewMedia, + newFile: newFile, + setNewFile: setNewFile, + folder: folderNameFull, + newVideo: newVideo, + setNewVideo: setNewVideo + }), + /*#__PURE__*/ jsx_runtime_.jsx(TargetMediaPreviewPopup/* default */.Z, { + targetMedia: targetMedia, + staticHost: staticHost, + setTargetMedia: setTargetMedia, + media: media + }), + /*#__PURE__*/ jsx_runtime_.jsx(NewFolderPopup/* default */.Z, { + folder: folderNameFull + }), + /*#__PURE__*/ jsx_runtime_.jsx(ChooseMediaTypePopup/* default */.Z, { + user: user + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + try { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {string[]} */ // @ts-ignore + const queryFoldersArray = query.folder; + const folderName = queryFoldersArray.join("/"); + const media = await DB_HANDLER_default()(`SELECT * FROM user_media WHERE user_id='${user.id}' AND folder='${folderName}'`); + const paths = grabPaths_default()({ + isPrivate: false, + user, + folder: folderName, + video: false, + pathOnly: true + }); + if (!paths) { + console.log("Static File ENV not Found!"); + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + const folderPath = paths.fileRootPath; + const folders = fs.readdirSync(folderPath).filter((name)=>!fs.statSync(external_path_default().normalize(`${folderPath}/${name}`)).isFile()); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + media: media, + folders: folders, + query: query, + staticHost: process.env.DSQL_STATIC_HOST || "", + folderNameFull: folderName + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {*} */ error) { + return { + redirect: { + destination: `/admin`, + permanent: false + } + }; + } +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 9765: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AssignmentTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8757: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteOutlineOutlined"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 8398: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/FolderCopyTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 8083: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockOpenOutlined"); + +/***/ }), + +/***/ 4624: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonRounded"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 5580: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PermMediaTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 871: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/VideoCameraBackTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,8345,6718,7946,6390], () => (__webpack_exec__(3947))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js.nft.json new file mode 100644 index 0000000..5d3be9d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/media/[...folder].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/913.js","../../../../chunks/9395.js","../../../../chunks/370.js","../../../../chunks/424.js","../../../../chunks/4858.js","../../../../chunks/5472.js","../../../../chunks/1781.js","../../../../chunks/8345.js","../../../../chunks/6718.js","../../../../chunks/7946.js","../../../../chunks/6390.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../node_modules/@mui/icons-material/AssignmentTwoTone.js","../../../../../../node_modules/@mui/icons-material/DeleteOutlineOutlined.js","../../../../../../node_modules/@mui/icons-material/FolderCopyTwoTone.js","../../../../../../node_modules/@mui/icons-material/LockOpenOutlined.js","../../../../../../node_modules/@mui/icons-material/LockPersonRounded.js","../../../../../../node_modules/@mui/icons-material/PermMediaTwoTone.js","../../../../../../node_modules/@mui/icons-material/VideoCameraBackTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js new file mode 100644 index 0000000..e3a7144 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js @@ -0,0 +1,938 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5957; +exports.ids = [5957,8105]; +exports.modules = { + +/***/ 7947: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* unused harmony export default */ +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {{ + * editorRef: { current: any }, + * readOnly: boolean, + * executeFunction: (editor: AceAjax.Editor) => void, + * content: string, + * placeholder?: string, + * mode?: string, + * fontSize?: string, + * }} props - React component props including { children } + */ function AceEditor({ editorRef , readOnly , executeFunction , content , placeholder , mode , fontSize , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.LegacyRef<HTMLDivElement | undefined>} */ const editorElementRef = React.useRef(); + /** @type {React.MutableRefObject<AceAjax.Editor | undefined>} */ const editorRefInstance = React.useRef(); + const [loading, setLoading] = React.useState(false); + const [refresh, setRefresh] = React.useState(0); + React.useEffect(()=>{ + if (!ace?.edit || !editorElementRef.current) { + setTimeout(()=>{ + setRefresh((prev)=>prev + 1); + }, 1000); + return; + } + const editor = ace.edit(editorElementRef.current); + editor.setOptions({ + mode: `ace/mode/${mode ? mode : "javascript"}`, + theme: "ace/theme/nord_dark", + // theme: "ace/theme/twilight", + value: content, + placeholder: placeholder ? placeholder : "", + enableBasicAutocompletion: true, + enableLiveAutocompletion: true, + readOnly: readOnly ? true : false, + fontSize: fontSize ? fontSize : null + }); + editor.commands.addCommand({ + name: "myCommand", + bindKey: { + win: "Ctrl-Enter", + mac: "Command-Enter" + }, + exec: function(editor) { + if (executeFunction) executeFunction(editor); + }, + readOnly: true + }); + editorRefInstance.current = editor; + if (editorRef) editorRef.current = editor; + }, [ + refresh + ]); + React.useEffect(()=>{ + if (!editorRefInstance.current) return; + editorRefInstance.current.setValue(content, -1); + }, [ + content + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ _jsx(React.Fragment, { + children: /*#__PURE__*/ _jsx("div", { + className: "p-4 w-full h-full block rounded-md", + style: { + backgroundColor: "#2e3440" + }, + children: /*#__PURE__*/ _jsx("div", { + // @ts-ignore + ref: editorElementRef, + className: "ace-editor-wrapper w-full h-full minimal-scrollbars all-children" + }) + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + React.useEffect(()=>{ + fetchApi("/api/admin/clientError", { + method: "post", + body: { + component: "AceEditor/main-catch-error", + message: error.message, + user: {} + } + }); + }, []); + return /*#__PURE__*/ _jsx(React.Fragment, { + children: /*#__PURE__*/ _jsx("h2", { + className: "text-xl m-0", + children: "Editor Error" + }) + }); + } +} + + +/***/ }), + +/***/ 4458: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "UserSchemaContext": () => (/* binding */ UserSchemaContext), + "default": () => (/* binding */ DatabaseSchema), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/ExtraContentDatabase.jsx +var ExtraContentDatabase = __webpack_require__(4941); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/admin/databases/UserSchemaVisualizer.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function UserSchemaVisualizer(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { dbSchemaData , user } = external_react_default().useContext(UserSchemaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper p-4 flex-col items-start justify-start gap-14", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "-mb-2 font-bold text-lg text-slate-400 mt-1", + children: "User Schema Map" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "-my-8" + }), + dbSchemaData.map((targetDb, rootIndex)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "w-full xl:w-auto ml-auto text-lg bg-primary px-3 py-1 rounded text-white font-bold top-0 sticky", + children: [ + targetDb.dbName, + " Database Tables" + ] + }), + targetDb.tables.map((table, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-4 left-border pl-6 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold text-base rounded sticky top-10 xl:top-0 px-3 py-1 bg-slate-800 text-white -ml-6 w-full xl:w-auto", + children: table.tableFullName + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Fields" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start left-border pl-6 w-full", + children: table.fields.map((field, _index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card flex-col items-start gap-1 bg-white p-4 border border-solid border-slate-300 rounded w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold", + children: field.fieldName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs", + children: field.dataType + }) + ] + }, _index + 1); + }) + }) + ] + }), + table.indexes && table.indexes[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Indexes" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start left-border pl-6 w-full", + children: table.indexes.map((index, _index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card flex-col items-start gap-1 bg-white p-4 border border-solid border-slate-300 rounded w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-bold text-secondary", + children: index.indexName + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs", + children: index.indexType + }) + ] + }, _index + 1); + }) + }) + ] + }) + ] + }, index + 1); + }) + ] + }, rootIndex + 1); + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "UserSchemaVisualizer/catch-error-return", + message: error.message, + user: user + } + }); + }, []); + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: "Nothing to See here" + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/AceEditor.jsx +var AceEditor = __webpack_require__(7947); +// EXTERNAL MODULE: ./components/general/CodeBlock.jsx +var CodeBlock = __webpack_require__(1095); +;// CONCATENATED MODULE: ./components/admin/databases/UserSchemaContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function UserSchemaContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { dbSchemaData , user } = external_react_default().useContext(UserSchemaContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ previewObject: any, setPreviewObject: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [previewObject, setPreviewObject] = external_react_default().useState(dbSchemaData); + const [targetDb, setTargetDb] = external_react_default().useState(null); + /** @type {[ dbTables: import("@/package-shared/types").DSQL_TableSchemaType[], setDbTables: React.Dispatch<React.SetStateAction<import("@/package-shared/types").DSQL_TableSchemaType[] | null>> ]} */ // @ts-ignore + const [dbTables, setDbTables] = external_react_default().useState(null); + const [targetTable, setTargetTable] = external_react_default().useState(null); + external_react_default().useEffect(()=>{ + if (targetDb) { + try { + const targetDbSchema = dbSchemaData.filter((db)=>db.dbFullName === targetDb)[0]; + setPreviewObject(targetDbSchema); + setDbTables(targetDbSchema.tables); + } catch (/** @type {any} */ error) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "UserSchemaContent/lines-64-66", + message: error.message, + user: user + } + }); + } + } else { + setDbTables(null); + setTargetTable(null); + setPreviewObject(dbSchemaData); + } + }, [ + targetDb + ]); + external_react_default().useEffect(()=>{ + if (targetTable && dbTables && dbTables[0]) { + try { + // @ts-ignore + const targetTableObject = dbTables.filter((/** @type {any} */ table)=>table.tableName === targetTable)[0]; + setPreviewObject(targetTableObject); + } catch (/** @type {any} */ error) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "UserSchemaContent/lines-87-88", + message: error.message, + user: user + } + }); + } + } else if (targetDb) { + try { + const targetDbSchema = dbSchemaData.filter((db)=>db.dbFullName === targetDb)[0]; + setPreviewObject(targetDbSchema); + setDbTables(targetDbSchema.tables); + } catch (/** @type {any} */ error1) { + (0,fetchApi/* default */.Z)("/api/admin/clientError", { + method: "post", + body: { + component: "UserSchemaContent/lines-100-103", + message: error1.message, + user: user + } + }); + } + } else { + setDbTables(null); + setTargetTable(null); + setPreviewObject(dbSchemaData); + } + }, [ + targetTable + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "", + children: /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "User Schema" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Database SCHEMA JSON" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + required: true, + selectOptions: [ + { + title: "All Databases", + payload: "none" + }, + ...dbSchemaData.map((db, index)=>{ + return { + title: db.dbName, + payload: db.dbFullName, + name: db.dbFullName + }; + }), + ], + name: "databases", + onChangeHandler: (e)=>{ + if (e.target.value?.match(/^none$/)) { + setTargetDb(null); + } else { + setTargetDb(e.target.value); + } + } + }), + dbTables && dbTables[0] && /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + required: true, + selectOptions: [ + { + title: "All Tables", + payload: "none" + }, + ...dbTables.map((table, index)=>{ + return { + title: table.tableFullName, + payload: table.tableName, + name: table.tableName + }; + }), + ], + name: "database_tables", + onChangeHandler: (e)=>{ + if (e.target.value?.match(/^none$/)) { + setTargetTable(null); + } else { + setTargetTable(e.target.value); + } + } + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "grid grid-cols-1 xl:grid-cols-2 items-stretch w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "relative w-full block", + children: /*#__PURE__*/ jsx_runtime_.jsx(CodeBlock/* default */.Z, { + content: JSON.stringify(previewObject, null, 4), + language: "javascript" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserSchemaVisualizer, {}) + ] + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/VerificationBanner.jsx +var VerificationBanner = __webpack_require__(7946); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/schema.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").UserSchemaContextType} */ // @ts-ignore +const init = {}; +const UserSchemaContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.query + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} props.dbSchemaData + */ function DatabaseSchema({ user , query , dbSchemaData }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Add Database | Datasquirel"; + const pageDescription = "Add a database"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + aceEditor: true, + children: /*#__PURE__*/ jsx_runtime_.jsx(UserSchemaContext.Provider, { + value: { + user, + dbSchemaData + }, + children: user?.verification_status?.toString().match(/1/) ? /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(UserSchemaContent, {}) + }) : /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "", + children: /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "User Schema" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(VerificationBanner/* default */.Z, {}) + ] + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const folderPath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + if (!fs.existsSync(folderPath)) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const dbSchemaData = JSON.parse(fs.readFileSync(folderPath, "utf-8")); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + query, + dbSchemaData: dbSchemaData ? dbSchemaData : [] + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 3849: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CodeRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 6843: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ContentCopy"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 6500: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SendToMobileTwoTone"); + +/***/ }), + +/***/ 7428: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SummarizeTwoTone"); + +/***/ }), + +/***/ 507: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TipsAndUpdatesTwoTone"); + +/***/ }), + +/***/ 9174: +/***/ ((module) => { + +module.exports = require("@mui/material/Snackbar"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,1781,4941,4114,7946,2434], () => (__webpack_exec__(4458))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js.nft.json new file mode 100644 index 0000000..e243533 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/schema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/1781.js","../../../chunks/4941.js","../../../chunks/4114.js","../../../chunks/7946.js","../../../chunks/2434.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/@mui/material/Snackbar/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../../../node_modules/@mui/icons-material/ContentCopy.js","../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../node_modules/@mui/icons-material/CodeRounded.js","../../../../../node_modules/@mui/icons-material/SummarizeTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/base/node/index.js","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/react-transition-group/package.json","../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../node_modules/@popperjs/core/package.json","../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/dom-helpers/package.json","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@floating-ui/dom/package.json","../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/@floating-ui/core/package.json","../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js new file mode 100644 index 0000000..d9cc71b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js @@ -0,0 +1,855 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2417; +exports.ids = [2417,133,4135]; +exports.modules = { + +/***/ 9310: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ UserMediaPopup) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5472); +/* harmony import */ var _general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/* harmony import */ var _ExistingFieldEdit__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9967); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {React.Dispatch<React.SetStateAction<string | null | import("@/package-shared/types").ImageObjectType>>} props.setDbImage + */ function UserMediaPopup({ setDbImage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(true); + /** @type {any} */ const mediaState = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type { [ media: import("@/package-shared/types").MYSQL_MediaType[] | null, setMedia: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_MediaType | null>> ] } */ const [media, setMedia] = mediaState; + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/getUserMedia").then((res)=>{ + setLoading(false); + setMedia(res.media); + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .ZP, { + title: "user-media-popup", + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + width: "20px" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h4", { + className: "m-0 text-lg", + children: "Your Uploaded Images" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "grid grid-cols-2", + children: media && media[0] && media.filter((media)=>media.media_type == "image").map((mediaObject, index)=>{ + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "w-full h-44 cursor-pointer hover:opacity-70", + onClick: (e)=>{ + setDbImage(mediaObject.media_thumbnail_url || null); + (0,_general_GeneralPopup__WEBPACK_IMPORTED_MODULE_2__/* .closePopup */ .j4)(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: mediaObject.media_thumbnail_url, + alt: "User Media", + className: "w-full h-full object-contain" + }) + }, index + 1); + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 4227: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const serverError = __webpack_require__(7023); +const NO_DB_HANDLER = __webpack_require__(2020); +/** + * Create database from Schema Function + * ============================================================================== + * @param {string} queryString - Query String + * @returns {Promise<any>} + */ module.exports = async function noDatabaseDbHandler(queryString) { + "production"?.match(/dev/) && fs.appendFileSync("./.tmp/sqlQuery.sql", queryString + "\n" + Date() + "\n\n\n", "utf8"); + /** + * Declare variables + * + * @description Declare "results" variable + */ let results; + /** + * Fetch from db + * + * @description Fetch data from db if no cache + */ try { + /** ********************* Run Query */ results = await NO_DB_HANDLER(queryString); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "noDatabaseDbHandler", + message: error.message + }); + console.log("ERROR in noDatabaseDbHandler =>", error.message); + } + /** + * Return results + * + * @description Return results add to cache if "req" param is passed + */ if (results) { + return results; + } else { + return null; + } +}; + + +/***/ }), + +/***/ 2020: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +// const mysql = require("mysql"); +// const NO_DB = mysql.createConnection({ +// host: process.env.DSQL_DB_HOST, +// user: process.env.DSQL_DB_USERNAME, +// password: process.env.DSQL_DB_PASSWORD, +// charset: "utf8mb4", +// }); +const mysql = __webpack_require__(2261); +const SSL_DIR = "/app/ssl"; +let NO_DB = mysql({ + config: { + host: process.env.DSQL_DB_HOST, + user: process.env.DSQL_DB_USERNAME, + password: process.env.DSQL_DB_PASSWORD, + charset: "utf8mb4", + ssl: { + ca: fs.readFileSync(`${SSL_DIR}/ca-cert.pem`) + } + } +}); +/** + * DSQL user read-only DB handler + * @param {object} params + * @param {string} params.paradigm + * @param {string} params.database + * @param {string} params.queryString + * @param {string[]} [params.queryValues] + */ // @ts-ignore +function NO_DB_HANDLER(...args) { + try { + return new Promise((resolve, reject)=>{ + NO_DB.query(...args).then((results)=>{ + NO_DB.end(); + resolve(JSON.parse(JSON.stringify(results))); + }).catch((err)=>{ + NO_DB.end(); + resolve({ + error: err.message, + sql: err.sql + }); + }); + }); + } catch (/** @type {any} */ error) { + return { + success: false, + error: error.message + }; + } +} +module.exports = NO_DB_HANDLER; + + +/***/ }), + +/***/ 1481: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SettingsContext": () => (/* binding */ SettingsContext), + "default": () => (/* binding */ Settings), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./pages/admin/[user_id]/index.jsx +var _user_id_ = __webpack_require__(1457); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/pages/create-account/CreateAccountForm.jsx + 1 modules +var CreateAccountForm = __webpack_require__(5114); +// EXTERNAL MODULE: ./functions/frontend/imageInputFileToBase64.js +var imageInputFileToBase64 = __webpack_require__(6718); +// EXTERNAL MODULE: ./components/general/GeneralPopup.jsx +var GeneralPopup = __webpack_require__(5472); +// EXTERNAL MODULE: ./components/general/ui/ButtonGroup.jsx +var ButtonGroup = __webpack_require__(5449); +;// CONCATENATED MODULE: ./components/admin/databases/UserImage.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} [props.user] + * @param {string | null | import("@/package-shared/types").ImageObjectType} props.image + * @param {React.Dispatch<React.SetStateAction<string | null | import("@/package-shared/types").ImageObjectType>>} props.setImage + */ function UserImage({ user , image , setImage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const imagePreviewRef = external_react_default().useRef(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper w-full items-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "m-0 text-xl", + children: "User Image" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "bg-white rounded-full overflow-hidden w-24 h-24", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: image ? typeof image === "string" ? image : image.imageBase64Full : "/images/database-placeholder.png", + alt: "User Image", + width: 100, + className: "w-full h-full object-cover", + // @ts-ignore + ref: imagePreviewRef, + "data-imagepreview": "image" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col", + id: "upload-user-image-options", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)(ButtonGroup/* default */.Z, { + column: true, + className: "w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "outlined gray w-full whitespace-normal", + onClick: (e)=>{ + (0,GeneralPopup/* openPopup */.Mw)("user-media-popup"); + }, + children: "Choose image From your Uploads" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "secondary w-full whitespace-normal", + onClick: (e)=>{ + /** @type {HTMLButtonElement} */ // @ts-ignore + const buttonEl = e.target; + buttonEl.closest("#upload-user-image-options")?.querySelector("input")?.click(); + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Choose image From your Computer" + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "file", + accept: ".png,.jpg,.jpeg,.webp", + placeholder: "Choose Image", + className: "hidden", + onChange: async (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + const inputFile = inputEl?.files?.[0]; + if (inputFile) { + let imageData = await (0,imageInputFileToBase64/* default */.Z)({ + imageInputFile: inputFile, + maxWidth: 400 + }); + setImage(imageData); + } + } + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/settings/SettingsContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SettingsContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , image , setImage , activeUser } = external_react_default().useContext(SettingsContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [delLoading, setDelLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex items-center justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Settings" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: !user?.social_login && /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/send-password-reset-link", + className: "button outlined", + children: "Reset Password" + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "p-0", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full grid grid-cols-1 xl:grid-cols-2 gap-8 items-stretch", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "m-0 text-xl", + children: "Account Information" + }), + /*#__PURE__*/ jsx_runtime_.jsx(CreateAccountForm/* default */.Z, { + user: activeUser, + image: image + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "items-stretch", + children: /*#__PURE__*/ jsx_runtime_.jsx(UserImage, { + image: image, + setImage: setImage + }) + }) + ] + }) + }), + false && /*#__PURE__*/ 0 + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/admin/databases/UserMediaPopup.jsx +var UserMediaPopup = __webpack_require__(9310); +// EXTERNAL MODULE: ./package-shared/functions/backend/noDatabaseDbHandler.js +var noDatabaseDbHandler = __webpack_require__(4227); +var noDatabaseDbHandler_default = /*#__PURE__*/__webpack_require__.n(noDatabaseDbHandler); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/settings.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").SettingsPageContextType} */ // @ts-ignore +const init = {}; +const SettingsContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} [props.databases] + * @param {any} props.activeUser + */ function Settings({ user , databases , activeUser }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [image, setImage] = external_react_default().useState(activeUser.image); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(SettingsContext.Provider, { + value: { + user, + image, + setImage, + activeUser + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SettingsContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(UserMediaPopup/* default */.Z, { + setDbImage: setImage + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const databases = await noDatabaseDbHandler_default()(`SELECT SCHEMA_NAME AS dbFullName FROM INFORMATION_SCHEMA.SCHEMATA WHERE SCHEMA_NAME LIKE 'user_${user.id}%'`); + const activeUser = await DB_HANDLER_default()(`SELECT first_name,last_name,username,email,image,image_thumbnail FROM users WHERE id='${user.id}'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + databases: databases, + activeUser: activeUser[0] + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 5050: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CopyAllTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 7039: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteForeverTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 8193: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DriveFileRenameOutlineTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 4063: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StorageTwoTone"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 7849: +/***/ ((module) => { + +module.exports = require("react-dom/client"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,7023,7901,6718,9594,9471,7037,9967,7946,1500,75,9282,8374,7926,5114], () => (__webpack_exec__(1481))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js.nft.json new file mode 100644 index 0000000..44c320e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/settings.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../chunks/7023.js","../../../chunks/7901.js","../../../chunks/6718.js","../../../chunks/9594.js","../../../chunks/9471.js","../../../chunks/7037.js","../../../chunks/9967.js","../../../chunks/7946.js","../../../chunks/1500.js","../../../chunks/75.js","../../../chunks/9282.js","../../../chunks/8374.js","../../../chunks/7926.js","../../../chunks/5114.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/CopyAllTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteForeverTwoTone.js","../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../node_modules/@mui/icons-material/DriveFileRenameOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../../../node_modules/@mui/icons-material/Close.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/client.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../jsonData/dbSchemas/dataTypes.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js new file mode 100644 index 0000000..0937718 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js @@ -0,0 +1,754 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1838; +exports.ids = [1838]; +exports.modules = { + +/***/ 3931: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "UsersContext": () => (/* binding */ UsersContext), + "default": () => (/* binding */ Dashboard), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/users/TargetUserPreviewPopup.jsx +var TargetUserPreviewPopup = __webpack_require__(9417); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/users/UserListCard.jsx +var UserListCard = __webpack_require__(3863); +;// CONCATENATED MODULE: ./components/admin/users/UsersList.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>>} props.setTargetUser + * @param {import("@/package-shared/types").MYSQL_user_users_table_def[]} [props.users] + * @param {any[]} props.adminUsers + * @param {any[]} props.invitedAccounts + */ function UsersList({ user , setTargetUser , users , adminUsers , invitedAccounts , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Users List" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card no-hover items-center w-full justify-between", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-10 h-10 rounded-full overflow-hidden", + children: /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: user.image_thumbnail, + alt: "Main User Image", + width: 40, + className: "w-full h-full object-cover" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "font-semibold", + children: [ + user.first_name, + " ", + user.last_name + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm font-semibold", + children: "Super User (Owner)" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col items-stretch", + children: [ + invitedAccounts && invitedAccounts[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h4", { + className: "m-0 text-sm font-semibold text-slate-400", + children: "Accounts that Invited you" + }), + invitedAccounts.map((userObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(UserListCard/* default */.Z, { + userObject: userObject, + setTargetUser: setTargetUser, + paradigm: "invited" + }, index + 1); + }) + ] + }), + adminUsers && adminUsers[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h4", { + className: "m-0 text-sm font-semibold text-slate-400", + children: "Accounts you Invited" + }), + adminUsers.map((userObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(UserListCard/* default */.Z, { + userObject: userObject, + setTargetUser: setTargetUser + }, index + 1); + }) + ] + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: ./components/admin/users/InvitationReceivedCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.invitationObject + */ function InvitationReceivedCard({ invitationObject }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "bg-slate-100 px-4 py-2 rounded w-full justify-between relative", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-sm font-semibold", + children: [ + invitationObject.first_name, + " ", + invitationObject.last_name, + " (", + invitationObject.email, + ")" + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "py-1.5 px-3 text-sm secondary", + onClick: (e)=>{ + setLoading(true); + (0,fetchApi/* default */.Z)("/api/acceptUserInvitation", { + method: "post", + body: { + ...invitationObject + } + }, true).then((res)=>{ + if (res.success) { + window.alert("Invitation Accepted!"); + window.location.reload(); + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + }, + children: "Accept Invitation" + }) + ] + }, invitationObject.id); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/admin/users/UsersContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function UsersContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { user , databases , pendingInvitations , pendingInvitationsReceived , adminUsers , invitedAccounts , setTargetUser , } = external_react_default().useContext(UsersContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "Users" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/add-user`, + className: "flex items-center gap-2 whitespace-normal button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New User" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full grid grid-cols-1 items-start justify-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-stretch justify-start", + children: /*#__PURE__*/ jsx_runtime_.jsx(UsersList, { + setTargetUser: setTargetUser, + user: user, + adminUsers: adminUsers, + invitedAccounts: invitedAccounts + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-stretch justify-start", + children: [ + pendingInvitations && pendingInvitations[0] && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "p-4 items-start gap-4 overflow-visible", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Invitations Sent" + }), + pendingInvitations.map((invitationObject, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "bg-slate-100 px-4 py-2 rounded w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm font-semibold", + children: invitationObject.invited_user_email + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-slate-400", + children: "Pending" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-sm text-orange-600 hover:opacity-50 cursor-pointer", + onClick: (e)=>{ + if (window.confirm("Delete this invitation?")) { + (0,fetchApi/* default */.Z)("/api/deleteInvitation", { + method: "POST", + body: { + id: invitationObject.id + } + }, true).finally(()=>{ + window.location.reload(); + }); + } + }, + children: "Delete Invitation" + }) + ] + }) + ] + }, invitationObject.id); + }) + ] + }) + }) + }), + pendingInvitationsReceived && pendingInvitationsReceived[0] && /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "p-4 items-start gap-4 overflow-visible", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Pending Invitations Received" + }), + pendingInvitationsReceived.map((invitationObject, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(InvitationReceivedCard, { + invitationObject: invitationObject + }, index + 1); + }) + ] + }) + }) + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/users/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AllUserUsersContextType} */ // @ts-ignore +const init = {}; +const UsersContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").MYSQL_delegated_users_table_def[]} props.users + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases + * @param {import("@/package-shared/types").MYSQL_invitations_table_def[]} props.pendingInvitations + * @param {any[]} props.pendingInvitationsReceived + * @param {any[]} props.adminUsers + * @param {any[]} props.invitedAccounts + */ function Dashboard({ user , users , databases , pendingInvitations , pendingInvitationsReceived , adminUsers , invitedAccounts , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Users | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [newUser, setNewUser] = external_react_default().useState(null); + /** @type {[ targetUser: import("@/package-shared/types").MYSQL_user_users_table_def | null, setTargetUser: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>> ]} */ // @ts-ignore + const [targetUser, setTargetUser] = external_react_default().useState(null); + /** @type {[ media: any, setTargetMedia: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + const [media, setTargetMedia] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(UsersContext.Provider, { + value: { + user, + users, + targetUser, + setTargetUser, + databases, + pendingInvitations, + pendingInvitationsReceived, + adminUsers, + invitedAccounts + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(UsersContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TargetUserPreviewPopup/* default */.Z, { + targetUser: targetUser, + user: user, + setTargetUser: setTargetUser + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await DB_HANDLER_default()(`SELECT * FROM delegated_users WHERE user_id='${user.id}'`); + const databases = await DB_HANDLER_default()(`SELECT db_name,db_slug,db_image FROM user_databases WHERE user_id='${user.id}'`); + const pendingInvitations = await DB_HANDLER_default()(`SELECT * FROM invitations WHERE inviting_user_id='${user.id}' AND invitation_status='Pending'`); + const pendingInvitationsReceived = await DB_HANDLER_default()(`SELECT invitations.*,users.first_name,users.last_name,users.email FROM invitations JOIN users ON users.id=invitations.inviting_user_id WHERE invited_user_email='${user.email}' AND invitation_status='Pending'`); + const adminUsers = await DB_HANDLER_default()(`SELECT * FROM user_users WHERE user_id='${user.id}' AND user_type='admin'`); + const invitedAccounts = await DB_HANDLER_default()(`SELECT user_users.*,users.first_name AS inviteeFirstName,users.last_name AS inviteeLastName,users.email AS inviteeEmail, users.image_thumbnail AS inviteeImage FROM user_users JOIN users ON users.id=user_users.user_id WHERE user_users.email='${user.email}' AND user_users.user_type='admin'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + users: users, + databases: databases, + pendingInvitations, + pendingInvitationsReceived, + adminUsers, + invitedAccounts + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,4114,9486,9417,3863], () => (__webpack_exec__(3931))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js.nft.json new file mode 100644 index 0000000..82ba053 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/913.js","../../../chunks/9395.js","../../../chunks/370.js","../../../chunks/424.js","../../../chunks/4858.js","../../../chunks/5472.js","../../../chunks/4114.js","../../../chunks/9486.js","../../../chunks/9417.js","../../../chunks/3863.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../jsonData/userPriviledges.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js new file mode 100644 index 0000000..a089295 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js @@ -0,0 +1,746 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3869; +exports.ids = [3869]; +exports.modules = { + +/***/ 421: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AddNewUserContext": () => (/* binding */ AddNewUserContext), + "default": () => (/* binding */ AddUserPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/form/FormCheckboxes.jsx +var FormCheckboxes = __webpack_require__(9486); +;// CONCATENATED MODULE: ./components/admin/users/AddNewUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {any} */ let timeout; +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AddNewUserContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , user , query } = external_react_default().useContext(AddNewUserContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userPriviledges = __webpack_require__(9169); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [paradigm, setParadigm] = external_react_default().useState("invitation"); + const [loading, setLoading] = external_react_default().useState(false); + const [allDbSelected, setAllDbSelected] = external_react_default().useState(false); + const [priviledges, setPriviledges] = external_react_default().useState([ + "Update Entries", + "Delete Entries", + ]); + /** @type {[ databasesAccess: string[], setDatabasesAccess: React.Dispatch<React.SetStateAction<string[]>> ]} */ // @ts-ignore + const [databasesAccess, setDatabasesAccess] = external_react_default().useState([]); + const [targetDb, setTargetDb] = external_react_default().useState(databases && databases[0] ? databases[0].db_slug : null); + /** @type {[ selectedDbTables: string | null, setSelectedDbTables: React.Dispatch<React.SetStateAction<string | null>> ]} */ // @ts-ignore + const [alert, setAlert] = external_react_default().useState(null); + /** @type {[ userImage: import("@/package-shared/types").ImageObjectType, setUserImage: React.Dispatch<React.SetStateAction<import("@/package-shared/types").ImageObjectType>> ]} */ // @ts-ignore + const [userImage, setUserImage] = external_react_default().useState(null); + /** @type {[ dbTables: import("@/package-shared/types").MYSQL_user_database_tables_table_def[] | null, setDbTables: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_database_tables_table_def[] | null>> ]} */ // @ts-ignore + const [dbTables, setDbTables] = external_react_default().useState([]); + /** @type {[ selectedDbTables: string[], setSelectedDbTables: React.Dispatch<React.SetStateAction<string[]>> ]} */ // @ts-ignore + const [selectedDbTables, setSelectedDbTables] = external_react_default().useState([]); + external_react_default().useEffect(()=>{ + if (!targetDb) return; + (0,fetchApi/* default */.Z)(`/api/getDatabaseTables?dbSlug=${targetDb}&dbOwnerId=${user.id}`).then((res)=>{ + if (res.success) { + setDbTables(null); + setTimeout(()=>{ + setDbTables([ + ...res.tables + ]); + }, 200); + } + }); + }, [ + targetDb + ]); + external_react_default().useEffect(()=>{ + setTargetDb(databasesAccess[0]); + }, [ + databasesAccess + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full justify-between flex-wrap", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + "Add A New User", + paradigm?.match(/database/) && targetDb ? ` To ${targetDb}` : "" + ] + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "p-4 items-start gap-4 overflow-visible", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const form = e.target; + const formFields = Array.from(form); + /** @type {any} */ const formFieldsObject = {}; + formFields.forEach((/** @type {any} */ field)=>{ + if (field.nodeName?.match(/button/i)) return; + if (!field.name || !field.value?.match(/./)) return; + formFieldsObject[field.name] = field.value; + }); + const fetchObject = { + ...formFieldsObject, + db_tables: databasesAccess && databasesAccess[0] ? selectedDbTables.join("|") : "", + paradigm + }; + if (paradigm.match(/database/i)) { + fetchObject["database"] = targetDb; + } else { + fetchObject["database_access"] = databasesAccess.join("|"); + fetchObject["priviledge"] = priviledges.join("|"); + } + (0,fetchApi/* default */.Z)("/api/addUserUser", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (res.success) { + if (userImage) { + userImage["imageName"] = `${targetDb}-user-${res.newUserId}`; + userImage["mimeType"] = "jpeg"; + delete userImage["imageBase64Full"]; + (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + userImage + ], + folder: targetDb?.replace(/_/g, "-"), + type: "image" + } + }, true).then((_res)=>{ + (0,fetchApi/* default */.Z)("/api/updateUserUser", { + method: "post", + body: { + id: res.newUserId, + user_type: paradigm, + image: _res.mediaData[0].media_url, + image_thumbnail: _res.mediaData[0].media_thumbnail_url + } + }, true).then((__res)=>{ + if (__res.success) { + if (paradigm?.match(/database/)) { + window.location.pathname = `/admin/${user?.id}/users/databases/${targetDb}`; + } else { + window.location.pathname = `/admin/${user?.id}/users`; + } + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + }); + } else { + if (paradigm?.match(/database/)) { + window.location.pathname = `/admin/${user?.id}/users/databases/${targetDb}`; + } else { + window.location.pathname = `/admin/${user?.id}/users`; + } + } + } else { + setTimeout(()=>{ + setLoading(false); + }, 500); + } + }); + }, + className: "w-full flex flex-col items-stretch gap-4", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600 mt-4", + children: "User Email Address" + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "email", + name: "email_address", + id: "email_address", + placeholder: "Email Address", + autoComplete: "email", + required: true, + onInput: (e)=>{ + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + if (inputEl.value.match(/./)) { + inputEl.classList.remove("warning"); + setAlert(null); + } else { + inputEl.classList.add("warning"); + } + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + (0,fetchApi/* default */.Z)(`/api/checkDuplicateData?type=email&value=${inputEl.value}&tableName=user_users&userId=${user.id}&userType=invitation`).then((res)=>{ + if (res?.result) { + setAlert("Email Already Exists"); + inputEl.classList.add("warning"); + } else { + setAlert(null); + inputEl.classList.remove("warning"); + } + }); + }, 300); + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600 mt-4", + children: "User Priviledges" + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + checkBoxValues: userPriviledges.map((userPriviledge)=>{ + return { + title: userPriviledge, + name: userPriviledge, + default: userPriviledge.match(/entries/i) ? true : false, + onChangeHandler: (e)=>{ + if (priviledges.includes(userPriviledge)) { + let newArray = priviledges.filter((priv)=>priv != userPriviledge); + setPriviledges([ + ...newArray + ]); + } else { + setPriviledges((prev)=>[ + ...prev, + userPriviledge, + ]); + } + } + }; + }), + smallText: true, + flexRow: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600 mt-4", + children: "Databases Access" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "button outlined gray px-4 py-1 -mt-2", + onClick: (e)=>{ + if (allDbSelected) { + databases.forEach((db)=>{ + setTimeout(()=>{ + /** @type {HTMLInputElement | null} */ // @ts-ignore + const elt = document.getElementById(db.db_slug); + if (elt?.checked) elt.click(); + }, 200); + }); + setAllDbSelected(false); + } else { + databases.forEach((db)=>{ + setTimeout(()=>{ + /** @type {HTMLInputElement | null} */ // @ts-ignore + const elt = document.getElementById(db.db_slug); + if (!elt?.checked) elt?.click(); + }, 200); + }); + setAllDbSelected(true); + } + }, + children: allDbSelected ? "Deselect All" : "Select All" + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + checkBoxValues: databases.map((db)=>{ + return { + title: db.db_name, + name: db.db_slug, + onChangeHandler: (e)=>{ + if (databasesAccess.includes(db.db_slug)) { + let newArray = databasesAccess.filter((_db)=>_db != db.db_slug); + setDatabasesAccess([ + ...newArray + ]); + } else { + setDatabasesAccess((prev)=>[ + ...prev, + db.db_slug, + ]); + } + if (databasesAccess.length === databases.length) { + setAllDbSelected(true); + } else { + setAllDbSelected(false); + } + } + }; + }), + smallText: true, + flexRow: true, + name: "db-select" + }), + databasesAccess && databasesAccess[0] && /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "my-6" + }), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-2 text-slate-600", + children: "Database Tables" + }), + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + required: true, + selectOptions: databases.filter((db)=>databasesAccess.includes(db.db_slug)).map((db)=>{ + return { + title: db.db_name, + payload: db.db_slug + }; + }), + name: "databases", + onChangeHandler: (e)=>{ + setTargetDb(e.target.value); + } + }), + dbTables && dbTables[0] && /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + checkBoxValues: dbTables.map((dbTable)=>{ + return { + title: dbTable.table_name, + name: dbTable.table_slug, + onChangeHandler: (e)=>{ + if (e.target.checked) { + setSelectedDbTables((prev)=>[ + ...prev, + `${targetDb}-${dbTable.table_slug}`, + ]); + } else { + let newArray = selectedDbTables.filter((table)=>table != `${targetDb}-${dbTable.table_slug}`); + setSelectedDbTables([ + ...newArray + ]); + } + // if (selectedDbTables.includes(`${targetDb}-${dbTable.table_slug}`)) { + // let newArray = selectedDbTables.filter(table => table != `${targetDb}-${dbTable.table_slug}`); + // setSelectedDbTables([...newArray]) + // } else { + // setSelectedDbTables(prev => [...prev, `${targetDb}-${dbTable.table_slug}`]) + // } + }, + default: selectedDbTables?.includes(`${targetDb}-${dbTable.table_slug}`) ? true : false + }; + }), + smallText: true, + flexRow: true + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: paradigm?.match(/database/) ? "Add User" : "Invite User" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/users/add-user.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").AddUserContextType} */ // @ts-ignore +const init = {}; +const AddNewUserContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").MYSQL_delegated_users_table_def[]} props.users + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases + * @param {any} props.query + */ function AddUserPage({ user , users , databases , query }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Users | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [newUser, setNewUser] = external_react_default().useState(null); + const [targetUser, setTargetUser] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(AddNewUserContext.Provider, { + value: { + user, + users, + databases, + query + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(AddNewUserContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await DB_HANDLER_default()(`SELECT * FROM delegated_users WHERE user_id='${user.id}'`); + const databases = await DB_HANDLER_default()(`SELECT db_name,db_slug,db_image FROM user_databases WHERE user_id='${user.id}'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + users: users, + databases: databases, + query + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9169: +/***/ ((module) => { + +module.exports = JSON.parse('["Edit Tables","Update Entries","Create Table","Delete Entries","Delete Tables"]'); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,1781,4114,9486], () => (__webpack_exec__(421))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js.nft.json new file mode 100644 index 0000000..bdaa179 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/add-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/913.js","../../../../chunks/9395.js","../../../../chunks/370.js","../../../../chunks/424.js","../../../../chunks/4858.js","../../../../chunks/1781.js","../../../../chunks/4114.js","../../../../chunks/9486.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../jsonData/userPriviledges.json","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js new file mode 100644 index 0000000..24e3aa1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js @@ -0,0 +1,520 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9334; +exports.ids = [9334]; +exports.modules = { + +/***/ 3666: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "AllDatabasesUsersContext": () => (/* binding */ AllDatabasesUsersContext), + "default": () => (/* binding */ AllDatabasesUsersPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/users/TargetUserPreviewPopup.jsx +var TargetUserPreviewPopup = __webpack_require__(9417); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +;// CONCATENATED MODULE: ./components/admin/users/DatabaseUsers.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases + * @param {import("@/package-shared/types").UserType} props.user + */ function DatabaseUsers({ databases , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "p-4 items-start gap-4 overflow-visible", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Database Users" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex flex-wrap gap-6", + children: databases && databases[0] ? databases.map((dbObject, index)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/databases/${dbObject.db_slug}`, + className: "border border-slate-200 border-solid rounded px-6 py-4 hover:border-primary flex items-center gap-2", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: dbObject.db_image, + className: "w-8 h-8 rounded-full object-cover", + alt: "" + }), + dbObject.db_name + ] + }, index + 1); + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Databases Yet" + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +;// CONCATENATED MODULE: ./components/admin/users/AllDatabasesUsersContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function AllDatabasesUsersContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { databases , user } = external_react_default().useContext(AllDatabasesUsersContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-3xl m-0", + children: "All Databases Users" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/add-user`, + className: "flex items-center gap-2 whitespace-normal button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New User" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(DatabaseUsers, { + databases: databases, + user: user + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/users/databases/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").UserDatabasesContextType} */ // @ts-ignore +const init = {}; +const AllDatabasesUsersContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any[]} props.users + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[]} props.databases + */ function AllDatabasesUsersPage({ user , users , databases }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Users | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [newUser, setNewUser] = external_react_default().useState(null); + /** @type {[ targetUser: import("@/package-shared/types").MYSQL_user_users_table_def, setTargetUser: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>> ]} */ // @ts-ignore + const [targetUser, setTargetUser] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(AllDatabasesUsersContext.Provider, { + value: { + user, + users, + targetUser, + setTargetUser, + databases + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(AllDatabasesUsersContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TargetUserPreviewPopup/* default */.Z, { + targetUser: targetUser, + user: user, + setTargetUser: setTargetUser + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await DB_HANDLER_default()(`SELECT * FROM delegated_users WHERE user_id='${user.id}'`); + const databases = await DB_HANDLER_default()(`SELECT db_name,db_slug,db_image FROM user_databases WHERE user_id='${user.id}'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + users: users, + databases: databases + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4114,9486,9417], () => (__webpack_exec__(3666))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js.nft.json new file mode 100644 index 0000000..dd89315 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/913.js","../../../../chunks/9395.js","../../../../chunks/370.js","../../../../chunks/424.js","../../../../chunks/4858.js","../../../../chunks/5472.js","../../../../chunks/1781.js","../../../../chunks/4114.js","../../../../chunks/9486.js","../../../../chunks/9417.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../jsonData/userPriviledges.json","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js new file mode 100644 index 0000000..9a76634 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js @@ -0,0 +1,498 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1383; +exports.ids = [1383]; +exports.modules = { + +/***/ 7650: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleDatabaseUsersContext": () => (/* binding */ SingleDatabaseUsersContext), + "default": () => (/* binding */ DatabaseUsersPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/admin/users/TargetUserPreviewPopup.jsx +var TargetUserPreviewPopup = __webpack_require__(9417); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/users/UserListCard.jsx +var UserListCard = __webpack_require__(3863); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +;// CONCATENATED MODULE: ./components/admin/users/SingleDatabaseUsersContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleDatabaseUsersContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { database , users , user } = external_react_default().useContext(SingleDatabaseUsersContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + database.db_name, + " Users" + ] + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/add-user?db=${database.db_slug}`, + className: "flex items-center gap-2 whitespace-normal button", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "symbol", + children: "+" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Add New User" + }) + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "paper w-full flex-col items-stretch", + children: users && users[0] ? users.map((userObject)=>{ + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/admin/${user?.id}/users/databases/${database.db_slug}/${userObject.id}`, + className: "w-full flex items-center gap-2 p-4 border border-solid border-slate-200 rounded cursor-pointer hover:border-slate-400 flex-wrap", + onClick: (e)=>{ + // @ts-ignore + if (e.target.closest("button")) return e.preventDefault(); + // setTargetUser(userObject) + // openPopup("target-media-popup") + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: userObject.image_thumbnail, + alt: "", + className: "w-10 h-10 rounded-full object-cover bg-slate-200" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-1", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "font-bold", + children: [ + userObject.first_name, + " ", + userObject.last_name + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-xs text-slate-500", + children: userObject.date_created?.substring(0, 16) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "ml-auto outlined gray pointer-events-none", + children: "Edit User" + }) + ] + }); + }) : /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Users for this database yet" + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/users/databases/[database]/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").DelegatedDbContextType} */ // @ts-ignore +const init = {}; +const SingleDatabaseUsersContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").MYSQL_user_users_table_def[]} props.users + * @param {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type} props.database + */ function DatabaseUsersPage({ user , users , database }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${database.db_name} Users | Datasquirel"`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [newUser, setNewUser] = external_react_default().useState(null); + /** @type {[ targetUser: import("@/package-shared/types").MYSQL_user_users_table_def | null, setTargetUser: React.Dispatch<React.SetStateAction<import("@/package-shared/types").MYSQL_user_users_table_def | null>> ]} */ // @ts-ignore + const [targetUser, setTargetUser] = external_react_default().useState(null); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)(SingleDatabaseUsersContext.Provider, { + value: { + user, + users, + targetUser, + setTargetUser, + database + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SingleDatabaseUsersContent, {}), + /*#__PURE__*/ jsx_runtime_.jsx(TargetUserPreviewPopup/* default */.Z, { + targetUser: targetUser, + user: user, + setTargetUser: setTargetUser + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await DB_HANDLER_default()(`SELECT * FROM user_users WHERE user_id='${user.id}' AND \`database\`='${query.database}'`); + const database = await DB_HANDLER_default()(`SELECT db_name,db_slug,db_image FROM user_databases WHERE user_id='${user.id}' AND db_slug='${query.database}'`); + if (!database || !database[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/users`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + users: users, + database: database[0] + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4114,9486,9417,3863], () => (__webpack_exec__(7650))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js.nft.json new file mode 100644 index 0000000..6e746d2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../webpack-runtime.js","../../../../../chunks/4017.js","../../../../../chunks/8313.js","../../../../../chunks/5264.js","../../../../../chunks/6729.js","../../../../../chunks/5449.js","../../../../../chunks/5304.js","../../../../../chunks/913.js","../../../../../chunks/9395.js","../../../../../chunks/370.js","../../../../../chunks/424.js","../../../../../chunks/4858.js","../../../../../chunks/5472.js","../../../../../chunks/1781.js","../../../../../chunks/4114.js","../../../../../chunks/9486.js","../../../../../chunks/9417.js","../../../../../chunks/3863.js","../../../../../../package.json","../../../../../../../ssl/ca-cert.pem","../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../node_modules/lucide-react/package.json","../../../../../../../node_modules/@mui/material/package.json","../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../node_modules/next/head.js","../../../../../../../node_modules/next/package.json","../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../node_modules/react/package.json","../../../../../../../node_modules/react/index.js","../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../node_modules/mysql/index.js","../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../node_modules/@mui/system/package.json","../../../../../../../node_modules/@mui/system/index.js","../../../../../../../node_modules/mysql/package.json","../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../node_modules/@mui/base/package.json","../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../node_modules/prop-types/package.json","../../../../../../../node_modules/prop-types/index.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../node_modules/clsx/package.json","../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../node_modules/@mui/system/display.js","../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../node_modules/@mui/system/style.js","../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../node_modules/react-is/package.json","../../../../../../../node_modules/react-is/index.js","../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../node_modules/sqlstring/index.js","../../../../../../../node_modules/object-assign/index.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../node_modules/sqlstring/package.json","../../../../../../../node_modules/object-assign/package.json","../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../node_modules/readable-stream/package.json","../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../node_modules/string_decoder/package.json","../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../node_modules/isarray/package.json","../../../../../../../node_modules/isarray/index.js","../../../../../../../node_modules/inherits/package.json","../../../../../../../node_modules/inherits/inherits.js","../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../node_modules/core-util-is/package.json","../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../node_modules/stylis/package.json","../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../jsonData/userPriviledges.json","../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js new file mode 100644 index 0000000..5bbfe48 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js @@ -0,0 +1,647 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9268; +exports.ids = [9268]; +exports.modules = { + +/***/ 5342: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SingleDatabaseSingleUserContext": () => (/* binding */ SingleDatabaseSingleUserContext), + "default": () => (/* binding */ DatabaseSingleUserPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/AdminLayout.jsx + 2 modules +var AdminLayout = __webpack_require__(4858); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: ./components/admin/users/UserListCard.jsx +var UserListCard = __webpack_require__(3863); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +// EXTERNAL MODULE: ./components/form/FormCheckboxes.jsx +var FormCheckboxes = __webpack_require__(9486); +// EXTERNAL MODULE: ./components/admin/users/UserImage.jsx +var UserImage = __webpack_require__(2733); +;// CONCATENATED MODULE: ./components/admin/users/SingleDatabaseSingleUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SingleDatabaseSingleUserContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { singleUser , user } = external_react_default().useContext(SingleDatabaseSingleUserContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const userFields = Object.keys(singleUser).filter((key)=>!key.match(/^id$|^date_|^user_id$|^social_|^disk_usage|user_type/)); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [priviledges, setPriviledges] = external_react_default().useState(singleUser.user_type?.match(/invitation/) ? singleUser["user_priviledge"]?.split("|") : [ + "Edit" + ]); + /** @type {[ userImage: string | import("@/package-shared/types").ImageObjectType | any, setUserImage: React.Dispatch<React.SetStateAction<string | import("@/package-shared/types").ImageObjectType | any>> ]} */ // @ts-ignore + const [userImage, setUserImage] = external_react_default().useState(singleUser["image"]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start gap-0 w-full", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between flex-wrap", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + singleUser.first_name, + " ", + singleUser.last_name + ] + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + className: "bg-red-500", + onClick: (e)=>{ + setLoading(true); + if (window.confirm("Delete this user?")) { + (0,fetchApi/* default */.Z)("/api/deleteUserUser", { + method: "post", + body: { + ...singleUser + } + }, true).then((res)=>{ + if (res.success) window.location.pathname = `/admin/${user?.id}/users/databases/${singleUser.database}`; + }); + } + }, + children: "Delete User" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(Breadcrumbs/* default */.Z, { + user: user + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full flex-col items-stretch", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-col items-stretch gap-4", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const form = e.target; + const formFields = Array.from(form); + /** @type {any} */ const formFieldsObject = {}; + formFields.forEach((/** @type {any} */ field)=>{ + if (field?.nodeName?.match(/button/i)) return; + if (!field?.name || !field?.value?.match(/./)) return; + if (field?.name?.match(/username|email/)) return; + formFieldsObject[field.name] = field.value; + }); + const fetchObject = { + ...formFieldsObject, + user_type: singleUser["user_type"], + id: singleUser["id"] + }; + if (singleUser["user_type"]?.match(/invitation/i)) { + // fetchObject["database_access"] = + // databasesAccess.join("|"); + fetchObject["user_priviledge"] = priviledges?.join("|"); + } + (0,fetchApi/* default */.Z)("/api/updateUserUser", { + method: "post", + body: fetchObject + }, true).then((res)=>{ + if (userImage?.imageBase64) { + userImage["imageName"] = `${singleUser["database"]}-user-${singleUser.id}`; + userImage["mimeType"] = "jpeg"; + delete userImage["imageBase64Full"]; + (0,fetchApi/* default */.Z)("/api/addUserMedia", { + method: "post", + body: { + media: [ + userImage + ], + folder: singleUser["database"]?.replace(/_/g, "-"), + type: "image" + } + }, true).then((_res)=>{ + if (_res && _res.mediaData && _res.mediaData[0]?.media_url) { + (0,fetchApi/* default */.Z)("/api/updateUserUser", { + method: "post", + body: { + id: singleUser.id, + user_type: singleUser.user_type, + image: _res.mediaData[0].media_url, + image_thumbnail: _res.mediaData[0].media_thumbnail_url + } + }, true).then((__res)=>{ + if (__res.success) window.location.reload(); + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + } else { + window.location.reload(); + } + }); + } else { + window.location.reload(); + } + }); + }, + children: [ + userFields.map((field, index)=>{ + if (field?.match(/user_priviledge/) && singleUser.user_type?.match(/invitation/)) { + return /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-start w-full gap-1", + children: /*#__PURE__*/ jsx_runtime_.jsx(FormCheckboxes/* default */.Z, { + // @ts-ignore + checkBoxValues: singleUser[field]?.split("|").map((/** @type {string} */ priv)=>{ + return { + title: priv, + name: priv, + onChangeHandler: (/** @type {any} */ e)=>{ + if (priviledges?.includes("Edit")) { + let newArray = priviledges.filter((_db)=>_db != "Edit"); + setPriviledges([ + ...newArray, + ]); + } else { + setPriviledges((prev)=>prev ? [ + ...prev, + "Edit", + ] : []); + } + } + }; + }), + smallText: true, + flexRow: true + }) + }, index + 1); + } else if (field?.match(/user_priviledge/) && !singleUser.user_type?.match(/invitation/)) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, {}, index + 1); + } + if (field?.match(/password|^database|email|username/)) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: field, + id: field, + value: // @ts-ignore + singleUser[field], + placeholder: field, + className: "opacity-40 pointer-events-none", + onChange: (e)=>{ + e.preventDefault(); + } + }, index + 1) + ] + }, index + 1); + } + if (field?.match(/more_user_data/)) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("textarea", { + name: field, + id: field, + defaultValue: // @ts-ignore + singleUser[field] ? singleUser[field] : undefined, + placeholder: field, + rows: 6 + }, index + 1) + ] + }, index + 1); + } + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start w-full gap-1", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("label", { + htmlFor: field, + children: field + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: field, + id: field, + defaultValue: // @ts-ignore + singleUser[field] ? singleUser[field] : undefined, + placeholder: field + }, index + 1) + ] + }, index + 1); + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "border border-slate-300 dark:border-slate-600 border-solid bg-slate-100 dark:bg-slate-700 rounded p-6 flex-col items-start w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold mb-1 text-slate-600", + children: "Update Image" + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserImage/* default */.Z, { + userImage: userImage, + setUserImage: setUserImage + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: "Update User" + }) + ] + }) + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/admin/[user_id]/users/databases/[database]/[user].jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").SingleUserUserContextType} */ // @ts-ignore +const init = {}; +const SingleDatabaseSingleUserContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {import("@/package-shared/types").MYSQL_user_users_table_def} props.singleUser + */ function DatabaseSingleUserPage({ user , singleUser }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${singleUser.first_name} ${singleUser.last_name} Users | Datasquirel"`; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(AdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SingleDatabaseSingleUserContext.Provider, { + value: { + user, + singleUser + }, + children: /*#__PURE__*/ jsx_runtime_.jsx(SingleDatabaseSingleUserContent, {}) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (!user?.logged_in_status) { + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const singleUser = await DB_HANDLER_default()(`SELECT id,\`database\`,database_access,first_name,last_name,email,phone,user_type,user_priviledge,username,image,image_thumbnail,city,state,country,zip_code,verification_status,more_user_data FROM user_users WHERE user_id='${user.id}' AND \`database\`='${query.database}' AND id='${query.user}'`); + if (!singleUser || !singleUser[0]) { + return { + redirect: { + destination: `/admin/${user?.id}/users/databases/${query.database}`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + singleUser: singleUser[0] + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4003: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdminPanelSettingsTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 69: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudOffTwoTone"); + +/***/ }), + +/***/ 4008: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CloudQueueRounded"); + +/***/ }), + +/***/ 7306: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CollectionsTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 8979: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DynamicFormTwoTone"); + +/***/ }), + +/***/ 300: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LanguageOutlined"); + +/***/ }), + +/***/ 2814: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9806: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleOutlineTwoTone"); + +/***/ }), + +/***/ 36: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/RefreshRounded"); + +/***/ }), + +/***/ 1799: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SchemaTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,424,4858,5472,1781,4114,6718,9486,2733,3863], () => (__webpack_exec__(5342))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js.nft.json b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js.nft.json new file mode 100644 index 0000000..f6f58b7 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/admin/[user_id]/users/databases/[database]/[user].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../../../webpack-runtime.js","../../../../../../chunks/4017.js","../../../../../../chunks/8313.js","../../../../../../chunks/5264.js","../../../../../../chunks/6729.js","../../../../../../chunks/5449.js","../../../../../../chunks/5304.js","../../../../../../chunks/913.js","../../../../../../chunks/9395.js","../../../../../../chunks/370.js","../../../../../../chunks/424.js","../../../../../../chunks/4858.js","../../../../../../chunks/5472.js","../../../../../../chunks/1781.js","../../../../../../chunks/4114.js","../../../../../../chunks/6718.js","../../../../../../chunks/9486.js","../../../../../../chunks/2733.js","../../../../../../chunks/3863.js","../../../../../../../package.json","../../../../../../../../ssl/ca-cert.pem","../../../../../../../../node_modules/serverless-mysql/package.json","../../../../../../../../node_modules/lucide-react/package.json","../../../../../../../../node_modules/@mui/material/package.json","../../../../../../../../node_modules/serverless-mysql/index.js","../../../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../../../node_modules/next/head.js","../../../../../../../../node_modules/next/package.json","../../../../../../../../node_modules/@mui/icons-material/AdminPanelSettingsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudOffTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/CloudQueueRounded.js","../../../../../../../../node_modules/@mui/icons-material/CollectionsTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/LanguageOutlined.js","../../../../../../../../node_modules/@mui/icons-material/LockTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/PeopleOutlineTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/RefreshRounded.js","../../../../../../../../node_modules/@mui/icons-material/SchemaTwoTone.js","../../../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../../../node_modules/react/package.json","../../../../../../../../node_modules/react/index.js","../../../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../../../node_modules/react/jsx-runtime.js","../../../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../../../node_modules/react/cjs/react.development.js","../../../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../../../node_modules/@swc/helpers/package.json","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../../../node_modules/mysql/index.js","../../../../../../../../node_modules/@babel/runtime/package.json","../../../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../../../node_modules/@mui/system/package.json","../../../../../../../../node_modules/@mui/system/index.js","../../../../../../../../node_modules/mysql/package.json","../../../../../../../../node_modules/@mui/utils/package.json","../../../../../../../../node_modules/@mui/utils/index.js","../../../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../../../node_modules/@mui/base/package.json","../../../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../../../node_modules/prop-types/package.json","../../../../../../../../node_modules/prop-types/index.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../../../node_modules/clsx/package.json","../../../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../../../node_modules/@mui/system/borders.js","../../../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../../../node_modules/@mui/system/compose.js","../../../../../../../../node_modules/@mui/system/display.js","../../../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../../../node_modules/@mui/system/palette.js","../../../../../../../../node_modules/@mui/system/positions.js","../../../../../../../../node_modules/@mui/system/sizing.js","../../../../../../../../node_modules/@mui/system/spacing.js","../../../../../../../../node_modules/@mui/system/shadows.js","../../../../../../../../node_modules/@mui/system/style.js","../../../../../../../../node_modules/@mui/system/typography.js","../../../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../../../node_modules/@mui/system/createBox.js","../../../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../../../node_modules/@mui/system/styled.js","../../../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../../../node_modules/@mui/utils/refType.js","../../../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../../../node_modules/@mui/system/merge.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../../../node_modules/@mui/system/memoize.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../../../node_modules/react-is/package.json","../../../../../../../../node_modules/react-is/index.js","../../../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../../../node_modules/prop-types/lib/has.js","../../../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../../../node_modules/sqlstring/index.js","../../../../../../../../node_modules/object-assign/index.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../../../node_modules/sqlstring/package.json","../../../../../../../../node_modules/object-assign/package.json","../../../../../../../../node_modules/@emotion/styled/package.json","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../../../node_modules/@emotion/react/package.json","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../../../node_modules/readable-stream/package.json","../../../../../../../../node_modules/readable-stream/readable.js","../../../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../../../node_modules/@emotion/cache/package.json","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../../../node_modules/@emotion/utils/package.json","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/string_decoder/package.json","../../../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../../../node_modules/process-nextick-args/package.json","../../../../../../../../node_modules/process-nextick-args/index.js","../../../../../../../../node_modules/isarray/package.json","../../../../../../../../node_modules/isarray/index.js","../../../../../../../../node_modules/inherits/package.json","../../../../../../../../node_modules/inherits/inherits.js","../../../../../../../../node_modules/util-deprecate/package.json","../../../../../../../../node_modules/util-deprecate/node.js","../../../../../../../../node_modules/core-util-is/package.json","../../../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../../../node_modules/stylis/package.json","../../../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../../../node_modules/@emotion/hash/package.json","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js b/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js new file mode 100644 index 0000000..a6f53bc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js @@ -0,0 +1,222 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9361; +exports.ids = [9361]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6765: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ // const { id, inviting_user_id, invited_user_email, invitation_status, database_access, priviledge } = req.body; + const sanitizedReqBody = lodash__WEBPACK_IMPORTED_MODULE_2___default().cloneDeep(req.body); + const inviting_user_id = sanitizedReqBody.inviting_user_id; + const invited_user_email = sanitizedReqBody.invited_user_email; + const database_access = sanitizedReqBody.database_access; + const priviledge = sanitizedReqBody.priviledge; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const existingUserUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT email FROM user_users WHERE user_id=? AND invited_user_id=? AND user_type='admin' AND email=?`, [ + inviting_user_id, + user.id, + user.email + ]); + if (existingUserUser && existingUserUser[0]) { + return res.json({ + success: false + }); + } + /** @type {any} */ const newUserUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_4___default()({ + dbFullName: "datasquirel", + tableName: "user_users", + data: { + user_id: inviting_user_id, + invited_user_id: user.id, + database_access: database_access, + user_priviledge: priviledge, + user_type: "admin", + first_name: user.first_name, + last_name: user.last_name, + email: user.email, + username: user.first_name, + image: user.image, + image_thumbnail: user.image_thumbnail + } + }); + const inviteAccepted = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`UPDATE invitations SET invitation_status='Accepted' WHERE inviting_user_id=? AND invited_user_email=?`, [ + inviting_user_id, + invited_user_email + ]); + const dbTableData = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT db_tables_data FROM invitations WHERE inviting_user_id=?`, [ + inviting_user_id + ]); + // const dbTableData = await DB_HANDLER(`SELECT db_tables_data FROM invitations WHERE inviting_user_id='${inviting_user_id}' AND invited_user_email='${invited_user_email}'`); + const clearEntries = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`DELETE FROM delegated_user_tables WHERE root_user_id='${inviting_user_id}' AND delegated_user_id='${user.id}'`); + if (dbTableData && dbTableData[0]) { + const dbTableEntries = dbTableData[0].db_tables_data.split("|"); + for(let i = 0; i < dbTableEntries.length; i++){ + const dbTableEntry = dbTableEntries[i]; + const dbTableEntryArray = dbTableEntry.split("-"); + const [db_slug, table_slug] = dbTableEntryArray; + const newEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_4___default()({ + dbFullName: "datasquirel", + tableName: "delegated_user_tables", + data: { + delegated_user_id: user.id, + root_user_id: inviting_user_id, + database: db_slug, + table: table_slug, + priviledge: priviledge + } + }); + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: newUserUser?.insertId ? true : false + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/acceptUserInvitation/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338], () => (__webpack_exec__(6765))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js.nft.json b/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js.nft.json new file mode 100644 index 0000000..e30f6c4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/acceptUserInvitation.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js b/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js new file mode 100644 index 0000000..8469419 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js @@ -0,0 +1,144 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3488; +exports.ids = [3488]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3278: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(613); +/* harmony import */ var _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ console.log("Invitation Received by current logged in user, Loggin in VIA API ..."); + const acceptInvitation = await _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1___default()({ + // @ts-ignore + query: req.body.query, + user + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + result: acceptInvitation + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,613], () => (__webpack_exec__(3278))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js.nft.json new file mode 100644 index 0000000..3fae66a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addAdminUserUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/613.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/datasquirel/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/datasquirel/utils/get.js","../../../../node_modules/datasquirel/utils/post.js","../../../../node_modules/datasquirel/utils/upload-image.js","../../../../node_modules/datasquirel/utils/get-schema.js","../../../../node_modules/datasquirel/utils/delete-file.js","../../../../node_modules/datasquirel/utils/upload-file.js","../../../../node_modules/datasquirel/users/add-user.js","../../../../node_modules/datasquirel/users/update-user.js","../../../../node_modules/datasquirel/users/login-user.js","../../../../node_modules/datasquirel/users/send-email-code.js","../../../../node_modules/datasquirel/users/logout-user.js","../../../../node_modules/datasquirel/users/user-auth.js","../../../../node_modules/datasquirel/users/reauth-user.js","../../../../node_modules/datasquirel/users/get-user.js","../../../../node_modules/datasquirel/users/get-token.js","../../../../node_modules/datasquirel/users/validate-token.js","../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../node_modules/datasquirel/functions/decrypt.js","../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/datasquirel/functions/encrypt.js","../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../node_modules/datasquirel/engine/query/post.js","../../../../node_modules/datasquirel/engine/query/get.js","../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addApiKey.js b/dsql-app/.local_dist/server/pages/api/addApiKey.js new file mode 100644 index 0000000..254c84c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addApiKey.js @@ -0,0 +1,239 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1600; +exports.ids = [1600]; +exports.modules = { + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5241: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); +const generator = __webpack_require__(3785); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ /** @type {import("@/package-shared/types").AddApiKeyRequestBody} */ const reqBody = req.body; + const { api_key_name , api_key_slug , api_key_scope , target_database , target_table , } = reqBody; + /** + * Input Validation + * + * @description Input Validation + */ if (!api_key_name?.match(/./) || !api_key_slug?.match(/./) || !api_key_scope?.match(/./)) { + return res.json({ + success: false, + msg: "Wrong Input" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + const allowedKeysPath = process.env.DSQL_API_KEYS_PATH; + if (!allowedKeysPath) throw new Error("process.env.DSQL_API_KEYS_PATH variable not found"); + if (!fs.existsSync(allowedKeysPath)) { + fs.mkdirSync(allowedKeysPath, { + recursive: true + }); + } + let sign = generator.generate({ + length: 24, + numbers: true, + uppercase: true, + lowercase: true, + symbols: "-" + }) + "-" + Date.now(); + /** @type {import("@/package-shared/types").ApiKeyObject} */ let payload = { + user_id: user.id, + date_code: Date.now(), + sign, + target_database, + target_table + }; + if (api_key_scope == "fullAccess") { + const extraPayload = { + full_access: true + }; + payload = { + ...payload, + ...extraPayload + }; + } + const apiKey = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default()(JSON.stringify(payload)); + if (!apiKey) return res.json({ + success: false, + msg: "Couldn't encrypt API key" + }); + const encryptedApiKey = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default()(apiKey); + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ /** @type {any} */ let dbEntryObject = { + dbFullName: "datasquirel", + tableName: "api_keys", + data: { + user_id: user.id, + name: api_key_name, + slug: api_key_slug, + key: encryptedApiKey, + scope: api_key_scope + } + }; + if (sign) dbEntryObject.data.csrf = sign; + let newApiKey = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()(dbEntryObject); + if (!newApiKey.insertId) { + throw new Error("Api Key Couldn't be added"); + } + fs.writeFileSync(`${allowedKeysPath}/${sign}`, JSON.stringify(payload), "utf-8"); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/addApiKey/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338], () => (__webpack_exec__(5241))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addApiKey.js.nft.json b/dsql-app/.local_dist/server/pages/api/addApiKey.js.nft.json new file mode 100644 index 0000000..f7b6ae5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addApiKey.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/generate-password/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/generate-password/main.js","../../../../node_modules/generate-password/src/generate.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addDbUser.js b/dsql-app/.local_dist/server/pages/api/addDbUser.js new file mode 100644 index 0000000..09890a3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addDbUser.js @@ -0,0 +1,171 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8066; +exports.ids = [8066]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5078: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { payload , dbFullName , dbId } = sanitizedReqBody; + /** + * Input Validation + * + * @description Input Validation + */ const newUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: "users", + data: (()=>{ + const reqBodyKeys = Object.keys(payload); + /** @type {any} */ let finalData = {}; + reqBodyKeys.forEach((key)=>{ + if (key?.match(/paradigm|priviledge|database_access|databases|confirm/)) return; + finalData[key] = payload[key]; + }); + finalData["password"] = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: payload.password + }); + finalData["email"] = payload.email_address; + finalData["image"] = "/images/user_images/user-preset.png"; + finalData["image_thumbnail"] = "/images/user_images/user-preset-thumbnail.png"; + delete finalData["email_address"]; + return finalData; + })() + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: newUser?.insertId ? true : false, + msg: "New User User Added", + newUserId: newUser.insertId + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,7547,5886,5338], () => (__webpack_exec__(5078))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addDbUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/addDbUser.js.nft.json new file mode 100644 index 0000000..9879dbb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addDbUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js b/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js new file mode 100644 index 0000000..2a4ea64 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js @@ -0,0 +1,312 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8336; +exports.ids = [8336]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2250: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const _ = __webpack_require__(6517); +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * Sanitize SQL function + * ============================================================================== + * @description this function takes in a text(or number) and returns a sanitized + * text, usually without spaces + * + * @param {any} text - Text or number or object + * @param {boolean} [spaces] - Allow spaces + * @param {RegExp?} [regex] - Regular expression, removes any match + * + * @returns {any} + */ function sanitizeSql(text, spaces, regex) { + /** + * Initial Checks + * + * @description Initial Checks + */ if (!text) return ""; + if (typeof text == "number" || typeof text == "boolean") return text; + if (typeof text == "string" && !text?.toString()?.match(/./)) return ""; + if (typeof text == "object" && !Array.isArray(text)) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const newObject = sanitizeObjects(text, spaces); + return newObject; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else if (typeof text == "object" && Array.isArray(text)) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const newArray = sanitizeArrays(text, spaces); + return newArray; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } + // if (text?.toString()?.match(/\'|\"/)) { + // console.log("TEXT containing commas =>", text); + // return ""; + // } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Declare variables + * + * @description Declare "results" variable + */ let finalText = text; + if (regex) { + finalText = text.toString().replace(regex, ""); + } + if (spaces) {} else { + finalText = text.toString().replace(/\n|\r|\n\r|\r\n/g, "").replace(/ /g, ""); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const escapeRegex = /select |insert |drop |delete |alter |create |exec | union | or | like | concat|LOAD_FILE|ASCII| COLLATE | HAVING | information_schema|DECLARE |\#|WAITFOR |delay |BENCHMARK |\/\*.*\*\//gi; + finalText = finalText.replace(/(?<!\\)\'/g, "\\'").replace(/(?<!\\)\`/g, "\\`")// .replace(/(?<!\\)\"/g, '\\"') + .replace(/\/\*\*\//g, "").replace(escapeRegex, "\\$&"); + // const injectionRegexp = /select .* from|\*|delete from|drop database|drop table|update .* set/i; + // if (text?.toString()?.match(injectionRegexp)) { + // console.log("ATTEMPTED INJECTION =>", text); + // return ""; + // } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return finalText; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * Sanitize Objects Function + * ============================================================================== + * @description Sanitize objects in the form { key: "value" } + * + * @param {any} object - Database Full Name + * @param {boolean} [spaces] - Allow spaces + * + * @returns {object} + */ function sanitizeObjects(object, spaces) { + /** @type {any} */ let objectUpdated = { + ...object + }; + const keys = Object.keys(objectUpdated); + keys.forEach((key)=>{ + const value = objectUpdated[key]; + if (!value) { + delete objectUpdated[key]; + return; + } + if (typeof value == "string" || typeof value == "number") { + objectUpdated[key] = sanitizeSql(value, spaces); + } else if (typeof value == "object" && !Array.isArray(value)) { + objectUpdated[key] = sanitizeObjects(value, spaces); + } else if (typeof value == "object" && Array.isArray(value)) { + objectUpdated[key] = sanitizeArrays(value, spaces); + } + }); + return objectUpdated; +} +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * Sanitize Objects Function + * ============================================================================== + * @description Sanitize objects in the form { key: "value" } + * + * @param {any[]} array - Database Full Name + * @param {boolean} [spaces] - Allow spaces + * + * @returns {string[]|number[]|object[]} + */ function sanitizeArrays(array, spaces) { + let arrayUpdated = _.cloneDeep(array); + arrayUpdated.forEach((item, index)=>{ + const value = item; + if (!value) { + arrayUpdated.splice(index, 1); + return; + } + if (typeof item == "string" || typeof item == "number") { + arrayUpdated[index] = sanitizeSql(value, spaces); + } else if (typeof item == "object" && !Array.isArray(value)) { + arrayUpdated[index] = sanitizeObjects(value, spaces); + } else if (typeof item == "object" && Array.isArray(value)) { + arrayUpdated[index] = sanitizeArrays(item, spaces); + } + }); + return arrayUpdated; +} +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +module.exports = sanitizeSql; + + +/***/ }), + +/***/ 4373: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_sanitizeSql__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2250); +/* harmony import */ var _package_shared_functions_backend_db_sanitizeSql__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_sanitizeSql__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = _package_shared_functions_backend_db_sanitizeSql__WEBPACK_IMPORTED_MODULE_2___default()(req.body); + const { name } = sanitizedReqBody; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return res.json({ + success: false, + msg: "No Static File Path" + }); + } + const folderPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(STATIC_ROOT, `images/user-images/user-${user.id}/`); + const newFolderPath = folderPath + name; + const doesFolderExist = fs.existsSync(newFolderPath); + if (doesFolderExist) return res.json({ + success: false + }); + fs.mkdirSync(newFolderPath); + /** + * Send Response + * + * @description Send a boolean response + */ res.json({ + success: true + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(4373))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js.nft.json b/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js.nft.json new file mode 100644 index 0000000..d316354 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addNewMediaFolder.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addSocialLogin.js b/dsql-app/.local_dist/server/pages/api/addSocialLogin.js new file mode 100644 index 0000000..8a20c83 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addSocialLogin.js @@ -0,0 +1,225 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5012; +exports.ids = [5012]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1541: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ // import { get, set } from "lodash"; +// const rateLimit = 10; // Number of allowed requests per minute +// const rateLimiter = {}; +// const rateLimiterMiddleware = (ip) => { +// const now = Date.now(); +// const windowStart = now - 60 * 1000; // 1 minute ago +// const requestTimestamps = get(rateLimiter, ip, []).filter((timestamp) => timestamp > windowStart); +// requestTimestamps.push(now); +// set(rateLimiter, ip, requestTimestamps); +// return requestTimestamps.length <= rateLimit; +// }; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ // const ip = req.headers["x-real-ip"] || req.connection.remoteAddress; + // if (!rateLimiterMiddleware(ip)) { + // // res.status(429).json({ message: "Too Many Requests" }); + // return res.status(429).json({ msg: "Too Many Requests" }); + // } + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbFullName , dbSlug , paradigm , platforms } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userEnvFilePath = `./jsonData/dbSchemas/users/user-${user.id}/env.json`; + if (!fs.existsSync(userEnvFilePath)) { + fs.writeFileSync(userEnvFilePath, "{}", "utf8"); + } + const envObject = JSON.parse(fs.readFileSync(userEnvFilePath, "utf8")); + let databseObject = envObject[dbFullName]; + if (!databseObject) { + databseObject = { + social: [] + }; + envObject[dbFullName] = databseObject; + } + /** @type {object[]} */ let socialLogins = databseObject.social; + socialLogins = []; + for(let i = 0; i < platforms.length; i++){ + const platform = platforms[i]; + const { clientId , clientSecret , domain1 , domain2 , callbackUrl } = platform; + if (paradigm?.match(/personal/) && !clientId?.match(/./)) { + throw new Error("Client Id Must be present"); + } + if (paradigm?.match(/personal/) && !clientSecret?.match(/./)) { + throw new Error("Client Secret Must be present"); + } + if (paradigm?.match(/datasquirel/) && !domain1?.match(/./)) { + throw new Error("Atleast one Domain Must be present"); + } + // const existingPlatformIndex = socialLogins.findIndex((scObj) => scObj.platform === platform.platform); + // console.log(existingPlatformIndex); + // if (existingPlatformIndex >= 0) { + // if (paradigm?.match(/personal/)) { + // socialLogins[existingPlatformIndex] = { ...platform, paradigm }; + // } else { + // socialLogins[existingPlatformIndex] = { paradigm, platform: platform.platform }; + // } + // } else { + // socialLogins.push({ paradigm, ...platform }); + // } + if (paradigm?.match(/personal/)) { + socialLogins.push({ + platform: platform.platform, + paradigm, + clientId, + clientSecret, + callbackUrl + }); + } else { + socialLogins.push({ + platform: platform.platform, + paradigm, + domain1, + domain2 + }); + } + } + databseObject.social = socialLogins; + fs.writeFileSync(userEnvFilePath, JSON.stringify(envObject, null, 4), "utf-8"); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/addSocialLogin/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(1541))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addSocialLogin.js.nft.json b/dsql-app/.local_dist/server/pages/api/addSocialLogin.js.nft.json new file mode 100644 index 0000000..ebf4a9f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addSocialLogin.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addTableEntry.js b/dsql-app/.local_dist/server/pages/api/addTableEntry.js new file mode 100644 index 0000000..cc968e7 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addTableEntry.js @@ -0,0 +1,216 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8325; +exports.ids = [8325]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2771: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(766); +/* harmony import */ var _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DSQL_USER_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3403); +/* harmony import */ var _package_shared_utils_backend_global_db_DSQL_USER_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DSQL_USER_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check + + + + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const checkUserRights = __webpack_require__(8999); +const grabDelegatedUserFromCookie = __webpack_require__(1352); +const serverError = __webpack_require__(2163); +const userAuth = __webpack_require__(6825); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} AddTableEntryRequestBody + * @property {string} tableName + * @property {any} payload + * @property {import("@/package-shared/types").DSQL_TableSchemaType} tableSchema + * @property {string} dbSlug + * @property {number} dbId + * @property {boolean} delegated + */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await userAuth(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "User Auth Failed" + }); + } + /** + * User auth + * + * @description Authenticate user + */ /** @type {AddTableEntryRequestBody} */ const sanitizedReqBody = req.body; + const { tableName , payload , tableSchema , dbSlug , dbId , delegated } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await grabDelegatedUserFromCookie({ + databaseSlug: dbSlug, + request: req, + user: user, + query: req.query + }); + const checkUserRightsBoolean = await checkUserRights({ + user: user, + confirmedDelegetedUser: delegatedUser, + database: dbSlug, + table: tableName, + dbId: dbId, + priviledgeRegex: /Update Entries/i + }); + if (!checkUserRightsBoolean) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const dbFullName = delegatedUser?.rootUserId ? `datasquirel_user_${delegatedUser.rootUserId}_${dbSlug}` : `datasquirel_user_${user.id}_${dbSlug}`; + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const newTableEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: tableName, + data: payload, + tableSchema: tableSchema + }); + if (!newTableEntry.insertId) { + console.log("Table Insertion Failed =>", newTableEntry); + throw new Error("Table Insertion Failed"); + } + const handleOrder = await _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0___default()({ + dbName: dbFullName, + entryId: newTableEntry.insertId, + entryOrder: payload.order, + tableName: tableName, + tableSchema: tableSchema + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + serverError({ + component: "/api/addTableEntry/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!", + err: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,1352,8999,766], () => (__webpack_exec__(2771))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addTableEntry.js.nft.json b/dsql-app/.local_dist/server/pages/api/addTableEntry.js.nft.json new file mode 100644 index 0000000..bee59d1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addTableEntry.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/1352.js","../../chunks/8999.js","../../chunks/766.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserMedia.js b/dsql-app/.local_dist/server/pages/api/addUserMedia.js new file mode 100644 index 0000000..d9bf9d5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserMedia.js @@ -0,0 +1,355 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3909; +exports.ids = [3909]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7441: +/***/ ((module) => { + +module.exports = require("sharp"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9146: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5910); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6715); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); +const config = { + api: { + responseLimit: "1mb", + bodyParser: { + sizeLimit: "200mb" + } + } +}; + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { media } = sanitizedReqBody; + const folder = sanitizedReqBody.folder; + const type = sanitizedReqBody.type; + const newMediaArray = media; + const isProduction = "production".match(/production/); + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return res.json({ + success: false, + msg: "No Static File Path" + }); + } + if (folder) { + const folderPath = path.join(STATIC_ROOT, `images/user-images/user-${user.id}/${folder}`); + const folderExists = fs.existsSync(folderPath); + if (!folderExists) { + fs.mkdirSync(folderPath, { + recursive: true + }); + } + const privateFolderPath = `./jsonData/dbSchemas/users/user-${user.id}/media/${folder}`; + const privateFolderExists = fs.existsSync(privateFolderPath); + if (!privateFolderExists) { + fs.mkdirSync(privateFolderPath, { + recursive: true + }); + } + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const mediaData = []; + for(let i = 0; i < newMediaArray.length; i++){ + const newMedia = newMediaArray[i]; + if (type?.match(/image/i)) { + const { imageBase64 , imageName , imageSize , mimeType } = newMedia; + const imageWrite = await _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_1___default()({ + imageName: imageName.replace(/ /g, "-"), + imageSourceBase64: imageBase64, + user: user, + folder, + mimeType, + isPrivate: newMedia.private + }); + if (!imageWrite) { + console.log("Image Write Failed!"); + continue; + } + const { urlPath , urlThumbnailPath , urlRelativePath , urlThumbnailRelativePath , } = imageWrite; + let newMediaEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + data: { + user_id: user.id, + media_name: imageName.replace(/ /g, "-"), + media_url: urlPath, + media_type: "image", + media_thumbnail_url: urlThumbnailPath, + media_path: urlRelativePath, + media_thumbnail_path: urlThumbnailRelativePath, + folder: folder, + private: newMedia.private ? 1 : 0 + }, + duplicateColumnName: "media_url", + duplicateColumnValue: urlPath + }); + // if (newMediaEntry?.insertId) { + mediaData.push({ + media_name: imageName.replace(/ /g, "-"), + media_url: urlPath, + media_thumbnail_url: urlThumbnailPath + }); + // } + } else if (type?.match(/file/i)) { + const { fileBase64 , fileSize , fileType } = newMedia; + const fileName = newMedia.fileName.replace(/ /g, "-").replace(/\./g, ""); + /** + * Grab URL Paths + */ const grabedPaths = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2___default()({ + isPrivate: newMedia.private, + user: user, + folder: folder + }); + if (!grabedPaths) { + continue; + } + const { fileRootPath , urlRootPath , relativePath } = grabedPaths; + const fileExt = (()=>{ + if (fileType?.match(/pdf/)) return ".pdf"; + if (fileType?.match(/xlsx/)) return ".xlsx"; + if (fileType?.match(/csv/)) return ".csv"; + if (fileType?.match(/json/)) return ".json"; + return null; + })(); + if (!fileExt) continue; + const writePath = fileRootPath + fileName + fileExt; + const urlPath1 = urlRootPath + fileName + fileExt; + const urlRelativePath1 = relativePath + fileName + fileExt; + fs.writeFileSync(writePath, fileBase64, "base64"); + let newMediaEntry1 = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + data: { + user_id: user.id, + media_name: fileName, + media_url: urlPath1, + media_thumbnail_url: urlPath1, + media_path: urlRelativePath1, + media_thumbnail_path: urlRelativePath1, + media_type: "file" + "/" + fileExt.replace(/\./, ""), + folder: folder, + private: newMedia.private ? 1 : 0 + }, + duplicateColumnName: "media_url", + duplicateColumnValue: urlPath1 + }); + mediaData.push({ + media_name: fileName, + media_url: urlPath1, + media_thumbnail_url: urlPath1 + }); + } else if (type?.match(/video/i)) { + const { fileBase64: fileBase641 , fileSize: fileSize1 , fileType: fileType1 } = newMedia; + const fileName1 = newMedia.fileName.replace(/ /g, "-").replace(/\./g, ""); + /** + * Grab URL Paths + */ const grabedPaths1 = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2___default()({ + isPrivate: newMedia.private, + user: user, + folder: folder, + video: true + }); + if (!grabedPaths1) { + continue; + } + const { fileRootPath: fileRootPath1 , urlRootPath: urlRootPath1 , relativePath: relativePath1 } = grabedPaths1; + const fileExt1 = (()=>{ + if (fileType1?.match(/mp4/)) return ".mp4"; + return null; + })(); + if (!fileExt1) continue; + const writePath1 = fileRootPath1 + fileName1 + fileExt1; + const urlPath2 = urlRootPath1 + fileName1 + fileExt1; + const urlRelativePath2 = relativePath1 + fileName1 + fileExt1; + fs.writeFileSync(writePath1, fileBase641, "base64"); + let newMediaEntry2 = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + data: { + user_id: user.id, + media_name: fileName1, + media_url: urlPath2, + media_thumbnail_url: urlPath2, + media_path: urlRelativePath2, + media_thumbnail_path: urlRelativePath2, + media_type: "video" + "/" + fileExt1.replace(/\./, ""), + folder: folder, + private: newMedia.private ? 1 : 0 + }, + duplicateColumnName: "media_url", + duplicateColumnValue: urlPath2 + }); + mediaData.push({ + media_name: fileName1, + media_url: urlPath2, + media_thumbnail_url: urlPath2 + }); + } + } + //////////////////////////////////////// + res.json({ + success: true, + mediaData: mediaData + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(`Add User Media Error: ${error.message}`); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/addUserMedia/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,6715,5910], () => (__webpack_exec__(9146))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/addUserMedia.js.nft.json new file mode 100644 index 0000000..643ebe7 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/6715.js","../../chunks/5910.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/sharp/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/sharp/lib/index.js","../../../../node_modules/sharp/lib/constructor.js","../../../../node_modules/sharp/lib/input.js","../../../../node_modules/sharp/lib/composite.js","../../../../node_modules/sharp/lib/operation.js","../../../../node_modules/sharp/lib/resize.js","../../../../node_modules/sharp/lib/colour.js","../../../../node_modules/sharp/lib/channel.js","../../../../node_modules/sharp/lib/output.js","../../../../node_modules/sharp/lib/utility.js","../../../../node_modules/sharp/lib/is.js","../../../../node_modules/sharp/lib/sharp.js","../../../../node_modules/sharp/lib/libvips.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/lru-cache/package.json","../../../../node_modules/lru-cache/index.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/sharp/node_modules/semver/functions/coerce.js","../../../../node_modules/sharp/node_modules/semver/functions/satisfies.js","../../../../node_modules/sharp/node_modules/semver/functions/gte.js","../../../../node_modules/sharp/node_modules/semver/package.json","../../../../node_modules/color/index.js","../../../../node_modules/detect-libc/package.json","../../../../node_modules/detect-libc/lib/detect-libc.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/color/package.json","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/sharp/node_modules/semver/functions/compare.js","../../../../node_modules/sharp/node_modules/semver/functions/parse.js","../../../../node_modules/sharp/node_modules/semver/classes/range.js","../../../../node_modules/sharp/node_modules/semver/classes/semver.js","../../../../node_modules/sharp/node_modules/semver/internal/re.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/detect-libc/lib/process.js","../../../../node_modules/detect-libc/lib/filesystem.js","../../../../node_modules/yallist/package.json","../../../../node_modules/yallist/yallist.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/sharp/node_modules/semver/internal/debug.js","../../../../node_modules/sharp/node_modules/semver/internal/constants.js","../../../../node_modules/sharp/node_modules/semver/internal/parse-options.js","../../../../node_modules/sharp/node_modules/semver/internal/identifiers.js","../../../../node_modules/sharp/node_modules/semver/classes/comparator.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/yallist/iterator.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/color/node_modules/color-convert/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/color/node_modules/color-convert/package.json","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/sharp/node_modules/semver/functions/cmp.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/color-string/index.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/color-string/package.json","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/color/node_modules/color-convert/conversions.js","../../../../node_modules/color/node_modules/color-convert/route.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sharp/node_modules/semver/functions/eq.js","../../../../node_modules/sharp/node_modules/semver/functions/neq.js","../../../../node_modules/sharp/node_modules/semver/functions/gt.js","../../../../node_modules/sharp/node_modules/semver/functions/lte.js","../../../../node_modules/sharp/node_modules/semver/functions/lt.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/color-name/package.json","../../../../node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/color/node_modules/color-name/package.json","../../../../node_modules/color/node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/package.json","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserTable.js b/dsql-app/.local_dist/server/pages/api/addUserTable.js new file mode 100644 index 0000000..74c3081 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserTable.js @@ -0,0 +1,304 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8448; +exports.ids = [8448]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8583: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8164); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_setUserSchemaData__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7638); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + console.log("No User"); + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { payload } = req.body; + const dbFullName = req.body.dbFullName.replace(/[^a-z\_0-9]/g, ""); + const dbSlug = req.body.dbSlug; + const dbId = req.body.dbId; + const parentDatabase = req.body.parentDatabase; + const parentTable = req.body.parentTable; + /** + * Send Response + * + * @description Send a boolean response + */ try { + let userSchemaData = (0,_functions_backend_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_2__["default"])({ + userId: user.id + }); + if (!userSchemaData) { + throw new Error("No User Schema found!"); + } + let targetDatabaseIndex = userSchemaData.findIndex((db)=>db.dbFullName === dbFullName); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ let targetDatabase = userSchemaData[targetDatabaseIndex]; + if (!targetDatabase) { + throw new Error("No Target Database Found!"); + } + let existingTableIndex = targetDatabase.tables.findIndex((table)=>table.tableName === payload.tableName); + if (existingTableIndex >= 0) { + userSchemaData[targetDatabaseIndex].tables[existingTableIndex] = payload; + } else { + userSchemaData[targetDatabaseIndex].tables.push(payload); + } + if (payload?.childTable) { + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ const parentDb = userSchemaData.find((db)=>db.dbFullName === parentDatabase); + const parentTableObject = parentDb?.tables.find((table)=>{ + if (table.tableName === parentTable) { + return true; + } + }); + if (!parentTableObject) { + throw new Error("Child Table Parent Doesn't Exist!"); + } + if (parentTableObject.childrenTables?.[0]) { + parentTableObject.childrenTables.push({ + dbNameFull: dbFullName, + tableName: payload.tableName, + tableNameFull: payload.tableNameFull + }); + } else { + parentTableObject.childrenTables = [ + { + dbNameFull: dbFullName, + tableName: payload.tableName, + tableNameFull: payload.tableFullName + }, + ]; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Check Children Databases + * + * @description Check Children Databases + */ if (targetDatabase.childrenDatabases) { + for(let i = 0; i < targetDatabase.childrenDatabases.length; i++){ + const childDb = targetDatabase.childrenDatabases[i]; + try { + const targetChildIndex = userSchemaData.findIndex((db)=>db.dbFullName === childDb.dbFullName); + if (userSchemaData[targetChildIndex]) userSchemaData[targetChildIndex].tables = lodash__WEBPACK_IMPORTED_MODULE_3___default().cloneDeep(targetDatabase.tables); + const targetDbRecord = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM user_databases WHERE user_id = ? AND db_full_name = ?`, [ + user.id, + childDb.dbFullName + ]); + const existingEntry = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM user_database_tables WHERE db_id=? AND user_id=? AND table_slug=?`, [ + targetDbRecord[0].id, + user.id, + payload.tableName + ]); + if (existingEntry?.[0]) continue; + const newChildTableEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_6___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: user.id, + db_id: targetDbRecord[0].id, + db_slug: targetDbRecord[0].db_slug, + table_name: payload.tableFullName, + table_slug: payload.tableName + } + }); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/addUserTable/lines-124-140", + message: error.message, + user: user + }); + } + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + // console.log("Done ..."); + // fs.writeFileSync( + // "./.tmp/newTableSchema.json", + // JSON.stringify(userSchemaData, null, 4), + // "utf8" + // ); + // return res.json({ + // success: false, + // msg: "Testing", + // }); + (0,_functions_backend_setUserSchemaData__WEBPACK_IMPORTED_MODULE_4__["default"])({ + userId: user.id, + schemaData: userSchemaData + }); + //////////////////////////////////////// + /** @type {any} */ const newTableInsertObject = { + user_id: user.id, + db_id: dbId, + db_slug: dbSlug, + table_name: payload.tableFullName, + table_slug: payload.tableName + }; + if (payload?.childTable) { + newTableInsertObject["child_table"] = "1"; + newTableInsertObject["child_table_parent_database"] = parentDatabase; + newTableInsertObject["child_table_parent_table"] = parentTable; + } + const newTableEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_6___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: newTableInsertObject + }); + //////////////////////////////////////// + const targetPath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${user.id} --database ${dbFullName}${payload?.childTable ? " --clone" : ""}`, { + cwd: targetPath + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + console.log(error1.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/addUserTable/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,8164,7638], () => (__webpack_exec__(8583))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserTable.js.nft.json b/dsql-app/.local_dist/server/pages/api/addUserTable.js.nft.json new file mode 100644 index 0000000..05f8ed8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserTable.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/8164.js","../../chunks/7638.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserUser.js b/dsql-app/.local_dist/server/pages/api/addUserUser.js new file mode 100644 index 0000000..dda0d67 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserUser.js @@ -0,0 +1,231 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5402; +exports.ids = [5402]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9210: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ // const sanitizedReqBody = sanitizeSql(req.body); + const sanitizedReqBody = req.body; + const paradigm = sanitizedReqBody.paradigm; + /** + * Input Validation + * + * @description Input Validation + */ if (paradigm?.match(/database/)) { + const newUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "user_users", + data: (()=>{ + const reqBodyKeys = Object.keys(sanitizedReqBody); + /** @type {any} */ const finalData = {}; + reqBodyKeys.forEach((key)=>{ + if (key?.match(/paradigm|priviledge|database_access|databases|confirm/)) return; + finalData[key] = sanitizedReqBody[key]; + }); + finalData["user_id"] = user.id; + finalData["password"] = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: sanitizedReqBody.password + }); + finalData["user_type"] = "database"; + finalData["email"] = sanitizedReqBody.email_address; + finalData["image"] = "/images/user_images/user-preset.png"; + finalData["image_thumbnail"] = "/images/user_images/user-preset-thumbnail.png"; + delete finalData["email_address"]; + return finalData; + })() + }); + res.json({ + success: newUser?.insertId ? true : false, + msg: "New User User Added", + newUserId: newUser.insertId + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } else { + if (user?.email === sanitizedReqBody.email_address) { + return res.json({ + success: false, + msg: "Can't Invite yourself" + }); + } + const existingInvitation = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4___default()(`SELECT * FROM invitations WHERE invited_user_email=? AND inviting_user_id=?`, [ + sanitizedReqBody.email_address, + user.id + ]); + if (existingInvitation && existingInvitation[0]) { + return res.json({ + success: false, + msg: "User Already Invited" + }); + } + const newInvitation = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "invitations", + data: { + inviting_user_id: user.id, + invited_user_email: sanitizedReqBody.email_address, + database_access: sanitizedReqBody.database_access, + priviledge: sanitizedReqBody.priviledge, + db_tables_data: sanitizedReqBody.db_tables + } + }); + const sendInvitationMail = await _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default()({ + to: sanitizedReqBody.email_address, + subject: `${user.first_name} ${user.last_name} Invited you`, + text: `${user.first_name} ${user.last_name} has invited you to manage a datasquirel account`, + html: ` + <h2>${user.first_name} ${user.last_name} has invited you to manage a datasquirel account.</h2> + <a href="${process.env.DSQL_HOST}/create-account?invite=${user.id}&database_access=${sanitizedReqBody.database_access}&priviledge=${sanitizedReqBody.priviledge}&email=${sanitizedReqBody.email_address}">Accept Invitation</a> + ` + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: sendInvitationMail?.accepted ? true : false, + msg: "This is an invitation request" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,7547,5886,5338,6926], () => (__webpack_exec__(9210))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUserUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/addUserUser.js.nft.json new file mode 100644 index 0000000..29b128d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUserUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/6926.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js b/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js new file mode 100644 index 0000000..8a8b4fd --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js @@ -0,0 +1,265 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9372; +exports.ids = [9372]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2066: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbFullName , dbSlug , dbId } = sanitizedReqBody; + const userPreset = __webpack_require__(9258); + const defaultFields = __webpack_require__(2439); + const finalFields = [ + ...defaultFields.slice(0, 2), + ...userPreset.fields, + ...defaultFields.slice(2), + ]; + userPreset.fields = [ + ...finalFields + ]; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + let targetDatabase = userSchemaData.filter((db)=>db.dbFullName === dbFullName)[0]; + /** @type {number | undefined} */ let existingTableIndex; + let existingTable = targetDatabase.tables.filter((table, index)=>{ + if (table.tableName === "users") { + existingTableIndex = index; + return true; + } + }); + // if (typeof existingTableIndex !== "number") + // return res.json({ success: false }); + if (existingTable?.[0] && typeof existingTableIndex == "number") { + targetDatabase.tables[existingTableIndex] = userPreset; + } else { + targetDatabase.tables.push(userPreset); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Check Children Databases + * + * @description Check Children Databases + */ if (targetDatabase.childrenDatabases) { + for(let i = 0; i < targetDatabase.childrenDatabases.length; i++){ + const childDb = targetDatabase.childrenDatabases[i]; + try { + const targetChild = userSchemaData.filter((db)=>db.dbFullName === childDb.dbFullName)[0]; + targetChild.tables = targetDatabase.tables; + const targetDbRecord = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_databases WHERE user_id = ? AND db_full_name = ?`, [ + user.id, + childDb.dbFullName + ]); + const newChildTableEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: user.id, + db_id: targetDbRecord[0].id, + db_slug: targetDbRecord[0].db_slug, + table_name: "Users", + table_slug: "users" + } + }); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/addUsersTableToDatabase/lines-100-115", + message: error.message, + user: user + }); + } + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const newTableEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: user.id, + db_id: dbId, + db_slug: dbSlug, + table_name: "Users", + table_slug: "users" + } + }); + //////////////////////////////////////// + const targetPath = path.join(process.cwd(), "/shell"); + const sanitizedDbName = dbFullName.replace(/[^a-z\_0-9]/g, ""); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${user.id} --database ${sanitizedDbName}`, { + cwd: targetPath + }); + console.log(dbShellUpdate.toString()); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/addUsersTableToDatabase/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }), + +/***/ 2439: +/***/ ((module) => { + +module.exports = JSON.parse('[{"fieldName":"id","dataType":"BIGINT","notNullValue":true,"primaryKey":true,"autoIncrement":true},{"fieldName":"uuid","dataType":"UUID","defaultValueLiteral":"UUID()"},{"fieldName":"date_created","dataType":"VARCHAR(250)","nullValue":true},{"fieldName":"date_created_code","dataType":"BIGINT","nullValue":true},{"fieldName":"date_created_timestamp","dataType":"TIMESTAMP","defaultValueLiteral":"CURRENT_TIMESTAMP"},{"fieldName":"date_updated","dataType":"VARCHAR(250)","nullValue":true},{"fieldName":"date_updated_code","dataType":"BIGINT","nullValue":true},{"fieldName":"date_updated_timestamp","dataType":"TIMESTAMP","defaultValueLiteral":"CURRENT_TIMESTAMP","onUpdateLiteral":"CURRENT_TIMESTAMP"}]'); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,9258], () => (__webpack_exec__(2066))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js.nft.json new file mode 100644 index 0000000..8de43f0 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/addUsersTableToDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/9258.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../jsonData/dbSchemas/defaultFields.json","../../../../package.json","../../../../jsonData/presets/users.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js b/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js new file mode 100644 index 0000000..2bf5d56 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js @@ -0,0 +1,184 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2383; +exports.ids = [2383]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5509: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +const fs = __webpack_require__(7147); +const os = __webpack_require__(2037); +const { execSync , spawnSync } = __webpack_require__(2081); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "Unauthorized" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + try { + /** + * Validate Form + * + * @description Check if request body is valid + */ const dsqlUser = req.body.user; + const dsqlUserId = dsqlUser.id.toString().replace(/[^0-9]/g, "").replace(/\//g, ""); + const backupFolder = `./jsonData/dbSchemas/users/user-${dsqlUserId}/backups`; + if (!fs.existsSync(backupFolder)) { + fs.mkdirSync(backupFolder); + } + const newBackupFolderName = Date.now().toString(); + fs.mkdirSync(`${backupFolder}/${newBackupFolderName}`); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const userDatabases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SHOW databases LIKE ?`, [ + `datasquirel_user_${dsqlUserId}_%`, + ]); + for(let i = 0; i < userDatabases.length; i++){ + const dbObject = userDatabases[i]; + const dbName = Object.values(dbObject)[0].replace(/[^a-z0-9\_]/g, ""); + //////////////////////////////////////////////// + const mysqlDumpPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysqldump.exe" + "'" : "mysqldump"; + /** @type {import("child_process").SpawnSyncOptions} */ let execSyncOptions = { + cwd: process.cwd() + }; + const filePath = `${backupFolder}/${newBackupFolderName}/${dbName}.sql`; + if (os.platform().match(/win/i)) execSyncOptions.shell = "bash.exe"; + const exe = `${mysqlDumpPath} -u ${process.env.DSQL_DB_USERNAME} -h ${process.env.DSQL_DB_HOST} -p${process.env.DSQL_DB_PASSWORD} ${dbName} > ${filePath}`; + console.log(`addUserBackup.js exe => ${exe}`); + const dumpDb = spawnSync(mysqlDumpPath, [ + "-u", + process.env.DSQL_DB_USERNAME, + "-h", + process.env.DSQL_DB_HOST, + `-p${process.env.DSQL_DB_PASSWORD}`, + dbName, + ">", + filePath, + ], execSyncOptions); + // const dumpDb = execSync(mysqlDumpPath, [], execSyncOptions); + //////////////////////////////////////////////// + } + //////////////////////////////////////////////// + fs.copyFileSync(`./jsonData/dbSchemas/users/user-${dsqlUserId}/main.json`, `${backupFolder}/${newBackupFolderName}/main.json`); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + res.json({ + success: false + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,4432], () => (__webpack_exec__(5509))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js.nft.json new file mode 100644 index 0000000..7c4323c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/addUserBackup.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/4432.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js b/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js new file mode 100644 index 0000000..8ee7ce2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js @@ -0,0 +1,112 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7331; +exports.ids = [7331]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 5313: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +const { execSync } = __webpack_require__(2081); +const fs = __webpack_require__(7147); + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ fs.writeFileSync("./.tmp/error.log", "", "utf-8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(5313))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js.nft.json new file mode 100644 index 0000000..8a64a17 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/clearErrorLogs.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/clientError.js b/dsql-app/.local_dist/server/pages/api/admin/clientError.js new file mode 100644 index 0000000..497639c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/clientError.js @@ -0,0 +1,88 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7194; +exports.ids = [7194]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 4177: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Failed" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const { component , message , user } = req.body; + const log = `💻 CLIENT ERROR ===========================\nUser Id: ${user?.id}\nUser Name: ${user?.first_name} ${user?.last_name}\nUser Email: ${user?.email}\nError Message: ${message}\nComponent: ${component}\nDate: ${Date()}\n========================================`; + const initialText = fs.readFileSync(`./.tmp/error.log`, "utf-8"); + fs.writeFileSync(`./.tmp/error.log`, log); + fs.appendFileSync(`./.tmp/error.log`, `\n\n\n\n\n${initialText}`); + // if (process.env.NODE_ENV.match(/production/)) { + // handleNodemailer({ + // to: "benoti.san@gmail.com", + // subject: "CLIENT Error in Datasquirel Application", + // text: "An Error occured in Datasquirel Application Client Side", + // html: log, + // }); + // } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [6926], () => (__webpack_exec__(4177))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/clientError.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/clientError.js.nft.json new file mode 100644 index 0000000..0583ce1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/clientError.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/6926.js","../../../../package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js b/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js new file mode 100644 index 0000000..28b8a86 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js @@ -0,0 +1,230 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2845; +exports.ids = [2845]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 233: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * rootFolderPath: string, + * destinationFolderPath: string, + * }} params - params + * + * @returns {boolean} operation successful or not + */ module.exports = function copyFolderRecursively({ rootFolderPath , destinationFolderPath , }) { + try { + /** + * Start Operations + * + * @description Start Operations + */ fs.mkdirSync(destinationFolderPath); + /** + * Recursive Copy Function + * + * @description Recursive Copy Function + * @param {string} srcPath - path string + * @param {string} dstPath - path string + */ function copyFiles(srcPath, dstPath) { + const files = fs.readdirSync(srcPath); + for(let i = 0; i < files.length; i++){ + const file = files[i]; + if (file?.match(/\..{2,5}$/)) { + fs.copyFileSync(`${srcPath}/${file}`, `${dstPath}/${file}`); + } else { + fs.mkdirSync(`${dstPath}/${file}`, { + recursive: true + }); + copyFiles(`${srcPath}/${file}`, `${dstPath}/${file}`); + } + } + } + copyFiles(rootFolderPath, destinationFolderPath); + return true; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + return false; + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }), + +/***/ 9389: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_copyFolderRecursively__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(233); +/* harmony import */ var _functions_backend_copyFolderRecursively__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_copyFolderRecursively__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const fs = __webpack_require__(7147); +const os = __webpack_require__(2037); +const { execSync } = __webpack_require__(2081); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + success: false, + msg: "Failed" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const backupFolder = "./.tmp/backups"; + if (!fs.existsSync(backupFolder)) { + fs.mkdirSync("./.tmp/backups"); + } + const newBackupFolderName = Date.now().toString(); + fs.mkdirSync(`${backupFolder}/${newBackupFolderName}`); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const mysqlDumpPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysqldump.exe" + "'" : "mysqldump"; + try { + /** @type {import("child_process").ExecSyncOptions} */ let execSyncOptions = { + cwd: process.cwd() + }; + const filePath = `${backupFolder}/${newBackupFolderName}/datasquirel.sql`; + if (os.platform().match(/win/i)) execSyncOptions.shell = "bash.exe"; + const exe = `${mysqlDumpPath} -u ${process.env.DSQL_DB_USERNAME} -h ${process.env.DSQL_DB_HOST} -p${process.env.DSQL_DB_PASSWORD} datasquirel > ${filePath}`; + console.log(`createNewBackup.js exe => ${exe}`); + const dumpDb = execSync(exe, execSyncOptions); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + fs.copyFileSync(`./jsonData/dbSchemas/main.json`, `${backupFolder}/${newBackupFolderName}/datasquirelSchema.json`); + const copyUserFiles = _functions_backend_copyFolderRecursively__WEBPACK_IMPORTED_MODULE_0___default()({ + rootFolderPath: `./jsonData/dbSchemas/users`, + destinationFolderPath: `${backupFolder}/${newBackupFolderName}/userSchemas` + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + res.json({ + success: false + }); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/admin/createNewBackup/lines-73-90", + message: error.message + }); + } +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163,4432], () => (__webpack_exec__(9389))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js.nft.json new file mode 100644 index 0000000..bda5d45 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/createNewBackup.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2163.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js b/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js new file mode 100644 index 0000000..7d1b4a2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js @@ -0,0 +1,556 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9875; +exports.ids = [9875]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1689: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const sanitizeHtml = __webpack_require__(6109); +const DB_HANDLER = __webpack_require__(2224); +const addDbEntry = __webpack_require__(5338); +const sanitizeHtmlOptions = __webpack_require__(9544); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {any} params.body - Request body + * @param {boolean} [params.update] - Update if existing + * + * @returns {Promise<object|null>} + */ module.exports = async function({ body , update }) { + /** + * Initialize variables + */ const slug = body.title.toLowerCase().replace(/ /g, "-").replace(/[^a-z0-9\-]/g, ""); + const currentOrder = await async function() { + if (update) return null; + try { + const lastOrder = await DB_HANDLER(`SELECT page_order FROM docs_pages ORDER BY page_order DESC LIMIT 1`); + return lastOrder[0].page_order; + } catch (error) { + return null; + } + }(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + * @type {any} + */ const addDocPage = await addDbEntry({ + data: { + title: body.title, + slug: slug, + description: sanitizeHtml(body.description, sanitizeHtmlOptions), + content: sanitizeHtml(body.content, sanitizeHtmlOptions), + text_content: body.text_content, + level: body.level, + page_order: update ? body.page_order : parseInt(currentOrder) + 1, + parent_id: body?.parent_id + }, + tableName: "docs_pages", + update: update, + duplicateColumnName: "id", + duplicateColumnValue: body.id + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ if (addDocPage?.insertId) { + return addDocPage; + } else if (update && addDocPage.affectedRows) { + return addDocPage; + } + { + return null; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 6672: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const DB_HANDLER = __webpack_require__(2224); +/** + * Imports: Handle imports + */ /** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {any} params.body - Request body + * @param {boolean} [params.update] - Update if existing + * + * @returns {Promise<object|null>} + */ module.exports = async function({ body }) { + /** + * Initialize variables + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ const deleteDocPage = await DB_HANDLER(`DELETE FROM docs_pages WHERE id=?`, [ + body.id + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ if (deleteDocPage) { + return deleteDocPage; + } else { + return null; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 2755: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const fs = __webpack_require__(7147); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {object} [params.body] - Request body + * @param {boolean} [params.update] - Update if existing + * + * @returns {Promise<object|null>} + */ module.exports = async function() { + /** + * Initialize variables + */ const snippetsDirectory = "./components/su/components/RichText/html-presets"; + /** @type {any[]} */ let snippets = []; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ if (fs.existsSync(snippetsDirectory)) { + const presetFiles = fs.readdirSync(snippetsDirectory); + presetFiles.forEach((file)=>{ + if (file?.endsWith(".html")) { + /** @type {any} */ const pushObject = {}; + pushObject[file.replace(/\.html$/, "")] = fs.readFileSync(`${snippetsDirectory}/${file}`, "utf-8"); + snippets.push({ + ...pushObject + }); + } + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return snippets; +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 5217: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const fs = __webpack_require__(7147); +const DB_HANDLER = __webpack_require__(2224); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {any} params.body - Request body + * + * @returns {Promise<object|null>} + */ module.exports = async function({ body }) { + /** + * Initialize variables + */ let results; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ const pages = await DB_HANDLER(`SELECT id, title, slug FROM docs_pages WHERE parent_id = ?`, [ + body.pageId + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ if (!pages[0]) return null; + return pages; +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 5030: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const DB_HANDLER = __webpack_require__(2224); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {any} params.body - Request body + * + * @returns {Promise<object|null>} + */ module.exports = async function({ body }) { + /** + * Initialize variables + */ let results; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ const pages = body?.currentPageId ? await DB_HANDLER(`SELECT * FROM docs_pages WHERE level = ? AND id != ?`, [ + body.pagesLevel, + body.currentPageId + ]) : await DB_HANDLER(`SELECT * FROM docs_pages WHERE level = ?`, [ + body.pagesLevel, + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return pages; +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 4751: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const fs = __webpack_require__(7147); +const DB_HANDLER = __webpack_require__(2224); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {any} params.body - Request body + * + * @returns {Promise<any>} + */ module.exports = async function({ body }) { + /** + * Initialize variables + */ const { pull } = body; + const filePath = "./jsonData/docs.json"; + // return null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ if (pull) { + try { + const jsonPages = JSON.parse(fs.readFileSync(filePath, "utf-8")); + for(let i = 0; i < jsonPages.length; i++){ + const page = jsonPages[i]; + const existingPageEntry = await DB_HANDLER(`SELECT id FROM docs_pages WHERE slug = ? AND level = ?`, [ + page.slug, + page.level + ]); + if (existingPageEntry && existingPageEntry[0]) { + let trimmedPage = { + ...page + }; + delete trimmedPage.date_created; + delete trimmedPage.date_created_code; + delete trimmedPage.date_created_timestamp; + delete trimmedPage.date_updated; + delete trimmedPage.date_updated_code; + delete trimmedPage.date_updated_timestamp; + delete trimmedPage.id; + const update = await DB_HANDLER(`UPDATE docs_pages SET ? WHERE slug = '${page.slug}' AND level = '${page.level}'`, trimmedPage); + //////////////////////////////////////// + } else { + //////////////////////////////////////// + let trimmedPage1 = { + ...page + }; + delete trimmedPage1.date_created_timestamp; + delete trimmedPage1.date_updated_timestamp; + const newPage = await DB_HANDLER(`INSERT INTO docs_pages SET ?`, trimmedPage1); + } + } + } catch (error) { + // console.log(error.message); + return null; + } + } else { + const pages = await DB_HANDLER(`SELECT * FROM docs_pages`); + fs.writeFileSync(filePath, JSON.stringify(pages, null, 4), "utf-8"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return true; +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 4108: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_admin_addDocPage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1689); +/* harmony import */ var _functions_backend_admin_addDocPage__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_addDocPage__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_admin_deleteDocPage__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6672); +/* harmony import */ var _functions_backend_admin_deleteDocPage__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_deleteDocPage__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_admin_getSnippets__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2755); +/* harmony import */ var _functions_backend_admin_getSnippets__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_getSnippets__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_admin_grabChildPages__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5217); +/* harmony import */ var _functions_backend_admin_grabChildPages__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_grabChildPages__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_admin_grabParentPages__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5030); +/* harmony import */ var _functions_backend_admin_grabParentPages__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_grabParentPages__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _functions_backend_admin_persistDocs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4751); +/* harmony import */ var _functions_backend_admin_persistDocs__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_admin_persistDocs__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_6___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "Unauthorized" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const { action } = req.query; + const reqBody = req.body; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + try { + /** + * Validate Form + * + * @description Check if request body is valid + */ let result; + switch(action){ + case "add-page": + result = await _functions_backend_admin_addDocPage__WEBPACK_IMPORTED_MODULE_0___default()({ + body: reqBody + }); + break; + case "update-page": + result = await _functions_backend_admin_addDocPage__WEBPACK_IMPORTED_MODULE_0___default()({ + body: reqBody, + update: true + }); + break; + case "delete-page": + result = await _functions_backend_admin_deleteDocPage__WEBPACK_IMPORTED_MODULE_1___default()({ + body: reqBody + }); + break; + case "get-snippets": + result = await _functions_backend_admin_getSnippets__WEBPACK_IMPORTED_MODULE_2___default()(); + break; + case "grab-parent-pages": + result = await _functions_backend_admin_grabParentPages__WEBPACK_IMPORTED_MODULE_4___default()({ + body: reqBody + }); + break; + case "get-child-pages": + result = await _functions_backend_admin_grabChildPages__WEBPACK_IMPORTED_MODULE_3___default()({ + body: reqBody + }); + break; + case "persist": + result = await _functions_backend_admin_persistDocs__WEBPACK_IMPORTED_MODULE_5___default()({ + body: reqBody + }); + break; + default: + break; + } + if (!result) throw new Error("Operation failed!"); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true, + result + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (error) { + res.json({ + success: false + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,3017,3403,7547,5886,5338,4432], () => (__webpack_exec__(4108))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js.nft.json new file mode 100644 index 0000000..09916f9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/docs/[action].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-api-runtime.js","../../../../chunks/5425.js","../../../../chunks/2224.js","../../../../chunks/3017.js","../../../../chunks/3403.js","../../../../chunks/7547.js","../../../../chunks/5886.js","../../../../chunks/5338.js","../../../../chunks/4432.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/lodash/package.json","../../../../../../node_modules/sanitize-html/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lodash/lodash.js","../../../../../../node_modules/sanitize-html/index.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/escape-string-regexp/index.js","../../../../../../node_modules/htmlparser2/package.json","../../../../../../node_modules/htmlparser2/lib/index.js","../../../../../../node_modules/is-plain-object/package.json","../../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../../node_modules/deepmerge/package.json","../../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../../node_modules/parse-srcset/package.json","../../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../../node_modules/postcss/package.json","../../../../../../node_modules/postcss/lib/postcss.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/escape-string-regexp/package.json","../../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../../node_modules/postcss/lib/result.js","../../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../../node_modules/postcss/lib/declaration.js","../../../../../../node_modules/postcss/lib/container.js","../../../../../../node_modules/postcss/lib/processor.js","../../../../../../node_modules/postcss/lib/stringify.js","../../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../../node_modules/postcss/lib/document.js","../../../../../../node_modules/postcss/lib/warning.js","../../../../../../node_modules/postcss/lib/comment.js","../../../../../../node_modules/postcss/lib/at-rule.js","../../../../../../node_modules/postcss/lib/input.js","../../../../../../node_modules/postcss/lib/parse.js","../../../../../../node_modules/postcss/lib/list.js","../../../../../../node_modules/postcss/lib/rule.js","../../../../../../node_modules/postcss/lib/root.js","../../../../../../node_modules/postcss/lib/node.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../../node_modules/postcss/lib/symbols.js","../../../../../../node_modules/postcss/lib/map-generator.js","../../../../../../node_modules/postcss/lib/warn-once.js","../../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../../node_modules/postcss/lib/stringifier.js","../../../../../../node_modules/postcss/lib/previous-map.js","../../../../../../node_modules/postcss/lib/parser.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/entities/package.json","../../../../../../node_modules/entities/lib/decode.js","../../../../../../node_modules/domelementtype/package.json","../../../../../../node_modules/domelementtype/lib/index.js","../../../../../../node_modules/domhandler/package.json","../../../../../../node_modules/domhandler/lib/index.js","../../../../../../node_modules/domutils/package.json","../../../../../../node_modules/domutils/lib/index.js","../../../../../../node_modules/postcss/lib/tokenize.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/picocolors/package.json","../../../../../../node_modules/picocolors/picocolors.js","../../../../../../node_modules/source-map-js/package.json","../../../../../../node_modules/source-map-js/source-map.js","../../../../../../node_modules/domhandler/lib/node.js","../../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../../node_modules/domutils/lib/stringify.js","../../../../../../node_modules/domutils/lib/manipulation.js","../../../../../../node_modules/domutils/lib/traversal.js","../../../../../../node_modules/domutils/lib/querying.js","../../../../../../node_modules/domutils/lib/legacy.js","../../../../../../node_modules/domutils/lib/helpers.js","../../../../../../node_modules/domutils/lib/feeds.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/nanoid/non-secure/package.json","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/nanoid/package.json","../../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/dom-serializer/package.json","../../../../../../node_modules/dom-serializer/lib/index.js","../../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../../node_modules/source-map-js/lib/util.js","../../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../../node_modules/source-map-js/lib/base64.js","../../../../../../node_modules/entities/lib/index.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/entities/lib/escape.js","../../../../../../node_modules/entities/lib/encode.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js b/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js new file mode 100644 index 0000000..2581472 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js @@ -0,0 +1,149 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9987; +exports.ids = [9987]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2372: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const { database } = req.query; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const result = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: typeof database === "string" ? database : "", + queryString: `SHOW TABLES FROM ${database}` + }); + if (!result) { + return res.json({ + success: false, + msg: "Query Failed!" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + tables: result.map((/** @type {any} */ table)=>Object.values(table)[0]) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311,4432], () => (__webpack_exec__(2372))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js.nft.json new file mode 100644 index 0000000..4eca290 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getTablesForUserDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/4432.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js b/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js new file mode 100644 index 0000000..fb604d9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js @@ -0,0 +1,111 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5485; +exports.ids = [5485]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2235: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const dsqlUser = req.body.user; + const dsqlUserId = dsqlUser.id.toString().replace(/[^0-9]/g, "").replace(/\//g, ""); + const backupFolder = `./jsonData/dbSchemas/users/user-${dsqlUserId}/backups`; + if (!fs.existsSync(backupFolder)) { + fs.mkdirSync(backupFolder); + } + const backups = fs.readdirSync(backupFolder); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true, + backups: backups + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(2235))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js.nft.json new file mode 100644 index 0000000..8a64a17 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getUserBackups.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getUserData.js b/dsql-app/.local_dist/server/pages/api/admin/getUserData.js new file mode 100644 index 0000000..4e6543e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getUserData.js @@ -0,0 +1,164 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8141; +exports.ids = [8141]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6450: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check + + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const dsqlUser = req.body.user; + const dsqlUserId = dsqlUser?.id.toString().replace(/[^0-9]/g, "").replace(/\//g, ""); + const userFolder = `./jsonData/dbSchemas/users/user-${dsqlUserId}`; + /** @type {any[]} */ let userData = []; + /** + * + * @param {object} params + * @param {any[]} params.originArray + * @param {string} params.rootPath + */ function grabFolderContent({ originArray , rootPath }) { + const folderContent = fs.readdirSync(rootPath); + for(let i = 0; i < folderContent.length; i++){ + const fileName = folderContent[i]; + if (fileName?.match(/\..{2,5}$/)) { + originArray.push({ + name: fileName, + type: "file", + root: rootPath + }); + } else { + const newObject = { + name: fileName, + type: "folder", + root: rootPath, + content: [] + }; + grabFolderContent({ + originArray: newObject.content, + rootPath: `${rootPath}/${fileName}` + }); + originArray.push(newObject); + } + } + } + grabFolderContent({ + originArray: userData, + rootPath: userFolder + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** @type {any[]} */ const userDatabases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SHOW databases LIKE 'datasquirel_user_${dsqlUser.id}_%'`); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true, + data: userData, + databases: userDatabases.map((db)=>Object.values(db)[0]) + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,4432], () => (__webpack_exec__(6450))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/getUserData.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/getUserData.js.nft.json new file mode 100644 index 0000000..7c4323c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/getUserData.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/4432.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js b/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js new file mode 100644 index 0000000..5d0d155 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js @@ -0,0 +1,109 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3649; +exports.ids = [3649]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1183: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + success: false, + msg: "Failed" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const backupFolder = "./.tmp/backups"; + if (!fs.existsSync(backupFolder)) { + fs.mkdirSync(backupFolder); + } + const backups = fs.readdirSync(backupFolder); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + backups: backups + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(1183))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js.nft.json new file mode 100644 index 0000000..8a64a17 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabBackups.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js b/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js new file mode 100644 index 0000000..4c34e48 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js @@ -0,0 +1,111 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5267; +exports.ids = [5267]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 3360: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + success: false, + msg: "Failed" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ if (!fs.existsSync("./.tmp/error.log")) { + return res.json({ + success: true, + log: "No Logs Yet." + }); + } + const errorLogs = fs.readFileSync("./.tmp/error.log", "utf-8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + log: errorLogs + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(3360))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js.nft.json new file mode 100644 index 0000000..8a64a17 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabErrorLogs.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabFile.js b/dsql-app/.local_dist/server/pages/api/admin/grabFile.js new file mode 100644 index 0000000..9bddca3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabFile.js @@ -0,0 +1,114 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5736; +exports.ids = [5736]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 9411: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_0___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const { type , path } = req.body; + const dsqlUser = req.body.user; + if (!path?.match(/^\.\/jsonData\/dbSchemas\/users/)) { + return res.json({ + success: false, + msg: "Invalid Path" + }); + } + const sanitizedPath = path.replace(/\//g, "\\\\"); + let fileContent = fs.readFileSync(sanitizedPath, "utf-8"); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true, + data: fileContent + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(9411))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/grabFile.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/grabFile.js.nft.json new file mode 100644 index 0000000..8a64a17 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/grabFile.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js b/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js new file mode 100644 index 0000000..5981a9a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js @@ -0,0 +1,105 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2094; +exports.ids = [2094]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 9393: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Failed" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const { email , password , authKey } = req.body; + if (false) {} + if (false) {} + if (password !== process.env.DSQL_USER_KEY) return res.json({ + success: false + }); + if (authKey !== process.env.DSQL_SPECIAL_KEY) return res.json({ + success: false + }); + //////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ let encryptedPayload = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default()(JSON.stringify({ + email: email, + password: process.env.DSQL_USER_KEY, + authKey: process.env.DSQL_SPECIAL_KEY, + logged_in_status: true, + date: Date.now() + })); + res.setHeader("Set-Cookie", [ + `datasquirelSuAdminUserAuthKey=${encryptedPayload};samesite=strict;path=/;HttpOnly=true;Secure=true`, + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [3017,7547], () => (__webpack_exec__(9393))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js.nft.json new file mode 100644 index 0000000..7653835 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/loginSuUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/3017.js","../../../chunks/7547.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js b/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js new file mode 100644 index 0000000..0cc9d64 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js @@ -0,0 +1,165 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6750; +exports.ids = [6750]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4256: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ const { database , query } = req.body; + const dsqlUser = req.body.user; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const allowedQueryRegex = /^select .* from .*|^show tables$|^show indexes from .*|show columns from .*|^update |^delete from /i; + const disAllowedQueryRegex = /^create user|INFORMATION_SCHEMA/i; + if (!query?.match(allowedQueryRegex) || query?.match(disAllowedQueryRegex)) { + return res.json({ + success: false, + msg: "Disallowed query" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const result = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: database, + queryString: query + }); + if (!result) { + return res.json({ + success: false, + msg: "Query Failed!" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + result + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/runUserDbQuery/main-catch-error", + message: error.message + }); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311,4432], () => (__webpack_exec__(4256))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js.nft.json new file mode 100644 index 0000000..4eca290 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/runUserDbQuery.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/4432.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js b/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js new file mode 100644 index 0000000..817adb1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js @@ -0,0 +1,148 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1710; +exports.ids = [1710]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6520: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4432); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const { execSync } = __webpack_require__(2081); +const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Wrong Method" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const user = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_1___default()(req); + if (!user?.logged_in_status) { + return res.json({ + success: false, + log: "No Logs" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const envPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(process.cwd(), ".env"); + const envContent = fs.readFileSync(envPath, "utf-8"); + const envRegex = new RegExp(`${lodash__WEBPACK_IMPORTED_MODULE_2___default().escapeRegExp(req.body.key)}=.*`); + const envMatch = envContent.match(envRegex); + const newEnv = envContent.replace(envRegex, `${req.body.key}=${req.body.value}`); + fs.writeFileSync(envPath, newEnv, "utf-8"); + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + console.log("updating Env error =>", error.message); + res.json({ + success: false, + error: error.message + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,4432], () => (__webpack_exec__(6520))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js.nft.json b/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js.nft.json new file mode 100644 index 0000000..ae3d941 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/admin/updateEnv.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/4432.js","../../../../package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/lodash/lodash.js","../../../../../package.json","../../../../../.env"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js b/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js new file mode 100644 index 0000000..64f5872 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js @@ -0,0 +1,160 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5705; +exports.ids = [5705]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3509: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { userId , password , dbId } = req.body; + /** + * Input Validation + * + * @description Input Validation + */ try { + const validDbId = Boolean(String(dbId).match(/^\d+$/)); + const validUserId = Boolean(String(userId).match(/^\d+$/)); + const invalidPassword = Boolean(String(password).match(/ /)); + if (!validDbId || !validUserId) { + throw new Error("Invalud Parameters!"); + } + if (invalidPassword) { + throw new Error("Invalid Password!"); + } + const targetDb = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_databases WHERE id = ?`, [ + dbId + ]); + const dbFullName = targetDb?.[0]?.db_full_name; + const newPasswordHashed = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: password + }); + const updatePassword = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`UPDATE \`${dbFullName}\`.\`users\` SET password = ? WHERE id = ?`, [ + newPasswordHashed, + userId + ]); + res.json({ + success: true, + msg: "DB user Password Changed!" + }); + } catch (/** @type {any} */ error) { + res.json({ + success: false, + msg: error.message + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(3509))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js.nft.json b/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js.nft.json new file mode 100644 index 0000000..1f0f360 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/changeDbUserPassword.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js b/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js new file mode 100644 index 0000000..380b97e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js @@ -0,0 +1,129 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9976; +exports.ids = [9976]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2472: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + success: false, + msg: "Failed!" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const sanitizedReqBody = req.query; + const { type , value , tableName , dbFullName , userId , dbId , userType , database , } = sanitizedReqBody; + // if (!email.match(/.*@.*\..*/)) return res.json({ success: false, msg: "Invalid Email" }); + /** + * Add New Rating + * + * @description Check user verification status + */ let queryStr = `SELECT \`${type}\` FROM \`${tableName}\` WHERE \`${type}\`=?`; + let queryArray = [ + value + ]; + if (userId) { + queryStr += " AND user_id=?"; + queryArray.push(userId); + } + if (dbId) { + queryStr += " AND db_id=?"; + queryArray.push(dbId); + } + if (userType) { + queryStr += " AND user_type=?"; + queryArray.push(userType); + } + if (database) { + queryStr += " AND `database`=?"; + queryArray.push(database); + } + const duplicate = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + queryString: queryStr, + queryValuesArray: queryArray, + database: dbFullName && typeof dbFullName == "string" ? dbFullName.replace(/[^a-z0-9_]/g, "") : "datasquirel" + }); + /** + * Add New Rating + * + * @description Check user verification status + */ res.json({ + result: duplicate && duplicate[0] ? true : false + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,3017,3403,8326,1311], () => (__webpack_exec__(2472))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js.nft.json b/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js.nft.json new file mode 100644 index 0000000..437c6e8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/checkDuplicateData.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js b/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js new file mode 100644 index 0000000..ca12c60 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js @@ -0,0 +1,130 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2407; +exports.ids = [2407]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9668: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { name , folder } = req.query; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + return res.json({ + success: false, + msg: "No Static Path!" + }); + } + const folderPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(STATIC_ROOT, `images/user-images/user-${user.id}/${folder ? folder + "/" : ""}`); + const existingFolderPath = folderPath + name; + const doesFolderExist = fs.existsSync(existingFolderPath); + /** + * Send Response + * + * @description Send a boolean response + */ res.json({ + success: doesFolderExist + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(9668))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js.nft.json b/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/checkExistingFolder.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/clientSideAuth.js b/dsql-app/.local_dist/server/pages/api/clientSideAuth.js new file mode 100644 index 0000000..bf49d8c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/clientSideAuth.js @@ -0,0 +1,104 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 225; +exports.ids = [225]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8848: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + /** + * Send Response + * + * @description Send a boolean response + */ res.json({ + user + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(8848))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/clientSideAuth.js.nft.json b/dsql-app/.local_dist/server/pages/api/clientSideAuth.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/clientSideAuth.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect.js b/dsql-app/.local_dist/server/pages/api/connect.js new file mode 100644 index 0000000..337c4c1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect.js @@ -0,0 +1,140 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8607; +exports.ids = [8607]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8026: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + /** @type {{ url:string, key: string, database: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type, dbSchema: import("@/package-shared/types").DSQL_DatabaseSchemaType, type: "pull" | "push" }} */ const { url , key , database , dbSchema , type } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + const authorization = key; + if (!authorization) return res.json({ + success: false, + msg: "Unauthorized" + }); + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default()(authorization); + const remoteUser = userJSON ? JSON.parse(userJSON) : null; + const { user_id , full_access , csrf } = remoteUser; + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + const userSchemaPath = path__WEBPACK_IMPORTED_MODULE_2___default().resolve(process.cwd(), "jsonData/dbSchemas/users", `user-${user_id}`, "main.json"); + if (!fs.existsSync(userSchemaPath)) throw new Error("User Shcema data file doesn't exist!"); + const dbSchema1 = JSON.parse(fs.readFileSync(userSchemaPath, "utf-8")); + res.json({ + success: true, + payload: dbSchema1 + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("Connect Verification Error, =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/connect/main-catch-error", + message: error.message + }); + res.json({ + success: false, + msg: "Connect Verification Operation Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163], () => (__webpack_exec__(8026))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect.js.nft.json b/dsql-app/.local_dist/server/pages/api/connect.js.nft.json new file mode 100644 index 0000000..e40c9f6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2163.js","../../../package.json","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/disconnect.js b/dsql-app/.local_dist/server/pages/api/connect/disconnect.js new file mode 100644 index 0000000..3b841c5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/disconnect.js @@ -0,0 +1,179 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7160; +exports.ids = [7160]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7310: +/***/ ((module) => { + +module.exports = require("url"); + +/***/ }), + +/***/ 3837: +/***/ ((module) => { + +module.exports = require("util"); + +/***/ }), + +/***/ 7131: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const utils = __webpack_require__(3837); +const { URL } = __webpack_require__(7310); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbId } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + if (!dbId) throw new Error("No Target Database ID provided"); + /** + * User auth + * + * @description Authenticate user + */ const updateDb = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_2___default()({ + tableName: "user_databases", + data: { + remote_connected: 0, + remote_connection_host: "", + remote_connection_key: "", + remote_connection_type: "", + remote_db_full_name: "" + }, + identifierColumnName: "id", + identifierValue: dbId + }); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("Disconnect Error, =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/connect/verify/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Operation Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886], () => (__webpack_exec__(7131))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/disconnect.js.nft.json b/dsql-app/.local_dist/server/pages/api/connect/disconnect.js.nft.json new file mode 100644 index 0000000..72b22ce --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/disconnect.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/handshake.js b/dsql-app/.local_dist/server/pages/api/connect/handshake.js new file mode 100644 index 0000000..ba66cac --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/handshake.js @@ -0,0 +1,291 @@ +(() => { +var exports = {}; +exports.id = 9569; +exports.ids = [9569]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +"use strict"; +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +"use strict"; +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +"use strict"; +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +"use strict"; +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +"use strict"; +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +"use strict"; +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +"use strict"; +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +"use strict"; +module.exports = require("path"); + +/***/ }), + +/***/ 7310: +/***/ ((module) => { + +"use strict"; +module.exports = require("url"); + +/***/ }), + +/***/ 3837: +/***/ ((module) => { + +"use strict"; +module.exports = require("util"); + +/***/ }), + +/***/ 8518: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +var __webpack_unused_export__; +// @ts-check +const { execSync } = __webpack_require__(2081); +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +// const serverError = require("./serverError"); +/** + * @async + * @param {object} params + * @param {number | string} params.userId + * @param {DSQL_DatabaseSchemaType[]} params.dbSchema + * @param {string} [params.targetDb] - Eg `datasquirel_user_7_db_name` + * @returns {string} + */ const dbSchemaExec = ({ userId , dbSchema , targetDb })=>{ + const userSchemaPath = path.resolve(process.cwd(), "jsonData/dbSchemas/users", `user-${userId}`, "main.json"); + fs.writeFileSync(userSchemaPath, JSON.stringify(dbSchema), "utf-8"); + const targetPath = path.join(process.cwd(), "shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${userId}${targetDb ? " --database " + targetDb : ""}`, { + cwd: targetPath + }); + return `User ${userId} Db Schema Updated => ${dbShellUpdate.toString("utf-8")}`; +}; +/** + * @async + * @param {object} params + * @param {number | string} params.userId + * @param {DSQL_DatabaseSchemaType} params.dbSchema - New Db Schema for `targetDbFullName` variable + * @param {DSQL_MYSQL_user_databases_Type} params.database - Db entry + * @returns {string} + */ const dbSchemaExecDbUpdate = ({ userId , dbSchema , database })=>{ + const userSchemaPath = path.resolve(process.cwd(), "jsonData/dbSchemas/users", `user-${userId}`, "main.json"); + /** @type {DSQL_DatabaseSchemaType[]} */ let userDbSchema = JSON.parse(fs.readFileSync(userSchemaPath, "utf-8")); + const targetDbIndex = userDbSchema.findIndex((db)=>db.dbFullName == database.db_full_name); + if (targetDbIndex < 0) { + throw new Error("Target Database not found in user schema data"); + } + const targetDb = { + ...userDbSchema[targetDbIndex] + }; + userDbSchema[targetDbIndex] = dbSchema; + userDbSchema[targetDbIndex].dbName = targetDb.dbName; + userDbSchema[targetDbIndex].dbFullName = targetDb.dbFullName; + userDbSchema[targetDbIndex].dbSlug = targetDb.dbSlug; + userDbSchema[targetDbIndex].dbImage = targetDb.dbImage; + return dbSchemaExec({ + dbSchema: userDbSchema, + userId, + targetDb: database.db_full_name + }); +}; +__webpack_unused_export__ = dbSchemaExec; +exports.H = dbSchemaExecDbUpdate; + + +/***/ }), + +/***/ 2917: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_dbSchemaExec__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8518); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const utils = __webpack_require__(3837); +const { URL } = __webpack_require__(7310); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + /** @type {import("@/package-shared/types").DbConnectType} */ const { url , key , database , dbSchema , type , remoteDbs , targetDb } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + if (!targetDb?.tables) throw new Error("No Target Database"); + /** + * User auth + * + * @description Authenticate user + */ const updateDb = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + tableName: "user_databases", + // /** @type {DSQL_MYSQL_user_databases_Type} */ + data: { + remote_connected: 1, + remote_connection_host: url, + remote_connection_key: key, + remote_connection_type: type, + remote_db_full_name: targetDb.dbFullName + }, + identifierColumnName: "db_full_name", + identifierValue: database.db_full_name + }); + const update = (0,_functions_backend_dbSchemaExec__WEBPACK_IMPORTED_MODULE_0__/* .dbSchemaExecDbUpdate */ .H)({ + dbSchema: targetDb, + database: database, + userId: user.id + }); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("Connect Handshake Error, =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/connect/verify/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Operation Failed!" + }); + //////////////////////////////////////// + } +} // const userSchemaPath = path.resolve( + // process.cwd(), + // "jsonData/dbSchemas/users", + // `user-${user.id}`, + // "main.json" + // ); + // if (!fs.existsSync(userSchemaPath)) + // throw new Error("User Shcema data file doesn't exist!"); + // /** @type {DSQL_DatabaseSchemaType[]} */ + // let userDbSchema = JSON.parse(fs.readFileSync(userSchemaPath, "utf-8")); + // const targetDbIndex = userDbSchema.findIndex( + // (db) => db.dbFullName == dbSchema?.dbFullName + // ); + // if (targetDbIndex < 0) + // throw new Error( + // "Target Database for handshake not found in user schema data" + // ); + // userDbSchema[targetDbIndex] = targetDb; + // userDbSchema[targetDbIndex].dbName = dbSchema.dbName; + // userDbSchema[targetDbIndex].dbFullName = dbSchema.dbFullName; + // userDbSchema[targetDbIndex].dbSlug = dbSchema.dbSlug; + // userDbSchema[targetDbIndex].dbDescription = dbSchema.dbDescription; + // userDbSchema[targetDbIndex].dbImage = dbSchema.dbImage; + // fs.writeFileSync(userSchemaPath, JSON.stringify(userDbSchema), "utf-8"); + // const targetPath = path.join(process.cwd(), "shell"); + // const dbShellUpdate = execSync( + // `node createDbFromSchema.js --user ${user.id}`, + // { cwd: targetPath } + // ); + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886], () => (__webpack_exec__(2917))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/handshake.js.nft.json b/dsql-app/.local_dist/server/pages/api/connect/handshake.js.nft.json new file mode 100644 index 0000000..b45480b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/handshake.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json","../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../../shell/checkDb.js","../../../../../shell/createDbFromSchema.js","../../../../../shell/encodingUpdate.js","../../../../../shell/deploy.js","../../../../../shell/grantFullPriviledges.js","../../../../../shell/lessWatch.js","../../../../../shell/readImage.js","../../../../../shell/recoverMainJsonFromDb.js","../../../../../shell/resetSQLCredentials.js","../../../../../shell/resetSQLCredentialsPasswords.js","../../../../../shell/setSQLCredentials.js","../../../../../shell/tailwindWatch.js","../../../../../shell/test-external-server.js","../../../../../shell/test.js","../../../../../shell/testSQLEscape.js","../../../../../shell/updateChildrenTablesOnDb.js","../../../../../shell/updateDateTimestamps.js","../../../../../shell/updateDbSlugsForTableRecords.js","../../../../../shell/updateSSLUsers.js","../../../../../shell/utils/createTable.js","../../../../../shell/utils/dbHandler.js","../../../../../shell/utils/generateColumnDescription.js","../../../../../shell/utils/noDatabaseDbHandler.js","../../../../../shell/utils/supplementTable.js","../../../../../shell/utils/updateTable.js","../../../../../shell/utils/varDatabaseDbHandler.js","../../../../../shell/functions/jsonToBase64.js","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/verify.js b/dsql-app/.local_dist/server/pages/api/connect/verify.js new file mode 100644 index 0000000..a9fa9a8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/verify.js @@ -0,0 +1,188 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2519; +exports.ids = [2519]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 5687: +/***/ ((module) => { + +module.exports = require("https"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7310: +/***/ ((module) => { + +module.exports = require("url"); + +/***/ }), + +/***/ 3837: +/***/ ((module) => { + +module.exports = require("util"); + +/***/ }), + +/***/ 7034: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_httpsRequest__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(722); +/* harmony import */ var _functions_backend_httpsRequest__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_httpsRequest__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const utils = __webpack_require__(3837); +const { URL } = __webpack_require__(7310); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + /** @type {{ url:string, key: string, database: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type, dbSchema: import("@/package-shared/types").DSQL_DatabaseSchemaType, type: "pull" | "push" }} */ const { url , key , database , dbSchema , type } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const REMOTE_URL = new URL(url); + const { hostname , port , protocol } = REMOTE_URL; + const pingBody = { + url, + key + }; + const pingRemote = await _functions_backend_httpsRequest__WEBPACK_IMPORTED_MODULE_0___default()({ + scheme: protocol, + headers: { + Authorization: key + }, + hostname: hostname, + port: port, + path: "/api/connect", + method: "POST", + body: pingBody + }); + const resultObject = JSON.parse(pingRemote); + if (!resultObject?.success) { + throw new Error(resultObject.msg || "Remote request failed"); + } + res.json({ + success: true, + payload: resultObject.payload + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("Connect Verification Initialtor Error, =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/connect/verify/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Operation Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,722], () => (__webpack_exec__(7034))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/connect/verify.js.nft.json b/dsql-app/.local_dist/server/pages/api/connect/verify.js.nft.json new file mode 100644 index 0000000..31e3ca3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/connect/verify.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../chunks/722.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/contact.js b/dsql-app/.local_dist/server/pages/api/contact.js new file mode 100644 index 0000000..046e2e4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/contact.js @@ -0,0 +1,123 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2091; +exports.ids = [2091]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 7221: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { name , email , message } = sanitizedReqBody; + if (!email.match(/.*@.*\..*/)) return res.json({ + success: false, + msg: "Invalid Email" + }); + if (!name.match(/./) || !message.match(/./)) return res.json({ + success: false, + msg: "Please Fill in all Fields" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const mail = await _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default()({ + to: "benoti.san@gmail.com", + html: ` + <h2>Message From ${name}, ${email}</h2> + <p>${message}</p> + `, + subject: "Contact Form Submission", + text: `Message from ${name}, ${email}` + }); + //////////////////////////////////////// + if (mail.messageId) { + res.json({ + success: true + }); + } else { + res.json({ + success: false, + msg: "Message Sending Failed" + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/contact/main-catch-error", + message: error.message + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2163,6926], () => (__webpack_exec__(7221))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/contact.js.nft.json b/dsql-app/.local_dist/server/pages/api/contact.js.nft.json new file mode 100644 index 0000000..ad2702b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/contact.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/2163.js","../../chunks/6926.js","../../../package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/createUserDatabase.js b/dsql-app/.local_dist/server/pages/api/createUserDatabase.js new file mode 100644 index 0000000..48c3b57 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/createUserDatabase.js @@ -0,0 +1,301 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2316; +exports.ids = [2316]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4577: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9132); +/* harmony import */ var _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const fullUserArray = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM users WHERE id = ?`, [ + user.id, + ]); + const fullUser = fullUserArray?.[0]; + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { db_name , db_slug , db_description , db_image , duplicate , keepUpdated , keepDataUpdated , } = sanitizedReqBody; + if (db_slug.match(/[^a-zA-Z0-9-_]/)) { + return res.json({ + success: false, + msg: "Input Error" + }); + } + const db_full_name = `datasquirel_user_${user.id}_${db_slug}`; + const createDatabaseForUser = await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()(`CREATE DATABASE IF NOT EXISTS \`${db_full_name}\` CHARACTER SET utf8mb4 COLLATE utf8mb4_bin`); + /** + * User auth + * + * @description Authenticate user + */ if (!createDatabaseForUser?.affectedRows) { + return res.json({ + success: false, + msg: "Database Could Not be created!" + }); + } + /** @type {any} */ let newDbData = { + user_id: user.id, + db_name, + db_slug, + db_full_name, + db_description, + db_image + }; + if (duplicate && keepUpdated) { + newDbData["active_clone"] = "1"; + newDbData["active_clone_parent_db"] = duplicate; + } + if (duplicate && keepDataUpdated) { + newDbData["active_data"] = "1"; + } + const newDatabaseEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "user_databases", + data: newDbData + }); + /** + * Send Response + * + * @description Send a boolean response + */ if (newDatabaseEntry.insertId) { + try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + /** @type {any} */ let newDbSchemaObject = { + dbName: db_name, + dbSlug: db_slug, + dbFullName: db_full_name, + dbDescription: db_description, + dbImage: db_image, + tables: [] + }; + if (duplicate) { + try { + const parentDatabase = userSchemaData.filter((db)=>db.dbFullName === duplicate)[0]; + newDbSchemaObject.tables = parentDatabase.tables; + if (keepUpdated) { + newDbSchemaObject["childDatabase"] = true; + newDbSchemaObject["childDatabaseDbFullName"] = duplicate; + if (keepDataUpdated) newDbSchemaObject["updateData"] = true; + if (parentDatabase.childrenDatabases) { + parentDatabase.childrenDatabases.push({ + dbFullName: db_full_name + }); + } else { + parentDatabase.childrenDatabases = [ + { + dbFullName: db_full_name + }, + ]; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + for(let i = 0; i < newDbSchemaObject.tables.length; i++){ + const newDbTable = newDbSchemaObject.tables[i]; + const newDbTableRecord = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: user.id, + db_id: newDatabaseEntry.insertId, + db_slug: db_slug, + table_name: newDbTable.tableFullName, + table_slug: newDbTable.tableName + } + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/createUserDatabase/lines-117-159", + message: error.message, + user: user + }); + } + } + userSchemaData.push(newDbSchemaObject); + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + if (duplicate) { + const targetPath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${user.id} --database ${db_full_name}`, { + cwd: targetPath + }); + } + //////////////////////////////////////// + const grantDbPriviledges = await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()(`GRANT ALL PRIVILEGES ON ${db_full_name}.* TO '${process.env.DSQL_DB_FULL_ACCESS_USERNAME}'@'${process.env.DSQL_DB_TARGET_IP_ADDRESS || "%"}' WITH GRANT OPTION`); + if (grantDbPriviledges.error) { + throw new Error(grantDbPriviledges.error); + } + const grantRead = await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()(`GRANT SELECT ON ${db_full_name}.* TO '${process.env.DSQL_DB_READ_ONLY_USERNAME}'@'${process.env.DSQL_DB_TARGET_IP_ADDRESS || "%"}'`); + if (grantRead.error) { + throw new Error(grantRead.error); + } + if (fullUser?.mariadb_user && fullUser?.mariadb_pass) { + const grantDbPriviledgesToSqlUser = await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()(`GRANT ALL PRIVILEGES ON ${db_full_name}.* TO '${fullUser.mariadb_user}'@'${fullUser.mariadb_host}'`); + } + await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()(`FLUSH PRIVILEGES`); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/createUserDatabase/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } + } else { + res.json({ + success: false, + msg: "Database Could Not Be Recorded!" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,7487,9132], () => (__webpack_exec__(4577))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/createUserDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/createUserDatabase.js.nft.json new file mode 100644 index 0000000..77c7c7e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/createUserDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/7487.js","../../chunks/9132.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteApiKey.js b/dsql-app/.local_dist/server/pages/api/deleteApiKey.js new file mode 100644 index 0000000..b019fe1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteApiKey.js @@ -0,0 +1,188 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6209; +exports.ids = [6209]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 537: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + console.log("User", user); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { id , key , user_id } = req.body; + /** + * Send Response + * + * @description Send a boolean response + */ try { + const allowedKeysPath = process.env.DSQL_API_KEYS_PATH; + if (!allowedKeysPath) throw new Error("process.env.DSQL_API_KEYS_PATH variable not found"); + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_5___default()({ + key: key + }); + if (!apiCred?.sign) { + await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4___default()({ + dbFullName: "datasquirel", + tableName: "api_keys", + identifierColumnName: "id", + identifierValue: id + }); + throw new Error("API KEY is Invalid"); + } + try { + fs.unlinkSync(`${allowedKeysPath}/${apiCred?.sign}`); + } catch (/** @type {any} */ error) { + console.log("Error Deleting API key", error.message); + } + /** + * Delete API key from database + */ await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4___default()({ + dbFullName: "datasquirel", + tableName: "api_keys", + identifierColumnName: "id", + identifierValue: id + }); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteApiKey/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Deletion Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,1007,6147], () => (__webpack_exec__(537))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteApiKey.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteApiKey.js.nft.json new file mode 100644 index 0000000..4a02dd6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteApiKey.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/1007.js","../../chunks/6147.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteDbUser.js b/dsql-app/.local_dist/server/pages/api/deleteDbUser.js new file mode 100644 index 0000000..d35a6b8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteDbUser.js @@ -0,0 +1,127 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5395; +exports.ids = [5395]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8511: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Input Validation + * + * @description Input Validation + */ const sanitizedReqBody = req.body; + const { dbFullName , userId } = sanitizedReqBody; + const deleteUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: dbFullName, + queryString: `DELETE FROM users WHERE id = ?`, + queryValuesArray: [ + userId + ] + }); + res.json({ + success: true, + msg: "User Deleted!" + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,8326,1311], () => (__webpack_exec__(8511))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteDbUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteDbUser.js.nft.json new file mode 100644 index 0000000..7481b5c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteDbUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteInvitation.js b/dsql-app/.local_dist/server/pages/api/deleteInvitation.js new file mode 100644 index 0000000..46d9684 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteInvitation.js @@ -0,0 +1,120 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 593; +exports.ids = [593]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9043: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const deletInvitation = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM invitations WHERE id = ? AND inviting_user_id = ?`, [ + req.body.id, + user.id + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(9043))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteInvitation.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteInvitation.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteInvitation.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js b/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js new file mode 100644 index 0000000..45c8329 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js @@ -0,0 +1,193 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 820; +exports.ids = [820]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2562: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { folder } = sanitizedReqBody; + try { + /** + * ### Clean Target Folder + * @param {object} params + * @param {string} params.path + */ async function cleanFolder({ path }) { + try { + const folderFiles = fs.readdirSync(path); + for(let i = 0; i < folderFiles.length; i++){ + const fileName = folderFiles[i]; + if (!fileName.match(/\..{3,4}$/)) { + await cleanFolder({ + path: path + fileName + "/" + }); + continue; + } + const targetFolder = path.replace(/.*user-images\/user-\d+\/|.*jsonData\/dbSchemas\/users\/user-\d+\/media\//, "").replace(/\/+$/, ""); + const targetMediaInDb = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_media WHERE folder=? && media_url LIKE '%${fileName}'`, [ + targetFolder + ]); + if (targetMediaInDb && targetMediaInDb[0]) { + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_media WHERE id = ?`, [ + targetMediaInDb[0].id + ]); + } + try { + fs.unlinkSync(path + fileName); + } catch (error1) { + try { + fs.rmdirSync(path + fileName); + } catch (error) {} + } + } + fs.rmdirSync(path); + } catch (/** @type {any} */ error2) { + console.log("File cleaning error =>", error2.message); + } + } + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const folderPath = path__WEBPACK_IMPORTED_MODULE_3___default().join(STATIC_ROOT, `images/user-images/user-${user.id}/`); + const privateFolderPath = `./jsonData/dbSchemas/users/user-${user.id}/media/`; + const fullFolderPath = folderPath + (folder ? folder.replace(/\.| /g, "") + "/" : ""); + const fullPrivateFolderPath = privateFolderPath + (folder ? folder.replace(/\.| /g, "") + "/" : ""); + await cleanFolder({ + path: fullFolderPath + }); + await cleanFolder({ + path: fullPrivateFolderPath + }); + /** + * Send Response + * + * @description Send a boolean response + */ res.json({ + success: true + }); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteMediaFolder/main-catch-error", + message: error.message, + user: user + }); + /** + * Send Error Response + * + * @description Send a boolean response + */ res.json({ + success: false + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(2562))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js.nft.json new file mode 100644 index 0000000..ebf4a9f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteMediaFolder.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js b/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js new file mode 100644 index 0000000..9e4a9ad --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js @@ -0,0 +1,180 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9745; +exports.ids = [9745]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6970: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8999); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbFullName , tableName , entryId , dbSlug , dbId , delegated } = sanitizedReqBody; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default()({ + databaseSlug: dbSlug, + request: req, + user: user, + query: req.query + }); + const checkUserRightsBoolean = await _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default()({ + user: user, + confirmedDelegetedUser: delegatedUser, + database: dbSlug, + table: tableName, + dbId: dbId, + priviledgeRegex: /Delete Entries/i + }); + if (!checkUserRightsBoolean) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const deleteTableEntry = await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: tableName, + identifierColumnName: "id", + identifierValue: entryId + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/deleteTableEntry/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Deletion Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3403,1352,6147,8999], () => (__webpack_exec__(6970))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js.nft.json new file mode 100644 index 0000000..1cddd3b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteTableEntry.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3403.js","../../chunks/1352.js","../../chunks/6147.js","../../chunks/8999.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUser.js b/dsql-app/.local_dist/server/pages/api/deleteUser.js new file mode 100644 index 0000000..a8d8409 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUser.js @@ -0,0 +1,265 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4739; +exports.ids = [4739]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4512: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {{ + * rootFolderPath: string, + * }} params - params + * + * @returns {boolean} operation successful or not + */ module.exports = function deleteFolderRecursively({ rootFolderPath }) { + try { + /** + * Recursive Copy Function + * + * @description Recursive Copy Function + * @param {string} srcPath + */ function deleteFiles(srcPath) { + try { + const files = fs.readdirSync(srcPath); + for(let i = 0; i < files.length; i++){ + const file = files[i]; + if (file?.match(/\..{2,5}$/)) { + fs.unlinkSync(`${srcPath}/${file}`); + } else { + deleteFiles(`${srcPath}/${file}`); + } + } + fs.rmdirSync(`${srcPath}`); + } catch (error) { + try { + fs.unlinkSync(srcPath); + } catch (err) {} + } + } + deleteFiles(rootFolderPath); + fs.rmSync(`${rootFolderPath}`, { + recursive: true, + force: true + }); + return true; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log("ERROR in deleteFolderRecursively.js function =>", error.message); + return false; + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }), + +/***/ 3456: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_deleteFolderRecursively__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4512); +/* harmony import */ var _functions_backend_deleteFolderRecursively__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_deleteFolderRecursively__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const isProduction = "production".match(/prod/i); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const deleteUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM users WHERE id='${user.id}'`); + const deleteUserUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_users WHERE invited_user_id='${user.id}' OR user_id='${user.id}'`); + const deleteDelegatedUserTables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM delegated_user_tables WHERE delegated_user_id='${user.id}' OR root_user_id='${user.id}'`); + const deleteUserDatabases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_databases WHERE user_id='${user.id}'`); + const deleteUserDatabaseTables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_database_tables WHERE user_id='${user.id}'`); + const deleteUserMedia = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_media WHERE user_id='${user.id}'`); + const deleteDelegatedUsers = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM delegated_users WHERE user_id='${user.id}' OR delegated_user_id='${user.id}'`); + const deleteUnsubscribes = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM unsubscribes WHERE user_id='${user.id}'`); + const deleteNotifications = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM notifications WHERE user_id='${user.id}'`); + const deleteApiKeys = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM api_keys WHERE user_id='${user.id}'`); + const deleteInvitations = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM invitations WHERE inviting_user_id='${user.id}' OR invited_user_email='${user.email}'`); + const mariadbUsersArray = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM mariadb_users WHERE user_id = ?`, [ + user.id + ]); + for(let i = 0; i < mariadbUsersArray.length; i++){ + const mariadbUser = mariadbUsersArray[i]; + const { username , host } = mariadbUser; + const deleteMariadbUsers = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DROP USER IF EXISTS '${username}'@'${host}'`); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const userDatabases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SHOW databases LIKE 'datasquirel_user_${user.id}_%'`); + for(let i1 = 0; i1 < userDatabases.length; i1++){ + const dbObj = userDatabases[i1]; + const dbName = Object.values(dbObj); + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DROP database IF EXISTS ${dbName}`); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + const userSchemaPath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + if (fs.existsSync(userSchemaPath)) fs.unlinkSync(userSchemaPath); + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const userMediaFolder = path.join(STATIC_ROOT, `images/user-images/user-${user.id}`); + if (fs.existsSync(userMediaFolder)) _functions_backend_deleteFolderRecursively__WEBPACK_IMPORTED_MODULE_1___default()({ + rootFolderPath: userMediaFolder + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/addApiKey/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "User could not be deleted!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(3456))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteUser.js.nft.json new file mode 100644 index 0000000..ebf4a9f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js b/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js new file mode 100644 index 0000000..91abd5d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js @@ -0,0 +1,170 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8937; +exports.ids = [8937]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2005: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9132); +/* harmony import */ var _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { id , db_slug , db_full_name } = sanitizedReqBody; + if (!db_full_name.match(`user_${user.id}_`)) { + throw new Error("Database doesn't belong to user"); + } + await _package_shared_functions_backend_noDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()(`DROP DATABASE \`${db_full_name}\``); + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_databases WHERE id = ?`, [ + id + ]); + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_users WHERE user_id = ? AND \`database\` = ?`, [ + user.id, + db_slug + ]); + try { + /** + * Send Response + * + * @description Send a boolean response + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + /** @type {any} */ let targetDatabaseIndex; + let targetDatabase = userSchemaData.filter((databaseObject, index)=>{ + if (databaseObject.dbFullName === db_full_name) { + targetDatabaseIndex = index; + return true; + } + }); + if (targetDatabase[0].childDatabase) { + const parentDb = userSchemaData.filter((db)=>db.dbFullName === targetDatabase[0].childDatabaseDbFullName)[0]; + const targetChildIndex = parentDb.childrenDatabases?.findIndex((val)=>val.dbFullName === targetDatabase[0].childDatabaseDbFullName); + if (parentDb.childrenDatabases && typeof targetChildIndex == "number") { + parentDb.childrenDatabases.splice(targetChildIndex, 1); + } + } + userSchemaData.splice(targetDatabaseIndex, 1); + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteUserDatabase/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "File Updates Failed" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,7487,9132], () => (__webpack_exec__(2005))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js.nft.json new file mode 100644 index 0000000..21db82a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/7487.js","../../chunks/9132.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js b/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js new file mode 100644 index 0000000..64d0c8a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js @@ -0,0 +1,185 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 551; +exports.ids = [551]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4316: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6715); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const mediaObject = req.body; + const { media_name , media_url , media_thumbnail_url , media_path , media_thumbnail_path , folder , } = mediaObject; + const isProduction = "production".match(/production/); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const isPrivate = mediaObject?.private == 1 ? true : false; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const grabedPaths = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_3___default()({ + isPrivate: isPrivate, + user: user, + folder: mediaObject.folder ? mediaObject.folder + "/" : "", + video: mediaObject.media_type?.match(/video/i) ? true : false + }); + if (!grabedPaths) { + throw new Error("Couldn't grab paths!"); + } + const { fileRootPath , urlRootPath , relativePath } = grabedPaths; + const rootFolder = fileRootPath; + const mediaFolder = folder?.match(/./) ? "/" + folder + "/" : "/"; + const fileName = media_url.match(/[^\/]+$/)[0]; + const fileThumbnailName = media_thumbnail_url.match(/[^\/]+$/)[0]; + const filePath = path__WEBPACK_IMPORTED_MODULE_0___default().normalize(rootFolder + fileName); + const fileThumbnailPath = path__WEBPACK_IMPORTED_MODULE_0___default().normalize(rootFolder + fileThumbnailName); + fs.unlinkSync(filePath); + try { + fs.unlinkSync(fileThumbnailPath); + } catch (error) { + // console.log("ERROR in deleting user media =>", error.message); + } + await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_4___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + identifierColumnName: "id", + identifierValue: mediaObject.id + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + console.log("ERROR in deleting user media =>", error1.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteUserMedia/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3403,6147,6715], () => (__webpack_exec__(4316))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js.nft.json new file mode 100644 index 0000000..1e10c85 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3403.js","../../chunks/6147.js","../../chunks/6715.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserTable.js b/dsql-app/.local_dist/server/pages/api/deleteUserTable.js new file mode 100644 index 0000000..a47e675 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserTable.js @@ -0,0 +1,218 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 590; +exports.ids = [590]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6772: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { id , user_id , table_name , table_slug , table_description } = sanitizedReqBody.table; + const { db_full_name } = sanitizedReqBody.database; + await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: db_full_name, + queryString: `DROP TABLE \`${table_slug}\`` + }); + const deleteTableQuery = id ? `DELETE FROM user_database_tables WHERE id=?` : `DELETE FROM user_database_tables WHERE table_slug=? AND user_id=? AND db_id=?`; + const deleteTableQueryValues = id ? [ + id + ] : [ + table_slug, + user.id, + sanitizedReqBody.database.id + ]; + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(deleteTableQuery, deleteTableQueryValues); + try { + /** + * Send Response + * + * @description Send a boolean response + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + let targetDatabaseIndex; + let targetDatabase = userSchemaData.filter((databaseObject, index)=>{ + if (databaseObject.dbFullName === db_full_name) { + targetDatabaseIndex = index; + return true; + } + }); + /** @type {any} */ let targetTableIndex; + let targetTable = targetDatabase[0].tables.filter((tableObject, index)=>{ + if (tableObject?.tableName === table_slug) { + targetTableIndex = index; + return true; + } + }); + if (targetTable[0].childTable) { + const parentDb = userSchemaData.filter((db)=>db.dbFullName === targetTable[0].childTableDbFullName)[0]; + const parentTableObject = parentDb.tables.filter((table)=>{ + if (table.tableName === targetTable[0].childTableName) { + return true; + } + })[0]; + let targetChildIndex; + const parentTableChildObject = parentTableObject.childrenTables?.filter((childTable, index)=>{ + if (childTable.tableName === table_slug) { + targetChildIndex = index; + } + }); + if (typeof targetChildIndex === "number") parentTableObject.childrenTables?.splice(targetChildIndex, 1); + } + targetDatabase[0].tables.splice(targetTableIndex, 1); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Check Children Databases + * + * @description Check Children Databases + */ if (targetDatabase[0].childrenDatabases) { + for(let i = 0; i < targetDatabase[0].childrenDatabases.length; i++){ + const childDb = targetDatabase[0].childrenDatabases[i]; + try { + const targetChild = userSchemaData.filter((db)=>db.dbFullName === childDb.dbFullName)[0]; + targetChild.tables = targetDatabase[0].tables; + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`DELETE FROM user_database_tables WHERE table_slug=? AND user_id=? AND db_slug=?`, [ + table_slug, + user.id, + targetChild.dbSlug + ]); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteUserTable/lines-125-128", + message: error.message, + user: user + }); + } + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/deleteUserTable/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "File Updates Failed" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311], () => (__webpack_exec__(6772))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserTable.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteUserTable.js.nft.json new file mode 100644 index 0000000..a32b390 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserTable.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserUser.js b/dsql-app/.local_dist/server/pages/api/deleteUserUser.js new file mode 100644 index 0000000..82805a2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserUser.js @@ -0,0 +1,134 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3857; +exports.ids = [3857]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4229: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Input Validation + * + * @description Input Validation + */ const sanitizedReqBody = req.body; + const { user_type , user_id , email , invited_user_id } = sanitizedReqBody; + const deleteUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_users WHERE id=?`, [ + sanitizedReqBody.id, + ]); + if (user_type?.match(/admin/i)) { + const deleteUserInvitation = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + user.id, + email + ]); + const deleteUserDelegatedTables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM delegated_user_tables WHERE delegated_user_id=? AND root_user_id=?`, [ + invited_user_id, + user.id + ]); + } + // fs.unlinkSync() + res.json({ + success: true, + msg: "User Deleted!" + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(4229))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/deleteUserUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/deleteUserUser.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/deleteUserUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js b/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js new file mode 100644 index 0000000..d8ea71c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js @@ -0,0 +1,151 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7896; +exports.ids = [7896]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 711: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4194); +/* harmony import */ var _functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { dbName } = req.query; + /** + * Input Validation + * + * @description Input Validation + */ try { + const schemaPath = path.resolve(process.cwd(), "jsonData/dbSchemas/users", `user-${user.id}/main.json`); + if (!fs.existsSync(schemaPath)) { + return res.end(); + } + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const schemaData = JSON.parse(fs.readFileSync(schemaPath, "utf-8")); + const targetSchema = schemaData.find((schema)=>schema.dbFullName == dbName); + if (!targetSchema) throw new Error("Database not found!"); + const targetWritePath = path.resolve(process.cwd(), "./.tmp/_tmp.json"); + fs.writeFileSync(targetWritePath, JSON.stringify(targetSchema), "utf-8"); + const fileStream = fs.createReadStream(targetWritePath); + fileStream.pipe(res); + fileStream.on("close", ()=>{ + fs.unlinkSync(targetWritePath); + }); + } catch (error) { + console.log(error); + return res.end(); + } +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,4194], () => (__webpack_exec__(711))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js.nft.json b/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js.nft.json new file mode 100644 index 0000000..31f80ad --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/downloadDatabaseSchema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/4194.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/exportDatabase.js b/dsql-app/.local_dist/server/pages/api/exportDatabase.js new file mode 100644 index 0000000..a7e05c3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/exportDatabase.js @@ -0,0 +1,136 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9470; +exports.ids = [9470]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8507: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4194); +/* harmony import */ var _functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { dbName } = req.query; + /** + * Input Validation + * + * @description Input Validation + */ const file = await _functions_backend_exportDb__WEBPACK_IMPORTED_MODULE_0___default()({ + dbName: dbName?.toString() || "", + res: res, + user: user + }); +// res.json({ success: true, text: file }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,4194], () => (__webpack_exec__(8507))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/exportDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/exportDatabase.js.nft.json new file mode 100644 index 0000000..adfc491 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/exportDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/4194.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/exportTableData.js b/dsql-app/.local_dist/server/pages/api/exportTableData.js new file mode 100644 index 0000000..a867a2d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/exportTableData.js @@ -0,0 +1,162 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3368; +exports.ids = [3368]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5856: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_importExportTableDataFn__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2630); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +const config = { + api: { + responseLimit: "1mb", + bodyParser: { + sizeLimit: "200mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { paradigm , dbName , tableName , payload } = req.body; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + const exportData = await (0,_functions_backend_importExportTableDataFn__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z)({ + dbName, + paradigm, + payload, + tableName, + userId: user.id, + payloadType: "base64" + }); + if (!exportData) { + return res.json({ + success: false, + msg: "Operation Failed!" + }); + } + res.json({ + success: true, + msg: "Success!", + data: exportData?.tableData + }); + } catch (/** @type {any} */ error) { + res.json({ + success: false, + msg: error.message + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,2630], () => (__webpack_exec__(5856))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/exportTableData.js.nft.json b/dsql-app/.local_dist/server/pages/api/exportTableData.js.nft.json new file mode 100644 index 0000000..68b92fb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/exportTableData.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/2630.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js b/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js new file mode 100644 index 0000000..3e7991d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js @@ -0,0 +1,180 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8362; +exports.ids = [8362]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1118: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const checkUserRights = __webpack_require__(8999); +const grabDelegatedUserFromCookie = __webpack_require__(1352); +const serverError = __webpack_require__(2163); +const userAuth = __webpack_require__(6825); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} FetchEntriesBasicBody + * @property {string} tableName + * @property {string} dbSlug + * @property {number} dbId + * @property {boolean} [isTitle] + * @property {boolean} [isSlug] + * @property {boolean} [isFullName] + * @property {string} [defaultField] + */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await userAuth(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "User Auth Failed" + }); + } + /** + * User auth + * + * @description Authenticate user + */ /** @type {FetchEntriesBasicBody} */ const { tableName , dbSlug , dbId , isTitle , isSlug , isFullName , defaultField , } = req.body; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await grabDelegatedUserFromCookie({ + databaseSlug: dbSlug, + request: req, + user: user, + query: req.query + }); + const checkUserRightsBoolean = await checkUserRights({ + user: user, + confirmedDelegetedUser: delegatedUser, + database: dbSlug, + table: tableName, + dbId: dbId, + priviledgeRegex: /Update Entries/i + }); + if (!checkUserRightsBoolean) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const dbFullName = delegatedUser?.rootUserId ? `datasquirel_user_${delegatedUser.rootUserId}_${dbSlug}` : `datasquirel_user_${user.id}_${dbSlug}`; + const queryString = `SELECT id${isTitle ? ",title" : isSlug ? ",slug" : isFullName ? ",CONCAT(first_name, ' ', last_name) AS full_name" : defaultField ? "," + defaultField : ""} FROM ${tableName}`; + const entries = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: dbFullName, + queryString: queryString + }); + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ //////////////////////////////////////// + res.json({ + success: true, + entries + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + serverError({ + component: "/api/addTableEntry/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!", + err: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311,1352,8999], () => (__webpack_exec__(1118))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js.nft.json b/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js.nft.json new file mode 100644 index 0000000..a53f8cd --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/fetch-entries-basic.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../chunks/1352.js","../../chunks/8999.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js b/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js new file mode 100644 index 0000000..933bc57 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js @@ -0,0 +1,209 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7072; +exports.ids = [7072]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7840: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8164); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} SyncTableBodySrcDstObject + * @property {string} db + * @property {string} table + */ /** + * @typedef {object} SyncTableBody + * @property {"Pull" | "Push"} paradigm + * @property {SyncTableBodySrcDstObject} src + * @property {SyncTableBodySrcDstObject} dst + * @property {any} [delegated] + */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const dbUserId = req.query.dbUserId; + const delegated = req.query.delegated; + /** + * Send Response + * + * @description Send a boolean response + */ try { + if (!dbUserId) { + throw new Error("No Root user Id Found!"); + } + /** @type {import("@/package-shared/types").MYSQL_delegated_user_tables_table_def[]} */ const delegatedTables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_4___default()(`SELECT * FROM datasquirel.delegated_user_tables WHERE delegated_user_id=? AND root_user_id=?`, [ + String(user.id), + String(dbUserId) + ]); + const rootUserDbSchema = (0,_functions_backend_grabUserSchemaData__WEBPACK_IMPORTED_MODULE_0__["default"])({ + userId: String(dbUserId) + }); + if (!rootUserDbSchema) { + throw new Error("Root user schema not found!"); + } + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const filteredDbSchema = []; + delegatedTables.forEach((tblObj)=>{ + const existingDbIndex = filteredDbSchema.findIndex((db)=>db.dbSlug === tblObj.database); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ const targetDb = rootUserDbSchema.find((db)=>db.dbSlug === tblObj.database); + if (targetDb) { + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType} */ const finalDb = filteredDbSchema[existingDbIndex] ? filteredDbSchema[existingDbIndex] : { + ...targetDb, + tables: [] + }; + const targetDbTbls = lodash__WEBPACK_IMPORTED_MODULE_3___default().cloneDeep(targetDb.tables); + const targetTable = targetDbTbls.find((tbl)=>tbl.tableName === tblObj.table); + if (targetTable && filteredDbSchema[existingDbIndex]) { + filteredDbSchema[existingDbIndex] = { + ...finalDb, + tables: [ + ...filteredDbSchema[existingDbIndex].tables, + targetTable, + ] + }; + } else if (targetTable && !filteredDbSchema[existingDbIndex]) { + filteredDbSchema.push({ + ...targetDb, + tables: [ + targetTable + ] + }); + } + } + }); + //////////////////////////////////////// + res.json({ + success: true, + payload: filteredDbSchema + }); + } catch (/** @type {any} */ error) { + console.log("ERROR:", error.message); + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/get-authorized-databases", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,8164], () => (__webpack_exec__(7840))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js.nft.json b/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js.nft.json new file mode 100644 index 0000000..2237904 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/get-authorized-databases.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/8164.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js b/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js new file mode 100644 index 0000000..6485143 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js @@ -0,0 +1,163 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2747; +exports.ids = [2747]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3284: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ // const { dbSlug, dbOwnerId, delegatedUserId } = req.query; + const dbSlug = req.query.dbSlug; + const dbOwnerId = req.query.dbOwnerId; + const delegatedUserId = req.query.delegatedUserId; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const targetDbData = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT id FROM user_databases WHERE user_id=? AND db_slug=?`, [ + dbOwnerId, + dbSlug + ]); + if (!targetDbData || !targetDbData[0]) return res.json({ + success: false, + msg: "Database not found" + }); + const tables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT table_name,table_slug FROM user_database_tables WHERE user_id=? AND db_id=?`, [ + dbOwnerId, + targetDbData[0].id + ]); + const accessed_tables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`SELECT \`database\`,\`table\` FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=?`, [ + dbOwnerId, + delegatedUserId + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + tables: tables, + accessed_tables: accessed_tables + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/getDatabaseTables/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(3284))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js.nft.json b/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js.nft.json new file mode 100644 index 0000000..ebf4a9f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDatabaseTables.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js new file mode 100644 index 0000000..4ddb6db --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js @@ -0,0 +1,181 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1146; +exports.ids = [1146]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5989: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ // const { rootUserId, priviledges, database } = req.body; + const rootUserId = req.body.rootUserId; + const priviledges = req.body.priviledges; + const database = req.body.database; + /** + * Input Validation + * + * @description Input Validation + */ try { + const foundUserUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_users WHERE user_id=? AND invited_user_id=? AND MATCH(database_access) AGAINST(?)`, [ + rootUserId, + user.id, + database + ]); + if (!foundUserUser || !foundUserUser[0]) throw new Error(`user with id ${user.id} has no access to ${database} database belonging to user ${rootUserId}`); + const foundUserTables = (await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=? AND \`database\`=?`, [ + rootUserId, + user.id, + database + ])).map((/** @type {any} */ tableObject)=>{ + return tableObject.table; + }); + const rootUserinfo = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM users WHERE id=?`, [ + rootUserId + ]); + const payload = { + rootUserId: rootUserId, + rootUserName: `${rootUserinfo[0].first_name} ${rootUserinfo[0].last_name}`, + rootUserEmail: rootUserinfo[0].email, + rootUserImage: rootUserinfo[0].image_thumbnail, + delegatedUserId: user.id, + databaseFullName: `datasquirel_user_${rootUserId}_${database}`, + databaseSlug: database, + allowedTables: foundUserTables, + priviledges: priviledges, + dateCreated: Date.now() + }; + const encryptedPayload = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1___default()(JSON.stringify(payload)); + const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${payload.rootUserId}_${database}`; + const tokenName = `${process.env.DSQL_USER_DELEGATED_DB_COOKIE_PREFIX}${dbFullName}`; + res.setHeader("Set-Cookie", [ + `${tokenName}=${encryptedPayload};path=/`, + ]); + res.json({ + success: true, + msg: "Processed Successfully" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log("ERROR:", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/getDelegatedDatabaseToken/main-catch-error", + message: error.message, + user: user + }); + return res.json({ + success: false, + msg: "Unauthorized" + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,7547], () => (__webpack_exec__(5989))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js.nft.json b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js.nft.json new file mode 100644 index 0000000..9018219 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabaseToken.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/7547.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js new file mode 100644 index 0000000..bc223ef --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js @@ -0,0 +1,151 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4265; +exports.ids = [4265]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3990: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const delegetedDbAccess = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(` + SELECT + user_users.user_id,user_users.database_access,user_users.user_id,user_users.user_priviledge,users.first_name,users.last_name,users.email,users.image_thumbnail + FROM + user_users JOIN users ON user_users.user_id=users.id + WHERE + user_users.invited_user_id='${user.id}' + `); + let databasesArray = []; + if (delegetedDbAccess && delegetedDbAccess[0]) { + for(let i = 0; i < delegetedDbAccess.length; i++){ + const deleDbAccessObject = delegetedDbAccess[i]; + const { database_access , user_id , user_priviledge } = deleDbAccessObject; + if (!database_access?.match(/./)) continue; + const delegetedDbs = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_databases WHERE (${database_access.split("|").map((/** @type {string} */ db)=>`db_slug='${db}'`).join(" OR ")}) AND user_id=${user_id}`); + for(let j = 0; j < delegetedDbs.length; j++){ + const delegetedDb = delegetedDbs[j]; + databasesArray.push({ + id: delegetedDb.id, + user_id: deleDbAccessObject.user_id, + first_name: deleDbAccessObject.first_name, + last_name: deleDbAccessObject.last_name, + email: deleDbAccessObject.email, + image_thumbnail: deleDbAccessObject.image_thumbnail, + db_name: delegetedDb.db_name, + db_slug: delegetedDb.db_slug, + db_full_name: delegetedDb.db_full_name, + db_image: delegetedDb.db_image, + db_description: delegetedDb.db_description, + date_created: delegetedDb.date_created, + user_priviledge: user_priviledge + }); + } + } + } + //////////////////////////////////////// + res.json({ + success: true, + databases: databasesArray + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(3990))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js.nft.json b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDelegatedDatabases.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDiskUsage.js b/dsql-app/.local_dist/server/pages/api/getDiskUsage.js new file mode 100644 index 0000000..ffd3ce4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDiskUsage.js @@ -0,0 +1,236 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1659; +exports.ids = [1659]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7918: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const isProduction = "production".match(/production/); + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const diskUsageDb = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(` + SELECT table_schema, + SUM((data_length+index_length)/1024/1024) AS "mb" from + information_schema.tables + where table_schema like ? + group by table_schema + `, [ + `datasquirel_user_${user.id}%` + ]); + const totalDbDiskUsageInMb = diskUsageDb.reduce((/** @type {any} */ prev, /** @type {any} */ current, /** @type {Number} */ currentIndex)=>{ + if (prev?.mb) { + return prev.mb + current.mb; + } else { + return prev + current.mb; + } + }, 0); + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ let totalFileUsageInMb = 0; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + if (!STATIC_ROOT && !fs.existsSync(STATIC_ROOT)) { + fs.mkdirSync(STATIC_ROOT, { + recursive: true + }); + } + const USER_STATIC_DIR = path.join(STATIC_ROOT, `images/user-images/user-${user.id}`); + if (!fs.existsSync(USER_STATIC_DIR)) { + fs.mkdirSync(USER_STATIC_DIR, { + recursive: true + }); + } + const userMediaFilePath = path.join(STATIC_ROOT, `images/user-images/user-${user.id}`); + const userVideosPath = path.join(STATIC_ROOT, `videos/user-videos/user-${user.id}`); + if (!fs.existsSync(userVideosPath)) { + fs.mkdirSync(userVideosPath, { + recursive: true + }); + } + async function readFolders(/** @type {String} */ path) { + try { + const userMediaFiles = fs.readdirSync(path); + for(let i = 0; i < userMediaFiles.length; i++){ + const file = userMediaFiles[i]; + const fileFullPath = path + "/" + file; + if (!file.match(/\..{3,4}$/)) { + await readFolders(fileFullPath); + continue; + } + if (fs.existsSync(fileFullPath)) { + const fileSize = fs.statSync(fileFullPath); + totalFileUsageInMb += fileSize.size / 1024 / 1024; + } else { + const isProduction = "production".match(/production/); + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const userMediaUrl = fileFullPath.replace(STATIC_ROOT, process.env.DSQL_STATIC_HOST || ""); + const userMediaPath = fileFullPath.replace(STATIC_ROOT, ""); + const deleteMedia = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM user_media WHERE media_path = ? OR media_thumbnail_path = ? OR media_url=? OR media_thumbnail_url=?`, [ + userMediaPath, + userMediaPath, + userMediaUrl, + userMediaUrl, + ]); + console.log(`MEDIA => ${userMediaUrl} DELETED FROM DATABASE`); + } + } + } catch (/** @type {any} */ error) { + console.log("ERROR in getDiskUsage API route =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/getDiskUsage/lines-93-101", + message: error.message + }); + } + } + await readFolders(userMediaFilePath); + await readFolders(userVideosPath); + const totalUsageInMb = totalFileUsageInMb + totalDbDiskUsageInMb; + res.json({ + success: true, + total: totalUsageInMb + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/getDiskUsage/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Disk Usage Calculation Error!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(7918))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getDiskUsage.js.nft.json b/dsql-app/.local_dist/server/pages/api/getDiskUsage.js.nft.json new file mode 100644 index 0000000..ebf4a9f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getDiskUsage.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js b/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js new file mode 100644 index 0000000..0a1dbcc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js @@ -0,0 +1,130 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 399; +exports.ids = [399]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7500: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** # MODULE TRACE +====================================================================== + * No imports found for this Module +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const tables = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT id, table_name, table_slug FROM user_database_tables WHERE user_id='${user.id}' AND db_id='${req.query.dbId}'`); + //////////////////////////////////////// + res.json({ + success: true, + tables + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(7500))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js.nft.json b/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserDatabaseTables.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserDatabases.js b/dsql-app/.local_dist/server/pages/api/getUserDatabases.js new file mode 100644 index 0000000..cecf56f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserDatabases.js @@ -0,0 +1,130 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3167; +exports.ids = [3167]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4995: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** # MODULE TRACE +====================================================================== + * No imports found for this Module +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const databases = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT id,db_name,db_slug,db_full_name FROM user_databases WHERE user_id='${user.id}'`); + //////////////////////////////////////// + res.json({ + success: true, + databases + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(4995))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserDatabases.js.nft.json b/dsql-app/.local_dist/server/pages/api/getUserDatabases.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserDatabases.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserMedia.js b/dsql-app/.local_dist/server/pages/api/getUserMedia.js new file mode 100644 index 0000000..b73128c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserMedia.js @@ -0,0 +1,115 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1086; +exports.ids = [1086]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6692: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Fetch Media + * + * @description Fetch Media + */ const userMedia = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_media WHERE user_id=${user.id} ORDER BY id DESC`); + res.json({ + media: userMedia + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(6692))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/getUserMedia.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js b/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js new file mode 100644 index 0000000..c151d61 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js @@ -0,0 +1,149 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9226; +exports.ids = [9226]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9274: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ // const { delegated, dbSlug } = req.query; + // const delegatedUser = await grabDelegatedUserFromCookie({ + // request: req, + // user: user, + // databaseSlug: dbSlug, + // query: { delegated }, + // }); + // console.log("delegated =>", delegated); + // console.log(delegatedUser); + // const userId = delegatedUser?.rootUserId ? delegatedUser.rootUserId : user.id; + const userSchemaPath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + const userSchemaArray = JSON.parse(fs.readFileSync(userSchemaPath, "utf8")); + res.json({ + success: true, + schemaData: userSchemaArray + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/getUserSchemaData/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Couldn't read schema data" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,1352], () => (__webpack_exec__(9274))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js.nft.json b/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js.nft.json new file mode 100644 index 0000000..243c9a1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/getUserSchemaData.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/1352.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/healthcheck.js b/dsql-app/.local_dist/server/pages/api/healthcheck.js new file mode 100644 index 0000000..affc3fd --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/healthcheck.js @@ -0,0 +1,50 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8428; +exports.ids = [8428]; +exports.modules = { + +/***/ 9551: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + res.json({ + success: true + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = (__webpack_exec__(9551)); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/healthcheck.js.nft.json b/dsql-app/.local_dist/server/pages/api/healthcheck.js.nft.json new file mode 100644 index 0000000..b8438e2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/healthcheck.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../../package.json","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/importDatabase.js b/dsql-app/.local_dist/server/pages/api/importDatabase.js new file mode 100644 index 0000000..1949766 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/importDatabase.js @@ -0,0 +1,372 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2488; +exports.ids = [2488]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6345: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const varDatabaseDbHandler = __webpack_require__(1311); +const slugToCamelTitle = __webpack_require__(4885); +const { default: grabUserSchemaData } = __webpack_require__(8164); +const { default: setUserSchemaData } = __webpack_require__(7638); +const addDbEntry = __webpack_require__(5338); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Grab Schema + * + * @description Grab Schema + * + * @param {{ + * userId: number|string, + * database: import("@/package-shared/types").DSQL_MYSQL_user_databases_Type + * }} params + */ module.exports = async function createDbSchemaFromDb({ userId , database }) { + try { + if (!userId) { + console.log("No user Id provided"); + return; + } + /** + * Initialize + * + * @description Initialize + */ const userSchemaData = grabUserSchemaData({ + userId + }); + if (!userSchemaData) throw new Error("User schema data not found!"); + /** @type {{ tables: object[] }} */ const targetDb = userSchemaData.filter((dbObject)=>dbObject.dbFullName === database.db_full_name)[0]; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Add Tables + * + * @description Add Tables + */ const existingTables = await varDatabaseDbHandler({ + database: database.db_full_name, + queryString: `SHOW TABLES` + }); + if (!existingTables) throw new Error("No Existing Tables"); + for(let i = 0; i < existingTables.length; i++){ + const table = existingTables[i]; + const tableName = Object.values(table)[0]; + const tableInsert = await addDbEntry({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: userId, + db_id: database.id, + db_slug: database.db_slug, + table_name: slugToCamelTitle(tableName), + table_slug: tableName + } + }); + //////////////////////////////////////////////// + /** @type {import("@/package-shared/types").DSQL_TableSchemaType} */ const tableObject = { + tableName: tableName, + tableFullName: slugToCamelTitle(tableName) || "", + fields: [], + indexes: [] + }; + //////////////////////////////////////////////// + const tableColumns = await varDatabaseDbHandler({ + database: database.db_full_name, + queryString: `SHOW COLUMNS FROM ${tableName}` + }); + if (tableColumns) { + for(let k = 0; k < tableColumns.length; k++){ + const tableColumn = tableColumns[k]; + const { Field , Type , Null , Key , Default , Extra } = tableColumn; + /** @type {import("@/package-shared/types").DSQL_FieldSchemaType} */ const fieldObject = { + fieldName: Field, + dataType: Type.toUpperCase() + }; + if (Null?.match(/^no$/i)) fieldObject.notNullValue = true; + if (Key?.match(/^pri$/i)) fieldObject.primaryKey = true; + if (Default?.toString()?.match(/./)) fieldObject.defaultValue = Default; + if (Default?.toString()?.match(/timestamp/i)) { + delete fieldObject.defaultValue; + fieldObject.defaultValueLiteral = Default; + } + if (Extra?.toString()?.match(/auto_increment/i)) fieldObject.autoIncrement = true; + tableObject.fields.push(fieldObject); + } + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Add Indexes + * + * @description Add Indexes + */ const tableIndexes = await varDatabaseDbHandler({ + database: database.db_full_name, + queryString: `SHOW INDEXES FROM ${tableName}` + }); + if (tableIndexes) { + for(let m = 0; m < tableIndexes.length; m++){ + const indexObject = tableIndexes[m]; + const { Table , Key_name , Column_name , Null: Null1 , Index_type , Index_comment , } = indexObject; + //////////////////////////////////////////////// + if (!Index_comment?.match(/^schema_index$/)) continue; + //////////////////////////////////////////////// + /** @type {import("@/package-shared/types").DSQL_IndexSchemaType} */ const indexNewObject = { + indexType: Index_type?.match(/fulltext/i) ? "fullText" : "regular", + indexName: Key_name, + indexTableFields: [] + }; + const targetTableFieldObject = tableColumns?.filter((/** @type {any} */ col)=>col.Field === Column_name)[0]; + const existingIndexField = tableObject.indexes?.filter((indx)=>indx.indexName == Key_name); + if (existingIndexField && existingIndexField[0]) { + existingIndexField[0].indexTableFields?.push({ + value: Column_name, + dataType: targetTableFieldObject.Type.toUpperCase() + }); + } else { + //////////////////////////////////////////////// + indexNewObject.indexTableFields = [ + { + value: Column_name, + dataType: targetTableFieldObject.Type.toUpperCase() + }, + ]; + tableObject.indexes?.push(indexNewObject); + } + } + } + //////////////////////////////////////////////// + targetDb.tables.push(tableObject); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Update User Specific Database + * + * @description Update User Specific Database + */ setUserSchemaData({ + schemaData: userSchemaData, + userId + }); + return true; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (error) { + console.log(error); + return false; + } +}; + + +/***/ }), + +/***/ 2369: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_createDbSchemaFromDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6345); +/* harmony import */ var _functions_backend_createDbSchemaFromDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_createDbSchemaFromDb__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const os = __webpack_require__(2037); +const { execSync } = __webpack_require__(2081); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { database , fileBase64 } = sanitizedReqBody; + if (!database?.db_full_name?.match(/datasquirel_user_.*/)) { + res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const sqlName = `user-${user.id}-temp-sql`; + const mysqlPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysql.exe" + "'" : "mysql"; + fs.writeFileSync(`./.tmp/${sqlName}.sql`, fileBase64, "base64"); + /** @type {import("child_process").ExecOptions} */ let execSyncOptions = { + cwd: process.cwd() + }; + if (os.platform().match(/win/i)) execSyncOptions.shell = "bash.exe"; + const importToNewDb = execSync(`${mysqlPath} -u ${process.env.DSQL_DB_USERNAME} -p${process.env.DSQL_DB_PASSWORD} ${database.db_full_name} < .tmp/${sqlName}.sql`, execSyncOptions); + const updateSchema = await _functions_backend_createDbSchemaFromDb__WEBPACK_IMPORTED_MODULE_0___default()({ + database: database, + userId: user.id + }); + res.json({ + success: updateSchema ? true : false + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log(error); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/importDatabase/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Import Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }), + +/***/ 4885: +/***/ ((module) => { + +// @ts-check + +module.exports = function slugToCamelTitle(/** @type {String} */ text) { + if (text) { + let addArray = text.split("-").filter((item)=>item !== ""); + let camelArray = addArray.map((item)=>{ + return item.substr(0, 1).toUpperCase() + item.substr(1).toLowerCase(); + }); + let parsedAddress = camelArray.join(" "); + return parsedAddress; + } else { + return null; + } +}; + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,8326,1311,8164,7638], () => (__webpack_exec__(2369))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/importDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/importDatabase.js.nft.json new file mode 100644 index 0000000..90b2c7b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/importDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/8326.js","../../chunks/1311.js","../../chunks/8164.js","../../chunks/7638.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js b/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js new file mode 100644 index 0000000..a0ec37a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js @@ -0,0 +1,178 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2289; +exports.ids = [2289]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6779: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const os = __webpack_require__(2037); +const { execSync } = __webpack_require__(2081); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + /** @type { {database:import("@/package-shared/types").DSQL_MYSQL_user_databases_Type, fileBase64: string} } */ const { database , fileBase64 } = sanitizedReqBody; + if (!database?.db_full_name?.match(/datasquirel_user_.*/)) { + res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const dbSchemaJSON = Buffer.from(fileBase64, "base64").toString("utf-8"); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType} */ const dbSchema = JSON.parse(dbSchemaJSON); + const schemaPath = path.resolve(process.cwd(), "jsonData/dbSchemas/users", `user-${user.id}/main.json`); + if (!fs.existsSync(schemaPath)) { + return res.end(); + } + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const schemaData = JSON.parse(fs.readFileSync(schemaPath, "utf-8")); + const targetSchema = schemaData.find((schema)=>schema.dbFullName == database.db_full_name); + if (!targetSchema) throw new Error("Database not found!"); + targetSchema.tables = dbSchema.tables; + fs.writeFileSync(schemaPath, JSON.stringify(schemaData), "utf-8"); + const shellUpdatePath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${user.id} --database ${database.db_full_name}`, { + cwd: shellUpdatePath + }); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("JSON import ERROR =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/importDatabase/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Import Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(6779))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js.nft.json b/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js.nft.json new file mode 100644 index 0000000..022c77e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/importDatabaseSchema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/infiniteScroll.js b/dsql-app/.local_dist/server/pages/api/infiniteScroll.js new file mode 100644 index 0000000..0a24032 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/infiniteScroll.js @@ -0,0 +1,195 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5450; +exports.ids = [5450]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1090: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} InfiniteScrollBodyObject + * @property {string} dbName + * @property {import("@/package-shared/types").DSQL_TableSchemaType} tableSchema + * @property {string} tableName + * @property {number} page + * @property {boolean} delegated + * @property {string} [search] + * @property {string} [searchField] + */ /** + * @typedef {object} InfiniteScrollAPIRes + * @property {boolean} success + * @property {any[] | null} [data] + * @property {number} [page] + */ const BATCH_NO = 20; +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** @type {InfiniteScrollBodyObject} */ const body = req.body; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const delegatedUser = await _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_3___default()({ + databaseSlug: body.dbName, + request: req, + user: user, + query: req.query + }); + const finalUserId = delegatedUser ? delegatedUser?.rootUserId ? delegatedUser.rootUserId : delegatedUser.dbUserId : null; + if (!finalUserId) throw new Error("User not Found!"); + const dbNameFull = `datasquirel_user_${finalUserId}_${body.dbName}`; + const tableName = body.tableName; + const page = body.page; + const offset = BATCH_NO * page; + let query = `SELECT * FROM ${tableName}`; + let queryValues = []; + if (body.search && body.searchField) { + query += ` WHERE LOWER(\`${body.searchField.toLowerCase().replace(/ /g, "_")}\`) LIKE ?`; + queryValues.push(`%${body.search.toLowerCase()}%`); + } + query += ` ORDER BY id DESC LIMIT ${BATCH_NO} OFFSET ${offset}`; + const tableEntries = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_4___default()({ + database: dbNameFull, + queryString: query, + queryValuesArray: queryValues, + tableSchema: body.tableSchema + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** @type {InfiniteScrollAPIRes} */ const resObject = { + success: true, + data: tableEntries, + page: Number(page) + 1 + }; + res.json(resObject); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/infiniteScroll/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + data: null + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311,1352], () => (__webpack_exec__(1090))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/infiniteScroll.js.nft.json b/dsql-app/.local_dist/server/pages/api/infiniteScroll.js.nft.json new file mode 100644 index 0000000..d68aeca --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/infiniteScroll.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../chunks/1352.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/loginUser.js b/dsql-app/.local_dist/server/pages/api/loginUser.js new file mode 100644 index 0000000..7b49a1c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/loginUser.js @@ -0,0 +1,310 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6134; +exports.ids = [6134]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9842: +/***/ ((module) => { + +// @ts-check +/** + * Delay async function + * + * @param {number} [milliseconds] + * + * @returns {Promise<boolean>} new user auth object payload + */ +module.exports = async function delay(milliseconds) { + await new Promise((resolve, reject)=>{ + setTimeout(()=>{ + resolve(true); + }, milliseconds || 1000); + }); + return true; +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }), + +/***/ 4150: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(613); +/* harmony import */ var _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_delay__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9842); +/* harmony import */ var _functions_backend_delay__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_delay__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + + +const encrypt = __webpack_require__(7547); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + if (req.method === "POST") { + /** ********************* Get Page Data */ const sanitizedReqBody = req.body; + // let { email, password, query } = reqBody; + let email = sanitizedReqBody.email; + let password = sanitizedReqBody.password; + let query = sanitizedReqBody.query; + if (email.match(/ /)) return res.json({ + user: null, + msg: "Invalid Email" + }); + try { + const allowedAuthKeysPath = process.env.DSQL_USER_LOGIN_KEYS_PATH; + if (!allowedAuthKeysPath) throw new Error("loginUser error: process.env.DSQL_USER_LOGIN_KEYS_PATH not present"); + if (!fs.existsSync(allowedAuthKeysPath)) { + fs.mkdirSync(allowedAuthKeysPath, { + recursive: true + }); + } + const ip = req.headers["x-real-ip"] || req.headers["x-forwarded-for"] || req.connection.remoteAddress; + const site = process.env.DSQL_HOST || "https://datasquirel.com"; + let hashedPassword = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_5___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: password + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (password?.match(/ /) || email?.match(/ /)) { + return res.json({ + msg: "Failed!", + user: null + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + let foundUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM users WHERE email=? OR username=?`, [ + email, + email + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (!foundUser || !foundUser[0]) { + return res.json({ + msg: "No user found", + user: null + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + let isPasswordCorrect = false; + if (foundUser && foundUser[0]) isPasswordCorrect = hashedPassword === foundUser[0].password; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (!isPasswordCorrect) { + await _functions_backend_delay__WEBPACK_IMPORTED_MODULE_4___default()(); + if (true) { + _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3___default()({ + to: "benoti.san@gmail.com", + subject: `Failed Login from ${email}`, + html: `<h1><u>${email}</u> tried to login with a wrong password</h1><p><b>${email}</b> attempted a login on ${site} from ${ip} with a wrong password.</p>` + }); + } + return res.json({ + msg: "Wrong Password, Wrong Social Media Credentials", + user: null + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + let csrfKey = Math.random().toString(36).substring(2) + "-" + Math.random().toString(36).substring(2); + let userPayload = { + id: foundUser[0].id, + stripe_id: foundUser[0].stripe_id || "", + first_name: foundUser[0].first_name, + last_name: foundUser[0].last_name, + username: foundUser[0].username, + email: foundUser[0].email, + social_id: foundUser[0].social_id, + image: foundUser[0].image, + image_thumbnail: foundUser[0].image_thumbnail, + verification_status: foundUser[0].verification_status, + social_login: foundUser[0].social_login, + social_platform: foundUser[0].social_platform, + csrf_k: csrfKey, + logged_in_status: true, + date: Date.now() + }; + let encryptedPayload = encrypt(JSON.stringify(userPayload)); + res.setHeader("Set-Cookie", [ + `datasquirelAuthKey=${encryptedPayload};samesite=strict;path=/;HttpOnly=true;Secure=true`, + `csrf=${csrfKey};samesite=strict;path=/;HttpOnly=true`, + ]); + fs.appendFile("./.tmp/userLoginLogs.log", `${foundUser[0].first_name} ${foundUser[0].last_name} Logged in from ${foundUser[0].social_login ? foundUser[0].social_platform : "Regular Email Login"} at ${Date()} \n\n\n`, "utf8", (err)=>{ + if (err) console.log(`Loging log write error`); + }); + fs.writeFileSync(`${allowedAuthKeysPath}/${csrfKey}`, JSON.stringify(userPayload)); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (query?.invite) { + _functions_backend_addAdminUserOnLogin__WEBPACK_IMPORTED_MODULE_1___default()({ + query: query, + user: { + ...userPayload, + phone: foundUser[0].phone + } + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + await _functions_backend_delay__WEBPACK_IMPORTED_MODULE_4___default()(); + if (true) { + _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3___default()({ + to: "benoti.san@gmail.com", + subject: `${email} Logged in successfully`, + html: `<h1><u>${email}</u> successfully logged in</h1><p><b>${email}</b> successfully logged in on ${site} from ${ip} on ${Date().substring(0, 16)}.</p>` + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** ********************* Send Response */ res.json({ + msg: "User Found", + user: { + auth: true, + userid: foundUser[0].id, + csrf_k: csrfKey, + stripe_id: foundUser[0].stripe_id || "" + }, + userPayload + }); + } catch (/** @type {any} */ error) { + console.log("Login Error =>", error.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/loginUser/main-catch-error", + message: error.message, + user: { + email: email + } + }); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } else { + res.json({ + msg: "Oops ..." + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224,2163,3017,3403,7547,5886,5338,6926,613], () => (__webpack_exec__(4150))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/loginUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/loginUser.js.nft.json new file mode 100644 index 0000000..6b59391 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/loginUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/6926.js","../../chunks/613.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/datasquirel/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/datasquirel/utils/get.js","../../../../node_modules/datasquirel/utils/post.js","../../../../node_modules/datasquirel/utils/upload-image.js","../../../../node_modules/datasquirel/utils/get-schema.js","../../../../node_modules/datasquirel/utils/delete-file.js","../../../../node_modules/datasquirel/utils/upload-file.js","../../../../node_modules/datasquirel/users/add-user.js","../../../../node_modules/datasquirel/users/update-user.js","../../../../node_modules/datasquirel/users/login-user.js","../../../../node_modules/datasquirel/users/send-email-code.js","../../../../node_modules/datasquirel/users/logout-user.js","../../../../node_modules/datasquirel/users/user-auth.js","../../../../node_modules/datasquirel/users/reauth-user.js","../../../../node_modules/datasquirel/users/get-user.js","../../../../node_modules/datasquirel/users/get-token.js","../../../../node_modules/datasquirel/users/validate-token.js","../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../node_modules/datasquirel/functions/decrypt.js","../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/datasquirel/functions/encrypt.js","../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../node_modules/datasquirel/engine/query/post.js","../../../../node_modules/datasquirel/engine/query/get.js","../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/logoutUser.js b/dsql-app/.local_dist/server/pages/api/logoutUser.js new file mode 100644 index 0000000..7d91eb9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/logoutUser.js @@ -0,0 +1,115 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3204; +exports.ids = [3204]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6807: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** + * + * Imports + * ------------------------------------------------------------------------------ + */ /** ********************* Node Core Imports */ const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** ********************* Functions and Other API Imports */ //////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** + * API handler + * ------------------------------------------------------------------------------ + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + if (req.method === "GET") { + /** ********************* Reset Cookie Value */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res); + if (user) { + console.log(user.csrf_k); + try { + const allowedAuthKeysPath = process.env.DSQL_USER_LOGIN_KEYS_PATH; + const allowedAuthKeyPath = `${allowedAuthKeysPath}/${user.csrf_k}`; + fs.unlinkSync(allowedAuthKeyPath); + } catch (/** @type {any} */ error) { + console.log(`Logout API error: ${error.message}`); + } + } + res.setHeader("Set-Cookie", [ + `datasquirelAuthKey=null;samesite=strict;path=/;HttpOnly=true;Secure:true`, + ]); + /** ********************* Send Response */ res.json({ + msg: "Logged Out" + }); + } else { + return res.json({ + msg: "Logout Error" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(6807))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/logoutUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/logoutUser.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/logoutUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js b/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js new file mode 100644 index 0000000..ff4e15f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js @@ -0,0 +1,263 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8373; +exports.ids = [8373]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9643: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check + + + +/** + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const datasquirel = __webpack_require__(9538); +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * addPrivateMedia API handler + * ============================================================================== + * @type {import("next").NextApiHandler} - Next API handler + */ async function handler(req, res) { + /** + * Check method + * ========================================= + * @description Check if the request method is correct + */ if (req.method !== "POST") { + return res.json({ + success: false, + msg: "Failed!" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User auth + * ========================================= + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Grab request data + * ========================================= + * @description Grab data from the request + * @type {any} + */ const requestBody = datasquirel.sanitizeSql(req.body, null); + if (requestBody.media_url?.match(/\.\./) || requestBody.folder?.match(/\.\./) || requestBody.id?.toString()?.match(/\.\./)) { + return res.json({ + success: false, + msg: "Error!", + error: "Invalid url" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Send Response + * ========================================= + * @description Send a response to the client + */ try { + /** + * Handle request logic here + */ const isPrivate = requestBody?.private == 1 ? true : false; + const mediaMatchedPath = isPrivate ? requestBody?.media_path?.replace(/\@\/media/i, "") || requestBody?.media_url.replace(/\@\/media/i, "") : requestBody?.media_path?.match(/\/user-images\/user-.*/) || requestBody?.media_url?.match(/\/user-images\/user-.*/); + /** @type {string} */ const folder = requestBody.folder ? `/${requestBody.folder}` : ""; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const publicRootPath = path__WEBPACK_IMPORTED_MODULE_2___default().join(STATIC_ROOT, `images`); + const publicUrlPathRoot = `${process.env.DSQL_STATIC_HOST}/images/user-images/user-${user.id}`; + const publicRelativePathRoot = `/images/user-images/user-${user.id}`; + const mediaRelPathRoot = isPrivate ? `./jsonData/dbSchemas/users/user-${user.id}/media` : publicRootPath; + const mediaRelPath = mediaRelPathRoot + mediaMatchedPath; + const destinationPath = isPrivate ? `${publicRootPath}/user-images/user-${user.id}` : `./jsonData/dbSchemas/users/user-${user.id}/media`; + if (!fs.existsSync(destinationPath)) { + try { + fs.mkdirSync(destinationPath, { + recursive: true + }); + } catch (/** @type {any} */ error) { + console.log("LINE 88 error:", error.message); + } + } + if (folder) { + folder.split("/").reduce((prev, curr)=>{ + const currFolder = prev?.match(/./) ? `${prev}/${curr}` : destinationPath; + 7; + if (!fs.existsSync(currFolder)) { + fs.mkdirSync(currFolder, { + recursive: true + }); + } + return currFolder; + }, ""); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * construct new file name + */ const fileNameWithExtension = mediaRelPath?.match(/[^\/]+$/)?.[0]; + if (!fileNameWithExtension) { + throw new Error("No File Name Detected!"); + } + const fileName = fileNameWithExtension.split(".")[0]; + const fileExtension = fileNameWithExtension.split(".")[1]; + const newFileNameInDb = isPrivate ? `${publicUrlPathRoot}${folder ? folder + "/" : "/"}${fileNameWithExtension}` : `@/media${folder ? folder + "/" : "/"}${fileNameWithExtension}`; + const newRelativeFileNameInDb = isPrivate ? `${publicRelativePathRoot}${folder ? folder + "/" : "/"}${fileNameWithExtension}` : `@/media${folder ? folder + "/" : "/"}${fileNameWithExtension}`; + // if (isPrivate) { + // const dstPathFinal = destinationPath + folder + "/" + fileNameWithExtension; + // fs.copyFileSync(dstPathFinal, mediaRelPath); + // fs.unlinkSync(dstPathFinal); + // } else { + // } + fs.copyFileSync(mediaRelPath, destinationPath + folder + "/" + fileNameWithExtension); + fs.unlinkSync(mediaRelPath); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Construct new File Thumbnail name + */ const thumbnailNameWithExtension = fileName + "_thumbnail." + fileExtension; + const thumbnailSourcePath = mediaRelPath.replace(fileNameWithExtension, thumbnailNameWithExtension); + const newFileThumbnailNameInDb = isPrivate ? `${publicUrlPathRoot}${folder ? folder + "/" : "/"}${thumbnailNameWithExtension}` : `@/media${folder ? folder + "/" : "/"}${thumbnailNameWithExtension}`; + const newRelativeThumbnailNameInDb = isPrivate ? `${publicRelativePathRoot}${folder ? folder + "/" : "/"}${thumbnailNameWithExtension}` : `@/media${folder ? folder + "/" : "/"}${thumbnailNameWithExtension}`; + // if (isPrivate) { + // const dstPathFinal = destinationPath + folder + "/" + thumbnailNameWithExtension; + // fs.copyFileSync(dstPathFinal, thumbnailSourcePath); + // fs.unlinkSync(dstPathFinal); + // } else { + // } + try { + fs.copyFileSync(thumbnailSourcePath, destinationPath + folder + "/" + thumbnailNameWithExtension); + fs.unlinkSync(thumbnailSourcePath); + } catch (error1) {} + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const updateDb = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`UPDATE user_media SET private = ?, media_url= ?, media_thumbnail_url= ?, media_path = ?, media_thumbnail_path = ? WHERE id = ?`, [ + isPrivate ? 0 : 1, + newFileNameInDb, + newFileThumbnailNameInDb, + newRelativeFileNameInDb, + newRelativeThumbnailNameInDb, + requestBody.id, + ]); + /** + * Response data + */ res.json({ + success: true, + msg: "Success!" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error2) { + /** + * Handle error + * ========================================= + * @description Handle errors that occur during + * the request + */ console.log(error2.message); + res.json({ + success: false, + msg: "Error!", + error: error2 + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(9643))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js.nft.json new file mode 100644 index 0000000..3a10f5b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/media/addPrivateMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/6825.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js b/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js new file mode 100644 index 0000000..183cc73 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js @@ -0,0 +1,170 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3876; +exports.ids = [3876]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1635: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const datasquirel = __webpack_require__(9538); +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// +/** + * addPrivateMedia API handler + * ============================================================================== + * @type {import("next").NextApiHandler} - Next API handler + */ async function handler(req, res) { + /** + * Check method + * ========================================= + * @description Check if the request method is correct + */ if (req.method !== "POST") { + return res.json({ + success: false, + msg: "Failed!" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User auth + * ========================================= + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Send Response + * ========================================= + * @description Send a response to the client + */ try { + /** + * Grab request data + * ========================================= + * @description Grab data from the request + */ const filePath = JSON.parse(req.body).path.replace(/ /g, "").replace(/\.\./g, ""); + if (filePath?.match(/\.\./)) { + return res.json({ + success: false, + msg: "Error!", + error: "Invalid url" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle request logic here + */ const rootFolder = `./jsonData/dbSchemas/users/user-${user.id.toString().replace(/\//g, "")}`; + const rootPath = filePath.replace(/\@/, rootFolder); + const fileStream = fs.createReadStream(rootPath); + /** + * Response data + */ fileStream.pipe(res); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + /** + * Handle error + * ========================================= + * @description Handle errors that occur during + * the request + */ console.log("ERROR in getPrivateMedia api route:", error.message); + res.json({ + success: false, + msg: "Error!", + error: error + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(1635))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js.nft.json new file mode 100644 index 0000000..3a10f5b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/media/getPrivateMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/6825.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/purgeDb.js b/dsql-app/.local_dist/server/pages/api/purgeDb.js new file mode 100644 index 0000000..900f738 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/purgeDb.js @@ -0,0 +1,161 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5730; +exports.ids = [5730]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9102: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var fs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7147); +/* harmony import */ var fs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(fs__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { paradigm , payload } = sanitizedReqBody; + let response; + try { + console.log("Deleting media =>", payload.id); + const mediaUrl = payload.media_url; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + const STATIC_HOST = process.env.DSQL_STATIC_HOST; + if (!STATIC_ROOT) { + console.log("No Static Root Path"); + res.json({ + success: false, + msg: "No Static Root Path" + }); + return; + } + const relativePath = mediaUrl.replace(STATIC_HOST, ""); + const filePath = path__WEBPACK_IMPORTED_MODULE_3___default().join(STATIC_ROOT, relativePath); + const fileExist = fs__WEBPACK_IMPORTED_MODULE_0___default().existsSync(filePath); + console.log("relativePath", relativePath); + console.log("STATIC_ROOT", STATIC_ROOT); + console.log("STATIC_HOST", STATIC_HOST); + console.log("filePath", filePath); + console.log("fileExist", fileExist); + if (fileExist) { + res.json({ + success: false + }); + return; + } + } catch (/** @type {any} */ error) { + console.log("File verification Error =>", error.message); + console.log("File Truly doesn't exist, cotinuing ..."); + } + switch(paradigm){ + case "user_media": + response = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1___default()(`DELETE FROM user_media WHERE id='${payload.id}'`); + break; + default: + break; + } + res.json({ + success: true + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(9102))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/purgeDb.js.nft.json b/dsql-app/.local_dist/server/pages/api/purgeDb.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/purgeDb.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/add-file.js b/dsql-app/.local_dist/server/pages/api/query/add-file.js new file mode 100644 index 0000000..19bbe67 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/add-file.js @@ -0,0 +1,250 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3769; +exports.ids = [3769]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7441: +/***/ ((module) => { + +module.exports = require("sharp"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8144: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5910); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6715); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_6__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_7__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + + + + +/** ****************************************************************************** */ const config = { + api: { + bodyParser: { + sizeLimit: "50mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + const authorization = req.headers.authorization; + if (!authorization) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_7___default()({ + key: authorization + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ let { fileData , fileName , mimeType , folder , isPrivate } = req.body; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + if (folder) { + const folderPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(STATIC_ROOT, `images/user-images/user-${user_id}/${folder?.toString().replace(/\.\./g, "")}`); + const folderExists = fs.existsSync(folderPath); + if (!folderExists) { + fs.mkdirSync(folderPath, { + recursive: true + }); + } + } + /** + * Input Validation + * + * @description Input Validation + */ const grabedPaths = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_5___default()({ + folder: folder, + isPrivate: isPrivate, + user: apiCred + }); + if (!grabedPaths) { + throw new Error("Couldn't Grab Image URLs"); + } + const { fileRootPath , urlRootPath } = grabedPaths; + const extension = (()=>{ + if (mimeType?.match(/csv/i)) return ".csv"; + if (mimeType?.match(/pdf/i)) return ".pdf"; + if (mimeType?.match(/xlsx/)) return ".xlsx"; + if (mimeType?.match(/json/i)) return ".json"; + return ".txt"; + })(); + const urlPath = urlRootPath + fileName + extension; + const writePath = fileRootPath + fileName + extension; + fs.writeFileSync(writePath, fileData, "base64"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const removeDuplicateMedia = await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + identifierColumnName: "media_url", + identifierValue: urlPath + }); + let newMediaEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + data: { + user_id: user_id, + media_name: fileName, + media_url: urlPath, + media_thumbnail_url: urlPath, + folder: folder ? folder : "", + media_type: "file", + private: isPrivate ? "1" : null + } + }); + //////////////////////////////////////// + res.json({ + success: true, + payload: { + urlPath + } + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("File write error:", error); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_6___default()({ + component: "/api/query/add-file/main-catch-error", + message: error.message + }); + res.json({ + success: false, + msg: "Add File Error!", + error: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,1007,6147,6715,5910], () => (__webpack_exec__(8144))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/add-file.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/add-file.js.nft.json new file mode 100644 index 0000000..cb16ac3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/add-file.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/1007.js","../../../chunks/6147.js","../../../chunks/6715.js","../../../chunks/5910.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/sharp/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/sharp/lib/index.js","../../../../../node_modules/sharp/lib/constructor.js","../../../../../node_modules/sharp/lib/input.js","../../../../../node_modules/sharp/lib/composite.js","../../../../../node_modules/sharp/lib/operation.js","../../../../../node_modules/sharp/lib/resize.js","../../../../../node_modules/sharp/lib/colour.js","../../../../../node_modules/sharp/lib/channel.js","../../../../../node_modules/sharp/lib/output.js","../../../../../node_modules/sharp/lib/utility.js","../../../../../node_modules/sharp/lib/is.js","../../../../../node_modules/sharp/lib/sharp.js","../../../../../node_modules/sharp/lib/libvips.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/lru-cache/package.json","../../../../../node_modules/lru-cache/index.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/sharp/node_modules/semver/functions/coerce.js","../../../../../node_modules/sharp/node_modules/semver/functions/satisfies.js","../../../../../node_modules/sharp/node_modules/semver/functions/gte.js","../../../../../node_modules/sharp/node_modules/semver/package.json","../../../../../node_modules/color/index.js","../../../../../node_modules/detect-libc/package.json","../../../../../node_modules/detect-libc/lib/detect-libc.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/color/package.json","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/sharp/node_modules/semver/functions/compare.js","../../../../../node_modules/sharp/node_modules/semver/functions/parse.js","../../../../../node_modules/sharp/node_modules/semver/classes/range.js","../../../../../node_modules/sharp/node_modules/semver/classes/semver.js","../../../../../node_modules/sharp/node_modules/semver/internal/re.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/detect-libc/lib/process.js","../../../../../node_modules/detect-libc/lib/filesystem.js","../../../../../node_modules/yallist/package.json","../../../../../node_modules/yallist/yallist.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/sharp/node_modules/semver/internal/debug.js","../../../../../node_modules/sharp/node_modules/semver/internal/constants.js","../../../../../node_modules/sharp/node_modules/semver/internal/parse-options.js","../../../../../node_modules/sharp/node_modules/semver/internal/identifiers.js","../../../../../node_modules/sharp/node_modules/semver/classes/comparator.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/yallist/iterator.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/color/node_modules/color-convert/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/color/node_modules/color-convert/package.json","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/sharp/node_modules/semver/functions/cmp.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/color-string/index.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/color-string/package.json","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/color/node_modules/color-convert/conversions.js","../../../../../node_modules/color/node_modules/color-convert/route.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sharp/node_modules/semver/functions/eq.js","../../../../../node_modules/sharp/node_modules/semver/functions/neq.js","../../../../../node_modules/sharp/node_modules/semver/functions/gt.js","../../../../../node_modules/sharp/node_modules/semver/functions/lte.js","../../../../../node_modules/sharp/node_modules/semver/functions/lt.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/color-name/package.json","../../../../../node_modules/color-name/index.js","../../../../../node_modules/simple-swizzle/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/color/node_modules/color-name/package.json","../../../../../node_modules/color/node_modules/color-name/index.js","../../../../../node_modules/simple-swizzle/package.json","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/simple-swizzle/node_modules/is-arrayish/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/add-image.js b/dsql-app/.local_dist/server/pages/api/query/add-image.js new file mode 100644 index 0000000..e4b6775 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/add-image.js @@ -0,0 +1,237 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3419; +exports.ids = [3419]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7441: +/***/ ((module) => { + +module.exports = require("sharp"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2518: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5910); +/* harmony import */ var _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + + + +/** ****************************************************************************** */ const config = { + api: { + bodyParser: { + sizeLimit: "50mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + const authorization = req.headers.authorization; + if (!authorization) throw new Error("No Authorization Found!"); + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_6___default()({ + key: authorization + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ let { imageData , imageName , mimeType , thumbnailSize , folder , isPrivate , } = req.body; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + if (folder) { + const folderPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(STATIC_ROOT, `images/user-images/user-${user_id}/${folder}`); + const folderExists = fs.existsSync(folderPath); + if (!folderExists) { + fs.mkdirSync(folderPath, { + recursive: true + }); + } + } + /** + * Input Validation + * + * @description Input Validation + */ const imageType = (()=>{ + if (mimeType?.match(/jpeg/i)) return "jpeg"; + if (mimeType?.match(/png/i)) return "png"; + if (mimeType?.match(/webp/i)) return "webp"; + if (mimeType?.match(/svg/i)) return "svg"; + return "jpg"; + })(); + const writeImage = await _functions_backend_fsWriteImageToDiskFromBase64__WEBPACK_IMPORTED_MODULE_4___default()({ + imageName: imageName, + imageSourceBase64: imageData, + user: { + id: user_id + }, + mimeType: imageType, + thumbnailSize: thumbnailSize, + folder, + isPrivate + }); + if (!writeImage) throw new Error("Write Image Failed in add-media API route"); + const { urlPath , urlThumbnailPath } = writeImage; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const removeDuplicateMedia = await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_2___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + identifierColumnName: "media_url", + identifierValue: urlPath + }); + let newMediaEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + data: { + user_id: user_id, + media_name: imageName, + media_url: urlPath, + media_thumbnail_url: urlThumbnailPath, + folder: folder ? folder : "" + } + }); + //////////////////////////////////////// + res.json({ + success: true, + payload: { + urlPath, + urlThumbnailPath + } + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_5___default()({ + component: "/api/query/add-image/main-catch-error", + message: error.message, + user: {} + }); + res.json({ + success: false, + msg: "Add Image Error!", + error: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,1007,6147,6715,5910], () => (__webpack_exec__(2518))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/add-image.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/add-image.js.nft.json new file mode 100644 index 0000000..cb16ac3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/add-image.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/1007.js","../../../chunks/6147.js","../../../chunks/6715.js","../../../chunks/5910.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/sharp/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/sharp/lib/index.js","../../../../../node_modules/sharp/lib/constructor.js","../../../../../node_modules/sharp/lib/input.js","../../../../../node_modules/sharp/lib/composite.js","../../../../../node_modules/sharp/lib/operation.js","../../../../../node_modules/sharp/lib/resize.js","../../../../../node_modules/sharp/lib/colour.js","../../../../../node_modules/sharp/lib/channel.js","../../../../../node_modules/sharp/lib/output.js","../../../../../node_modules/sharp/lib/utility.js","../../../../../node_modules/sharp/lib/is.js","../../../../../node_modules/sharp/lib/sharp.js","../../../../../node_modules/sharp/lib/libvips.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/lru-cache/package.json","../../../../../node_modules/lru-cache/index.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/sharp/node_modules/semver/functions/coerce.js","../../../../../node_modules/sharp/node_modules/semver/functions/satisfies.js","../../../../../node_modules/sharp/node_modules/semver/functions/gte.js","../../../../../node_modules/sharp/node_modules/semver/package.json","../../../../../node_modules/color/index.js","../../../../../node_modules/detect-libc/package.json","../../../../../node_modules/detect-libc/lib/detect-libc.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/color/package.json","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/sharp/node_modules/semver/functions/compare.js","../../../../../node_modules/sharp/node_modules/semver/functions/parse.js","../../../../../node_modules/sharp/node_modules/semver/classes/range.js","../../../../../node_modules/sharp/node_modules/semver/classes/semver.js","../../../../../node_modules/sharp/node_modules/semver/internal/re.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/detect-libc/lib/process.js","../../../../../node_modules/detect-libc/lib/filesystem.js","../../../../../node_modules/yallist/package.json","../../../../../node_modules/yallist/yallist.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/sharp/node_modules/semver/internal/debug.js","../../../../../node_modules/sharp/node_modules/semver/internal/constants.js","../../../../../node_modules/sharp/node_modules/semver/internal/parse-options.js","../../../../../node_modules/sharp/node_modules/semver/internal/identifiers.js","../../../../../node_modules/sharp/node_modules/semver/classes/comparator.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/yallist/iterator.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/color/node_modules/color-convert/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/color/node_modules/color-convert/package.json","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/sharp/node_modules/semver/functions/cmp.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/color-string/index.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/color-string/package.json","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/color/node_modules/color-convert/conversions.js","../../../../../node_modules/color/node_modules/color-convert/route.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sharp/node_modules/semver/functions/eq.js","../../../../../node_modules/sharp/node_modules/semver/functions/neq.js","../../../../../node_modules/sharp/node_modules/semver/functions/gt.js","../../../../../node_modules/sharp/node_modules/semver/functions/lte.js","../../../../../node_modules/sharp/node_modules/semver/functions/lt.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/color-name/package.json","../../../../../node_modules/color-name/index.js","../../../../../node_modules/simple-swizzle/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/color/node_modules/color-name/package.json","../../../../../node_modules/color/node_modules/color-name/index.js","../../../../../node_modules/simple-swizzle/package.json","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/simple-swizzle/node_modules/is-arrayish/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/delete-file.js b/dsql-app/.local_dist/server/pages/api/query/delete-file.js new file mode 100644 index 0000000..1f6206b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/delete-file.js @@ -0,0 +1,214 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1620; +exports.ids = [1620]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2201: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6147); +/* harmony import */ var _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + +/** ****************************************************************************** */ const config = { + api: { + bodyParser: { + sizeLimit: "50mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + const authorization = req.headers.authorization; + if (!authorization) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default()({ + key: authorization + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ let { url } = req.body; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const existingMedia = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT * FROM user_media WHERE media_url = ?`, [ + url + ]); + if (!existingMedia?.length) { + return res.json({ + success: false, + msg: "Media not found!" + }); + } + const { id , folder , media_url , media_thumbnail_url , media_type } = existingMedia[0]; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + /** + * + * @param {string | null | undefined} path + * @returns {string} + */ const formPath = (path)=>{ + if (!path) return ""; + if (path?.match(/\.\./)) return ""; + if (path?.match(/^\@/)) { + return path.replace(/@\/media\//, `./jsonData/dbSchemas/users/user-${user_id}/media/`); + } + return path.replace(process.env.DSQL_STATIC_HOST || "", STATIC_ROOT); + }; + const deletePath = formPath(media_url); + const deleteThumbnailPath = formPath(media_thumbnail_url); + if (!deletePath?.match(/./)) { + return res.json({ + success: false, + msg: "Invalid path!" + }); + } + try { + fs.unlinkSync(deletePath); + fs.unlinkSync(deleteThumbnailPath); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const removeDuplicateMedia = await _package_shared_functions_backend_db_deleteDbEntry__WEBPACK_IMPORTED_MODULE_1___default()({ + dbFullName: "datasquirel", + tableName: "user_media", + identifierColumnName: "id", + identifierValue: id + }); + //////////////////////////////////////// + res.json({ + success: true, + payload: { + url + } + }); + } catch (/** @type {any} */ error) { + console.log("File delete error:", error.message); + //////////////////////////////////////// + res.json({ + success: false, + payload: { + url + }, + error: error.message + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + console.log("File write error:", error1); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/delete-file/main-catch-error", + message: error1.message + }); + res.json({ + success: false, + msg: "Delete File Error!", + error: error1.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3403,1007,6147], () => (__webpack_exec__(2201))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/delete-file.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/delete-file.js.nft.json new file mode 100644 index 0000000..ca244ee --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/delete-file.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3403.js","../../../chunks/1007.js","../../../chunks/6147.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get-private-file.js b/dsql-app/.local_dist/server/pages/api/query/get-private-file.js new file mode 100644 index 0000000..a6c182d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get-private-file.js @@ -0,0 +1,172 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5109; +exports.ids = [5109]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2875: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6715); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + +/** ****************************************************************************** */ const config = { + api: { + bodyParser: { + sizeLimit: "100mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + const authorization = req.headers.authorization; + if (!authorization) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default()({ + key: authorization + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ let { folder , fileName , downloadType } = req.body; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Input Validation + * + * @description Input Validation + */ const grabedPaths = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_2___default()({ + folder: folder, + isPrivate: true, + user: apiCred + }); + if (!grabedPaths) { + throw new Error("Couldn't Grab Image URLs"); + } + const { fileRootPath } = grabedPaths; + const filePath = path__WEBPACK_IMPORTED_MODULE_0___default().join(fileRootPath, fileName); + if (downloadType?.match(/raw/i)) { + const fileData = fs.readFileSync(filePath, "utf-8"); + return res.json({ + success: true, + data: fileData + }); + } else if (downloadType?.match(/base64/i)) { + const fileData1 = fs.readFileSync(filePath, "base64"); + return res.json({ + success: true, + data: fileData1 + }); + } else { + const fileStream = fs.createReadStream(filePath); + fileStream.pipe(res); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("Get Private File Error:", error); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/get-private-file/main-catch-error", + message: error.message + }); + res.json({ + success: false, + msg: "Get Private File Error!", + error: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163,1007,6715], () => (__webpack_exec__(2875))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get-private-file.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/get-private-file.js.nft.json new file mode 100644 index 0000000..a490570 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get-private-file.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2163.js","../../../chunks/1007.js","../../../chunks/6715.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get-schema.js b/dsql-app/.local_dist/server/pages/api/query/get-schema.js new file mode 100644 index 0000000..7e4da4d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get-schema.js @@ -0,0 +1,175 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8691; +exports.ids = [8691]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1640: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + console.log("Getting DB schema"); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + /** @type {import("@/package-shared/types").GetSchemaRequestQuery} */ // @ts-ignore + const reqQuery = req.query; + let { database , table , field } = reqQuery; + const authorization = req.headers.authorization; + if (!authorization) return res.json({ + success: false, + msg: "Unauthorized" + }); + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_2___default()({ + key: authorization, + database: database, + table: table + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ try { + const dbFullName = database && typeof database == "string" ? `datasquirel_user_${user_id}_${database?.toLowerCase().replace(/[^a-z0-9\_]/g, "")}` : null; + /** @type {string} */ const dbSchemaPath = path.join(process.cwd(), "jsonData/dbSchemas/users", `user-${user_id.toString().replace(/\//g, "")}`, "main.json"); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchema = JSON.parse(fs.readFileSync(dbSchemaPath, "utf8")); + const targetDbSchema = dbFullName ? dbSchema.find((db)=>db.dbFullName == dbFullName) : null; + if (table && database && targetDbSchema?.tables?.[0]) { + const targetTable = targetDbSchema.tables.find((tbl)=>tbl.tableName == table); + if (field && targetTable?.fields?.[0]) { + const targetField = targetTable.fields.find((fld)=>fld.fieldName === field); + return res.json({ + success: Boolean(targetField), + payload: targetField + }); + } else if (field && !targetTable?.fields?.[0]) { + throw new Error("Target Table Not Found!"); + } + return res.json({ + success: Boolean(targetTable), + payload: targetTable + }); + } else if (table && !targetDbSchema?.tables?.[0]) { + throw new Error("Target Database Not Found!"); + } + if (database) { + res.json({ + success: Boolean(targetDbSchema), + payload: targetDbSchema + }); + } else { + res.json({ + success: true, + payload: dbSchema + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/query/get-schema/lines-132-142", + message: error.message + }); + //////////////////////////////////////// + res.json({ + success: false, + payload: null, + error: error.message + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/query/get-schema/main-catch-error", + message: error1.message + }); + res.json({ + success: false, + payload: null, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163,1007], () => (__webpack_exec__(1640))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get-schema.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/get-schema.js.nft.json new file mode 100644 index 0000000..f833e25 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get-schema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2163.js","../../../chunks/1007.js","../../../../package.json","../../../../../package.json","../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get.js b/dsql-app/.local_dist/server/pages/api/query/get.js new file mode 100644 index 0000000..5afad71 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get.js @@ -0,0 +1,223 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5911; +exports.ids = [5911]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7082: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8499); +/* harmony import */ var _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ /** @type {import("@/package-shared/types").GetReqQueryObject} */ // @ts-ignore + const reqQueryObject = req.query; + const { query , db } = reqQueryObject; + /** @type {string | undefined } */ const tableName = reqQueryObject?.tableName ? String(reqQueryObject.tableName) : undefined; + const authorization = req.headers.authorization; + if (!authorization) return res.json({ + success: false, + msg: "Unauthorized" + }); + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default()({ + key: authorization, + database: db, + table: tableName + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id } = apiCred; + /** @type {string[] | undefined } */ let queryValues; + if (reqQueryObject?.queryValues && typeof reqQueryObject?.queryValues === "string") { + try { + queryValues = JSON.parse(reqQueryObject.queryValues); + } catch (error) {} + } + const dbFullName = `datasquirel_user_${user_id}_${db}`; + /** + * Input Validation + * + * @description Input Validation + */ if (typeof query == "string" && (query.match(/^alter|^delete|information_schema|databases|^create/i) || !query.match(/^select/i))) { + return res.json({ + success: false, + msg: "Wrong Input" + }); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ let results; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ let dbSchema; + const targetDbSchemaPath = `./jsonData/dbSchemas/users/user-${user_id.toString().replace(/\//g, "")}/main.json`; + if (fs.existsSync(targetDbSchemaPath)) { + try { + dbSchema = JSON.parse(fs.readFileSync(targetDbSchemaPath, "utf8")).filter((/** @type {any} */ db)=>db.dbFullName === dbFullName)[0]; + } catch (_err) {} + } + try { + let { result , error: error1 } = await _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1___default()({ + dbFullName: dbFullName, + query: query, + queryValuesArray: queryValues, + readOnly: true, + dbSchema, + tableName + }); + /** @type {import("@/package-shared/types").DSQL_TableSchemaType | undefined} */ let tableSchema; + if (dbSchema) { + const targetTable = dbSchema.tables.find((table)=>table.tableName === tableName); + if (targetTable) { + const clonedTargetTable = lodash__WEBPACK_IMPORTED_MODULE_0___default().cloneDeep(targetTable); + delete clonedTargetTable.childTable; + delete clonedTargetTable.childTableDbFullName; + delete clonedTargetTable.childTableName; + delete clonedTargetTable.childrenTables; + delete clonedTargetTable.updateData; + delete clonedTargetTable.tableNameOld; + delete clonedTargetTable.indexes; + tableSchema = clonedTargetTable; + } + } + if (error1) throw error1; + if (result.error) throw new Error(result.error); + results = result; + /** @type {import("@/package-shared/types").GetReturn} */ const resObject = { + success: true, + payload: results, + schema: tableName && tableSchema ? tableSchema : undefined + }; + res.json(resObject); + //////////////////////////////////////// + } catch (/** @type {any} */ error2) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/get/lines-85-94", + message: error2.message + }); + res.json({ + success: false, + payload: null, + error: error2.message + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error3) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/get/main-catch-error", + message: error3.message + }); + res.json({ + success: false, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1007,6147,8499], () => (__webpack_exec__(7082))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/get.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/get.js.nft.json new file mode 100644 index 0000000..42d355e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/get.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1007.js","../../../chunks/6147.js","../../../chunks/8499.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/post.js b/dsql-app/.local_dist/server/pages/api/query/post.js new file mode 100644 index 0000000..2ab0608 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/post.js @@ -0,0 +1,250 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3432; +exports.ids = [3432]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5830: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "config": () => (/* binding */ config), +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8499); +/* harmony import */ var _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + +/** ****************************************************************************** */ const config = { + api: { + bodyParser: { + sizeLimit: "50mb" + } + } +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + /** + * User auth + * + * @description Authenticate user + */ /** + * Grab Body + */ let { query , database , tableName , queryValues } = req.body; + const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + const authorization = req.headers.authorization; + if (!authorization) return res.json({ + success: false, + msg: "Unauthorized" + }); + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_4___default()({ + key: authorization, + database: database, + table: tableName + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + const dbFullName = `datasquirel_user_${user_id}_${database}`; + /** + * Input Validation + * + * @description Input Validation + */ if (typeof query === "string" && query?.match(/^create |^alter |^drop /i)) { + return res.json({ + success: false, + msg: "Wrong Input" + }); + } + if (typeof query === "object" && query?.action?.match(/^create |^alter |^drop /i)) { + return res.json({ + success: false, + msg: "Wrong Input" + }); + } + /** + * Grab db Schema + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ let dbSchema; + const targetDbSchemaPath = `./jsonData/dbSchemas/users/user-${user_id.toString().replace(/\//g, "")}/main.json`; + if (fs.existsSync(targetDbSchemaPath)) { + try { + dbSchema = JSON.parse(fs.readFileSync(targetDbSchemaPath, "utf8")).filter((/** @type {any} */ db)=>db.dbFullName === dbFullName)[0]; + } catch (_err) {} + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ try { + let { result , error } = await _package_shared_functions_backend_db_runQuery__WEBPACK_IMPORTED_MODULE_1___default()({ + dbFullName: dbFullName, + query: query, + dbSchema: dbSchema, + queryValuesArray: queryValues, + tableName + }); + results = result; + if (error) throw error; + /** @type {import("@/package-shared/types").DSQL_TableSchemaType | undefined} */ let tableSchema; + if (dbSchema) { + const targetTable = dbSchema.tables.find((table)=>table.tableName === tableName); + if (targetTable) { + const clonedTargetTable = lodash__WEBPACK_IMPORTED_MODULE_0___default().cloneDeep(targetTable); + delete clonedTargetTable.childTable; + delete clonedTargetTable.childTableDbFullName; + delete clonedTargetTable.childTableName; + delete clonedTargetTable.childrenTables; + delete clonedTargetTable.updateData; + delete clonedTargetTable.tableNameOld; + delete clonedTargetTable.indexes; + tableSchema = clonedTargetTable; + } + } + res.json({ + success: true, + payload: results, + error: error, + schema: tableName && tableSchema ? tableSchema : undefined + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/post/lines-132-142", + message: error1.message + }); + //////////////////////////////////////// + res.json({ + success: false, + payload: results, + error: error1.message + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error2) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/query/post/main-catch-error", + message: error2.message + }); + res.json({ + success: false, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1007,6147,8499], () => (__webpack_exec__(5830))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/post.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/post.js.nft.json new file mode 100644 index 0000000..42d355e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/post.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1007.js","../../../chunks/6147.js","../../../chunks/8499.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js b/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js new file mode 100644 index 0000000..4791f3e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js @@ -0,0 +1,162 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8360; +exports.ids = [8360]; +exports.modules = { + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4260: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1007); +/* harmony import */ var _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ let results; + try { + /** + * User auth + * + * @description Authenticate user + */ const authorization = req.headers.authorization; + if (!authorization) return res.json({ + success: false, + msg: "Unauthorized" + }); + const apiCred = _package_shared_functions_backend_api_cred__WEBPACK_IMPORTED_MODULE_3___default()({ + key: authorization + }); + if (!apiCred?.user_id) { + throw new Error("Api Credentials invalid!"); + } + const { user_id , full_access } = apiCred; + if (!full_access) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * Grab the database schema + * @note This is only for one database + * @type {import("@/package-shared/types").DSQL_DatabaseSchemaType} + */ //@ts-ignore + const schema = req.query.schema; + /** @type {string} */ const dbSchemaPath = `./jsonData/dbSchemas/users/user-${user_id.toString().replace(/\//g, "")}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const dbSchema = JSON.parse(fs.readFileSync(dbSchemaPath, "utf8")); + const targetDbSchemaIndex = dbSchema.findIndex((db)=>db.dbFullName == schema?.dbFullName); + const targetDbSchema = schema?.dbFullName ? dbSchema.find((db)=>db.dbFullName == schema.dbFullName) : null; + if (targetDbSchemaIndex < 0) { + return res.json({ + success: false, + payload: null + }); + } + dbSchema[targetDbSchemaIndex] = schema; + fs.writeFileSync(dbSchemaPath, JSON.stringify(dbSchema, null, 4), "utf8"); + const targetPath = path.resolve(process.cwd(), "./shell"); + const dbShellUpdate = (0,child_process__WEBPACK_IMPORTED_MODULE_0__.execSync)(`node createDbFromSchema.js --user ${user_id.toString().replace(/\/| /g, "")} --database ${dbSchema[targetDbSchemaIndex].dbFullName}`, { + cwd: targetPath + }); + res.json({ + success: true, + payload: "Success!" + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/query/update-schema-from-single-database/main-catch-error", + message: error.message + }); + res.json({ + success: false, + payload: null, + msg: "Something went wrong" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163,1007], () => (__webpack_exec__(4260))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js.nft.json b/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js.nft.json new file mode 100644 index 0000000..33e4546 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/query/update-schema-from-single-database.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2163.js","../../../chunks/1007.js","../../../../package.json","../../../../../package.json","../../../../../shell/checkDb.js","../../../../../shell/createDbFromSchema.js","../../../../../shell/encodingUpdate.js","../../../../../shell/deploy.js","../../../../../shell/grantFullPriviledges.js","../../../../../shell/lessWatch.js","../../../../../shell/readImage.js","../../../../../shell/recoverMainJsonFromDb.js","../../../../../shell/resetSQLCredentials.js","../../../../../shell/resetSQLCredentialsPasswords.js","../../../../../shell/setSQLCredentials.js","../../../../../shell/tailwindWatch.js","../../../../../shell/test-external-server.js","../../../../../shell/test.js","../../../../../shell/testSQLEscape.js","../../../../../shell/updateChildrenTablesOnDb.js","../../../../../shell/updateDateTimestamps.js","../../../../../shell/updateDbSlugsForTableRecords.js","../../../../../shell/updateSSLUsers.js","../../../../../shell/utils/createTable.js","../../../../../shell/utils/dbHandler.js","../../../../../shell/utils/generateColumnDescription.js","../../../../../shell/utils/noDatabaseDbHandler.js","../../../../../shell/utils/supplementTable.js","../../../../../shell/utils/updateTable.js","../../../../../shell/utils/varDatabaseDbHandler.js","../../../../../shell/functions/jsonToBase64.js","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js b/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js new file mode 100644 index 0000000..66bfffb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js @@ -0,0 +1,162 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9715; +exports.ids = [9715]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6836: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ // const { table, db, field, term, operator } = req.query; + const table = req.query.table; + const db = req.query.db; + const field = req.query.field; + const term = String(req.query.term); + const operator = req.query.operator; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const query = `SELECT * FROM \`${table}\` WHERE LOWER(\`${field}\`) ${operator?.toString()?.match(/equal/i) ? "=" : " LIKE "}? ORDER BY id DESC LIMIT 20`; + const queryArray = [ + operator?.toString()?.match(/equal/i) ? term.toLowerCase() : "%" + term.toLowerCase() + "%", + ]; + const result = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + database: db?.toString()?.replace(/[^a-z0-9_]/g, ""), + queryString: query, + queryValuesArray: queryArray + }); + const count = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + database: db?.toString()?.replace(/[^a-z0-9_]/g, ""), + queryString: query.replace(/\*/, "COUNT(id) AS count").replace(/ ORDER BY .*/, ""), + queryValuesArray: queryArray + }); + //////////////////////////////////////// + res.json({ + success: true, + result: result, + count: count?.[0]?.count + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_0___default()({ + component: "/api/queryEntriesSearchTerm/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311], () => (__webpack_exec__(6836))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js.nft.json b/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js.nft.json new file mode 100644 index 0000000..a32b390 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/queryEntriesSearchTerm.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js b/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js new file mode 100644 index 0000000..dd832a9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js @@ -0,0 +1,247 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9662; +exports.ids = [9662]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2148: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +const serverError = __webpack_require__(2163); +const { ServerResponse } = __webpack_require__(3685); +const DB_HANDLER = __webpack_require__(2224); +const encrypt = __webpack_require__(7547); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {object} params + * @param {number} params.userId - user id + * @param {string} params.csrf + * @param {import("next").NextApiResponse} params.res - response object + * + * @returns {Promise<import("@/package-shared/types").UserType | null>} new user auth object payload + */ module.exports = async function reAuthUser({ userId , res , csrf }) { + try { + const allowedAuthKeysPath = process.env.DSQL_USER_LOGIN_KEYS_PATH; + if (!allowedAuthKeysPath) { + console.log(`DSQL_USER_LOGIN_KEYS_PATH env variable not found. Please set this variable.`); + return null; + } + /** + * Fetch user + * + * @description Fetch user from db + */ let refreshedUser = await DB_HANDLER(`SELECT * FROM users WHERE id=?`, [ + userId, + ]); + fs.unlinkSync(`${allowedAuthKeysPath}/${csrf}`); + /** + * Generate csrf + * + * @description Generate csrf + */ let csrfKey = Math.random().toString(36).substring(2) + "-" + Math.random().toString(36).substring(2); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Construct new user payload + * + * @description Construct new user payload + * @type {import("@/package-shared/types").UserType} + */ let newUserPayload = { + id: refreshedUser[0].id, + stripe_id: refreshedUser[0].stripe_id || "", + first_name: refreshedUser[0].first_name, + last_name: refreshedUser[0].last_name, + email: refreshedUser[0].email, + social_id: refreshedUser[0].social_id, + image: refreshedUser[0].image, + image_thumbnail: refreshedUser[0].image_thumbnail, + verification_status: refreshedUser[0].verification_status, + social_login: refreshedUser[0].social_login, + social_platform: refreshedUser[0].social_platform, + csrf_k: csrfKey, + logged_in_status: true, + date: Date.now() + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Encrypt payload + * + * @description Encrypt new user payload + */ let encryptedPayload = encrypt(JSON.stringify(newUserPayload)); + fs.writeFileSync(`${allowedAuthKeysPath}/${csrfKey}`, JSON.stringify(newUserPayload)); + /** + * Update header + * + * @description Update header response with new payload + */ res.setHeader("Set-Cookie", [ + `datasquirelAuthKey=${encryptedPayload};samesite=strict;path=/;HttpOnly=true;Secure=true`, + `csrf=${csrfKey};samesite=strict;path=/;HttpOnly=true;Secure=true`, + `user_refresh=1`, + ]); + // =============================================================================== + // ============================ End User Refresh ================================= + // =============================================================================== + /** + * Return payload + * + * @description return new user object payload + */ return newUserPayload; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {*} */ error) { + serverError({ + component: "reAuthUser", + message: error.message, + user: { + id: userId + } + }); + return null; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 8251: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_reAuthUser__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2148); +/* harmony import */ var _functions_backend_reAuthUser__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_reAuthUser__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} reAuthenticateUserResponse + * @property {boolean} status - Response Status + * @property {string | null} [csrf] - CSRF String + * @property {import("@/package-shared/types").UserType | null} user - Authenticated User + */ /** + * ============================================================================== + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ let user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + console.log("No user Found"); + res.redirect(307, "/logout"); + return; + } + /** + * Re Authenticate User + * + * @description re authenticate user + */ let reAuthenticatedUser = await _functions_backend_reAuthUser__WEBPACK_IMPORTED_MODULE_1___default()({ + userId: user.id, + res, + csrf: user.csrf_k + }); + /** + * Send Response + * + * @description Send a boolean response + */ /** @type {reAuthenticateUserResponse} */ const resObj = { + status: reAuthenticatedUser ? true : false, + csrf: reAuthenticatedUser?.csrf_k, + user: reAuthenticatedUser + }; + res.json(resObj); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,7547], () => (__webpack_exec__(8251))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js.nft.json new file mode 100644 index 0000000..9018219 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/reAuthenticateUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/7547.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/refreshEntry.js b/dsql-app/.local_dist/server/pages/api/refreshEntry.js new file mode 100644 index 0000000..5594eb2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/refreshEntry.js @@ -0,0 +1,174 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9279; +exports.ids = [9279]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7281: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { table , db , id } = req.query; + /** @type {string | undefined} */ // @ts-ignore + const schemaJSONString = req.query.schema; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const query = `SELECT * FROM \`${table}\` WHERE id=?`; + const queryArray = [ + id?.toString() || "" + ]; + const entry = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_0___default()({ + database: db?.toString() || "", + queryString: query, + queryValuesArray: queryArray + }); + if (!entry || !entry[0]) { + return res.json({ + success: false, + msg: "Entry not found" + }); + } + //////////////////////////////////////// + /** @type {import("@/package-shared/types").DSQL_TableSchemaType} */ const tableSchema = JSON.parse(schemaJSONString || "{}"); + try { + for(let i = 0; i < tableSchema.fields.length; i++){ + const field = tableSchema.fields[i]; + if (field.encrypted && field.fieldName) { + entry[0][field.fieldName] = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_3___default()(entry[0][field.fieldName]); + } + } + } catch (/** @type {any} */ error) { + console.log("Error in parsing and decrypting fields in 'UpdateDbEntry' API ROute =>", error.message); + } + //////////////////////////////////////// + res.json({ + success: true, + entry: entry[0] + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/refreshEntry/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Deletion Failed!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311], () => (__webpack_exec__(7281))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/refreshEntry.js.nft.json b/dsql-app/.local_dist/server/pages/api/refreshEntry.js.nft.json new file mode 100644 index 0000000..a32b390 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/refreshEntry.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/registerUser.js b/dsql-app/.local_dist/server/pages/api/registerUser.js new file mode 100644 index 0000000..9be5912 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/registerUser.js @@ -0,0 +1,410 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2121; +exports.ids = [2121]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6142: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _package_shared_functions_backend_addMariadbUser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(4294); +/* harmony import */ var _package_shared_functions_backend_addMariadbUser__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_addMariadbUser__WEBPACK_IMPORTED_MODULE_6__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_9__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const sanitizedReqBody = req.body; + const { inviteObject } = sanitizedReqBody; + const first_name = sanitizedReqBody.first_name; + const last_name = sanitizedReqBody.last_name; + const email = sanitizedReqBody.email; + const password = sanitizedReqBody.password; + const username = sanitizedReqBody.username; + if (!email.match(/.*@.*\..*/)) return res.json({ + user: null, + msg: "Invalid Email" + }); + if (!first_name.match(/^[a-zA-Z]+$/) || !last_name.match(/^[a-zA-Z]+$/)) return res.json({ + user: null, + msg: "Invalid Name" + }); + if (password?.match(/ /)) return res.json({ + user: null, + msg: "Invalid Password" + }); + if (username?.match(/ /)) return res.json({ + user: null, + msg: "Invalid Username" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + /** ********************* Hash Password */ let hashedPassword = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_2___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: password + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let existingUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7___default()(`SELECT * FROM users WHERE email='${email}'`); + if (existingUser && existingUser[0]) return res.json({ + user: null, + msg: "User Already Exists" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const newUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8___default()({ + dbFullName: "datasquirel", + tableName: "users", + data: { + first_name, + last_name, + email, + password: hashedPassword, + username + } + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + // console.log(response); + if (!newUser?.insertId) return res.json({ + user: null, + msg: "Adding User to Database failed" + }); + /** + * Add a Mariadb User for this User + */ await _package_shared_functions_backend_addMariadbUser__WEBPACK_IMPORTED_MODULE_6___default()({ + userId: newUser.insertId + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Create new Stripe customer + * + * @description Create a new stripe customer + */ // let newStripeCustomer = await handlePayments( + // "create_customer", + // { + // email: email, + // name: first_name + " " + last_name, + // description: "Agent user", + // }, + // { + // id: newUser.insertId, + // email: email, + // first_name: first_name, + // user_type: "agents", + // } + // ); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Send email Verification + * + * @description Send verification email to newly created agent + */ let generatedToken = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_0___default()(JSON.stringify({ + id: newUser.insertId, + email: email, + dateCode: Date.now() + })); + _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_1___default()({ + to: email, + subject: "Verify Email Address", + text: "Please click the link to verify your email address", + html: fs.readFileSync("./email/send-email-verification-link.html", "utf8").replace(/{{host}}/, process.env.DSQL_HOST || "").replace(/{{token}}/, generatedToken || "") + }).then((mail)=>{ + // console.log("User verification email =>", mail); + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const isProduction = "production".match(/production/); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let userImageName = `users_${newUser.insertId}.jpg`; + let userImageTnumbnailName = `users_${newUser.insertId}_thumbnail.jpg`; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path"); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ let newUserSchemaFolderPath = `./jsonData/dbSchemas/users/user-${newUser.insertId}`; + let newUserMediaFolderPath = path__WEBPACK_IMPORTED_MODULE_4___default().join(STATIC_ROOT, `images/user-images/user-${newUser.insertId}`); + fs.mkdirSync(newUserSchemaFolderPath, { + recursive: true + }); + fs.mkdirSync(newUserMediaFolderPath, { + recursive: true + }); + fs.writeFileSync(`${newUserSchemaFolderPath}/main.json`, JSON.stringify([]), "utf8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let imagePath = path__WEBPACK_IMPORTED_MODULE_4___default().join(STATIC_ROOT, `images/user-images/user-${newUser.insertId}/user-${newUser.insertId}-profile.jpg`); + let imageThumbnailPath = path__WEBPACK_IMPORTED_MODULE_4___default().join(STATIC_ROOT, `images/user-images/user-${newUser.insertId}/user-${newUser.insertId}-profile-thumbnail.jpg`); + let prodImageUrl = imagePath.replace(STATIC_ROOT, process.env.DSQL_STATIC_HOST || ""); + let prodImageThumbnailUrl = imageThumbnailPath.replace(STATIC_ROOT, process.env.DSQL_STATIC_HOST || ""); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + fs.copyFileSync("./public/images/user_images/user-preset.png", imagePath); + fs.copyFileSync("./public/images/user_images/user-preset-thumbnail.png", imageThumbnailPath); + (0,child_process__WEBPACK_IMPORTED_MODULE_5__.execSync)(`chmod 644 ${imagePath} ${imageThumbnailPath}`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const updateImages = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_9___default()({ + dbFullName: "datasquirel", + tableName: "users", + identifierColumnName: "id", + identifierValue: newUser.insertId, + data: { + image: prodImageUrl, + image_thumbnail: prodImageThumbnailUrl + } + }); + // await global.DB_HANDLER(` + // UPDATE + // users + // SET + // image='${isProduction ? prodImageUrl : imagePath.replace(/^\.\/public/, "")}', + // image_thumbnail='${isProduction ? prodImageThumbnailUrl : imageThumbnailPath.replace(/^\.\/public/, "")}' + // WHERE + // id='${newUser.insertId}' + // `); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (inviteObject) { + const newUserUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8___default()({ + dbFullName: "datasquirel", + tableName: "user_users", + data: { + user_id: inviteObject.invite, + invited_user_id: newUser.insertId, + database_access: inviteObject.database_access, + user_priviledge: inviteObject.priviledge, + user_type: "admin", + first_name, + last_name, + email, + username, + image: prodImageUrl, + image_thumbnail: prodImageThumbnailUrl + } + }); + const inviteAccepted = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7___default()(`UPDATE invitations SET invitation_status='Accepted' WHERE inviting_user_id=? AND invited_user_email=?`, [ + inviteObject.invite, + email + ]); + const dbTableData = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7___default()(`SELECT db_tables_data FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + inviteObject.invite, + email + ]); + const clearEntries = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_7___default()(`DELETE FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=?`, [ + inviteObject.invite, + newUserUser.insertId + ]); + if (dbTableData && dbTableData[0]) { + const dbTableEntries = dbTableData[0].db_tables_data.split("|"); + for(let i = 0; i < dbTableEntries.length; i++){ + const dbTableEntry = dbTableEntries[i]; + const dbTableEntryArray = dbTableEntry.split("-"); + const [db_slug, table_slug] = dbTableEntryArray; + const newEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_8___default()({ + dbFullName: "datasquirel", + tableName: "delegated_user_tables", + data: { + delegated_user_id: newUserUser.insertId, + root_user_id: inviteObject.invite, + database: db_slug, + table: table_slug, + priviledge: inviteObject.priviledge + } + }); + } + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json(newUser); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(`Error in creating user => ${error.message}`); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/registerUser/main-catch-error", + message: error.message, + user: { + first_name, + last_name, + email + } + }); + res.json({ + user: null + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224,2163,3017,3403,7547,5886,5338,6926,7487,4294], () => (__webpack_exec__(6142))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/registerUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/registerUser.js.nft.json new file mode 100644 index 0000000..bab69df --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/registerUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/6926.js","../../chunks/7487.js","../../chunks/4294.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/generate-password/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/generate-password/main.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/generate-password/src/generate.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/renameMedia.js b/dsql-app/.local_dist/server/pages/api/renameMedia.js new file mode 100644 index 0000000..88e7fb5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/renameMedia.js @@ -0,0 +1,213 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5146; +exports.ids = [5146]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6354: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6715); +/* harmony import */ var _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ // const { mediaObject, newName, replace } = req.body; + const mediaObject = req.body.mediaObject; + const newName = req.body.newName; + const newThumbnailName = req.body.newThumbnailName; + const replace = req.body.replace; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const isProduction = "production".match(/production/); + const fileExtension = mediaObject.media_url.match(/\..{3,4}$/)[0]; + const isPrivate = mediaObject?.private == 1 ? true : false; + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + const grabedPaths = _functions_backend_grabPaths__WEBPACK_IMPORTED_MODULE_4___default()({ + isPrivate: isPrivate, + user: user, + folder: mediaObject.folder ? mediaObject.folder + "/" : "", + video: mediaObject.media_type?.match(/video/i) ? true : false + }); + if (!grabedPaths) { + throw new Error("Couldn't grab paths!"); + } + const { fileRootPath , urlRootPath , relativePath } = grabedPaths; + const rootFolder = fileRootPath; + let imagePath = rootFolder; + const oldNamePath = `${imagePath}${mediaObject.media_name}${fileExtension}`; + const newNamePath = `${imagePath}${newName}${fileExtension}`; + const oldNameThumbnailPath = `${imagePath}${mediaObject.media_name}_thumbnail${fileExtension}`; + const newNameThumbnailPath = `${imagePath}${newName}_thumbnail${fileExtension}`; + const mediaNameRegex = new RegExp(lodash__WEBPACK_IMPORTED_MODULE_5___default().escapeRegExp(`${mediaObject.media_name}`)); + const newUrl = mediaObject.media_url.replace(mediaNameRegex, newName); + const newThumbnailUrl = mediaObject.media_url.replace(mediaNameRegex, newName + "_thumbnail"); + const newPath = mediaObject.media_path ? mediaObject.media_path.replace(mediaNameRegex, newName) : `${relativePath}${newName}`; + const newThumbnailPath = mediaObject.media_thumbnail_path ? mediaObject.media_thumbnail_path.replace(mediaNameRegex, newName) : `${relativePath}${newThumbnailName}`; + if (fs.existsSync(newNamePath) && !replace) { + return res.json({ + success: false, + msg: "File already exists" + }); + } + fs.renameSync(oldNamePath, newNamePath); + try { + fs.renameSync(oldNameThumbnailPath, newNameThumbnailPath); + } catch (error) { + // console.log(`ERROR in 'renameMedia' API route => ${error.message}`); + } + const updateMediaName = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_2___default()(`UPDATE user_media SET media_name = ?, media_url = ?, media_thumbnail_url = ?, media_path = ?, media_thumbnail_path = ? WHERE id = ?`, [ + newName, + newUrl, + newThumbnailUrl, + newPath, + newThumbnailPath, + mediaObject.id, + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + console.log("Error in renaming media =>", error1.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/renameMedia/catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Renaming failed. Please try again." + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,6715], () => (__webpack_exec__(6354))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/renameMedia.js.nft.json b/dsql-app/.local_dist/server/pages/api/renameMedia.js.nft.json new file mode 100644 index 0000000..dc4200b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/renameMedia.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/6715.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js b/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js new file mode 100644 index 0000000..3719333 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js @@ -0,0 +1,120 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2095; +exports.ids = [2095]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5339: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const { userId , dbSlug } = req.body; + /** + * Input Validation + * + * @description Input Validation + */ const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${userId}_${dbSlug}`; + const tokenName = `${process.env.DSQL_USER_DELEGATED_DB_COOKIE_PREFIX}${dbFullName}`; + res.setHeader("Set-Cookie", [ + `${tokenName}=null;path=/;max-age=0` + ]); + res.json({ + success: true, + msg: "Processed Successfully" + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825], () => (__webpack_exec__(5339))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js.nft.json b/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js.nft.json new file mode 100644 index 0000000..9ed645d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/resetDelegatedDatabaseToken.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/resetPassword.js b/dsql-app/.local_dist/server/pages/api/resetPassword.js new file mode 100644 index 0000000..444dd4b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/resetPassword.js @@ -0,0 +1,96 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6559; +exports.ids = [6559]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2434: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + if (req.method === "GET") { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const { email , password } = req.query; + const hashedPassword = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_1___default()({ + encryptionKey: process.env.DSQL_ENCRYPTION_PASSWORD || "", + password: String(password) + }); + const updatePassword = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`UPDATE users SET password='${hashedPassword}' WHERE email='${email}'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: updatePassword?.affectedRows ? true : false + }); + } else { + return res.json({ + msg: "UNauthorized" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224], () => (__webpack_exec__(2434))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/resetPassword.js.nft.json b/dsql-app/.local_dist/server/pages/api/resetPassword.js.nft.json new file mode 100644 index 0000000..9b1889b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/resetPassword.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/2224.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/datasquirel/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js b/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js new file mode 100644 index 0000000..7f3c255 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js @@ -0,0 +1,165 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5774; +exports.ids = [5774]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6297: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ const sanitizedReqBody = req.body; + const { database , query , tables } = sanitizedReqBody; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const allowedQueryRegex = /^select .* from .*|^show tables$|^show indexes from .*|show columns from .*|^update |^delete from /i; + const disAllowedQueryRegex = /^create user|INFORMATION_SCHEMA/i; + if (!query?.match(allowedQueryRegex) || query?.match(disAllowedQueryRegex)) { + return res.json({ + success: false, + msg: "Disallowed query" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const result = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + database: `datasquirel_user_${user.id}_${database}`, + queryString: query + }); + if (!result) { + return res.json({ + success: false, + msg: "Query Failed!" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + result + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/runUserDbQuery/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,8326,1311], () => (__webpack_exec__(6297))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js.nft.json b/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js.nft.json new file mode 100644 index 0000000..a32b390 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/runUserDbQuery.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js b/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js new file mode 100644 index 0000000..da69ba8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js @@ -0,0 +1,128 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5110; +exports.ids = [5110]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4991: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +const handleNodemailer = __webpack_require__(6926); +const encrypt = __webpack_require__(7547); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + if (req.method === "GET") { + /** ********************* User Auth */ let user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res); + if (!user) return res.redirect(307, "/logout"); + // return; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let generatedToken = encrypt(JSON.stringify({ + id: user.id, + email: user.email, + dateCode: Date.now() + })); + let host = process.env.DSQL_HOST; + let mail = await handleNodemailer({ + to: user.email, + subject: "Verify Email Address", + text: "Please click the link to verify your email address", + html: fs.readFileSync("./email/send-email-verification-link.html", "utf8").replace(/{{host}}/, host || "").replace(/{{token}}/, generatedToken || "") + }); + //////////////////////////////////////// + if (!mail) return res.json({ + success: false + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,7547,6926], () => (__webpack_exec__(4991))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js.nft.json b/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js.nft.json new file mode 100644 index 0000000..7ed6a6c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sendEmailVerificationLink.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/7547.js","../../chunks/6926.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js b/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js new file mode 100644 index 0000000..7db34d3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js @@ -0,0 +1,166 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8426; +exports.ids = [8426]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9842: +/***/ ((module) => { + +// @ts-check +/** + * Delay async function + * + * @param {number} [milliseconds] + * + * @returns {Promise<boolean>} new user auth object payload + */ +module.exports = async function delay(milliseconds) { + await new Promise((resolve, reject)=>{ + setTimeout(()=>{ + resolve(true); + }, milliseconds || 1000); + }); + return true; +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }), + +/***/ 8647: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_delay__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9842); +/* harmony import */ var _functions_backend_delay__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_delay__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check + + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +const handleNodemailer = __webpack_require__(6926); +const encrypt = __webpack_require__(7547); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + if (req.method === "GET") { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let generatedToken = encrypt(JSON.stringify({ + email: req.query.email, + dateCode: Date.now() + })); + let host = process.env.DSQL_HOST; + const email = req.query.email; + if (!String(email).match(/.*@.*\..*/)) return res.json({ + user: null, + msg: "Invalid Email" + }); + const ip = req.headers["x-real-ip"] || req.headers["x-forwarded-for"] || req.connection.remoteAddress; + const site = process.env.DSQL_HOST || "https://datasquirel.com"; + let mail = await handleNodemailer({ + to: req.query.email?.toString() || "benoti.san@gmail.com", + subject: "Reset Your Password", + text: "Please click the link to reset your password", + html: fs.readFileSync("./email/send-password-reset-link.html", "utf8").replace(/{{host}}/, host || "").replace(/{{ip}}/, String(ip)).replace(/{{token}}/, generatedToken || ""), + alias: "Support" + }); + await _functions_backend_delay__WEBPACK_IMPORTED_MODULE_0___default()(); + handleNodemailer({ + to: "benoti.san@gmail.com", + subject: `Password Reset Attempt for ${email}`, + html: `<h1><u>${email}</u> tried to reset password</h1><p><b>${email}</b> attempted a password reset on ${site} from ${ip} with a wrong password.</p>` + }); + //////////////////////////////////////// + if (!mail) return res.json({ + success: false + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,7547,6926], () => (__webpack_exec__(8647))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js.nft.json b/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js.nft.json new file mode 100644 index 0000000..7ed6a6c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sendPasswordResetLink.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/7547.js","../../chunks/6926.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js b/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js new file mode 100644 index 0000000..1c5695d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js @@ -0,0 +1,197 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1799; +exports.ids = [1799]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3107: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7839); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * User auth + * + * @description Authenticate user + */ const { facebookUserId , facebookUserImage , facebookUserFullName , facebookUserFirstName , facebookUserLastName , facebookUserEmail , supEmail , } = req.body; + const { invite } = req.query; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const loggedInFacebookUser = await _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default()({ + email: facebookUserEmail, + payload: { + email: facebookUserEmail, + first_name: facebookUserFirstName, + last_name: facebookUserLastName, + social_id: facebookUserId, + social_platform: "facebook", + image: facebookUserImage, + image_thumbnail: facebookUserImage, + username: `facebook-user-${facebookUserId}` + }, + social_platform: "facebook", + res: res, + social_id: facebookUserId, + invitation: invite, + supEmail: supEmail + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json(loggedInFacebookUser); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + console.log(error.message); + // serverError({ + // component: "/api/social-login/github-auth/catch-error", + // message: error.message, + // user: user, + // }); + res.json({ + success: false, + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,6926,7487,613,4294,7839], () => (__webpack_exec__(3107))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js.nft.json new file mode 100644 index 0000000..8d3cd87 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/facebook-auth.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/6926.js","../../../chunks/7487.js","../../../chunks/613.js","../../../chunks/4294.js","../../../chunks/7839.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js b/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js new file mode 100644 index 0000000..74d02ee --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js @@ -0,0 +1,231 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3115; +exports.ids = [3115]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 5687: +/***/ ((module) => { + +module.exports = require("https"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7310: +/***/ ((module) => { + +module.exports = require("url"); + +/***/ }), + +/***/ 5389: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7839); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2127); +/* harmony import */ var _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check + + +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const githubLogin = __webpack_require__(6069); +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * User auth + * + * @description Authenticate user + */ const { code , email , invite } = req.query; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const gitHubUser = await githubLogin({ + code: code?.toString() || "", + clientId: process.env.DSQL_GITHUB_ID || "", + clientSecret: process.env.DSQL_GITHUB_SECRET || "" + }); + if (!gitHubUser) { + return res.json({ + success: false, + msg: "No github user returned" + }); + } + if (!gitHubUser?.email && !email) { + return res.json({ + success: false, + msg: "Github User Email not present" + }); + } + const loggedInGithubUser = await _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default()({ + email: gitHubUser.email, + payload: { + email: gitHubUser.email, + first_name: _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_1___default()(gitHubUser.login)?.split(" ")[0], + last_name: _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_1___default()(gitHubUser.login)?.split(" ")[1], + social_id: gitHubUser.id, + social_platform: "github", + image: gitHubUser.avatar_url, + image_thumbnail: gitHubUser.avatar_url, + username: "github-user-" + gitHubUser.name + }, + social_platform: "github", + invitation: invite, + res: res, + social_id: gitHubUser.id, + supEmail: email ? email.toString() : undefined + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json(loggedInGithubUser); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + console.log("ERROR in 'github-auth' API route =>", error.message); + // serverError({ + // component: "/api/social-login/github-auth/catch-error", + // message: error.message, + // user: user, + // }); + res.json({ + success: false, + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,6926,7487,613,4294,7839,722,9971], () => (__webpack_exec__(5389))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js.nft.json new file mode 100644 index 0000000..d0cdb00 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/github-auth.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/6926.js","../../../chunks/7487.js","../../../chunks/613.js","../../../chunks/4294.js","../../../chunks/7839.js","../../../chunks/722.js","../../../chunks/9971.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js b/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js new file mode 100644 index 0000000..4d0a535 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js @@ -0,0 +1,265 @@ +(() => { +var exports = {}; +exports.id = 5288; +exports.ids = [5288]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +"use strict"; +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +"use strict"; +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6781: +/***/ ((module) => { + +"use strict"; +module.exports = require("google-auth-library"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +"use strict"; +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +"use strict"; +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +"use strict"; +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +"use strict"; +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +"use strict"; +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +"use strict"; +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +"use strict"; +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +"use strict"; +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +"use strict"; +module.exports = require("path"); + +/***/ }), + +/***/ 5382: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +// @ts-check +const { createHmac } = __webpack_require__(6113); +// +/** + * # Password Hash function + * @param {string} password + * @returns + */ function hashPassword(password) { + const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD || ""); + hmac.update(password); + let hashed = hmac.digest("base64"); + return hashed; +} +exports.hashPassword = hashPassword; // export const comparePasswords = async (password) => { + // const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD); + // hmac.update(password); + // let hashed = hmac.digest("base64"); + // let dbPass = await global.DB_HANDLER(`SELECT * FROM users WHERE password = '${hashed}'`); + // console.log(dbPass); + // return dbPass; + // }; + + +/***/ }), + +/***/ 2666: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7839); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const { OAuth2Client } = __webpack_require__(6781); +const { hashPassword , } = __webpack_require__(5382); +const serverError = __webpack_require__(2163); + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * User auth + * + * @description Authenticate user + */ const reqBody = req.body; + const { invite } = req.query; + const { token } = reqBody; + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Send Response + * + * @description Send a boolean response + */ try { + const client = new OAuth2Client("392696781563-imb0ddojfn6m4bdokjk5v80jn546t9tq.apps.googleusercontent.com"); + const ticket = await client.verifyIdToken({ + idToken: token, + audience: "392696781563-imb0ddojfn6m4bdokjk5v80jn546t9tq.apps.googleusercontent.com" + }); + const payload = ticket.getPayload(); + if (!payload || !payload.email_verified) { + res.json({ + user: null, + msg: "Invalid Credentials" + }); + return; + } + const { given_name , family_name , email , sub , picture , email_verified } = payload; + if (!email) throw new Error("No Email"); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const loggedInGoogleUser = await _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_0___default()({ + email: email, + payload: { + email: email, + first_name: given_name, + last_name: family_name, + social_id: sub, + social_platform: "google", + image: picture, + image_thumbnail: picture, + username: `google-user-${sub}` + }, + social_platform: "google", + res: res, + social_id: sub, + invitation: invite + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json(loggedInGoogleUser); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + console.log(error.message); + // serverError({ + // component: "/api/social-login/github-auth/catch-error", + // message: error.message, + // user: user, + // }); + res.json({ + success: false, + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,6926,7487,613,4294,7839], () => (__webpack_exec__(2666))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js.nft.json new file mode 100644 index 0000000..6c57e84 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/google-auth.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/6926.js","../../../chunks/7487.js","../../../chunks/613.js","../../../chunks/4294.js","../../../chunks/7839.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/node-fetch/package.json","../../../../../node_modules/google-auth-library/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/node-fetch/lib/index.js","../../../../../node_modules/google-auth-library/build/src/index.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/google-auth-library/build/src/transporters.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/google-auth-library/build/src/auth/authclient.js","../../../../../node_modules/google-auth-library/build/src/auth/envDetect.js","../../../../../node_modules/google-auth-library/build/src/auth/googleauth.js","../../../../../node_modules/google-auth-library/build/src/auth/iam.js","../../../../../node_modules/google-auth-library/build/src/auth/idtokenclient.js","../../../../../node_modules/google-auth-library/build/src/auth/computeclient.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtaccess.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtclient.js","../../../../../node_modules/google-auth-library/build/src/auth/impersonated.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2client.js","../../../../../node_modules/google-auth-library/build/src/auth/loginticket.js","../../../../../node_modules/google-auth-library/build/src/auth/refreshclient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsclient.js","../../../../../node_modules/google-auth-library/build/src/auth/identitypoolclient.js","../../../../../node_modules/google-auth-library/build/src/auth/baseexternalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/externalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/downscopedclient.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-client.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/google-auth-library/build/src/options.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/google-auth-library/build/src/auth/externalAccountAuthorizedUserClient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsrequestsigner.js","../../../../../node_modules/google-auth-library/build/src/auth/stscredentials.js","../../../../../node_modules/google-auth-library/build/src/auth/executable-response.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-handler.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/whatwg-url/package.json","../../../../../node_modules/whatwg-url/lib/public-api.js","../../../../../node_modules/google-auth-library/build/src/crypto/crypto.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/debug/package.json","../../../../../node_modules/debug/src/index.js","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2common.js","../../../../../node_modules/lru-cache/package.json","../../../../../node_modules/lru-cache/index.js","../../../../../node_modules/jws/package.json","../../../../../node_modules/jws/index.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/ecdsa-sig-formatter/package.json","../../../../../node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/arrify/index.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/whatwg-url/lib/URL.js","../../../../../node_modules/whatwg-url/lib/url-state-machine.js","../../../../../node_modules/google-auth-library/build/src/crypto/browser/crypto.js","../../../../../node_modules/google-auth-library/build/src/crypto/node/crypto.js","../../../../../node_modules/gcp-metadata/package.json","../../../../../node_modules/gcp-metadata/build/src/index.js","../../../../../node_modules/gaxios/package.json","../../../../../node_modules/gaxios/build/src/index.js","../../../../../node_modules/gtoken/package.json","../../../../../node_modules/gtoken/build/src/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/debug/src/browser.js","../../../../../node_modules/debug/src/node.js","../../../../../node_modules/arrify/package.json","../../../../../node_modules/whatwg-url/lib/utils.js","../../../../../node_modules/whatwg-url/lib/URL-impl.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/jws/lib/verify-stream.js","../../../../../node_modules/jws/lib/sign-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js","../../../../../node_modules/debug/src/common.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/gaxios/build/src/gaxios.js","../../../../../node_modules/gaxios/build/src/common.js","../../../../../node_modules/gcp-metadata/build/src/gcp-residency.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/yallist/package.json","../../../../../node_modules/yallist/yallist.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/jws/lib/data-stream.js","../../../../../node_modules/jws/lib/tostring.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/tr46/package.json","../../../../../node_modules/tr46/index.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/webidl-conversions/package.json","../../../../../node_modules/webidl-conversions/lib/index.js","../../../../../node_modules/gaxios/build/src/retry.js","../../../../../node_modules/fast-text-encoding/package.json","../../../../../node_modules/fast-text-encoding/text.min.js","../../../../../node_modules/safe-buffer/package.json","../../../../../node_modules/safe-buffer/index.js","../../../../../node_modules/base64-js/package.json","../../../../../node_modules/base64-js/index.js","../../../../../node_modules/supports-color/index.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/supports-color/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/yallist/iterator.js","../../../../../node_modules/json-bigint/package.json","../../../../../node_modules/json-bigint/index.js","../../../../../node_modules/google-p12-pem/package.json","../../../../../node_modules/google-p12-pem/build/src/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/tr46/lib/mappingTable.json","../../../../../node_modules/ms/package.json","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/jwa/package.json","../../../../../node_modules/jwa/index.js","../../../../../node_modules/ms/index.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/extend/package.json","../../../../../node_modules/is-stream/index.js","../../../../../node_modules/json-bigint/lib/stringify.js","../../../../../node_modules/json-bigint/lib/parse.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/extend/index.js","../../../../../node_modules/https-proxy-agent/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/https-proxy-agent/dist/index.js","../../../../../node_modules/is-stream/package.json","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/has-flag/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/has-flag/package.json","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/https-proxy-agent/dist/agent.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/buffer-equal-constant-time/package.json","../../../../../node_modules/buffer-equal-constant-time/index.js","../../../../../node_modules/node-forge/package.json","../../../../../node_modules/node-forge/lib/index.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/https-proxy-agent/dist/parse-proxy-response.js","../../../../../node_modules/bignumber.js/package.json","../../../../../node_modules/bignumber.js/bignumber.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/node-forge/lib/forge.js","../../../../../node_modules/node-forge/lib/aes.js","../../../../../node_modules/node-forge/lib/aesCipherSuites.js","../../../../../node_modules/node-forge/lib/asn1.js","../../../../../node_modules/node-forge/lib/cipher.js","../../../../../node_modules/node-forge/lib/des.js","../../../../../node_modules/node-forge/lib/ed25519.js","../../../../../node_modules/node-forge/lib/hmac.js","../../../../../node_modules/node-forge/lib/kem.js","../../../../../node_modules/node-forge/lib/log.js","../../../../../node_modules/node-forge/lib/md.all.js","../../../../../node_modules/node-forge/lib/mgf1.js","../../../../../node_modules/node-forge/lib/pbkdf2.js","../../../../../node_modules/node-forge/lib/pem.js","../../../../../node_modules/node-forge/lib/pkcs1.js","../../../../../node_modules/node-forge/lib/pkcs12.js","../../../../../node_modules/node-forge/lib/pkcs7.js","../../../../../node_modules/node-forge/lib/pki.js","../../../../../node_modules/node-forge/lib/prime.js","../../../../../node_modules/node-forge/lib/prng.js","../../../../../node_modules/node-forge/lib/pss.js","../../../../../node_modules/node-forge/lib/random.js","../../../../../node_modules/node-forge/lib/rc2.js","../../../../../node_modules/node-forge/lib/ssh.js","../../../../../node_modules/node-forge/lib/tls.js","../../../../../node_modules/node-forge/lib/util.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/agent-base/package.json","../../../../../node_modules/agent-base/dist/src/index.js","../../../../../node_modules/node-forge/lib/oids.js","../../../../../node_modules/node-forge/lib/cipherModes.js","../../../../../node_modules/node-forge/lib/jsbn.js","../../../../../node_modules/node-forge/lib/sha512.js","../../../../../node_modules/node-forge/lib/asn1-validator.js","../../../../../node_modules/node-forge/lib/md.js","../../../../../node_modules/node-forge/lib/md5.js","../../../../../node_modules/node-forge/lib/sha1.js","../../../../../node_modules/node-forge/lib/sha256.js","../../../../../node_modules/node-forge/lib/pkcs7asn1.js","../../../../../node_modules/node-forge/lib/pbe.js","../../../../../node_modules/node-forge/lib/rsa.js","../../../../../node_modules/node-forge/lib/x509.js","../../../../../node_modules/node-forge/lib/baseN.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/node-forge/lib/mgf.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/agent-base/dist/src/promisify.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js new file mode 100644 index 0000000..103f332 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js @@ -0,0 +1,109 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6267; +exports.ids = [6267]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9986: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ if (!req.query?.email?.toString()?.match(/^\S+$/)) { + res.json({ + email: null + }); + } + let email = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT email FROM users WHERE email=?`, [ + req.query.email, + ]); + if (email && email[0]) { + res.json({ + email: email + }); + } else { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + email: null + }); + } +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224], () => (__webpack_exec__(9986))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js.nft.json new file mode 100644 index 0000000..1d23146 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkEmail.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-api-runtime.js","../../../../chunks/2224.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js new file mode 100644 index 0000000..3632945 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js @@ -0,0 +1,107 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5445; +exports.ids = [5445]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8740: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ const sanitizedReqBody = req.query; + const { social_id , social_platform } = sanitizedReqBody; + let socialId = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT social_id FROM users WHERE social_id=? AND social_platform=?`, [ + social_id, + social_platform + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (social_id && social_id[0]) { + res.json({ + social_id: socialId + }); + } else { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + social_id: null + }); + } +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224], () => (__webpack_exec__(8740))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js.nft.json new file mode 100644 index 0000000..1d23146 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/checkSocialId.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-api-runtime.js","../../../../chunks/2224.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js b/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js new file mode 100644 index 0000000..119917b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js @@ -0,0 +1,107 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4828; +exports.ids = [4828]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6750: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ const sanitizedReqBody = req.query; + const { social_id , social_platform } = sanitizedReqBody; + let email = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT email FROM users WHERE social_id=? AND social_platform=?`, [ + social_id, + social_platform + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (email && email[0]) { + res.json({ + email: email[0].email + }); + } else { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + email: null + }); + } +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224], () => (__webpack_exec__(6750))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js.nft.json b/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js.nft.json new file mode 100644 index 0000000..1d23146 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/social-login/utils/getEmailFromSocialId.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-api-runtime.js","../../../../chunks/2224.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/create.js b/dsql-app/.local_dist/server/pages/api/sql-users/create.js new file mode 100644 index 0000000..9804425 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/create.js @@ -0,0 +1,235 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3363; +exports.ids = [3363]; +exports.modules = { + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8210: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +const fs = __webpack_require__(7147); +const generator = __webpack_require__(3785); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ const { data , edit , grants } = req.body; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const defaultMariadbUserHost = process.env.DSQL_DB_HOST || "127.0.0.1"; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const username = `dsql_user_${user.id}`; + const { host , password } = data; + if (!host.match(/./)) { + throw new Error("Invalid host"); + } + if (host.match(/^%$/)) { + throw new Error("Cannot set a catch-all host for this user."); + } + const sanitizedNewHost = String(host).replace(/[^a-zA-Z0-9-\.\:\/\%]/g, ""); + const finPassword = password?.match(/./) ? password : generator.generate({ + length: 16, + numbers: true, + symbols: true, + uppercase: true, + exclude: "*#.'`\"" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const existinSQLUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM mysql.user WHERE User = ? AND (Host = ? OR Host = ?)`, [ + username, + sanitizedNewHost, + defaultMariadbUserHost + ]); + const doesSQLUserExist = Boolean(existinSQLUser?.[0]?.User); + if (doesSQLUserExist) { + throw new Error("SQL User already exists. Remember if you have the '%' host on your primary user, it catches all other hosts."); + } + const absoluteHost = Boolean(sanitizedNewHost.match(/^%$/)); + if (absoluteHost) { + throw new Error("Can't create a catch-all host for this username. Catch-all host is only allowed on the primary user."); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const existingUsersCount = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT COUNT(*) FROM mariadb_users WHERE user_id = ?`, [ + user.id + ]); + if (existingUsersCount?.[0]?.["COUNT(*)"] >= 10) { + throw new Error("User limit reached"); + } + const encryptedPassword = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6___default()(finPassword); + const newMariaDBUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`INSERT INTO mariadb_users (user_id, username, host, password, grants) VALUES (?, ?, ?, ?, ?)`, [ + user.id, + username, + sanitizedNewHost, + encryptedPassword, + JSON.stringify(grants), + ]); + if (!newMariaDBUser?.insertId) { + throw new Error("Error in adding SQL user"); + } + const execPath = path__WEBPACK_IMPORTED_MODULE_3___default().resolve(__dirname, "../../../shell/mariadb-users"); + const execSQLUserScript = (0,child_process__WEBPACK_IMPORTED_MODULE_4__.execSync)(`node refreshUsersAndGrants.js --userId ${user.id} --username ${username} --host ${sanitizedNewHost}`, { + cwd: execPath + }); + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/acceptUserInvitation/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Error in adding SQL user =>" + error.message, + err: error.message + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,7547], () => (__webpack_exec__(8210))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/create.js.nft.json b/dsql-app/.local_dist/server/pages/api/sql-users/create.js.nft.json new file mode 100644 index 0000000..5fae6fc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/create.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../chunks/3017.js","../../../chunks/7547.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/delete.js b/dsql-app/.local_dist/server/pages/api/sql-users/delete.js new file mode 100644 index 0000000..0f62df2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/delete.js @@ -0,0 +1,175 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7049; +exports.ids = [7049]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9577: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ const { id } = req.body; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + const existingMariaDBUserArray = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT * FROM mariadb_users WHERE id = ? AND user_id = ?`, [ + id, + user.id + ]); + /** + * @type {import("@/package-shared/types").MYSQL_mariadb_users_table_def | undefined} + */ const activeMariadbUserObject = existingMariaDBUserArray?.[0]; + if (!activeMariadbUserObject?.id) { + throw new Error("Active User couldn't be verified"); + } + const isPrimary = String(activeMariadbUserObject.primary)?.match(/1/) ? true : false; + if (isPrimary) { + throw new Error("Cannot Delete Primary User"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const username = `dsql_user_${user.id}`; + const host = activeMariadbUserObject.host; + const deleteUserFromDatasquirelDb = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`DELETE FROM mariadb_users WHERE user_id = ? AND id = ?`, [ + user.id, + activeMariadbUserObject.id + ]); + const deleteSQLUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`DROP USER '${username}'@'${host}'`); + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/acceptUserInvitation/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Error in adding SQL user =>" + error.message, + err: error.message + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(9577))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/delete.js.nft.json b/dsql-app/.local_dist/server/pages/api/sql-users/delete.js.nft.json new file mode 100644 index 0000000..fe8ca1f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/delete.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/update.js b/dsql-app/.local_dist/server/pages/api/sql-users/update.js new file mode 100644 index 0000000..6dc4114 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/update.js @@ -0,0 +1,219 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9685; +exports.ids = [9685]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2287: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ const { data , edit , prev , grants } = req.body; + /** + * @type {import("@/package-shared/types").MYSQL_mariadb_users_table_def | undefined} + */ const existingMariaDBUser = prev; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + if (!existingMariaDBUser?.id) { + throw new Error("Invalid existing DB entry"); + } + const existingMariaDBUserArray = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT * FROM mariadb_users WHERE id = ? AND user_id = ?`, [ + existingMariaDBUser.id, + user.id + ]); + /** + * @type {import("@/package-shared/types").MYSQL_mariadb_users_table_def | undefined} + */ const activeMariadbUserObject = existingMariaDBUserArray?.[0]; + if (!activeMariadbUserObject?.id) { + throw new Error("Active User couldn't be verified"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const username = `dsql_user_${user.id}`; + const { host , password } = data; + if (!host) { + throw new Error("No host provided"); + } + if (host.match(/^%$/)) { + throw new Error("Cannot set a catch-all host for this user."); + } + const sanitizedNewHost = String(host).replace(/[^a-zA-Z0-9-\.\:\/\%]/g, ""); + if (activeMariadbUserObject.host != data.host) { + const existinUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT * FROM mariadb_users WHERE user_id = ? AND host = ?`, [ + user.id, + sanitizedNewHost + ]); + if (!existinUser?.[0]?.id) { + const renameUser = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`RENAME USER '${username}'@'${activeMariadbUserObject.host}' TO '${username}'@'${sanitizedNewHost}'`); + } else { + throw new Error("User already exists with this host. Please choose another host."); + } + } + const encryptedPassword = _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_6___default()(password); + const finalPassword = encryptedPassword == activeMariadbUserObject.password ? activeMariadbUserObject.password : encryptedPassword; + const updateUserEntry = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`UPDATE mariadb_users SET host = ?, password = ?, grants = ? WHERE id = ?`, [ + sanitizedNewHost, + finalPassword, + JSON.stringify(grants), + activeMariadbUserObject.id, + ]); + const updateSQLUserPassword = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SET PASSWORD FOR '${username}'@'${sanitizedNewHost}' = PASSWORD('${password}');`); + const execPath = path__WEBPACK_IMPORTED_MODULE_4___default().resolve(__dirname, "../../../shell/mariadb-users"); + const execSQLUserScript = (0,child_process__WEBPACK_IMPORTED_MODULE_5__.execSync)(`node refreshUsersAndGrants.js --userId ${user.id} --username ${username} --host ${sanitizedNewHost} --sql-user-id ${activeMariadbUserObject.id}}`, { + cwd: execPath + }); + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/acceptUserInvitation/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Error in adding SQL user =>" + error.message, + err: error.message + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,7547], () => (__webpack_exec__(2287))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sql-users/update.js.nft.json b/dsql-app/.local_dist/server/pages/api/sql-users/update.js.nft.json new file mode 100644 index 0000000..9cf8917 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sql-users/update.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../chunks/3017.js","../../../chunks/7547.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/stream/[path].js b/dsql-app/.local_dist/server/pages/api/stream/[path].js new file mode 100644 index 0000000..89a66e4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/stream/[path].js @@ -0,0 +1,83 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3620; +exports.ids = [3620]; +exports.modules = { + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2288: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Invalid Request" + }); + const videoDir = path__WEBPACK_IMPORTED_MODULE_0___default().resolve(process.cwd(), "./public/videos"); + const videoName = req.query.name; + if (!videoName || typeof videoName !== "string") { + res.status(400).end("No video name provided"); + return; + } + const videoPath = path__WEBPACK_IMPORTED_MODULE_0___default().join(videoDir, videoName); + if (!fs.existsSync(videoPath)) { + res.status(400).end("Video not found"); + return; + } + const stat = fs.statSync(videoPath); + const fileSize = stat.size; + const range = req.headers.range; + const videoReadStream = fs.createReadStream(videoPath); + videoReadStream.pipe(res); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = (__webpack_exec__(2288)); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/stream/[path].js.nft.json b/dsql-app/.local_dist/server/pages/api/stream/[path].js.nft.json new file mode 100644 index 0000000..cb5da74 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/stream/[path].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sync-table-data.js b/dsql-app/.local_dist/server/pages/api/sync-table-data.js new file mode 100644 index 0000000..c2d43b1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sync-table-data.js @@ -0,0 +1,357 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4266; +exports.ids = [4266]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7441: +/***/ ((module) => { + +module.exports = require("sharp"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6339: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ handler) +}); + +// EXTERNAL MODULE: ./package-shared/functions/backend/encrypt.js +var encrypt = __webpack_require__(7547); +// EXTERNAL MODULE: ./functions/backend/fsWriteImageToDiskFromBase64.js +var fsWriteImageToDiskFromBase64 = __webpack_require__(5910); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2163); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(6825); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(2224); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/importExportTableDataFn.js +var importExportTableDataFn = __webpack_require__(2630); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(1352); +;// CONCATENATED MODULE: ./functions/backend/delegatedUser.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const http = __webpack_require__(3685); +const delegatedUser_serverError = __webpack_require__(2163); +const delegatedUser_DB_HANDLER = __webpack_require__(2224); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} delegatedUserTableObject + * @property {string} db + * @property {string} table + */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @async + * + * @param {object} params + * @param {delegatedUserTableObject[]} params.tbls - Database name slug + * @param {{ id: number, first_name: string, last_name: string }} params.user - user object + * @param {any} params.query - query params + * + * @returns {Promise<{ + * isPriviledged: boolean, + * rootUserId?: number, + * error?: string, + * }>} new user auth object payload + */ async function delegatedUser({ tbls , user , query }) { + /** + * Fetch user + * + * @description Fetch user from db + */ let rootUserId; + if (!query?.delegated) { + return { + isPriviledged: true, + rootUserId: user.id + }; + } + try { + for(let i = 0; i < tbls.length; i++){ + const obj = tbls[i]; + const check = await delegatedUser_DB_HANDLER(`SELECT * FROM delegated_user_tables WHERE delegated_user_id='${user.id}' AND \`database\`='${obj.db}' AND \`table\`='${obj.table}'`); + if (!check?.[0]?.root_user_id) throw new Error("Unauthorized!"); + const delegateObj = check[0]; + if (!rootUserId) rootUserId = delegateObj.root_user_id; + } + return { + isPriviledged: true, + rootUserId + }; + } catch (/** @type {any} */ error) { + return { + isPriviledged: false, + rootUserId, + error: error.message + }; + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(8164); +;// CONCATENATED MODULE: ./pages/api/sync-table-data.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} SyncTableBodySrcDstObject + * @property {string} db + * @property {string} table + */ /** + * @typedef {object} SyncTableBody + * @property {"Pull" | "Push"} paradigm + * @property {SyncTableBodySrcDstObject} src + * @property {SyncTableBodySrcDstObject} dst + * @property {any} [delegated] + */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await userAuth_default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * @type {SyncTableBody} + */ const { paradigm , src , dst } = req.body; + /** + * Send Response + * + * @description Send a boolean response + */ try { + const delegatedUserObj = await delegatedUser({ + tbls: [ + { + db: src.db, + table: src.table + }, + { + db: dst.db, + table: dst.table + }, + ], + user, + query: req.query + }); + if (!delegatedUserObj.rootUserId || !delegatedUserObj.isPriviledged) throw new Error(delegatedUserObj.error || "Unauthorized!"); + const userDbSchemaData = (0,grabUserSchemaData["default"])({ + userId: delegatedUserObj.rootUserId + }); + if (!userDbSchemaData) throw new Error("User Schema Data not Found!"); + const dstDbName = `${process.env.DSQL_USER_DB_PREFIX}${delegatedUserObj.rootUserId}_${dst.db}`; + const srcDbName = `${process.env.DSQL_USER_DB_PREFIX}${delegatedUserObj.rootUserId}_${src.db}`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ const dstDbSchema = userDbSchemaData.find((db)=>db.dbFullName == dstDbName); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType | undefined} */ const srcDbSchema = userDbSchemaData.find((db)=>db.dbFullName == srcDbName); + const dstTableSchema = dstDbSchema?.tables.find((tbl)=>tbl.tableName == dst.table); + const srcTableSchema = srcDbSchema?.tables.find((tbl)=>tbl.tableName == src.table); + if (!dstTableSchema || !srcTableSchema) throw new Error("Operation Failed! Tables Schemas not present."); + const isEqual = external_lodash_default().isEqual(srcTableSchema.fields, dstTableSchema.fields); + if (!isEqual) throw new Error("Tables incompatible"); + switch(paradigm){ + case "Push": + const srcData = await DB_HANDLER_default()(`SELECT * FROM ${srcDbName}.${src.table}`); + const pushData = await (0,importExportTableDataFn/* default */.Z)({ + dbName: dst.db, + paradigm: "import", + payload: srcData, + tableName: dst.table, + userId: delegatedUserObj.rootUserId, + payloadType: "object" + }); + await pruneTable({ + dbName: dst.db, + tableName: dst.table, + data: srcData, + userId: delegatedUserObj.rootUserId + }); + return res.json({ + success: true, + payload: pushData + }); + case "Pull": + const dstData = await DB_HANDLER_default()(`SELECT * FROM ${dstDbName}.${dst.table}`); + const pullData = await (0,importExportTableDataFn/* default */.Z)({ + dbName: src.db, + paradigm: "import", + payload: dstData, + tableName: src.table, + userId: delegatedUserObj.rootUserId, + payloadType: "object" + }); + await pruneTable({ + dbName: src.db, + tableName: src.table, + data: dstData, + userId: delegatedUserObj.rootUserId + }); + return res.json({ + success: true, + payload: pullData + }); + default: + break; + } + res.json({ + success: false + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + //////////////////////////////////////// + serverError_default()({ + component: "/api/sync-table-data", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: error.message + }); + //////////////////////////////////////// + } +} +/** + * + * @param {object} param0 + * @param {string | number} param0.userId + * @param {string} param0.dbName + * @param {string} param0.tableName + * @param {any[]} param0.data + */ async function pruneTable({ dbName , tableName , data , userId }) { + const dbFullName = `${process.env.DSQL_USER_DB_PREFIX}${userId}_${dbName.replace(/ /g, "")}`; + const ids = data.map((dt)=>dt.id); + let query = `DELETE FROM ${dbFullName}.${tableName}`; + if (ids?.[0]) query += ` WHERE id NOT IN (${ids.join(",")})`; + const prune = await DB_HANDLER_default()(query); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,5338,1352,6715,8164,5910,2630], () => (__webpack_exec__(6339))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/sync-table-data.js.nft.json b/dsql-app/.local_dist/server/pages/api/sync-table-data.js.nft.json new file mode 100644 index 0000000..3fa7856 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/sync-table-data.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../chunks/1352.js","../../chunks/6715.js","../../chunks/8164.js","../../chunks/5910.js","../../chunks/2630.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/sharp/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/sharp/lib/index.js","../../../../node_modules/sharp/lib/constructor.js","../../../../node_modules/sharp/lib/input.js","../../../../node_modules/sharp/lib/composite.js","../../../../node_modules/sharp/lib/operation.js","../../../../node_modules/sharp/lib/resize.js","../../../../node_modules/sharp/lib/colour.js","../../../../node_modules/sharp/lib/channel.js","../../../../node_modules/sharp/lib/output.js","../../../../node_modules/sharp/lib/utility.js","../../../../node_modules/sharp/lib/is.js","../../../../node_modules/sharp/lib/sharp.js","../../../../node_modules/sharp/lib/libvips.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/lru-cache/package.json","../../../../node_modules/lru-cache/index.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/sharp/node_modules/semver/functions/coerce.js","../../../../node_modules/sharp/node_modules/semver/functions/satisfies.js","../../../../node_modules/sharp/node_modules/semver/functions/gte.js","../../../../node_modules/sharp/node_modules/semver/package.json","../../../../node_modules/color/index.js","../../../../node_modules/detect-libc/package.json","../../../../node_modules/detect-libc/lib/detect-libc.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/color/package.json","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/sharp/node_modules/semver/functions/compare.js","../../../../node_modules/sharp/node_modules/semver/functions/parse.js","../../../../node_modules/sharp/node_modules/semver/classes/range.js","../../../../node_modules/sharp/node_modules/semver/classes/semver.js","../../../../node_modules/sharp/node_modules/semver/internal/re.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/detect-libc/lib/process.js","../../../../node_modules/detect-libc/lib/filesystem.js","../../../../node_modules/yallist/package.json","../../../../node_modules/yallist/yallist.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/sharp/node_modules/semver/internal/debug.js","../../../../node_modules/sharp/node_modules/semver/internal/constants.js","../../../../node_modules/sharp/node_modules/semver/internal/parse-options.js","../../../../node_modules/sharp/node_modules/semver/internal/identifiers.js","../../../../node_modules/sharp/node_modules/semver/classes/comparator.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/yallist/iterator.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/color/node_modules/color-convert/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/color/node_modules/color-convert/package.json","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/sharp/node_modules/semver/functions/cmp.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/color-string/index.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/color-string/package.json","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/color/node_modules/color-convert/conversions.js","../../../../node_modules/color/node_modules/color-convert/route.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sharp/node_modules/semver/functions/eq.js","../../../../node_modules/sharp/node_modules/semver/functions/neq.js","../../../../node_modules/sharp/node_modules/semver/functions/gt.js","../../../../node_modules/sharp/node_modules/semver/functions/lte.js","../../../../node_modules/sharp/node_modules/semver/functions/lt.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/color-name/package.json","../../../../node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/color/node_modules/color-name/package.json","../../../../node_modules/color/node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/package.json","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/test/cors.js b/dsql-app/.local_dist/server/pages/api/test/cors.js new file mode 100644 index 0000000..727b2f0 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/test/cors.js @@ -0,0 +1,57 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3148; +exports.ids = [3148]; +exports.modules = { + +/***/ 1319: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @type {import("../../../node_modules/next/dist/shared/lib/utils").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ res.setHeader("Access-Control-Allow-Credentials", "true"); + res.setHeader("Access-Control-Allow-Origin", "*"); + res.setHeader("Access-Control-Allow-Methods", "*"); + res.setHeader("Access-Control-Allow-Headers", "*"); + res.status(200).json({ + title: "Hello There", + message: "General Kenobi" + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = (__webpack_exec__(1319)); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/test/cors.js.nft.json b/dsql-app/.local_dist/server/pages/api/test/cors.js.nft.json new file mode 100644 index 0000000..cb5da74 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/test/cors.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../../package.json","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/test/mail.js b/dsql-app/.local_dist/server/pages/api/test/mail.js new file mode 100644 index 0000000..9628f78 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/test/mail.js @@ -0,0 +1,100 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4914; +exports.ids = [4914]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 6871: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "GET") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const mail = await _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_0___default()({ + alias: "support", + html: "<h1>Test Mail</h1><p>Hi there DSQL. Firing up on all systems now.</p>", + subject: "Test Mail", + text: "Test Mail", + to: "dexomediaorg@gmail.com" + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/addUserMedia/catch-error", + message: error.message + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2163,6926], () => (__webpack_exec__(6871))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/test/mail.js.nft.json b/dsql-app/.local_dist/server/pages/api/test/mail.js.nft.json new file mode 100644 index 0000000..6ba5e98 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/test/mail.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/2163.js","../../../chunks/6926.js","../../../../package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/unsubscribe.js b/dsql-app/.local_dist/server/pages/api/unsubscribe.js new file mode 100644 index 0000000..c52453a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/unsubscribe.js @@ -0,0 +1,135 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7048; +exports.ids = [7048]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3553: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Validate Form + * + * @description Check if request body is valid + */ const sanitizedReqBody = req.body; + const { email , alerts , userId } = sanitizedReqBody; + if (!alerts) { + let existingAlert = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1___default()(`SELECT email FROM unsubscribes WHERE email=? AND type='alerts'`, [ + email + ]); + if (!existingAlert || !existingAlert[0]) { + await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "unsubscribes", + data: { + email: email, + type: "alerts", + user_id: userId ? userId : null + } + }); + } + } else if (alerts) { + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_1___default()(`DELETE FROM unsubscribes WHERE email=? AND type='alerts'`, [ + email + ]); + } + /** + * Send Response + * + * @description Send a boolean response + */ res.json({ + success: true + }); +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [2224,3017,3403,7547,5886,5338], () => (__webpack_exec__(3553))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/unsubscribe.js.nft.json b/dsql-app/.local_dist/server/pages/api/unsubscribe.js.nft.json new file mode 100644 index 0000000..29474d8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/unsubscribe.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/2224.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js b/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js new file mode 100644 index 0000000..8153028 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js @@ -0,0 +1,172 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5461; +exports.ids = [5461]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5611: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Sanitize body + * + * @description remove all potential injections + */ const sanitizedReqBody = req.body; + const { userObject , database_access , user_priviledge , db_tables , inv_user_id , } = sanitizedReqBody; + const updateUserAccess = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`UPDATE user_users SET database_access = ? ,user_priviledge = ? WHERE user_id = ? AND email = ?`, [ + database_access, + user_priviledge, + user.id, + userObject.email + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const dbTableEntries = db_tables.split("|"); + const clearEntries = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`DELETE FROM delegated_user_tables WHERE root_user_id='${user.id}' AND delegated_user_id='${inv_user_id}'`); + for(let i = 0; i < dbTableEntries.length; i++){ + const dbTableEntry = dbTableEntries[i]; + const dbTableEntryArray = dbTableEntry.split("-"); + const [db_slug, table_slug] = dbTableEntryArray; + // const existingEntry = await DB_HANDLER(`SELECT * FROM delegated_user_tables WHERE database='${db_slug}' AND table='${table_slug}' AND root_user_id='${user.id}' AND delegated_user_id='${inv_user_id}'`); + const newEntry = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_2___default()({ + dbFullName: "datasquirel", + tableName: "delegated_user_tables", + data: { + delegated_user_id: inv_user_id, + root_user_id: user.id, + database: db_slug, + table: table_slug, + priviledge: user_priviledge + } + }); + } + //////////////////////////////////////// + res.json({ + success: updateUserAccess?.affectedRows ? true : false + }); +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,7547,5886,5338], () => (__webpack_exec__(5611))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js.nft.json new file mode 100644 index 0000000..0978b6f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateAdminUserAccess.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/5338.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js b/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js new file mode 100644 index 0000000..d167441 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js @@ -0,0 +1,176 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2114; +exports.ids = [2114]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1724: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { tableData } = req.body; + const database = req.body.database; + const dbSlug = req.body.dbSlug; + const delegated = req.body.delegated; + const dbFullName = database.replace(/[^a-z\_0-9]/g, ""); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const delegatedUser = await _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_0___default()({ + request: req, + user: user, + databaseSlug: dbSlug, + query: req.query + }); + const userId = delegatedUser?.rootUserId ? delegatedUser.rootUserId : user.id; + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${userId}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const userSchemaObject = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf-8")); + const targetDbIndex = userSchemaObject.findIndex((db)=>db.dbFullName === database); + const targetTableIndex = userSchemaObject[targetDbIndex].tables.findIndex((tb)=>tb.childTable && tb.childTableDbFullName === tableData.childTableDbFullName && tb.childTableName === tableData.childTableName && tb.tableName === tableData.tableName); + userSchemaObject[targetDbIndex].tables[targetTableIndex] = tableData; + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaObject), "utf8"); + const targetPath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${userId} --database ${dbFullName}`, { + cwd: targetPath + }); + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + console.log(error.message); + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/addApiKey/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Foreign Key update Failed." + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,1352], () => (__webpack_exec__(1724))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js.nft.json new file mode 100644 index 0000000..80f9105 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateClonedTableForeignKeys.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/1352.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js b/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js new file mode 100644 index 0000000..1fc24ab --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js @@ -0,0 +1,455 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2873; +exports.ids = [2873]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 188: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ handler) +}); + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(2224); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./functions/backend/grabDelegatedUserFromCookie.js +var grabDelegatedUserFromCookie = __webpack_require__(1352); +var grabDelegatedUserFromCookie_default = /*#__PURE__*/__webpack_require__.n(grabDelegatedUserFromCookie); +// EXTERNAL MODULE: ./functions/backend/serverError.js +var serverError = __webpack_require__(2163); +var serverError_default = /*#__PURE__*/__webpack_require__.n(serverError); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(6825); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./functions/backend/grabUserSchemaData.js +var grabUserSchemaData = __webpack_require__(8164); +// EXTERNAL MODULE: external "fs" +var external_fs_ = __webpack_require__(7147); +var external_fs_default = /*#__PURE__*/__webpack_require__.n(external_fs_); +// EXTERNAL MODULE: external "lodash" +var external_lodash_ = __webpack_require__(6517); +var external_lodash_default = /*#__PURE__*/__webpack_require__.n(external_lodash_); +;// CONCATENATED MODULE: ./functions/backend/cleanUpSchemaData.js +// @ts-check + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} updateSchemaDataReturn + */ /** + * @param {object} params + * @param {DSQL_DatabaseSchemaType[]} params.dbSchemaData - Existing Schema + * @param {string} params.dbFullName - Target Database full name + * @param {DSQL_TableSchemaType} params.table - New Table Schema Data + * @param {number} params.userId + * + * @return {DSQL_DatabaseSchemaType[] | null} + */ function cleanUpSchemaData({ dbSchemaData , dbFullName , table , userId , }) { + try { + let newDbSchemaData = _.cloneDeep(dbSchemaData); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Check For Expired Child Tables + * + * @description Check For Expired Child Tables + */ newDbSchemaData.forEach((db, index)=>{ + db.tables.forEach((tableObject, _index)=>{ + if (tableObject.childrenTables) { + tableObject.childrenTables.forEach((childTable, __index)=>{ + try { + const childDbTest = newDbSchemaData.filter((_db)=>_db.dbFullName === childTable.dbNameFull); + if (!childDbTest?.[0]) { + tableObject.childrenTables?.splice(__index, 1); + return; + } + const childTableObjectTest = db.tables.filter((_table)=>_table.tableName === childTable.tableName); + if (!childTableObjectTest || !childTableObjectTest[0]) { + tableObject.childrenTables?.splice(__index, 1); + return; + } + } catch (/** @type {any} */ error) {} + }); + } + }); + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Start process + * ========================================================= + * @description Analyze existing schema data and parse/update + */ const dbIndex = newDbSchemaData.findIndex((db)=>db.dbFullName === dbFullName); + const targetDb = newDbSchemaData[dbIndex]; + const targetTableIndex = targetDb.tables.findIndex((_table)=>_table.tableName === table.tableName); + const targetTable = targetDb.tables[targetTableIndex]; + if (targetTable.childrenTables) { + targetTable.childrenTables.forEach((childTable, index)=>{ + try { + const childDbTest = newDbSchemaData.filter((db)=>db.dbFullName === childTable.dbNameFull); + if (!childDbTest || !childDbTest[0]) { + targetTable.childrenTables?.splice(index, 1); + return; + } + const childDb = childDbTest[0]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const childTableObjectTest = childDb.tables.filter((tb)=>tb.tableName === childTable.tableName); + if (!childTableObjectTest || !childTableObjectTest[0]) { + targetTable.childrenTables?.splice(index, 1); + return; + } + const childTableObject = childTableObjectTest[0]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const originChildTableFieldsClone = _.cloneDeep(targetTable.fields); + // const originChildTableFields = [...targetTable.fields]; + const originChildTableIndexesClone = _.cloneDeep(targetTable.indexes); + // const originChildTableIndexes = [...targetTable.indexes]; + childTableObject.fields = originChildTableFieldsClone; + childTableObject.indexes = originChildTableIndexesClone; + childTableObject.fields.forEach((childFieldObject, index)=>{ + const targetParentField = targetTable.fields[index]; + if (targetParentField?.foreignKey) { + const foreignKeyTable = childDb.tables.filter((tbl)=>tbl.tableName === targetParentField.foreignKey?.destinationTableName); + if (foreignKeyTable && foreignKeyTable[0]) { + const foreignKeyField = foreignKeyTable[0].fields.filter((fld)=>fld.fieldName === targetParentField?.foreignKey?.destinationTableColumnName); + if (foreignKeyField && foreignKeyField[0]) { + childFieldObject.foreignKey = { + ...targetParentField.foreignKey + }; + childFieldObject.foreignKey.foreignKeyName = childFieldObject.foreignKey.foreignKeyName?.replace(/dsql_\d+_[^_]+_/, `dsql_${userId}_${childDb.dbSlug}_`); + childFieldObject.dataType = foreignKeyField[0].dataType; + } else { + delete childFieldObject.foreignKey; + } + } else { + delete childFieldObject.foreignKey; + } + } else { + delete childFieldObject.foreignKey; + } + }); + } catch (/** @type {any} */ error) { + targetTable.childrenTables?.splice(index, 1); + } + }); + } + if (targetDb.childrenDatabases) { + targetDb.childrenDatabases.forEach((childDb, index)=>{ + try { + const { dbFullName } = childDb; + const targetChildDb = newDbSchemaData.filter((db)=>db.dbFullName === dbFullName)[0]; + if (!targetChildDb || !targetChildDb.tables) { + targetDb.childrenDatabases?.splice(index, 1); + return; + } + targetChildDb.tables = targetDb.tables; + } catch (/** @type {any} */ error) {} + }); + } + return newDbSchemaData; + } catch (error) { + return null; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./functions/backend/updateSchemaData.js +// @ts-check + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @typedef {object} updateSchemaDataReturn + */ /** + * @param {object} params + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} params.dbSchemaData - Existing Schema + * @param {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} params.schema - New Schema (Partial) + * @param {string} params.dbFullName - Target Database full name + * @param {import("./grabDelegatedUserFromCookie").grabDelegatedUserFromCookieReturn | null} params.delegatedUser + * @param {import("@/package-shared/types").DSQL_TableSchemaType} params.table - New Table Schema Data + * @param {number} params.userId + * + * @returns {boolean} + */ function updateSchemaData({ dbSchemaData , delegatedUser , dbFullName , schema , table , userId , }) { + const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${userId}/main.json`; + try { + if (!dbSchemaData) throw new Error("Database schema not found!"); + let newDbSchemaData = external_lodash_default().cloneDeep(dbSchemaData); + let targetDatabase = newDbSchemaData.find((db)=>db.dbFullName == dbFullName); + if (!targetDatabase) throw new Error("Old Database schema not found!"); + let targetDatabaseIndex = newDbSchemaData.findIndex((db)=>db.dbFullName == dbFullName); + if (targetDatabaseIndex < 0) throw new Error("Target Database index not found!"); + const newSchemaDatabase = schema.find((db)=>db.dbFullName === dbFullName); + if (!newSchemaDatabase) throw new Error("New Database schema not found!"); + if (delegatedUser?.delegated) { + const createTablePriviledge = Boolean(delegatedUser.priviledges?.match(/create.?table/i)); + const editTablePriviledge = Boolean(delegatedUser.priviledges?.match(/edit.?table/i)); + if (!editTablePriviledge) { + throw new Error("Unauthorized!"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } + const schemaTable = newSchemaDatabase.tables.find((tbl)=>tbl.tableName == table.tableName); + if (!schemaTable) throw new Error("Table schema not found!"); + const targetTableIndex = targetDatabase.tables.findIndex((tbl)=>tbl.tableName == table.tableName); + if (schemaTable) { + newDbSchemaData[targetDatabaseIndex].tables[targetTableIndex] = schemaTable; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const childrenDatabases = targetDatabase?.childrenDatabases; + childrenDatabases?.forEach((chDb)=>{ + const chDbIndex = newDbSchemaData.findIndex((db)=>db.dbFullName === chDb.dbFullName); + if (newDbSchemaData[chDbIndex] && targetDatabase) { + newDbSchemaData[chDbIndex].tables = targetDatabase.tables.map((tbl)=>{ + const newTbl = external_lodash_default().cloneDeep(tbl); + delete newTbl.childrenTables; + return newTbl; + }); + } + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const childrenTables = newDbSchemaData?.[targetDatabaseIndex]?.tables?.[targetTableIndex]?.childrenTables; + if (childrenTables) { + childrenTables.forEach((childTbl)=>{ + const childTblDbindex = newDbSchemaData.findIndex((db)=>db.dbFullName == childTbl.dbNameFull); + const childTblDbTblIndex = newDbSchemaData[childTblDbindex]?.tables?.findIndex((tbl)=>tbl.tableName === childTbl.tableName); + const childTblDbTbl = newDbSchemaData[childTblDbindex]?.tables[childTblDbTblIndex]; + if (childTblDbTbl) { + newDbSchemaData[childTblDbindex].tables[childTblDbTblIndex].fields = external_lodash_default().cloneDeep(schemaTable.fields); + newDbSchemaData[childTblDbindex].tables[childTblDbTblIndex].indexes = external_lodash_default().cloneDeep(schemaTable.indexes); + } + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + external_fs_default().writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(newDbSchemaData), "utf8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + return true; + } catch (/** @type {any} */ error) { + console.log("updateSchemaData.js ERROR: ", error.message); + return false; + } +} //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + +;// CONCATENATED MODULE: ./pages/api/updateDbSchemaDataForUser.js +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await userAuth_default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const schema = req.body.schema; + const database = req.body.database; + /** @type {import("@/package-shared/types").DSQL_TableSchemaType} */ const table = req.body.table; + const delegated = req.body.delegated; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await grabDelegatedUserFromCookie_default()({ + request: req, + user: user, + databaseSlug: database, + query: req.query + }); + const userId = delegatedUser?.rootUserId ? delegatedUser.rootUserId : user.id; + const dbFullName = `datasquirel_user_${userId}_${database}`.replace(/[^a-z\_0-9]/g, ""); + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ let confirm; + if (delegatedUser?.delegated) { + const checkDelegatedUser = await DB_HANDLER_default()(`SELECT * FROM user_users WHERE invited_user_id=? AND user_id=? AND user_priviledge LIKE '%Edit Tables%'`, [ + user.id, + delegatedUser.rootUserId + ]); + if (checkDelegatedUser && checkDelegatedUser[0]) confirm = true; + } else { + confirm = true; + } + if (!confirm) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const dbSchemaData = (0,grabUserSchemaData["default"])({ + userId: userId + }); + if (!dbSchemaData) throw new Error("Database schema not found!"); + const updateDbSchema = updateSchemaData({ + dbFullName, + dbSchemaData, + delegatedUser, + schema, + table, + userId + }); + if (!updateDbSchema) { + throw new Error("Update Failed!"); + } + //////////////////////////////////////// + const targetPath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${userId} --database ${dbFullName}`, { + cwd: targetPath + }); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + console.log("updateDbSchemaDataForUser ERROR:", error.message); + serverError_default()({ + component: "/api/updateDbSchemaDataForUser/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,1352,8164], () => (__webpack_exec__(188))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js.nft.json new file mode 100644 index 0000000..9754cb6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateDbSchemaDataForUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/1352.js","../../chunks/8164.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lodash/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lodash/lodash.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateDbUser.js b/dsql-app/.local_dist/server/pages/api/updateDbUser.js new file mode 100644 index 0000000..34a5252 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateDbUser.js @@ -0,0 +1,155 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2900; +exports.ids = [2900]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 2751: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbFullName , payload } = sanitizedReqBody; + /** + * Input Validation + * + * @description Input Validation + */ const data = (()=>{ + const reqBodyKeys = Object.keys(payload); + /** @type {any} */ const finalData = {}; + reqBodyKeys.forEach((key)=>{ + if (key?.match(/user_type|priviledge|database_access|databases?|confirm/)) return; + if (key?.match(/databases|confirm/)) return; + finalData[key] = payload[key]; + }); + return finalData; + })(); + /** + * Input Validation + * + * @description Input Validation + */ /** @type {any} */ const updatedUser = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: dbFullName, + tableName: "users", + identifierColumnName: "id", + identifierValue: payload.id, + data: { + ...data + }, + dbContext: "Dsql User", + paradigm: "Full Access" + }); + res.json({ + success: updatedUser?.affectedRows ? true : false, + msg: updatedUser?.affectedRows ? "User Updated" : updatedUser + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,7547,5886], () => (__webpack_exec__(2751))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateDbUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateDbUser.js.nft.json new file mode 100644 index 0000000..87946a9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateDbUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateTableEntry.js b/dsql-app/.local_dist/server/pages/api/updateTableEntry.js new file mode 100644 index 0000000..30e9986 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateTableEntry.js @@ -0,0 +1,222 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1351; +exports.ids = [1351]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 8560: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(766); +/* harmony import */ var _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8999); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbSlug , tableName , payload , entryId , tableSchema , delegated , dbId , } = sanitizedReqBody; + /** + * Remove Default Fields + * + * @description Remove Default Fields + */ delete payload["id"]; + delete payload["uuid"]; + delete payload["date_created"]; + delete payload["date_created_code"]; + delete payload["date_created_timestamp"]; + delete payload["date_updated"]; + delete payload["date_updated_code"]; + delete payload["date_updated_timestamp"]; + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default()({ + databaseSlug: dbSlug, + request: req, + user: user, + query: req.query + }); + const dbFullName = delegatedUser?.rootUserId ? `datasquirel_user_${delegatedUser.rootUserId}_${dbSlug}` : `datasquirel_user_${user.id}_${dbSlug}`; + const checkUserRightsBoolean = await _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default()({ + user: user, + confirmedDelegetedUser: delegatedUser, + database: dbSlug, + table: tableName, + dbId: dbId, + priviledgeRegex: /Update Entries/i + }); + if (!checkUserRightsBoolean) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ /** @type {any} */ const updateTableEntry = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: tableName, + identifierColumnName: "id", + identifierValue: entryId, + data: payload, + tableSchema: tableSchema + }); + //////////////////////////////////////// + if (updateTableEntry?.error) { + throw new Error(updateTableEntry.error); + } + if (!updateTableEntry) { + throw new Error("No result returned!"); + } + //////////////////////////////////////// + const handleOrder = await _functions_backend_handleTableEntryOrder__WEBPACK_IMPORTED_MODULE_0___default()({ + dbName: dbFullName, + entryId: entryId, + entryOrder: payload.order, + tableName: tableName, + tableSchema: tableSchema + }); + //////////////////////////////////////// + res.json({ + success: true, + payload: updateTableEntry + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/updateTableEntry/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!", + err: error.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,1352,8999,766], () => (__webpack_exec__(8560))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateTableEntry.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateTableEntry.js.nft.json new file mode 100644 index 0000000..60398e8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateTableEntry.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/1352.js","../../chunks/8999.js","../../chunks/766.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUser.js b/dsql-app/.local_dist/server/pages/api/updateUser.js new file mode 100644 index 0000000..e7c8860 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUser.js @@ -0,0 +1,329 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4196; +exports.ids = [4196]; +exports.modules = { + +/***/ 4809: +/***/ ((module) => { + +module.exports = require("node-fetch"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7441: +/***/ ((module) => { + +module.exports = require("sharp"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 4142: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const nodeFetch = __webpack_require__(4809); +const sharp = __webpack_require__(7441); +const serverError = __webpack_require__(2163); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * + * @param {object} params + * @param {string} params.imageSourceUrl + * @param {string} params.imageWritePath + * @param {number} [params.maxSize] + * @param {string} [params.sourceType] + */ module.exports = async function fsWriteImageToDisk({ imageSourceUrl , imageWritePath , maxSize , sourceType , }) { + try { + async function generateBuffer() { + let imageBuffer; + if (sourceType?.match("url")) { + if (imageSourceUrl.match(/^http/i)) { + let fetchedImage = await nodeFetch(imageSourceUrl, {}); + imageBuffer = await fetchedImage.buffer(); + } else { + let readPath = `./public${imageSourceUrl}`; + imageBuffer = readPath; + } + } else if (sourceType?.match("base64")) { + imageBuffer = Buffer.from(imageSourceUrl, "base64"); + } + return imageBuffer; + } + const buffer = await generateBuffer(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let imagePath = imageWritePath; + const MAX_SIZE = maxSize ? maxSize : 650; + // const sharpImage = sharp(imagePath); + const sharpImageRaw = sharp(buffer); + // let imageMetadata = await sharpImage.metadata(); + let imageMetadataRaw = await sharpImageRaw.metadata(); + let { width , height , format } = imageMetadataRaw; + if (width && height && width > MAX_SIZE) { + let resizeRatio = MAX_SIZE / width; + sharpImageRaw.resize(MAX_SIZE, Math.round(height * resizeRatio), { + fit: "cover" + }); + } + if (format) { + sharpImageRaw.toFormat(format, { + quality: 80 + }); + } + await sharpImageRaw.toFile(imagePath); + // console.log(image); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + // console.log("===================================="); + // console.log("Complete!!!"); + // console.log("===================================="); + } catch (/** @type {any} */ error) { + serverError({ + component: "functions/backend/fsWriteImageToDisk", + message: error.message + }); + } +}; /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + + +/***/ }), + +/***/ 9662: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7547); +/* harmony import */ var _package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_encrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_fsWriteImageToDisk__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4142); +/* harmony import */ var _functions_backend_fsWriteImageToDisk__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_fsWriteImageToDisk__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6926); +/* harmony import */ var _functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_handleNodemailer__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_6__); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_7__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_8__); +// @ts-check +const fs = __webpack_require__(7147); + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ const sanitizedReqBody = req.body; + const { first_name , last_name , image } = sanitizedReqBody; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + //////////////////////////////////////// + const existingImage = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`SELECT image FROM users WHERE id='${user.id}'`); + let isImageExisting = existingImage[0].image === image; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const STATIC_ROOT = process.env.DSQL_STATIC_SERVER_DIR; + if (!STATIC_ROOT) { + console.log("Static File ENV not Found!"); + throw new Error("No Static Path!"); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ let imagePath = path__WEBPACK_IMPORTED_MODULE_6___default().join(STATIC_ROOT, `images/user-images/user-${user.id}/user-${user.id}-profile.jpg`); + let imageThumbnailPath = path__WEBPACK_IMPORTED_MODULE_6___default().join(STATIC_ROOT, `images/user-images/user-${user.id}/user-${user.id}-profile-thumbnail.jpg`); + if (!isImageExisting) { + let writeImage = await _functions_backend_fsWriteImageToDisk__WEBPACK_IMPORTED_MODULE_2___default()({ + imageSourceUrl: typeof image === "string" ? image : image.imageBase64, + imageWritePath: imagePath, + sourceType: typeof image === "string" ? "url" : "base64" + }); + let writeImageThumbnail = await _functions_backend_fsWriteImageToDisk__WEBPACK_IMPORTED_MODULE_2___default()({ + imageSourceUrl: typeof image === "string" ? image : image.imageBase64, + imageWritePath: imageThumbnailPath, + maxSize: 250, + sourceType: typeof image === "string" ? "url" : "base64" + }); + (0,child_process__WEBPACK_IMPORTED_MODULE_7__.execSync)(`chmod 644 ${imagePath} ${imageThumbnailPath}`); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let imageUrl = imagePath.replace(STATIC_ROOT, process.env.DSQL_STATIC_HOST || ""); + let imageThumbnailUrl = imageThumbnailPath.replace(STATIC_ROOT, process.env.DSQL_STATIC_HOST || ""); + const updatedUser = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_8___default()({ + dbFullName: "datasquirel", + tableName: "users", + identifierColumnName: "id", + identifierValue: user.id, + data: { + first_name, + last_name, + image: imageUrl, + image_thumbnail: imageThumbnailUrl + } + }); + const updatedUserUser = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_8___default()({ + dbFullName: "datasquirel", + tableName: "user_users", + identifierColumnName: "invited_user_id", + identifierValue: user.id, + data: { + first_name, + last_name, + image: imageUrl, + image_thumbnail: imageThumbnailUrl + } + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + user: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4___default()({ + component: "/api/updateUser/main-catch-error", + message: error.message, + user: user + }); + res.json({ + user: null + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,6926], () => (__webpack_exec__(9662))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateUser.js.nft.json new file mode 100644 index 0000000..c40acbe --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/6926.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/nodemailer/package.json","../../../../node_modules/node-fetch/package.json","../../../../node_modules/sharp/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../node_modules/node-fetch/lib/index.js","../../../../node_modules/sharp/lib/index.js","../../../../node_modules/sharp/lib/constructor.js","../../../../node_modules/sharp/lib/input.js","../../../../node_modules/sharp/lib/composite.js","../../../../node_modules/sharp/lib/operation.js","../../../../node_modules/sharp/lib/resize.js","../../../../node_modules/sharp/lib/colour.js","../../../../node_modules/sharp/lib/channel.js","../../../../node_modules/sharp/lib/output.js","../../../../node_modules/sharp/lib/utility.js","../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../node_modules/nodemailer/lib/shared/index.js","../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../node_modules/sharp/lib/is.js","../../../../node_modules/sharp/lib/sharp.js","../../../../node_modules/sharp/lib/libvips.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/whatwg-url/package.json","../../../../node_modules/whatwg-url/lib/public-api.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/lru-cache/package.json","../../../../node_modules/lru-cache/index.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../node_modules/whatwg-url/lib/URL.js","../../../../node_modules/whatwg-url/lib/url-state-machine.js","../../../../node_modules/sharp/node_modules/semver/functions/coerce.js","../../../../node_modules/sharp/node_modules/semver/functions/satisfies.js","../../../../node_modules/sharp/node_modules/semver/functions/gte.js","../../../../node_modules/sharp/node_modules/semver/package.json","../../../../node_modules/color/index.js","../../../../node_modules/detect-libc/package.json","../../../../node_modules/detect-libc/lib/detect-libc.js","../../../../node_modules/whatwg-url/lib/utils.js","../../../../node_modules/whatwg-url/lib/URL-impl.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../node_modules/color/package.json","../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/sharp/node_modules/semver/functions/compare.js","../../../../node_modules/sharp/node_modules/semver/functions/parse.js","../../../../node_modules/sharp/node_modules/semver/classes/range.js","../../../../node_modules/sharp/node_modules/semver/classes/semver.js","../../../../node_modules/sharp/node_modules/semver/internal/re.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../node_modules/detect-libc/lib/process.js","../../../../node_modules/detect-libc/lib/filesystem.js","../../../../node_modules/yallist/package.json","../../../../node_modules/yallist/yallist.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/tr46/package.json","../../../../node_modules/tr46/index.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/webidl-conversions/package.json","../../../../node_modules/webidl-conversions/lib/index.js","../../../../node_modules/nodemailer/lib/base64/index.js","../../../../node_modules/nodemailer/lib/qp/index.js","../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/sharp/node_modules/semver/internal/debug.js","../../../../node_modules/sharp/node_modules/semver/internal/constants.js","../../../../node_modules/sharp/node_modules/semver/internal/parse-options.js","../../../../node_modules/sharp/node_modules/semver/internal/identifiers.js","../../../../node_modules/sharp/node_modules/semver/classes/comparator.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/yallist/iterator.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/color/node_modules/color-convert/index.js","../../../../node_modules/tr46/lib/mappingTable.json","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/color/node_modules/color-convert/package.json","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/sharp/node_modules/semver/functions/cmp.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/color-string/index.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/color-string/package.json","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/color/node_modules/color-convert/conversions.js","../../../../node_modules/color/node_modules/color-convert/route.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sharp/node_modules/semver/functions/eq.js","../../../../node_modules/sharp/node_modules/semver/functions/neq.js","../../../../node_modules/sharp/node_modules/semver/functions/gt.js","../../../../node_modules/sharp/node_modules/semver/functions/lte.js","../../../../node_modules/sharp/node_modules/semver/functions/lt.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/color-name/package.json","../../../../node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/color/node_modules/color-name/package.json","../../../../node_modules/color/node_modules/color-name/index.js","../../../../node_modules/simple-swizzle/package.json","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/index.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/simple-swizzle/node_modules/is-arrayish/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js b/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js new file mode 100644 index 0000000..fb9f16b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js @@ -0,0 +1,253 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9354; +exports.ids = [9354]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 2037: +/***/ ((module) => { + +module.exports = require("os"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3755: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const os = __webpack_require__(2037); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_2___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { id , db_name , db_slug , db_description , db_image , db_full_name , active_clone , active_clone_parent_db , } = sanitizedReqBody; + if (!db_full_name?.match(/datasquirel_user_.*/)) { + res.json({ + success: false, + msg: "Unauthorized" + }); + } + const newDbFullName = `datasquirel_user_${user.id}_${db_slug}`; + /** + * Update Database info in main db + * + * @description Update Database info in main db + */ const updateDatabase = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "user_databases", + identifierColumnName: "id", + identifierValue: id, + data: { + db_name, + db_slug, + db_description, + db_image, + db_full_name: newDbFullName + } + }); + /** + * Update User Specific Database + * + * @description Update User Specific Database + */ if (db_full_name && db_full_name !== newDbFullName) { + console.log("Renaming Database"); + const mysqlPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysql.exe" + "'" : "mysql"; + const mysqlDumpPath = os.platform().match(/win/i) ? "'" + "C:\\Program Files\\MySQL\\MySQL Server 8.0\\bin\\mysqldump.exe" + "'" : "mysqldump"; + try { + const createNewDb = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `CREATE DATABASE \`${newDbFullName}\` CHARACTER SET utf8mb4 COLLATE utf8mb4_bin`, + database: db_full_name + }); + /** @type {import("child_process").ExecSyncOptions} */ let execSyncOptions = { + cwd: process.cwd() + }; + if (os.platform().match(/win/i)) execSyncOptions.shell = "bash.exe"; + const exe = `${mysqlDumpPath} -u ${process.env.DSQL_DB_USERNAME} -h ${process.env.DSQL_DB_HOST} -p${process.env.DSQL_DB_PASSWORD} ${db_full_name} > tmpDbFile.sql`; + console.log(`updateUserDatabase.js exe => ${exe}`); + const dumpDb = execSync(exe, execSyncOptions); + const importToNewDb = execSync(`${mysqlPath} -u ${process.env.DSQL_DB_USERNAME} -h ${process.env.DSQL_DB_HOST} -p${process.env.DSQL_DB_PASSWORD} ${newDbFullName} < tmpDbFile.sql`, execSyncOptions); + const deleteOldDb = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `DROP DATABASE \`${db_full_name}\``, + database: db_full_name + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/updateUserDatabase/lines-88-111", + message: error.message, + user: user + }); + } + // const updateUserSpecificDatabase = await varDatabaseDbHandler({ + // queryString: `RENAME DATABASE \`${db_full_name}\` TO \`${newDbFullName}\``, + // database: db_full_name, + // }); + // console.log(updateUserSpecificDatabase); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${user.id}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + let targetDatabase = userSchemaData.filter((db)=>db.dbFullName === db_full_name); + targetDatabase[0].dbName = db_name; + targetDatabase[0].dbFullName = newDbFullName; + targetDatabase[0].dbDescription = db_description; + targetDatabase[0].dbImage = db_image; + targetDatabase[0].dbSlug = db_slug; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (active_clone) { + const parentDb = userSchemaData.filter((db)=>db.dbFullName === targetDatabase[0].childDatabaseDbFullName)[0]; + const targetChild = parentDb.childrenDatabases?.find((db)=>db.dbFullName === db_full_name); + if (targetChild) targetChild.dbFullName = newDbFullName; + } + //////////////////////////////////////// + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/updateUserDatabase/main-catch-error", + message: error1.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,8326,1311], () => (__webpack_exec__(3755))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js.nft.json new file mode 100644 index 0000000..d331cad --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserDatabase.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/8326.js","../../chunks/1311.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserTable.js b/dsql-app/.local_dist/server/pages/api/updateUserTable.js new file mode 100644 index 0000000..155c76c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserTable.js @@ -0,0 +1,271 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2919; +exports.ids = [2919]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 9052: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8999); +/* harmony import */ var _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1352); +/* harmony import */ var _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { dbFullName , dbSlug , dbId , tableNameOld , payload , delegated } = sanitizedReqBody; + const { tableName , tableFullName , tableDescription } = payload; + /** + * User auth + * + * @description Authenticate user + */ if (!tableName?.match(/./) || tableName.match(/[^a-zA-Z0-9-_]/)) { + return res.json({ + success: false, + msg: "Bad Input" + }); + } + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * Check if user has rights to this table + * + * @description Check if user has rights to this table + */ const delegatedUser = await _functions_backend_grabDelegatedUserFromCookie__WEBPACK_IMPORTED_MODULE_2___default()({ + databaseSlug: dbSlug, + request: req, + user: user, + query: req.query + }); + const checkUserRightsBoolean = await _functions_backend_checkUserRights__WEBPACK_IMPORTED_MODULE_1___default()({ + user: user, + confirmedDelegetedUser: delegatedUser, + database: dbSlug, + table: tableNameOld, + dbId: dbId, + priviledgeRegex: /Edit Table/i + }); + if (!checkUserRightsBoolean) { + console.log("User Unauthorized"); + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + const userId = delegatedUser?.rootUserId ? delegatedUser.rootUserId : user.id; + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const userSchemaMainFilePath = `./jsonData/dbSchemas/users/user-${userId}/main.json`; + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ let userSchemaData = JSON.parse(fs.readFileSync(userSchemaMainFilePath, "utf8")); + let targetDatabase = userSchemaData.filter((db)=>db.dbFullName === dbFullName)[0]; + let existingTableIndex; + let existingTable = targetDatabase.tables.filter((table, index)=>{ + if (table.tableName === tableNameOld) { + existingTableIndex = index; + return true; + } + }); + if (existingTable && existingTable[0]) { + existingTable[0].tableName = tableName; + existingTable[0].tableNameOld = tableNameOld; + existingTable[0].tableFullName = tableFullName; + tableDescription && (existingTable[0].tableDescription = tableDescription); + if (existingTable[0].childrenTables) { + existingTable[0].childrenTables.forEach((childTable)=>{ + try { + const childDb = userSchemaData.filter((db)=>db.dbFullName === childTable.dbNameFull)[0]; + const childTableObject = childDb.tables.filter((table)=>{ + if (table.tableName === childTable.tableName) { + return true; + } + })[0]; + childTableObject.childTableName = tableName; + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/updateUserTable/lines-131-138", + message: error.message, + user: user + }); + } + }); + } + } else { + throw new Error("Table Does not exist"); + } + fs.writeFileSync(`${userSchemaMainFilePath}`, JSON.stringify(userSchemaData), "utf8"); + //////////////////////////////////////// + const updateTable = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_5___default()({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + identifierColumnName: "table_slug", + identifierValue: tableNameOld, + data: { + table_name: tableFullName, + table_slug: tableName, + table_description: tableDescription + } + }); + if (delegated && delegatedUser) { + const updateDelegatedTable = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_0___default()(`UPDATE delegated_user_tables SET \`table\`=? WHERE delegated_user_id=? AND root_user_id=? AND \`table\`=? AND \`database\`=?`, [ + tableName, + user.id, + delegatedUser.rootUserId, + tableNameOld, + dbSlug, + ]); + } + //////////////////////////////////////// + const targetPath = path.join(process.cwd(), "/shell"); + const sanitizedDbName = dbFullName.replace(/[^a-z\_0-9]/g, ""); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${userId} --database ${sanitizedDbName}`, { + cwd: targetPath + }); + console.log(dbShellUpdate.toString()); + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_3___default()({ + component: "/api/updateUserTable/main-catch-error", + message: error.message, + user: user + }); + res.json({ + success: false, + msg: "Database Files could not be written!" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825,3017,3403,7547,5886,1352,8999], () => (__webpack_exec__(9052))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserTable.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateUserTable.js.nft.json new file mode 100644 index 0000000..75de97a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserTable.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/2163.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../chunks/1352.js","../../chunks/8999.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json","../../../../shell/checkDb.js","../../../../shell/createDbFromSchema.js","../../../../shell/encodingUpdate.js","../../../../shell/deploy.js","../../../../shell/grantFullPriviledges.js","../../../../shell/lessWatch.js","../../../../shell/readImage.js","../../../../shell/recoverMainJsonFromDb.js","../../../../shell/resetSQLCredentials.js","../../../../shell/resetSQLCredentialsPasswords.js","../../../../shell/setSQLCredentials.js","../../../../shell/tailwindWatch.js","../../../../shell/test-external-server.js","../../../../shell/test.js","../../../../shell/testSQLEscape.js","../../../../shell/updateChildrenTablesOnDb.js","../../../../shell/updateDateTimestamps.js","../../../../shell/updateDbSlugsForTableRecords.js","../../../../shell/updateSSLUsers.js","../../../../shell/utils/createTable.js","../../../../shell/utils/dbHandler.js","../../../../shell/utils/generateColumnDescription.js","../../../../shell/utils/noDatabaseDbHandler.js","../../../../shell/utils/supplementTable.js","../../../../shell/utils/updateTable.js","../../../../shell/utils/varDatabaseDbHandler.js","../../../../shell/functions/jsonToBase64.js","../../../../shell/mariadb-users/handleGrants.js","../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../shell/mariadb-users/users/create-user.js","../../../../shell/mariadb-users/users/new-user.json","../../../../shell/mariadb-users/users/update-user.json","../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserUser.js b/dsql-app/.local_dist/server/pages/api/updateUserUser.js new file mode 100644 index 0000000..f0abc2c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserUser.js @@ -0,0 +1,152 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2198; +exports.ids = [2198]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3649: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * User auth + * + * @description Authenticate user + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_1___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * User auth + * + * @description Authenticate user + */ const { user_type } = req.body; + /** + * Input Validation + * + * @description Input Validation + */ const data = (()=>{ + const reqBodyKeys = Object.keys(req.body); + /** @type {any} */ const finalData = {}; + reqBodyKeys.forEach((key)=>{ + if (user_type?.match(/database/) && key?.match(/user_type|priviledge|database_access|databases?|confirm/)) return; + if (key?.match(/databases|confirm/)) return; + finalData[key] = req.body[key]; + }); + return finalData; + })(); + /** + * Input Validation + * + * @description Input Validation + */ /** @type {any} */ const updatedUser = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbFullName: "datasquirel", + tableName: "user_users", + identifierColumnName: "id", + identifierValue: req.body.id, + data: { + ...data + } + }); + res.json({ + success: updatedUser?.affectedRows ? true : false, + msg: updatedUser?.affectedRows ? "User Updated" : updatedUser + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,6825,3017,3403,7547,5886], () => (__webpack_exec__(3649))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/updateUserUser.js.nft.json b/dsql-app/.local_dist/server/pages/api/updateUserUser.js.nft.json new file mode 100644 index 0000000..87946a9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/updateUserUser.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-api-runtime.js","../../chunks/5425.js","../../chunks/2224.js","../../chunks/6825.js","../../chunks/3017.js","../../chunks/3403.js","../../chunks/7547.js","../../chunks/5886.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/sanitize-html/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/sanitize-html/index.js","../../../../node_modules/mysql/index.js","../../../../node_modules/escape-string-regexp/index.js","../../../../node_modules/htmlparser2/package.json","../../../../node_modules/htmlparser2/lib/index.js","../../../../node_modules/is-plain-object/package.json","../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../node_modules/deepmerge/package.json","../../../../node_modules/deepmerge/dist/cjs.js","../../../../node_modules/parse-srcset/package.json","../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../node_modules/postcss/package.json","../../../../node_modules/postcss/lib/postcss.js","../../../../node_modules/mysql/package.json","../../../../node_modules/escape-string-regexp/package.json","../../../../node_modules/htmlparser2/lib/Parser.js","../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../node_modules/postcss/lib/result.js","../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../node_modules/postcss/lib/lazy-result.js","../../../../node_modules/postcss/lib/declaration.js","../../../../node_modules/postcss/lib/container.js","../../../../node_modules/postcss/lib/processor.js","../../../../node_modules/postcss/lib/stringify.js","../../../../node_modules/postcss/lib/fromJSON.js","../../../../node_modules/postcss/lib/document.js","../../../../node_modules/postcss/lib/warning.js","../../../../node_modules/postcss/lib/comment.js","../../../../node_modules/postcss/lib/at-rule.js","../../../../node_modules/postcss/lib/input.js","../../../../node_modules/postcss/lib/parse.js","../../../../node_modules/postcss/lib/list.js","../../../../node_modules/postcss/lib/rule.js","../../../../node_modules/postcss/lib/root.js","../../../../node_modules/postcss/lib/node.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../node_modules/postcss/lib/symbols.js","../../../../node_modules/postcss/lib/map-generator.js","../../../../node_modules/postcss/lib/warn-once.js","../../../../node_modules/postcss/lib/no-work-result.js","../../../../node_modules/postcss/lib/stringifier.js","../../../../node_modules/postcss/lib/previous-map.js","../../../../node_modules/postcss/lib/parser.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/entities/package.json","../../../../node_modules/entities/lib/decode.js","../../../../node_modules/domelementtype/package.json","../../../../node_modules/domelementtype/lib/index.js","../../../../node_modules/domhandler/package.json","../../../../node_modules/domhandler/lib/index.js","../../../../node_modules/domutils/package.json","../../../../node_modules/domutils/lib/index.js","../../../../node_modules/postcss/lib/tokenize.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/picocolors/package.json","../../../../node_modules/picocolors/picocolors.js","../../../../node_modules/source-map-js/package.json","../../../../node_modules/source-map-js/source-map.js","../../../../node_modules/domhandler/lib/node.js","../../../../node_modules/entities/lib/decode_codepoint.js","../../../../node_modules/domutils/lib/stringify.js","../../../../node_modules/domutils/lib/manipulation.js","../../../../node_modules/domutils/lib/traversal.js","../../../../node_modules/domutils/lib/querying.js","../../../../node_modules/domutils/lib/legacy.js","../../../../node_modules/domutils/lib/helpers.js","../../../../node_modules/domutils/lib/feeds.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/nanoid/non-secure/package.json","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/nanoid/package.json","../../../../node_modules/nanoid/non-secure/index.cjs","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../node_modules/source-map-js/lib/source-node.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/dom-serializer/package.json","../../../../node_modules/dom-serializer/lib/index.js","../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../node_modules/source-map-js/lib/util.js","../../../../node_modules/source-map-js/lib/array-set.js","../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../node_modules/source-map-js/lib/binary-search.js","../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../node_modules/source-map-js/lib/base64.js","../../../../node_modules/entities/lib/index.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/entities/lib/escape.js","../../../../node_modules/entities/lib/encode.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/entities/lib/generated/encode-html.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js b/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js new file mode 100644 index 0000000..8818c38 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js @@ -0,0 +1,204 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1176; +exports.ids = [1176]; +exports.modules = { + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3802: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6825); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2224); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2081); +/* harmony import */ var child_process__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(child_process__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +const fs = __webpack_require__(7147); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + user: null, + msg: "Registration Failed!" + }); + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_0___default()(req, res, true); + if (!user) { + return res.json({ + success: false, + msg: "Unauthorized" + }); + } + /** + * Validate Form + * + * @description Check if request body is valid + */ /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType} */ const schema = req.body.schema; + const dbId = req.body.dbId; + /** + * Validate Form + * + * @description Check if request body is valid + */ try { + /** + * @type {import("@/package-shared/types").DSQL_MYSQL_user_databases_Type[] | null} + */ const targetDBArray = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_3___default()(`SELECT * FROM user_databases WHERE user_id = ? AND id = ?`, [ + user.id, + dbId + ]); + if (!targetDBArray?.[0]) { + throw new Error("Invalid Database"); + } + const targetDb = targetDBArray[0]; + const userSchemaPath = path__WEBPACK_IMPORTED_MODULE_4___default().resolve(process.cwd(), `./jsonData/dbSchemas/users/user-${user.id}/main.json`); + /** @type {import("@/package-shared/types").DSQL_DatabaseSchemaType[]} */ const userSchema = JSON.parse(fs.readFileSync(userSchemaPath, "utf-8")); + const targetDatabase = userSchema.find((db)=>db.dbFullName == targetDb.db_full_name); + if (!targetDatabase) { + throw new Error("This Database doesn't exist"); + } + targetDatabase.tables = schema.tables; + if (targetDatabase.childrenDatabases) { + for(let i = 0; i < targetDatabase.childrenDatabases.length; i++){ + const childDb = targetDatabase.childrenDatabases[i]; + const { dbFullName } = childDb; + const targetChildDb = userSchema.find((db)=>db.dbFullName === dbFullName); + if (!targetChildDb || !targetChildDb.tables) { + targetDatabase.childrenDatabases?.splice(i, 1); + continue; + } + targetChildDb.tables = schema.tables; + } + } + fs.writeFileSync(`${userSchemaPath}`, JSON.stringify(userSchema), "utf8"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + const targetShellPath = path__WEBPACK_IMPORTED_MODULE_4___default().join(process.cwd(), "/shell"); + const dbShellUpdate = (0,child_process__WEBPACK_IMPORTED_MODULE_5__.execSync)(`node createDbFromSchema.js --user ${user.id} --database ${targetDb.db_full_name}`, { + cwd: targetShellPath + }); + console.log(dbShellUpdate.toString()); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/acceptUserInvitation/catch-error", + message: error.message, + user: user + }); + res.json({ + success: false + }); + } +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,6825], () => (__webpack_exec__(3802))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js.nft.json b/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js.nft.json new file mode 100644 index 0000000..3e2e249 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user-schema/replace-database-schema.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/6825.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json","../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../../shell/checkDb.js","../../../../../shell/createDbFromSchema.js","../../../../../shell/encodingUpdate.js","../../../../../shell/deploy.js","../../../../../shell/grantFullPriviledges.js","../../../../../shell/lessWatch.js","../../../../../shell/readImage.js","../../../../../shell/recoverMainJsonFromDb.js","../../../../../shell/resetSQLCredentials.js","../../../../../shell/resetSQLCredentialsPasswords.js","../../../../../shell/setSQLCredentials.js","../../../../../shell/tailwindWatch.js","../../../../../shell/test-external-server.js","../../../../../shell/test.js","../../../../../shell/testSQLEscape.js","../../../../../shell/updateChildrenTablesOnDb.js","../../../../../shell/updateDateTimestamps.js","../../../../../shell/updateDbSlugsForTableRecords.js","../../../../../shell/updateSSLUsers.js","../../../../../shell/utils/createTable.js","../../../../../shell/utils/dbHandler.js","../../../../../shell/utils/generateColumnDescription.js","../../../../../shell/utils/noDatabaseDbHandler.js","../../../../../shell/utils/supplementTable.js","../../../../../shell/utils/updateTable.js","../../../../../shell/utils/varDatabaseDbHandler.js","../../../../../shell/functions/jsonToBase64.js","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/add-user.js b/dsql-app/.local_dist/server/pages/api/user/add-user.js new file mode 100644 index 0000000..e4c24bb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/add-user.js @@ -0,0 +1,391 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4020; +exports.ids = [4020]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 2081: +/***/ ((module) => { + +module.exports = require("child_process"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 1459: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); +const serverError = __webpack_require__(2163); +const DB_HANDLER = __webpack_require__(2224); +const { default: grabUserSchemaData } = __webpack_require__(8164); +const { default: setUserSchemaData } = __webpack_require__(7638); +const addDbEntry = __webpack_require__(5338); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Function + * ============================================================================== + * @param {object} params + * @param {number} params.userId - user id + * @param {string} params.database + * + * @returns {Promise<any>} new user auth object payload + */ module.exports = async function addUsersTableToDb({ userId , database }) { + /** + * Initialize + * + * @description Initialize + */ const dbFullName = `datasquirel_user_${userId}_${database}`; + /** @type {import("@/package-shared/types").DSQL_TableSchemaType} */ // @ts-ignore + const userPreset = __webpack_require__(9258); + try { + /** + * Fetch user + * + * @description Fetch user from db + */ const userSchemaData = grabUserSchemaData({ + userId + }); + if (!userSchemaData) throw new Error("User schema data not found!"); + let targetDatabase = userSchemaData.filter((db)=>db.dbSlug === database)[0]; + let existingTableIndex; + // @ts-ignore + let existingTable = targetDatabase.tables.filter((table, index)=>{ + if (table.tableName === "users") { + existingTableIndex = index; + return true; + } + }); + if (existingTable && existingTable[0] && existingTableIndex) { + targetDatabase.tables[existingTableIndex] = userPreset; + } else { + targetDatabase.tables.push(userPreset); + } + setUserSchemaData({ + schemaData: userSchemaData, + userId + }); + //////////////////////////////////////// + const targetDb = await DB_HANDLER(`SELECT id FROM user_databases WHERE user_id=? AND db_slug=?`, [ + userId, + database + ]); + if (targetDb && targetDb[0]) { + const newTableEntry = await addDbEntry({ + dbFullName: "datasquirel", + tableName: "user_database_tables", + data: { + user_id: userId, + db_id: targetDb[0].id, + db_slug: database, + table_name: "Users", + table_slug: "users" + } + }); + } + //////////////////////////////////////// + const targetPath = path.join(process.cwd(), "/shell"); + const dbShellUpdate = execSync(`node createDbFromSchema.js --user ${userId} --database ${dbFullName}`, { + cwd: targetPath + }); + return dbShellUpdate.toString(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + serverError({ + component: "addUsersTableToDb", + message: error.message, + user: { + id: userId + } + }); + return error.message; + } +}; //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + + +/***/ }), + +/***/ 1280: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _functions_backend_addUsersTableToDb__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1459); +/* harmony import */ var _functions_backend_addUsersTableToDb__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_addUsersTableToDb__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5338); +/* harmony import */ var _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const path = __webpack_require__(1017); +const { execSync } = __webpack_require__(2081); + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + payload: null, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_2___default()(authorization); + if (!userJSON) throw new Error("Invalid Credentials"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const { payload , database , encryptionKey } = sanitizedReqBody; + /** + * Hash Password + * + * @description Hash Password + */ if (!payload?.password) { + res.json({ + success: false, + msg: `Password is required to create an account` + }); + return; + } + const hashedPassword = datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_3___default()({ + encryptionKey: encryptionKey, + password: String(payload.password) + }); + payload.password = hashedPassword; + /** + * Input Validation + * + * @description Input Validation + * @required - payload.first_name + * @required - payload.last_name + * @required - payload.email + * @required - payload.password + */ const dbFullName = `datasquirel_user_${user_id}_${database}`; + let fields = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + queryString: `SHOW COLUMNS FROM users`, + database: dbFullName + }); + if (!fields) { + const newTable = await _functions_backend_addUsersTableToDb__WEBPACK_IMPORTED_MODULE_0___default()({ + userId: user_id, + database: database + }); + fields = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + queryString: `SHOW COLUMNS FROM users`, + database: dbFullName + }); + } + if (!fields) { + return res.json({ + success: false, + msg: "Could not create users table" + }); + } + const fieldsTitles = fields.map((/** @type {any} */ fieldObject)=>fieldObject.Field); + let invalidField = null; + for(let i = 0; i < Object.keys(payload).length; i++){ + const key = Object.keys(payload)[i]; + if (!fieldsTitles.includes(key)) { + invalidField = key; + break; + } + } + if (invalidField) { + res.json({ + success: false, + msg: `${invalidField} is not a valid field!` + }); + return; + } + const existingUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + queryString: `SELECT * FROM users WHERE email = ?${payload.username ? " OR username = ?" : ""}`, + queryValuesArray: payload.username ? [ + payload.email, + payload.username + ] : [ + payload.email + ], + database: dbFullName + }); + console.log(existingUser); + if (existingUser?.[0]) { + return res.json({ + success: false, + msg: "User Already Exists", + payload: null + }); + } + const addUser = await _package_shared_functions_backend_db_addDbEntry__WEBPACK_IMPORTED_MODULE_1___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: "users", + data: { + ...payload, + image: "/images/user_images/user-preset.png", + image_thumbnail: "/images/user_images/user-preset-thumbnail.png" + } + }); + if (addUser?.insertId) { + const newlyAddedUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_5___default()({ + queryString: `SELECT id,first_name,last_name,email,username,phone,image,image_thumbnail,city,state,country,zip_code,address,verification_status,more_user_data FROM users WHERE id='${addUser.insertId}'`, + database: dbFullName + }); + res.json({ + success: true, + payload: newlyAddedUser[0] + }); + } else { + res.json({ + success: false, + msg: "Could not create user", + sqlResult: addUser, + payload: null + }); + } + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_4___default()({ + component: "/api/user/add-user/main-catch-error", + message: error.message, + user: {} + }); + res.json({ + success: false, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,8164,7638,9258], () => (__webpack_exec__(1280))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/add-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/add-user.js.nft.json new file mode 100644 index 0000000..8b9d7a2 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/add-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/8164.js","../../../chunks/7638.js","../../../chunks/9258.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json","../../../../../jsonData/dbSchemas/users/user-1/main.json","../../../../../jsonData/dbSchemas/users/user-10/main.json","../../../../../jsonData/dbSchemas/users/user-11/main.json","../../../../../jsonData/dbSchemas/users/user-13/main.json","../../../../../jsonData/dbSchemas/users/user-14/main.json","../../../../../jsonData/dbSchemas/users/user-18/main.json","../../../../../jsonData/dbSchemas/users/user-12/main.json","../../../../../jsonData/dbSchemas/users/user-19/main.json","../../../../../jsonData/dbSchemas/users/user-20/main.json","../../../../../jsonData/dbSchemas/users/user-3/main.json","../../../../../jsonData/dbSchemas/users/user-21/main.json","../../../../../jsonData/dbSchemas/users/user-22/main.json","../../../../../jsonData/dbSchemas/users/user-4/main.json","../../../../../jsonData/dbSchemas/users/user-6/main.json","../../../../../jsonData/dbSchemas/users/user-9/main.json","../../../../../jsonData/presets/users.json","../../../../../shell/checkDb.js","../../../../../shell/createDbFromSchema.js","../../../../../shell/encodingUpdate.js","../../../../../shell/deploy.js","../../../../../shell/grantFullPriviledges.js","../../../../../shell/lessWatch.js","../../../../../shell/readImage.js","../../../../../shell/recoverMainJsonFromDb.js","../../../../../shell/resetSQLCredentials.js","../../../../../shell/resetSQLCredentialsPasswords.js","../../../../../shell/setSQLCredentials.js","../../../../../shell/tailwindWatch.js","../../../../../shell/test-external-server.js","../../../../../shell/test.js","../../../../../shell/testSQLEscape.js","../../../../../shell/updateChildrenTablesOnDb.js","../../../../../shell/updateDateTimestamps.js","../../../../../shell/updateDbSlugsForTableRecords.js","../../../../../shell/updateSSLUsers.js","../../../../../shell/utils/createTable.js","../../../../../shell/utils/dbHandler.js","../../../../../shell/utils/generateColumnDescription.js","../../../../../shell/utils/noDatabaseDbHandler.js","../../../../../shell/utils/supplementTable.js","../../../../../shell/utils/updateTable.js","../../../../../shell/utils/varDatabaseDbHandler.js","../../../../../shell/functions/jsonToBase64.js","../../../../../shell/mariadb-users/handleGrants.js","../../../../../shell/mariadb-users/refreshUsersAndGrants.js","../../../../../shell/mariadb-users/resetSQLPasswords.js","../../../../../shell/mariadb-users/users/create-user.js","../../../../../shell/mariadb-users/users/new-user.json","../../../../../shell/mariadb-users/users/update-user.json","../../../../../shell/mariadb-users/users/update-user.js"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/delete-user.js b/dsql-app/.local_dist/server/pages/api/user/delete-user.js new file mode 100644 index 0000000..b389d72 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/delete-user.js @@ -0,0 +1,157 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4984; +exports.ids = [4984]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5134: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + payload: null, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("Invalid Credentials"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const { payload , database } = req.body; + /** + * Input Validation + * + * @description Input Validation + * @required - payload.first_name + * @required - payload.last_name + * @required - payload.email + * @required - payload.username + * @required - payload.password + */ const dbFullName = `datasquirel_user_${user_id}_${database}`; + const deleteUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + queryString: `DELETE FROM users WHERE id='${payload.id}'`, + database: dbFullName + }); + res.json({ + success: true, + payload: deleteUser + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/delete-user/main-catch-error", + message: error.message, + user: {} + }); + res.json({ + success: false, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311], () => (__webpack_exec__(5134))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/delete-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/delete-user.js.nft.json new file mode 100644 index 0000000..81a6277 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/delete-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/get-user.js b/dsql-app/.local_dist/server/pages/api/user/get-user.js new file mode 100644 index 0000000..c1b7fec --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/get-user.js @@ -0,0 +1,177 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1016; +exports.ids = [1016]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 6636: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("invalid Credentials"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = decryptedCsrfJSON ? JSON.parse(decryptedCsrfJSON) : null; + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/get-user/lines-61-64", + message: error.message, + user: {} + }); + } + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const sanitizedReqBody = req.body; + const sanitizedFields = sanitizedReqBody.fields.map((/** @type {String} */ fld)=>fld.replace(/[^a-z\_]/g, "")); + const { userId , database } = sanitizedReqBody; + const dbFullName = `datasquirel_user_${user_id}_${database}`; + /** + * GRAB user + * + * @description GRAB user + */ const query = `SELECT ${sanitizedFields.join(",")} FROM users WHERE id=?`; + let foundUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + queryString: query, + queryValuesArray: [ + userId + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!foundUser || !foundUser[0]) return res.json({ + success: false, + payload: null, + msg: "User not found!" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* Send Response */ res.json({ + success: true, + payload: foundUser[0] + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/get-user/main-catch-error", + message: error1.message, + user: {} + }); + res.json({ + success: false, + msg: "User fetch Error" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311], () => (__webpack_exec__(6636))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/get-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/get-user.js.nft.json new file mode 100644 index 0000000..81a6277 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/get-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/github-login.js b/dsql-app/.local_dist/server/pages/api/user/github-login.js new file mode 100644 index 0000000..eb45ebd --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/github-login.js @@ -0,0 +1,273 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4577; +exports.ids = [4577]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 5687: +/***/ ((module) => { + +module.exports = require("https"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7310: +/***/ ((module) => { + +module.exports = require("url"); + +/***/ }), + +/***/ 7911: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7839); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2127); +/* harmony import */ var _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + +const githubLogin = __webpack_require__(6069); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + const authorization = req.headers.authorization || ""; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + const user = userJSON ? JSON.parse(userJSON) : null; + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = decryptedCsrfJSON ? JSON.parse(decryptedCsrfJSON) : null; + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/google-login", + message: error.message + }); + } + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const { code , email , clientId , clientSecret , database , additionalFields , } = req.body; + if (!code || !clientId || !clientSecret || !database) { + return res.json({ + success: false, + msg: "Missing query params" + }); + } + if (typeof code !== "string" || typeof clientId !== "string" || typeof clientSecret !== "string" || typeof database !== "string") { + return res.json({ + success: false, + msg: "Wrong Parameters" + }); + } + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const gitHubUser = await githubLogin({ + code: code, + clientId: clientId, + clientSecret: clientSecret + }); + if (!gitHubUser) { + return res.json({ + success: false, + msg: "No github user returned" + }); + } + const targetDbName = `datasquirel_user_${user_id}_${database}`; + const socialId = gitHubUser.name || gitHubUser.id || gitHubUser.login; + const targetName = gitHubUser.name || gitHubUser.login; + const nameArray = targetName?.match(/ /) ? targetName?.split(" ") : targetName?.match(/\-/) ? targetName?.split("-") : [ + targetName + ]; + const payload = { + email: gitHubUser.email, + first_name: _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_3___default()(nameArray[0]), + last_name: _shell_utils_camelJoinedtoCamelSpace__WEBPACK_IMPORTED_MODULE_3___default()(nameArray[1]), + social_id: socialId, + social_platform: "github", + image: gitHubUser.avatar_url, + image_thumbnail: gitHubUser.avatar_url, + username: "github-user-" + socialId + }; + if (additionalFields && Object.keys(additionalFields).length > 0) { + Object.keys(additionalFields).forEach((key)=>{ + // @ts-ignore + payload[key] = additionalFields[key]; + }); + } + const loggedInGithubUser = await _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2___default()({ + database: targetDbName, + email: gitHubUser.email, + payload: payload, + social_platform: "github", + res: res, + social_id: socialId, + supEmail: email, + additionalFields + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + res.json({ + ...loggedInGithubUser, + dsqlUserId: user_id + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + console.log("ERROR in 'github-auth' API route =>", error1.message); + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/social-login/github-auth/catch-error", + message: error1.message + }); + res.json({ + success: false, + msg: "Failed!" + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,6926,7487,613,4294,7839,722,9971], () => (__webpack_exec__(7911))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/github-login.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/github-login.js.nft.json new file mode 100644 index 0000000..d0cdb00 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/github-login.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/6926.js","../../../chunks/7487.js","../../../chunks/613.js","../../../chunks/4294.js","../../../chunks/7839.js","../../../chunks/722.js","../../../chunks/9971.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/google-login.js b/dsql-app/.local_dist/server/pages/api/user/google-login.js new file mode 100644 index 0000000..f0f9129 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/google-login.js @@ -0,0 +1,262 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 862; +exports.ids = [862]; +exports.modules = { + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 3785: +/***/ ((module) => { + +module.exports = require("generate-password"); + +/***/ }), + +/***/ 6781: +/***/ ((module) => { + +module.exports = require("google-auth-library"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 5184: +/***/ ((module) => { + +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 3364: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7839); +/* harmony import */ var _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** # MODULE TRACE +====================================================================== + * No imports found for this Module +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const { OAuth2Client } = __webpack_require__(6781); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = JSON.parse(decryptedCsrfJSON || "{}"); + } catch (error) {} + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Grab User data + * + * @description Grab User data + */ const { token , clientId , database , additionalFields } = req.body; + const client = new OAuth2Client(clientId); + const ticket = await client.verifyIdToken({ + idToken: token, + audience: clientId + }); + if (!ticket?.getPayload()?.email_verified) { + return res.json({ + success: false, + user: null + }); + } + const payload = ticket.getPayload(); + if (!payload) throw new Error("No Payload"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!database || typeof database != "string" || database?.match(/ /)) { + return res.json({ + success: false, + user: undefined, + msg: "Please provide a database slug(database name in lowercase with no spaces)" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Create new user folder and file + * + * @description Create new user folder and file + */ const targetDbName = `datasquirel_user_${user_id}_${database}`; + const { given_name , family_name , email , sub , picture , email_verified } = payload; + const payloadObject = { + email: email, + first_name: given_name, + last_name: family_name, + social_id: sub, + social_platform: "google", + image: picture, + image_thumbnail: picture, + username: `google-user-${sub}` + }; + if (additionalFields && Object.keys(additionalFields).length > 0) { + Object.keys(additionalFields).forEach((key)=>{ + // @ts-ignore + payloadObject[key] = additionalFields[key]; + }); + } + const loggedInGoogleUser = await _functions_backend_social_login_handleSocialDb__WEBPACK_IMPORTED_MODULE_2___default()({ + database: targetDbName, + email: email || "", + payload: payloadObject, + social_platform: "google", + res: res, + social_id: sub, + additionalFields + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + ...loggedInGoogleUser, + dsqlUserId: user_id + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/google-login/main-catch-error", + message: error1.message, + user: {} + }); + res.json({ + success: false, + msg: "User fetch Error" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886,5338,8326,1311,6926,7487,613,4294,7839], () => (__webpack_exec__(3364))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/google-login.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/google-login.js.nft.json new file mode 100644 index 0000000..6c57e84 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/google-login.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../chunks/5338.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../chunks/6926.js","../../../chunks/7487.js","../../../chunks/613.js","../../../chunks/4294.js","../../../chunks/7839.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/lodash/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/generate-password/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/node-fetch/package.json","../../../../../node_modules/google-auth-library/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/index.js","../../../../../node_modules/lodash/lodash.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/node-fetch/lib/index.js","../../../../../node_modules/google-auth-library/build/src/index.js","../../../../../node_modules/generate-password/main.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/google-auth-library/build/src/transporters.js","../../../../../node_modules/datasquirel/utils/get.js","../../../../../node_modules/datasquirel/utils/post.js","../../../../../node_modules/datasquirel/utils/upload-image.js","../../../../../node_modules/datasquirel/utils/get-schema.js","../../../../../node_modules/datasquirel/utils/delete-file.js","../../../../../node_modules/datasquirel/utils/upload-file.js","../../../../../node_modules/datasquirel/users/add-user.js","../../../../../node_modules/datasquirel/users/update-user.js","../../../../../node_modules/datasquirel/users/login-user.js","../../../../../node_modules/datasquirel/users/send-email-code.js","../../../../../node_modules/datasquirel/users/logout-user.js","../../../../../node_modules/datasquirel/users/user-auth.js","../../../../../node_modules/datasquirel/users/reauth-user.js","../../../../../node_modules/datasquirel/users/get-user.js","../../../../../node_modules/datasquirel/users/get-token.js","../../../../../node_modules/datasquirel/users/validate-token.js","../../../../../node_modules/datasquirel/users/social/google-auth.js","../../../../../node_modules/datasquirel/users/social/github-auth.js","../../../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../../../node_modules/generate-password/src/generate.js","../../../../../node_modules/google-auth-library/build/src/auth/authclient.js","../../../../../node_modules/google-auth-library/build/src/auth/envDetect.js","../../../../../node_modules/google-auth-library/build/src/auth/googleauth.js","../../../../../node_modules/google-auth-library/build/src/auth/iam.js","../../../../../node_modules/google-auth-library/build/src/auth/idtokenclient.js","../../../../../node_modules/google-auth-library/build/src/auth/computeclient.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtaccess.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtclient.js","../../../../../node_modules/google-auth-library/build/src/auth/impersonated.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2client.js","../../../../../node_modules/google-auth-library/build/src/auth/loginticket.js","../../../../../node_modules/google-auth-library/build/src/auth/refreshclient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsclient.js","../../../../../node_modules/google-auth-library/build/src/auth/identitypoolclient.js","../../../../../node_modules/google-auth-library/build/src/auth/baseexternalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/externalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/downscopedclient.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-client.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/google-auth-library/build/src/options.js","../../../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../../../node_modules/datasquirel/functions/decrypt.js","../../../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/google-auth-library/build/src/auth/externalAccountAuthorizedUserClient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsrequestsigner.js","../../../../../node_modules/google-auth-library/build/src/auth/stscredentials.js","../../../../../node_modules/google-auth-library/build/src/auth/executable-response.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-handler.js","../../../../../node_modules/datasquirel/functions/encrypt.js","../../../../../node_modules/whatwg-url/package.json","../../../../../node_modules/whatwg-url/lib/public-api.js","../../../../../node_modules/google-auth-library/build/src/crypto/crypto.js","../../../../../node_modules/datasquirel/engine/user/get-user.js","../../../../../node_modules/datasquirel/engine/user/update-user.js","../../../../../node_modules/datasquirel/engine/user/add-user.js","../../../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../../../node_modules/datasquirel/engine/user/login-user.js","../../../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../../../node_modules/datasquirel/engine/query/post.js","../../../../../node_modules/datasquirel/engine/query/get.js","../../../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/debug/package.json","../../../../../node_modules/debug/src/index.js","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2common.js","../../../../../node_modules/lru-cache/package.json","../../../../../node_modules/lru-cache/index.js","../../../../../node_modules/jws/package.json","../../../../../node_modules/jws/index.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/ecdsa-sig-formatter/package.json","../../../../../node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/arrify/index.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/whatwg-url/lib/URL.js","../../../../../node_modules/whatwg-url/lib/url-state-machine.js","../../../../../node_modules/google-auth-library/build/src/crypto/browser/crypto.js","../../../../../node_modules/google-auth-library/build/src/crypto/node/crypto.js","../../../../../node_modules/gcp-metadata/package.json","../../../../../node_modules/gcp-metadata/build/src/index.js","../../../../../node_modules/gaxios/package.json","../../../../../node_modules/gaxios/build/src/index.js","../../../../../node_modules/gtoken/package.json","../../../../../node_modules/gtoken/build/src/index.js","../../../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../../../node_modules/debug/src/browser.js","../../../../../node_modules/debug/src/node.js","../../../../../node_modules/arrify/package.json","../../../../../node_modules/whatwg-url/lib/utils.js","../../../../../node_modules/whatwg-url/lib/URL-impl.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/jws/lib/verify-stream.js","../../../../../node_modules/jws/lib/sign-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js","../../../../../node_modules/debug/src/common.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../../../node_modules/gaxios/build/src/gaxios.js","../../../../../node_modules/gaxios/build/src/common.js","../../../../../node_modules/gcp-metadata/build/src/gcp-residency.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/yallist/package.json","../../../../../node_modules/yallist/yallist.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/jws/lib/data-stream.js","../../../../../node_modules/jws/lib/tostring.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/tr46/package.json","../../../../../node_modules/tr46/index.js","../../../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/webidl-conversions/package.json","../../../../../node_modules/webidl-conversions/lib/index.js","../../../../../node_modules/gaxios/build/src/retry.js","../../../../../node_modules/fast-text-encoding/package.json","../../../../../node_modules/fast-text-encoding/text.min.js","../../../../../node_modules/safe-buffer/package.json","../../../../../node_modules/safe-buffer/index.js","../../../../../node_modules/base64-js/package.json","../../../../../node_modules/base64-js/index.js","../../../../../node_modules/supports-color/index.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/supports-color/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/yallist/iterator.js","../../../../../node_modules/json-bigint/package.json","../../../../../node_modules/json-bigint/index.js","../../../../../node_modules/google-p12-pem/package.json","../../../../../node_modules/google-p12-pem/build/src/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/tr46/lib/mappingTable.json","../../../../../node_modules/ms/package.json","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/jwa/package.json","../../../../../node_modules/jwa/index.js","../../../../../node_modules/ms/index.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/extend/package.json","../../../../../node_modules/is-stream/index.js","../../../../../node_modules/json-bigint/lib/stringify.js","../../../../../node_modules/json-bigint/lib/parse.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/extend/index.js","../../../../../node_modules/https-proxy-agent/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/https-proxy-agent/dist/index.js","../../../../../node_modules/is-stream/package.json","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/has-flag/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/has-flag/package.json","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/https-proxy-agent/dist/agent.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/buffer-equal-constant-time/package.json","../../../../../node_modules/buffer-equal-constant-time/index.js","../../../../../node_modules/node-forge/package.json","../../../../../node_modules/node-forge/lib/index.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/https-proxy-agent/dist/parse-proxy-response.js","../../../../../node_modules/bignumber.js/package.json","../../../../../node_modules/bignumber.js/bignumber.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/node-forge/lib/forge.js","../../../../../node_modules/node-forge/lib/aes.js","../../../../../node_modules/node-forge/lib/aesCipherSuites.js","../../../../../node_modules/node-forge/lib/asn1.js","../../../../../node_modules/node-forge/lib/cipher.js","../../../../../node_modules/node-forge/lib/des.js","../../../../../node_modules/node-forge/lib/ed25519.js","../../../../../node_modules/node-forge/lib/hmac.js","../../../../../node_modules/node-forge/lib/kem.js","../../../../../node_modules/node-forge/lib/log.js","../../../../../node_modules/node-forge/lib/md.all.js","../../../../../node_modules/node-forge/lib/mgf1.js","../../../../../node_modules/node-forge/lib/pbkdf2.js","../../../../../node_modules/node-forge/lib/pem.js","../../../../../node_modules/node-forge/lib/pkcs1.js","../../../../../node_modules/node-forge/lib/pkcs12.js","../../../../../node_modules/node-forge/lib/pkcs7.js","../../../../../node_modules/node-forge/lib/pki.js","../../../../../node_modules/node-forge/lib/prime.js","../../../../../node_modules/node-forge/lib/prng.js","../../../../../node_modules/node-forge/lib/pss.js","../../../../../node_modules/node-forge/lib/random.js","../../../../../node_modules/node-forge/lib/rc2.js","../../../../../node_modules/node-forge/lib/ssh.js","../../../../../node_modules/node-forge/lib/tls.js","../../../../../node_modules/node-forge/lib/util.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/agent-base/package.json","../../../../../node_modules/agent-base/dist/src/index.js","../../../../../node_modules/node-forge/lib/oids.js","../../../../../node_modules/node-forge/lib/cipherModes.js","../../../../../node_modules/node-forge/lib/jsbn.js","../../../../../node_modules/node-forge/lib/sha512.js","../../../../../node_modules/node-forge/lib/asn1-validator.js","../../../../../node_modules/node-forge/lib/md.js","../../../../../node_modules/node-forge/lib/md5.js","../../../../../node_modules/node-forge/lib/sha1.js","../../../../../node_modules/node-forge/lib/sha256.js","../../../../../node_modules/node-forge/lib/pkcs7asn1.js","../../../../../node_modules/node-forge/lib/pbe.js","../../../../../node_modules/node-forge/lib/rsa.js","../../../../../node_modules/node-forge/lib/x509.js","../../../../../node_modules/node-forge/lib/baseN.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/node-forge/lib/mgf.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/agent-base/dist/src/promisify.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js b/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js new file mode 100644 index 0000000..150d89a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js @@ -0,0 +1,160 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 2890; +exports.ids = [2890]; +exports.modules = { + +/***/ 6781: +/***/ ((module) => { + +module.exports = require("google-auth-library"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 4606: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +// @ts-check +/** # MODULE TRACE +====================================================================== + * No imports found for this Module +==== MODULE TRACE END ==== */ /** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const { OAuth2Client } = __webpack_require__(6781); + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + payload: null, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + payload: null, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = JSON.parse(decryptedCsrfJSON || ""); + } catch (error) {} + if (!full_access || !csrf) return res.json({ + success: false, + payload: null, + msg: "Unauthorized" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Grab User data + * + * @description Grab User data + */ const { token , clientId } = req.body; + const client = new OAuth2Client(clientId); + const ticket = await client.verifyIdToken({ + idToken: token, + audience: clientId + }); + if (!ticket?.getPayload()?.email_verified) { + return res.json({ + success: false, + payload: null, + msg: "User not verified!" + }); + } + const payload = ticket.getPayload(); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + payload + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/grab-google-user-from-token/main-catch-error", + message: error1.message + }); + res.json({ + success: false, + payload: null, + msg: "User fetch Error" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2163], () => (__webpack_exec__(4606))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js.nft.json new file mode 100644 index 0000000..e6e1918 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/grab-google-user-from-token.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2163.js","../../../../package.json","../../../../../node_modules/node-fetch/package.json","../../../../../node_modules/google-auth-library/package.json","../../../../../node_modules/node-fetch/lib/index.js","../../../../../node_modules/google-auth-library/build/src/index.js","../../../../../node_modules/google-auth-library/build/src/transporters.js","../../../../../node_modules/google-auth-library/build/src/auth/authclient.js","../../../../../node_modules/google-auth-library/build/src/auth/envDetect.js","../../../../../node_modules/google-auth-library/build/src/auth/googleauth.js","../../../../../node_modules/google-auth-library/build/src/auth/iam.js","../../../../../node_modules/google-auth-library/build/src/auth/idtokenclient.js","../../../../../node_modules/google-auth-library/build/src/auth/computeclient.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtaccess.js","../../../../../node_modules/google-auth-library/build/src/auth/jwtclient.js","../../../../../node_modules/google-auth-library/build/src/auth/impersonated.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2client.js","../../../../../node_modules/google-auth-library/build/src/auth/loginticket.js","../../../../../node_modules/google-auth-library/build/src/auth/refreshclient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsclient.js","../../../../../node_modules/google-auth-library/build/src/auth/identitypoolclient.js","../../../../../node_modules/google-auth-library/build/src/auth/baseexternalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/externalclient.js","../../../../../node_modules/google-auth-library/build/src/auth/downscopedclient.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-client.js","../../../../../node_modules/google-auth-library/build/src/options.js","../../../../../node_modules/google-auth-library/build/src/auth/externalAccountAuthorizedUserClient.js","../../../../../node_modules/google-auth-library/build/src/auth/awsrequestsigner.js","../../../../../node_modules/google-auth-library/build/src/auth/stscredentials.js","../../../../../node_modules/google-auth-library/build/src/auth/executable-response.js","../../../../../node_modules/google-auth-library/build/src/auth/pluggable-auth-handler.js","../../../../../node_modules/whatwg-url/package.json","../../../../../node_modules/whatwg-url/lib/public-api.js","../../../../../node_modules/google-auth-library/build/src/crypto/crypto.js","../../../../../node_modules/debug/package.json","../../../../../node_modules/debug/src/index.js","../../../../../node_modules/google-auth-library/build/src/auth/oauth2common.js","../../../../../node_modules/lru-cache/package.json","../../../../../node_modules/lru-cache/index.js","../../../../../node_modules/jws/package.json","../../../../../node_modules/jws/index.js","../../../../../node_modules/ecdsa-sig-formatter/package.json","../../../../../node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js","../../../../../node_modules/arrify/index.js","../../../../../node_modules/whatwg-url/lib/URL.js","../../../../../node_modules/whatwg-url/lib/url-state-machine.js","../../../../../node_modules/google-auth-library/build/src/crypto/browser/crypto.js","../../../../../node_modules/google-auth-library/build/src/crypto/node/crypto.js","../../../../../node_modules/gcp-metadata/package.json","../../../../../node_modules/gcp-metadata/build/src/index.js","../../../../../node_modules/gaxios/package.json","../../../../../node_modules/gaxios/build/src/index.js","../../../../../node_modules/gtoken/package.json","../../../../../node_modules/gtoken/build/src/index.js","../../../../../node_modules/debug/src/browser.js","../../../../../node_modules/debug/src/node.js","../../../../../node_modules/arrify/package.json","../../../../../node_modules/whatwg-url/lib/utils.js","../../../../../node_modules/whatwg-url/lib/URL-impl.js","../../../../../node_modules/jws/lib/verify-stream.js","../../../../../node_modules/jws/lib/sign-stream.js","../../../../../node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js","../../../../../node_modules/debug/src/common.js","../../../../../node_modules/gaxios/build/src/gaxios.js","../../../../../node_modules/gaxios/build/src/common.js","../../../../../node_modules/gcp-metadata/build/src/gcp-residency.js","../../../../../node_modules/yallist/package.json","../../../../../node_modules/yallist/yallist.js","../../../../../node_modules/jws/lib/data-stream.js","../../../../../node_modules/jws/lib/tostring.js","../../../../../node_modules/tr46/package.json","../../../../../node_modules/tr46/index.js","../../../../../node_modules/webidl-conversions/package.json","../../../../../node_modules/webidl-conversions/lib/index.js","../../../../../node_modules/gaxios/build/src/retry.js","../../../../../node_modules/fast-text-encoding/package.json","../../../../../node_modules/fast-text-encoding/text.min.js","../../../../../node_modules/safe-buffer/package.json","../../../../../node_modules/safe-buffer/index.js","../../../../../node_modules/base64-js/package.json","../../../../../node_modules/base64-js/index.js","../../../../../node_modules/supports-color/index.js","../../../../../node_modules/supports-color/package.json","../../../../../node_modules/yallist/iterator.js","../../../../../node_modules/json-bigint/package.json","../../../../../node_modules/json-bigint/index.js","../../../../../node_modules/google-p12-pem/package.json","../../../../../node_modules/google-p12-pem/build/src/index.js","../../../../../node_modules/tr46/lib/mappingTable.json","../../../../../node_modules/ms/package.json","../../../../../node_modules/jwa/package.json","../../../../../node_modules/jwa/index.js","../../../../../node_modules/ms/index.js","../../../../../node_modules/extend/package.json","../../../../../node_modules/is-stream/index.js","../../../../../node_modules/json-bigint/lib/stringify.js","../../../../../node_modules/json-bigint/lib/parse.js","../../../../../node_modules/extend/index.js","../../../../../node_modules/https-proxy-agent/package.json","../../../../../node_modules/https-proxy-agent/dist/index.js","../../../../../node_modules/is-stream/package.json","../../../../../node_modules/has-flag/index.js","../../../../../node_modules/has-flag/package.json","../../../../../node_modules/https-proxy-agent/dist/agent.js","../../../../../node_modules/buffer-equal-constant-time/package.json","../../../../../node_modules/buffer-equal-constant-time/index.js","../../../../../node_modules/node-forge/package.json","../../../../../node_modules/node-forge/lib/index.js","../../../../../node_modules/https-proxy-agent/dist/parse-proxy-response.js","../../../../../node_modules/bignumber.js/package.json","../../../../../node_modules/bignumber.js/bignumber.js","../../../../../node_modules/node-forge/lib/forge.js","../../../../../node_modules/node-forge/lib/aes.js","../../../../../node_modules/node-forge/lib/aesCipherSuites.js","../../../../../node_modules/node-forge/lib/asn1.js","../../../../../node_modules/node-forge/lib/cipher.js","../../../../../node_modules/node-forge/lib/des.js","../../../../../node_modules/node-forge/lib/ed25519.js","../../../../../node_modules/node-forge/lib/hmac.js","../../../../../node_modules/node-forge/lib/kem.js","../../../../../node_modules/node-forge/lib/log.js","../../../../../node_modules/node-forge/lib/md.all.js","../../../../../node_modules/node-forge/lib/mgf1.js","../../../../../node_modules/node-forge/lib/pbkdf2.js","../../../../../node_modules/node-forge/lib/pem.js","../../../../../node_modules/node-forge/lib/pkcs1.js","../../../../../node_modules/node-forge/lib/pkcs12.js","../../../../../node_modules/node-forge/lib/pkcs7.js","../../../../../node_modules/node-forge/lib/pki.js","../../../../../node_modules/node-forge/lib/prime.js","../../../../../node_modules/node-forge/lib/prng.js","../../../../../node_modules/node-forge/lib/pss.js","../../../../../node_modules/node-forge/lib/random.js","../../../../../node_modules/node-forge/lib/rc2.js","../../../../../node_modules/node-forge/lib/ssh.js","../../../../../node_modules/node-forge/lib/tls.js","../../../../../node_modules/node-forge/lib/util.js","../../../../../node_modules/agent-base/package.json","../../../../../node_modules/agent-base/dist/src/index.js","../../../../../node_modules/node-forge/lib/oids.js","../../../../../node_modules/node-forge/lib/cipherModes.js","../../../../../node_modules/node-forge/lib/jsbn.js","../../../../../node_modules/node-forge/lib/sha512.js","../../../../../node_modules/node-forge/lib/asn1-validator.js","../../../../../node_modules/node-forge/lib/md.js","../../../../../node_modules/node-forge/lib/md5.js","../../../../../node_modules/node-forge/lib/sha1.js","../../../../../node_modules/node-forge/lib/sha256.js","../../../../../node_modules/node-forge/lib/pkcs7asn1.js","../../../../../node_modules/node-forge/lib/pbe.js","../../../../../node_modules/node-forge/lib/rsa.js","../../../../../node_modules/node-forge/lib/x509.js","../../../../../node_modules/node-forge/lib/baseN.js","../../../../../node_modules/node-forge/lib/mgf.js","../../../../../node_modules/agent-base/dist/src/promisify.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/login-user.js b/dsql-app/.local_dist/server/pages/api/user/login-user.js new file mode 100644 index 0000000..65ef2b6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/login-user.js @@ -0,0 +1,278 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3173; +exports.ids = [3173]; +exports.modules = { + +/***/ 2029: +/***/ ((module) => { + +module.exports = require("datasquirel/functions/hashPassword"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5827: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2029); +/* harmony import */ var datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default()(csrf); + const decryptedCsrf = JSON.parse(decryptedCsrfJSON || ""); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/user/login-user/lines-61-64", + message: error.message, + user: {} + }); + } + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ /** @type {import("@/package-shared/types").PackageUserLoginRequestBody} */ const reqBody = req.body; + const { encryptionKey , payload , database , additionalFields , email_login , email_login_code , email_login_field , token , } = reqBody; + const email = payload.email; + const username = payload.username; + const password = payload.password; + const dbFullName = `datasquirel_user_${user_id}_${database}`; + /** + * Check input validity + * + * @description Check input validity + */ if (email?.match(/ /) || username && username?.match(/ /) || password && password?.match(/ /)) { + return res.json({ + success: false, + msg: "Invalid Email/Password format" + }); + } + /** + * Password hash + * + * @description Password hash + */ let hashedPassword = password ? datasquirel_functions_hashPassword__WEBPACK_IMPORTED_MODULE_0___default()({ + encryptionKey: encryptionKey, + password: password + }) : null; + let isSocialValidated = false; + let loginFailureReason = null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let foundUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `SELECT * FROM users WHERE email = ? OR username = ?`, + queryValuesArray: [ + email, + username + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if ((!foundUser || !foundUser[0]) && !reqBody.social) return res.json({ + success: false, + payload: null, + msg: "No user found" + }); + let isPasswordCorrect = false; + if (foundUser && foundUser[0] && !email_login) { + isPasswordCorrect = hashedPassword === foundUser[0].password; + } else if (foundUser && foundUser[0] && email_login && email_login_code && email_login_field) { + /** @type {string} */ const tempCode = foundUser[0][email_login_field]; + if (!tempCode) throw new Error("No code Found!"); + const tempCodeArray = tempCode.split("-"); + const [code, codeDate] = tempCodeArray; + const millisecond15mins = 1000 * 60 * 15; + if (Date.now() - Number(codeDate) > millisecond15mins) { + throw new Error("Code Expired"); + } + isPasswordCorrect = code === email_login_code; + } + let socialUserValid = false; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!isPasswordCorrect && !socialUserValid) { + return res.json({ + success: false, + msg: "Wrong password, no social login validity", + payload: null + }); + } + if (isPasswordCorrect && email_login) { + const resetTempCode = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `UPDATE users SET ${email_login_field} = ? WHERE email = ? OR username = ?`, + queryValuesArray: [ + "", + email, + username + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let csrfKey = Math.random().toString(36).substring(2) + "-" + Math.random().toString(36).substring(2); + let userPayload = { + id: foundUser[0].id, + first_name: foundUser[0].first_name, + last_name: foundUser[0].last_name, + username: foundUser[0].username, + email: foundUser[0].email, + phone: foundUser[0].phone, + social_id: foundUser[0].social_id, + image: foundUser[0].image, + image_thumbnail: foundUser[0].image_thumbnail, + verification_status: foundUser[0].verification_status, + social_login: foundUser[0].social_login, + social_platform: foundUser[0].social_platform, + csrf_k: csrfKey, + more_data: foundUser[0].more_user_data, + logged_in_status: true, + date: Date.now() + }; + const resposeObject = { + success: true, + msg: "Login Successful", + payload: userPayload, + userId: user_id + }; + if (additionalFields && Array.isArray(additionalFields) && additionalFields.length > 0) { + additionalFields.forEach((key)=>{ + // @ts-ignore + userPayload[key] = foundUser[0][key]; + }); + } + // if (token) { + // resposeObject.token = + // } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* Send Response */ res.json(resposeObject); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/user/login-user/main-catch-error", + message: error1.message, + user: {} + }); + res.json({ + success: false, + msg: "Login Failed" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311], () => (__webpack_exec__(5827))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/login-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/login-user.js.nft.json new file mode 100644 index 0000000..dca6f0a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/login-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/datasquirel/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/datasquirel/functions/hashPassword.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/reauth-user.js b/dsql-app/.local_dist/server/pages/api/user/reauth-user.js new file mode 100644 index 0000000..4adaaa1 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/reauth-user.js @@ -0,0 +1,205 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8529; +exports.ids = [8529]; +exports.modules = { + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5231: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = JSON.parse(decryptedCsrfJSON || ""); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/reauth-user/lines-61-64", + message: error.message, + user: {} + }); + } + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const reqBody = req.body; + /** @type {{ existingUser:import("@/package-shared/types").UserType, database:string, additionalFields?: any}} */ const { existingUser , database , additionalFields } = reqBody; + const dbFullName = `datasquirel_user_${user_id}_${database}`; + /** + * GRAB user + * + * @description GRAB user + */ let foundUser = existingUser?.id && existingUser.id.toString().match(/./) ? await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_2___default()({ + queryString: `SELECT * FROM users WHERE id=?`, + queryValuesArray: [ + existingUser.id.toString() + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }) : null; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!foundUser || !foundUser[0]) return res.json({ + success: false, + payload: null, + msg: "No user found" + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let csrfKey = Math.random().toString(36).substring(2) + "-" + Math.random().toString(36).substring(2); + let userPayload = { + id: foundUser[0].id, + first_name: foundUser[0].first_name, + last_name: foundUser[0].last_name, + username: foundUser[0].username, + email: foundUser[0].email, + phone: foundUser[0].phone, + social_id: foundUser[0].social_id, + image: foundUser[0].image, + image_thumbnail: foundUser[0].image_thumbnail, + verification_status: foundUser[0].verification_status, + social_login: foundUser[0].social_login, + social_platform: foundUser[0].social_platform, + csrf_k: csrfKey, + more_data: foundUser[0].more_user_data, + logged_in_status: true, + date: Date.now() + }; + if (additionalFields && Array.isArray(additionalFields) && additionalFields.length > 0) { + additionalFields.forEach((key)=>{ + // @ts-ignore + userPayload[key] = foundUser[0][key]; + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** ********************* Send Response */ res.json({ + success: true, + msg: "Login Successful", + payload: userPayload, + userId: user_id + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_1___default()({ + component: "/api/user/reauth-user/main-catch-error", + message: error1.message, + user: {} + }); + res.json({ + success: false, + msg: "Login Failed" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311], () => (__webpack_exec__(5231))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/reauth-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/reauth-user.js.nft.json new file mode 100644 index 0000000..81a6277 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/reauth-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/send-email-code.js b/dsql-app/.local_dist/server/pages/api/user/send-email-code.js new file mode 100644 index 0000000..3a3d828 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/send-email-code.js @@ -0,0 +1,270 @@ +(() => { +var exports = {}; +exports.id = 7295; +exports.ids = [7295]; +exports.modules = { + +/***/ 5184: +/***/ ((module) => { + +"use strict"; +module.exports = require("nodemailer"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +"use strict"; +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +"use strict"; +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +"use strict"; +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +"use strict"; +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +"use strict"; +module.exports = require("path"); + +/***/ }), + +/***/ 5382: +/***/ ((__unused_webpack_module, exports, __webpack_require__) => { + +// @ts-check +const { createHmac } = __webpack_require__(6113); +// +/** + * # Password Hash function + * @param {string} password + * @returns + */ function hashPassword(password) { + const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD || ""); + hmac.update(password); + let hashed = hmac.digest("base64"); + return hashed; +} +exports.hashPassword = hashPassword; // export const comparePasswords = async (password) => { + // const hmac = createHmac("sha512", process.env.DSQL_ENCRYPTION_PASSWORD); + // hmac.update(password); + // let hashed = hmac.digest("base64"); + // let dbPass = await global.DB_HANDLER(`SELECT * FROM users WHERE password = '${hashed}'`); + // console.log(dbPass); + // return dbPass; + // }; + + +/***/ }), + +/***/ 9916: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_passwordHash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5382); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1311); +/* harmony import */ var _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); +const nodemailer = __webpack_require__(5184); +const path = __webpack_require__(1017); + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + try { + const decryptedCsrfJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_0___default()(csrf); + const decryptedCsrf = JSON.parse(decryptedCsrfJSON || ""); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/user/login-user/lines-61-64", + message: error.message, + user: {} + }); + } + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const reqBody = req.body; + const { email , database , email_login_field , mail_domain , mail_password , mail_username , mail_port , sender , html , } = reqBody; + const dbFullName = `datasquirel_user_${user_id}_${database}`; + /** + * Check input validity + * + * @description Check input validity + */ if (email?.match(/ /)) { + return res.json({ + success: false, + msg: "Invalid Email/Password format" + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let foundUser = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `SELECT * FROM users WHERE email = ?`, + queryValuesArray: [ + email + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!foundUser || !foundUser[0]) { + return res.json({ + success: false, + payload: null, + msg: "No user found" + }); + } + function generateCode() { + const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; + let code = ""; + for(let i = 0; i < 8; i++){ + code += chars[Math.floor(Math.random() * chars.length)]; + } + return code; + } + if (foundUser && foundUser[0] && email_login_field) { + const tempCode = generateCode(); + let transporter = nodemailer.createTransport({ + host: mail_domain || process.env.DSQL_MAIL_HOST, + port: mail_port || 465, + secure: true, + auth: { + user: mail_username || process.env.DSQL_MAIL_EMAIL, + pass: mail_password || process.env.DSQL_MAIL_PASSWORD + } + }); + let mailObject = {}; + mailObject["from"] = `"Datasquirel SSO" <${sender || "support@datasquirel.com"}>`; + mailObject["sender"] = sender || "support@datasquirel.com"; + mailObject["to"] = email; + mailObject["subject"] = "One Time Login Code"; + mailObject["html"] = html.replace(/{{code}}/, tempCode); + const info = await transporter.sendMail(mailObject); + if (!info?.accepted) throw new Error("Mail not Sent!"); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let setTempCode = await _package_shared_functions_backend_varDatabaseDbHandler__WEBPACK_IMPORTED_MODULE_3___default()({ + queryString: `UPDATE users SET ${email_login_field} = ? WHERE email = ?`, + queryValuesArray: [ + tempCode + `-${Date.now()}`, + email + ], + database: dbFullName.replace(/[^a-z0-9_]/g, "") + }); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + res.json({ + success: true, + msg: "Success" + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/user/login-user/main-catch-error", + message: error1.message, + user: {} + }); + res.json({ + success: false, + msg: "Failed: " + error1.message + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,8326,1311], () => (__webpack_exec__(9916))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/send-email-code.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/send-email-code.js.nft.json new file mode 100644 index 0000000..4d0cf0b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/send-email-code.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/8326.js","../../../chunks/1311.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/nodemailer/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/nodemailer/lib/nodemailer.js","../../../../../node_modules/nodemailer/lib/mailer/index.js","../../../../../node_modules/nodemailer/lib/shared/index.js","../../../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../../../node_modules/nodemailer/lib/json-transport/index.js","../../../../../node_modules/nodemailer/lib/fetch/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../../../node_modules/nodemailer/lib/dkim/index.js","../../../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../../../node_modules/nodemailer/lib/well-known/index.js","../../../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../../../node_modules/nodemailer/lib/mime-node/index.js","../../../../../node_modules/nodemailer/lib/well-known/services.json","../../../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../../../node_modules/nodemailer/lib/dkim/sign.js","../../../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/nodemailer/lib/base64/index.js","../../../../../node_modules/nodemailer/lib/qp/index.js","../../../../../node_modules/nodemailer/lib/punycode/index.js","../../../../../node_modules/nodemailer/lib/addressparser/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/update-user.js b/dsql-app/.local_dist/server/pages/api/user/update-user.js new file mode 100644 index 0000000..940dc06 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/update-user.js @@ -0,0 +1,178 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 969; +exports.ids = [969]; +exports.modules = { + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 7830: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5886); +/* harmony import */ var _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5425); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2163); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ const fs = __webpack_require__(7147); + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * API handler + * ============================================================================== + * @type {import("next").NextApiHandler} + */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + success: false, + payload: null, + msg: "Failed!" + }); + /** + * Send Response + * + * @description Send a boolean response + */ try { + /** + * User auth + * + * @description Authenticate user + */ const deletedKeys = fs.readFileSync("./apiKeys/deleted.txt", "utf8"); + /** @type {string} */ // @ts-ignore + const authorization = req.headers.authorization; + if (deletedKeys.includes(authorization)) { + return res.json({ + success: false, + msg: "Key Inactive!" + }); + } + const userJSON = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_1___default()(authorization); + if (!userJSON) throw new Error("Failed!"); + const user = JSON.parse(userJSON); + const { user_id , full_access , csrf } = user; + if (!full_access || !csrf) return res.json({ + success: false, + msg: "Unauthorized" + }); + /** + * User auth + * + * @description Authenticate user + */ const { payload , database } = req.body; + /** + * Input Validation + * + * @description Input Validation + * @required - payload.first_name + * @required - payload.last_name + * @required - payload.email + * @required - payload.username + * @required - payload.password + */ const dbFullName = `datasquirel_user_${user_id}_${database}`; + const data = (()=>{ + const reqBodyKeys = Object.keys(payload); + /** @type {any} */ const finalData = {}; + reqBodyKeys.forEach((key)=>{ + if (key?.match(/^date_|^id$/)) return; + finalData[key] = payload[key]; + }); + return finalData; + })(); + const updateUser = await _package_shared_functions_backend_db_updateDbEntry__WEBPACK_IMPORTED_MODULE_0___default()({ + dbContext: "Dsql User", + paradigm: "Full Access", + dbFullName: dbFullName, + tableName: "users", + identifierColumnName: "id", + identifierValue: payload.id, + data: data + }); + res.json({ + success: true, + payload: updateUser + }); + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_2___default()({ + component: "/api/user/update-user/main-catch-error", + message: error.message, + user: {} + }); + res.json({ + success: false, + msg: "Wrong Credentials" + }); + //////////////////////////////////////// + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5425,2224,2163,3017,3403,7547,5886], () => (__webpack_exec__(7830))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/user/update-user.js.nft.json b/dsql-app/.local_dist/server/pages/api/user/update-user.js.nft.json new file mode 100644 index 0000000..38c69b3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/user/update-user.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../chunks/5425.js","../../../chunks/2224.js","../../../chunks/2163.js","../../../chunks/3017.js","../../../chunks/3403.js","../../../chunks/7547.js","../../../chunks/5886.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/sanitize-html/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/sanitize-html/index.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/escape-string-regexp/index.js","../../../../../node_modules/htmlparser2/package.json","../../../../../node_modules/htmlparser2/lib/index.js","../../../../../node_modules/is-plain-object/package.json","../../../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../../../node_modules/deepmerge/package.json","../../../../../node_modules/deepmerge/dist/cjs.js","../../../../../node_modules/parse-srcset/package.json","../../../../../node_modules/parse-srcset/src/parse-srcset.js","../../../../../node_modules/postcss/package.json","../../../../../node_modules/postcss/lib/postcss.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/escape-string-regexp/package.json","../../../../../node_modules/htmlparser2/lib/Parser.js","../../../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../../../node_modules/postcss/lib/result.js","../../../../../node_modules/postcss/lib/css-syntax-error.js","../../../../../node_modules/postcss/lib/lazy-result.js","../../../../../node_modules/postcss/lib/declaration.js","../../../../../node_modules/postcss/lib/container.js","../../../../../node_modules/postcss/lib/processor.js","../../../../../node_modules/postcss/lib/stringify.js","../../../../../node_modules/postcss/lib/fromJSON.js","../../../../../node_modules/postcss/lib/document.js","../../../../../node_modules/postcss/lib/warning.js","../../../../../node_modules/postcss/lib/comment.js","../../../../../node_modules/postcss/lib/at-rule.js","../../../../../node_modules/postcss/lib/input.js","../../../../../node_modules/postcss/lib/parse.js","../../../../../node_modules/postcss/lib/list.js","../../../../../node_modules/postcss/lib/rule.js","../../../../../node_modules/postcss/lib/root.js","../../../../../node_modules/postcss/lib/node.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/postcss/lib/terminal-highlight.js","../../../../../node_modules/postcss/lib/symbols.js","../../../../../node_modules/postcss/lib/map-generator.js","../../../../../node_modules/postcss/lib/warn-once.js","../../../../../node_modules/postcss/lib/no-work-result.js","../../../../../node_modules/postcss/lib/stringifier.js","../../../../../node_modules/postcss/lib/previous-map.js","../../../../../node_modules/postcss/lib/parser.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/entities/package.json","../../../../../node_modules/entities/lib/decode.js","../../../../../node_modules/domelementtype/package.json","../../../../../node_modules/domelementtype/lib/index.js","../../../../../node_modules/domhandler/package.json","../../../../../node_modules/domhandler/lib/index.js","../../../../../node_modules/domutils/package.json","../../../../../node_modules/domutils/lib/index.js","../../../../../node_modules/postcss/lib/tokenize.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/picocolors/package.json","../../../../../node_modules/picocolors/picocolors.js","../../../../../node_modules/source-map-js/package.json","../../../../../node_modules/source-map-js/source-map.js","../../../../../node_modules/domhandler/lib/node.js","../../../../../node_modules/entities/lib/decode_codepoint.js","../../../../../node_modules/domutils/lib/stringify.js","../../../../../node_modules/domutils/lib/manipulation.js","../../../../../node_modules/domutils/lib/traversal.js","../../../../../node_modules/domutils/lib/querying.js","../../../../../node_modules/domutils/lib/legacy.js","../../../../../node_modules/domutils/lib/helpers.js","../../../../../node_modules/domutils/lib/feeds.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../../../node_modules/entities/lib/generated/decode-data-html.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/nanoid/non-secure/package.json","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/nanoid/package.json","../../../../../node_modules/nanoid/non-secure/index.cjs","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/source-map-js/lib/source-map-generator.js","../../../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../../../node_modules/source-map-js/lib/source-node.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/dom-serializer/package.json","../../../../../node_modules/dom-serializer/lib/index.js","../../../../../node_modules/source-map-js/lib/base64-vlq.js","../../../../../node_modules/source-map-js/lib/util.js","../../../../../node_modules/source-map-js/lib/array-set.js","../../../../../node_modules/source-map-js/lib/mapping-list.js","../../../../../node_modules/source-map-js/lib/binary-search.js","../../../../../node_modules/source-map-js/lib/quick-sort.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/dom-serializer/lib/foreignNames.js","../../../../../node_modules/source-map-js/lib/base64.js","../../../../../node_modules/entities/lib/index.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/entities/lib/escape.js","../../../../../node_modules/entities/lib/encode.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/entities/lib/generated/encode-html.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js b/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js new file mode 100644 index 0000000..59496bb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js @@ -0,0 +1,110 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7941; +exports.ids = [7941]; +exports.modules = { + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }), + +/***/ 5603: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ handler) +/* harmony export */ }); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1017); +/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_0__); +// @ts-check + +const http = __webpack_require__(3685); +const fs = __webpack_require__(7147); +const { createHmac } = __webpack_require__(6113); +const key = process.env.DSQL_GITHUB_WEBHOOK_SECRET || ""; +/** + * @param {import("next").NextApiRequest} req + * @returns {boolean} + */ const verify_signature = (req)=>{ + console.log(req.headers); + const signature = createHmac("sha256", key).update(JSON.stringify(req.body)).digest("hex"); + console.log(signature); + return `sha256=${signature}` === req.headers["x-hub-signature-256"]; +}; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").NextApiHandler} */ async function handler(req, res) { + /** + * Check method + * + * @description Check request method and return if invalid + */ if (req.method !== "POST") return res.json({ + msg: "Failed!" + }); + if (!verify_signature(req)) { + console.log("Authorization failed"); + res.status(401).send("Unauthorized"); + return; + } + /** ********************* Initialize data */ const data = req.body; + try { + /** ********************************************** */ /** ********************************************** */ /** ********************************************** */ console.log("Request Recieved"); + const ref = data.ref; + if (!ref?.match(/main/)) { + console.log("Not Main Branch"); + res.json({ + success: true + }); + return; + } + fs.writeFileSync(path__WEBPACK_IMPORTED_MODULE_0___default().resolve(process.cwd(), "./.dist", "REDEPLOY_FLAG"), String(Date.now()), "utf-8"); + console.log("Deploy Flag Triggered. Now Redeploying ..."); + /** ********************************************** */ /** ********************************************** */ /** ********************************************** */ res.json({ + success: true + }); + /** ********************************************** */ /** ********************************************** */ /** ********************************************** */ } catch (error) { + console.log(error); + res.json({ + msg: "Not Handled Yet" + }); + } +} + + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-api-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = (__webpack_exec__(5603)); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js.nft.json b/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js.nft.json new file mode 100644 index 0000000..35ac229 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/api/webhooks/github-push.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-api-runtime.js","../../../../package.json","../../../../../package.json","../../../../../.dist/REDEPLOY_FLAG"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/blog.html b/dsql-app/.local_dist/server/pages/blog.html new file mode 100644 index 0000000..bf92b3f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/blog.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/blog-be6db5dd2389f8c4.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/blog","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/blog.js.nft.json b/dsql-app/.local_dist/server/pages/blog.js.nft.json new file mode 100644 index 0000000..ba6a3d6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/blog.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/contact.html b/dsql-app/.local_dist/server/pages/contact.html new file mode 100644 index 0000000..29b6062 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/contact.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/contact-513427eea0db408d.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/contact","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/contact.js.nft.json b/dsql-app/.local_dist/server/pages/contact.js.nft.json new file mode 100644 index 0000000..d4d0a9e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/contact.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/7037.js","../chunks/2186.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/create-account.js b/dsql-app/.local_dist/server/pages/create-account.js new file mode 100644 index 0000000..ff039db --- /dev/null +++ b/dsql-app/.local_dist/server/pages/create-account.js @@ -0,0 +1,1052 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7398; +exports.ids = [7398]; +exports.modules = { + +/***/ 255: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ +const fs = __webpack_require__(7147); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +const datasquirel = __webpack_require__(9538); +const serverError = __webpack_require__(2317); +const DB_HANDLER = __webpack_require__(9395); +const addDbEntry = __webpack_require__(7857); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Add Admin User on Login + * ============================================================================== + * + * @description this function handles admin users that have been invited by another + * admin user. This fires when the invited user has been logged in or a new account + * has been created for the invited user + * + * @param {object} params - parameters object + * + * @param {object} params.query - query object + * @param {number} params.query.invite - Invitation user id + * @param {string} params.query.database_access - String containing authorized databases + * @param {string} params.query.priviledge - String containing databases priviledges + * @param {string} params.query.email - Inviting user email address + * + * @param {import("@/package-shared/types").UserType} params.user - invited user object + * + * @returns {Promise<any>} new user auth object payload + */ module.exports = async function addAdminUserOnLogin({ query , user }) { + try { + /** + * Fetch user + * + * @description Fetch user from db + */ // @ts-ignore + const { invite , database_access , priviledge , email } = query; + const lastInviteTimeArray = await DB_HANDLER(`SELECT date_created_code FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + // if (lastInviteTimeArray && lastInviteTimeArray[0]?.date_created_code) { + // const timeSinceLastInvite = Date.now() - parseInt(lastInviteTimeArray[0].date_created_code); + // if (timeSinceLastInvite > 21600000) { + // throw new Error("Invitation expired"); + // } + // } else if (!lastInviteTimeArray || !lastInviteTimeArray[0]) { + // throw new Error("No Invitation Found"); + // } + if (!lastInviteTimeArray || !lastInviteTimeArray[0]) { + throw new Error("No Invitation Found"); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + // @ts-ignore + const invitingUserDb = await DB_HANDLER(`SELECT first_name,last_name,email FROM users WHERE id=?`, [ + invite + ]); + if (invitingUserDb?.[0]) { + const existingUserUser = await DB_HANDLER(`SELECT email FROM user_users WHERE user_id=? AND invited_user_id=? AND user_type='admin' AND email=?`, [ + invite, + user.id, + email + ]); + if (existingUserUser?.[0]) { + console.log("User already added"); + } else { + // const newUserUser = await DB_HANDLER( + // `INSERT IGNORE INTO user_users + // (user_id, invited_user_id, database_access, first_name, last_name, phone, email, username, user_type, user_priviledge) + // VALUES + // (?,?,?,?,?,?,?,?,?,?) + // )`, + // [ + // invite, + // user.id, + // database_access, + // user.first_name, + // user.last_name, + // user.phone, + // user.email, + // user.username, + // "admin", + // priviledge, + // ] + // ); + addDbEntry({ + dbFullName: "datasquirel", + tableName: "user_users", + data: { + user_id: invite, + invited_user_id: user.id, + database_access: database_access, + first_name: user.first_name, + last_name: user.last_name, + phone: user.phone, + email: user.email, + username: user.username, + user_type: "admin", + user_priviledge: priviledge, + image: user.image, + image_thumbnail: user.image_thumbnail + } + }); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + // @ts-ignore + const dbTableData = await DB_HANDLER(`SELECT db_tables_data FROM invitations WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + // @ts-ignore + const clearEntries = await DB_HANDLER(`DELETE FROM delegated_user_tables WHERE root_user_id=? AND delegated_user_id=?`, [ + invite, + user.id + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + if (dbTableData && dbTableData[0]) { + const dbTableEntries = dbTableData[0].db_tables_data.split("|"); + for(let i = 0; i < dbTableEntries.length; i++){ + const dbTableEntry = dbTableEntries[i]; + const dbTableEntryArray = dbTableEntry.split("-"); + const [db_slug, table_slug] = dbTableEntryArray; + const newEntry = await addDbEntry({ + dbFullName: "datasquirel", + tableName: "delegated_user_tables", + data: { + delegated_user_id: user.id, + root_user_id: invite, + database: db_slug, + table: table_slug, + priviledge: priviledge + } + }); + } + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } + // @ts-ignore + const inviteAccepted = await DB_HANDLER(`UPDATE invitations SET invitation_status='Accepted' WHERE inviting_user_id=? AND invited_user_email=?`, [ + invite, + email + ]); + } + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + serverError({ + component: "addAdminUserOnLogin", + message: error.message, + user: user + }); + } +}; //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + + +/***/ }), + +/***/ 7857: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const encrypt = __webpack_require__(2380); +const sanitizeHtml = __webpack_require__(6109); +const sanitizeHtmlOptions = __webpack_require__(6704); +const updateDb = __webpack_require__(5851); +const updateDbEntry = __webpack_require__(5851); +const _ = __webpack_require__(6517); +const DB_HANDLER = __webpack_require__(9395); +const DSQL_USER_DB_HANDLER = __webpack_require__(8682); +/** + * Add a db Entry Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {("Master" | "Dsql User")} [params.dbContext] - What is the database context? "Master" + * or "Dsql User". Defaults to "Master" + * @param {("Read Only" | "Full Access")} [params.paradigm] - What is the paradigm for "Dsql User"? + * "Read only" or "Full Access"? Defaults to "Read Only" + * @param {string} [params.dbFullName] - Database full name + * @param {string} params.tableName - Table name + * @param {any} params.data - Data to add + * @param {import("../../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @param {string} [params.duplicateColumnName] - Duplicate column name + * @param {string} [params.duplicateColumnValue] - Duplicate column value + * @param {boolean} [params.update] - Update this row if it exists + * @param {string} [params.encryptionKey] - Update this row if it exists + * @param {string} [params.encryptionSalt] - Update this row if it exists + * + * @returns {Promise<any>} + */ async function addDbEntry({ dbContext , paradigm , dbFullName , tableName , data , tableSchema , duplicateColumnName , duplicateColumnValue , update , encryptionKey , encryptionSalt , }) { + /** + * Initialize variables + */ const isMaster = dbContext?.match(/dsql.user/i) ? false : dbFullName && !dbFullName.match(/^datasquirel$/) ? false : true; + /** @type { any } */ const dbHandler = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (data?.["date_created_timestamp"]) delete data["date_created_timestamp"]; + if (data?.["date_updated_timestamp"]) delete data["date_updated_timestamp"]; + if (data?.["date_updated"]) delete data["date_updated"]; + if (data?.["date_updated_code"]) delete data["date_updated_code"]; + if (data?.["date_created"]) delete data["date_created"]; + if (data?.["date_created_code"]) delete data["date_created_code"]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Handle function logic + */ if (duplicateColumnName && typeof duplicateColumnName === "string") { + const duplicateValue = isMaster ? await dbHandler(`SELECT * FROM \`${tableName}\` WHERE \`${duplicateColumnName}\`=?`, [ + duplicateColumnValue + ]) : await dbHandler({ + paradigm: "Read Only", + database: dbFullName, + queryString: `SELECT * FROM \`${tableName}\` WHERE \`${duplicateColumnName}\`=?`, + queryValues: [ + duplicateColumnValue + ] + }); + if (duplicateValue?.[0] && !update) { + return null; + } else if (duplicateValue && duplicateValue[0] && update) { + return await updateDbEntry({ + dbContext, + paradigm, + dbFullName, + tableName, + data, + tableSchema, + encryptionKey, + encryptionSalt, + identifierColumnName: duplicateColumnName, + identifierValue: duplicateColumnValue || "" + }); + } + } + /** + * Declare variables + * + * @description Declare "results" variable + */ const dataKeys = Object.keys(data); + let insertKeysArray = []; + let insertValuesArray = []; + for(let i = 0; i < dataKeys.length; i++){ + try { + const dataKey = dataKeys[i]; + // @ts-ignore + let value = data?.[dataKey]; + const targetFieldSchemaArray = tableSchema ? tableSchema?.fields?.filter((field)=>field.fieldName == dataKey) : null; + const targetFieldSchema = targetFieldSchemaArray && targetFieldSchemaArray[0] ? targetFieldSchemaArray[0] : null; + if (value == null || value == undefined) continue; + if (targetFieldSchema?.encrypted) { + value = encrypt(value, encryptionKey, encryptionSalt); + console.log("DSQL: Encrypted value =>", value); + } + if (targetFieldSchema?.richText) { + value = sanitizeHtml(value, sanitizeHtmlOptions); + } + if (targetFieldSchema?.pattern) { + const pattern = new RegExp(targetFieldSchema.pattern, targetFieldSchema.patternFlags || ""); + if (!pattern.test(value)) { + console.log("DSQL: Pattern not matched =>", value); + value = ""; + } + } + insertKeysArray.push("`" + dataKey + "`"); + if (typeof value === "object") { + value = JSON.stringify(value); + } + if (typeof value == "number") { + insertValuesArray.push(String(value)); + } else { + insertValuesArray.push(value); + } + } catch (/** @type {any} */ error) { + console.log("DSQL: Error in parsing data keys =>", error.message); + continue; + } + } + //////////////////////////////////////// + if (!data?.["date_created"]) { + insertKeysArray.push("`date_created`"); + insertValuesArray.push(Date()); + } + if (!data?.["date_created_code"]) { + insertKeysArray.push("`date_created_code`"); + insertValuesArray.push(Date.now()); + } + //////////////////////////////////////// + if (!data?.["date_updated"]) { + insertKeysArray.push("`date_updated`"); + insertValuesArray.push(Date()); + } + if (!data?.["date_updated_code"]) { + insertKeysArray.push("`date_updated_code`"); + insertValuesArray.push(Date.now()); + } + //////////////////////////////////////// + const query = `INSERT INTO \`${tableName}\` (${insertKeysArray.join(",")}) VALUES (${insertValuesArray.map(()=>"?").join(",")})`; + const queryValuesArray = insertValuesArray; + const newInsert = isMaster ? await dbHandler(query, queryValuesArray) : await dbHandler({ + paradigm, + database: dbFullName, + queryString: query, + queryValues: queryValuesArray + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return newInsert; +} +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = addDbEntry; + + +/***/ }), + +/***/ 5851: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check +/** + * Imports: Handle imports + */ +const encrypt = __webpack_require__(2380); +const sanitizeHtml = __webpack_require__(6109); +const sanitizeHtmlOptions = __webpack_require__(6704); +const DB_HANDLER = __webpack_require__(9395); +const DSQL_USER_DB_HANDLER = __webpack_require__(8682); +/** + * Update DB Function + * ============================================================================== + * @description Description + * @async + * + * @param {object} params - An object containing the function parameters. + * @param {("Master" | "Dsql User")} [params.dbContext] - What is the database context? "Master" + * or "Dsql User". Defaults to "Master" + * @param {("Read Only" | "Full Access")} [params.paradigm] - What is the paradigm for "Dsql User"? + * "Read only" or "Full Access"? Defaults to "Read Only" + * @param {string} [params.dbFullName] - Database full name + * @param {string} params.tableName - Table name + * @param {string} [params.encryptionKey] + * @param {string} [params.encryptionSalt] + * @param {any} params.data - Data to add + * @param {import("../../../types").DSQL_TableSchemaType} [params.tableSchema] - Table schema + * @param {string} params.identifierColumnName - Update row identifier column name + * @param {string | number} params.identifierValue - Update row identifier column value + * + * @returns {Promise<object|null>} + */ async function updateDbEntry({ dbContext , paradigm , dbFullName , tableName , data , tableSchema , identifierColumnName , identifierValue , encryptionKey , encryptionSalt , }) { + /** + * Check if data is valid + */ if (!data || !Object.keys(data).length) return null; + const isMaster = dbContext?.match(/dsql.user/i) ? false : dbFullName && !dbFullName.match(/^datasquirel$/) ? false : true; + /** @type {(a1:any, a2?:any)=> any } */ const dbHandler = isMaster ? DB_HANDLER : DSQL_USER_DB_HANDLER; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Declare variables + * + * @description Declare "results" variable + */ const dataKeys = Object.keys(data); + let updateKeyValueArray = []; + let updateValues = []; + for(let i = 0; i < dataKeys.length; i++){ + try { + const dataKey = dataKeys[i]; + // @ts-ignore + let value = data[dataKey]; + const targetFieldSchemaArray = tableSchema ? tableSchema?.fields?.filter((field)=>field.fieldName === dataKey) : null; + const targetFieldSchema = targetFieldSchemaArray && targetFieldSchemaArray[0] ? targetFieldSchemaArray[0] : null; + if (value == null || value == undefined) continue; + if (targetFieldSchema?.richText) { + value = sanitizeHtml(value, sanitizeHtmlOptions); + } + if (targetFieldSchema?.encrypted) { + value = encrypt(value, encryptionKey, encryptionSalt); + } + if (typeof value === "object") { + value = JSON.stringify(value); + } + if (targetFieldSchema?.pattern) { + const pattern = new RegExp(targetFieldSchema.pattern, targetFieldSchema.patternFlags || ""); + if (!pattern.test(value)) { + console.log("DSQL: Pattern not matched =>", value); + value = ""; + } + } + if (typeof value === "string" && value.match(/^null$/i)) { + value = { + toSqlString: function() { + return "NULL"; + } + }; + } + if (typeof value === "string" && !value.match(/./i)) { + value = { + toSqlString: function() { + return "NULL"; + } + }; + } + updateKeyValueArray.push(`\`${dataKey}\`=?`); + if (typeof value == "number") { + updateValues.push(String(value)); + } else { + updateValues.push(value); + } + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error) { + //////////////////////////////////////// + //////////////////////////////////////// + console.log("DSQL: Error in parsing data keys in update function =>", error.message); + continue; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + updateKeyValueArray.push(`date_updated='${Date()}'`); + updateKeyValueArray.push(`date_updated_code='${Date.now()}'`); + //////////////////////////////////////// + //////////////////////////////////////// + const query = `UPDATE ${tableName} SET ${updateKeyValueArray.join(",")} WHERE \`${identifierColumnName}\`=?`; + updateValues.push(identifierValue); + const updatedEntry = isMaster ? await dbHandler(query, updateValues) : await dbHandler({ + paradigm, + database: dbFullName, + queryString: query, + queryValues: updateValues + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Return statement + */ return updatedEntry; +} +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +module.exports = updateDbEntry; + + +/***/ }), + +/***/ 2380: +/***/ ((module, __unused_webpack_exports, __webpack_require__) => { + +// @ts-check + +const { scryptSync , createCipheriv } = __webpack_require__(6113); +const { Buffer } = __webpack_require__(4300); +const serverError = __webpack_require__(7023); +/** + * @async + * @param {string} data + * @param {string} [encryptionKey] + * @param {string} [encryptionSalt] + * @returns {string | null} + */ const encrypt = (data, encryptionKey, encryptionSalt)=>{ + const algorithm = "aes-192-cbc"; + const password = encryptionKey ? encryptionKey : process.env.DSQL_ENCRYPTION_PASSWORD || ""; + /** ********************* Generate key */ const salt = encryptionSalt ? encryptionSalt : process.env.DSQL_ENCRYPTION_SALT || ""; + let key = scryptSync(password, salt, 24); + let iv = Buffer.alloc(16, 0); + // @ts-ignore + const cipher = createCipheriv(algorithm, key, iv); + /** ********************* Encrypt data */ try { + let encrypted = cipher.update(data, "utf8", "hex"); + encrypted += cipher.final("hex"); + return encrypted; + } catch (/** @type {any} */ error) { + serverError({ + component: "encrypt", + message: error.message + }); + return null; + } +}; +module.exports = encrypt; + + +/***/ }), + +/***/ 6704: +/***/ ((module) => { + +// @ts-check + +const sanitizeHtmlOptions = { + allowedTags: [ + "b", + "i", + "em", + "strong", + "a", + "p", + "span", + "ul", + "ol", + "li", + "h1", + "h2", + "h3", + "h4", + "h5", + "h6", + "img", + "div", + "button", + "pre", + "code", + "br" + ], + allowedAttributes: { + a: [ + "href" + ], + img: [ + "src", + "alt", + "width", + "height", + "class", + "style" + ], + "*": [ + "style", + "class" + ] + } +}; +module.exports = sanitizeHtmlOptions; + + +/***/ }), + +/***/ 8214: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "CreateAccountContext": () => (/* binding */ CreateAccountContext), + "default": () => (/* binding */ CreateAccount), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/GeneralLayout.jsx + 1 modules +var GeneralLayout = __webpack_require__(6217); +// EXTERNAL MODULE: ./components/general/PageHeadTags.jsx +var PageHeadTags = __webpack_require__(4097); +// EXTERNAL MODULE: ./components/pages/create-account/CreateAccountForm.jsx + 1 modules +var CreateAccountForm = __webpack_require__(5114); +;// CONCATENATED MODULE: ./components/pages/create-account/Hero.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function Hero(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { query , invitingUser } = external_react_default().useContext(CreateAccountContext); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "flex-col items-center lg:items-center gap-20 p-0", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/grid.webp", + alt: "Dotted image background", + className: "absolute top-0 left-0 w-full h-full object-cover opacity-80 dark:opacity-10 z-0" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full lg:w-1/2 max-w-6xl gap-4 flex-col items-center px-4 py-10 bg-white dark:bg-slate-900 relative z-10", + children: [ + invitingUser?.first_name && /*#__PURE__*/ (0,jsx_runtime_.jsxs)("span", { + className: "text-xs bg-emerald-100 rounded-full px-4 py-1 mb-4", + children: [ + "You have been invited by", + " ", + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("b", { + children: [ + invitingUser.first_name, + " ", + invitingUser.last_name, + " (", + invitingUser.email, + ")" + ] + }), + " ", + "to manage an account. Please create an account to gain access." + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "m-0 text-center text-2xl", + children: "Create An Account" + }), + /*#__PURE__*/ jsx_runtime_.jsx(CreateAccountForm/* default */.Z, { + query: query + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./functions/backend/addAdminUserOnLogin.js +var addAdminUserOnLogin = __webpack_require__(255); +var addAdminUserOnLogin_default = /*#__PURE__*/__webpack_require__.n(addAdminUserOnLogin); +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +// EXTERNAL MODULE: ./components/general/Logo.jsx +var Logo = __webpack_require__(4017); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingScreen.jsx +var LoadingScreen = __webpack_require__(6478); +;// CONCATENATED MODULE: ./pages/create-account.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + +/** ****************************************************************************** */ + + + + + + + + + +/** ****************************************************************************** */ /** @type {import("@/package-shared/types").CreateAccountContextType} */ // @ts-ignore +const init = {}; +const CreateAccountContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").CreateAccountQueryType} props.query + * @param {any} props.invitingUser + * @param {any} props.isAuthCookie + * @param {import("@/package-shared/types").UserType} props.user + */ function CreateAccount(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Create Account | Datasquirel"; + const pageDescription = "Create a FREE account and start storing data."; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx(PageHeadTags/* default */.Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [user, setUser] = external_react_default().useState(null); + external_react_default().useEffect(()=>{ + if (props.query?.invite && !props.isAuthCookie) { + setTimeout(()=>{ + (0,fetchApi/* default */.Z)("/api/addAdminUserUser", { + method: "POST", + body: { + query: props.query + } + }, true).then((res)=>{ + window.location.pathname = `/admin/${props.user?.id}/users`; + }); + // clearCaches() + // .then(() => { + // console.log("caches cleared!"); + // }) + // .finally(() => { + // window.location.reload(); + // }); + }, 1000); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (props.query?.invite) { + return /*#__PURE__*/ jsx_runtime_.jsx(LoadingScreen/* default */.Z, {}); + } + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(GeneralLayout/* default */.Z, { + head: head, + children: /*#__PURE__*/ jsx_runtime_.jsx(CreateAccountContext.Provider, { + value: { + user, + query: props.query, + invitingUser: props.invitingUser + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("main", { + children: /*#__PURE__*/ jsx_runtime_.jsx(Hero, {}) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + if (true) { + return { + redirect: { + destination: "/login", + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const user = await userAuth_default()(req, res); + if (user?.logged_in_status && !query?.invite) { + return { + redirect: { + destination: "/admin", + permanent: false + } + }; + } + const isAuthCookie = req.cookies?.datasquirelAuthKey?.match(/./) ? true : false; + let invitingUser = {}; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ if (query?.email && user?.logged_in_status && user?.email === query.email) { + console.log("Invitation Received by current logged in user"); + const acceptInvitation = await addAdminUserOnLogin_default()({ + // @ts-ignore + query, + user + }); + return { + redirect: { + destination: `/admin/${user?.id}/users`, + permanent: false + } + }; + } else if (query?.email && user?.logged_in_status && user?.email !== query.email) { + console.log("Invitation Received but email doesn't match!"); + return { + redirect: { + destination: "/logout?login=true&" + Object.keys(query).map((key)=>`${key}=${query[key]}`).join("&"), + permanent: false + } + }; + } else if (query?.invite && !user?.logged_in_status) { + console.log("Invitation Received but no User Logged In"); + const existingUser = await DB_HANDLER_default()(`SELECT first_name FROM users WHERE email='${query.email}'`); + if (existingUser && existingUser[0]) { + return { + redirect: { + destination: "/login?" + Object.keys(query).map((key)=>`${key}=${query[key]}`).join("&"), + permanent: false + } + }; + } + const invitingUserDb = await DB_HANDLER_default()(`SELECT first_name,last_name,email FROM users WHERE id='${query.invite}'`); + if (invitingUserDb && invitingUserDb[0]) invitingUser = invitingUserDb[0]; + } else { + // console.log("No Invitation Received!"); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + query, + invitingUser, + isAuthCookie + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 6843: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ContentCopy"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9174: +/***/ ((module) => { + +module.exports = require("@mui/material/Snackbar"); + +/***/ }), + +/***/ 9538: +/***/ ((module) => { + +module.exports = require("datasquirel"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 6109: +/***/ ((module) => { + +module.exports = require("sanitize-html"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,9360,6217,4097,7023,8682,2317,7037,8374,5114,6478], () => (__webpack_exec__(8214))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/create-account.js.nft.json b/dsql-app/.local_dist/server/pages/create-account.js.nft.json new file mode 100644 index 0000000..8b7d907 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/create-account.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/7023.js","../chunks/8682.js","../chunks/2317.js","../chunks/7037.js","../chunks/8374.js","../chunks/5114.js","../chunks/6478.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/datasquirel/package.json","../../../node_modules/lodash/package.json","../../../node_modules/sanitize-html/package.json","../../../node_modules/react-dom/package.json","../../../node_modules/nodemailer/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/@mui/material/Snackbar/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/datasquirel/index.js","../../../node_modules/lodash/lodash.js","../../../node_modules/sanitize-html/index.js","../../../node_modules/nodemailer/lib/nodemailer.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/react-dom/index.js","../../../node_modules/@mui/material/node/Snackbar/index.js","../../../node_modules/@mui/material/node/Paper/index.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/ContentCopy.js","../../../node_modules/datasquirel/functions/hashPassword.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../node_modules/react-dom/cjs/react-dom.development.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/datasquirel/utils/get.js","../../../node_modules/datasquirel/utils/post.js","../../../node_modules/datasquirel/utils/upload-image.js","../../../node_modules/datasquirel/utils/get-schema.js","../../../node_modules/datasquirel/utils/delete-file.js","../../../node_modules/datasquirel/utils/upload-file.js","../../../node_modules/datasquirel/users/add-user.js","../../../node_modules/datasquirel/users/update-user.js","../../../node_modules/datasquirel/users/login-user.js","../../../node_modules/datasquirel/users/send-email-code.js","../../../node_modules/datasquirel/users/logout-user.js","../../../node_modules/datasquirel/users/user-auth.js","../../../node_modules/datasquirel/users/reauth-user.js","../../../node_modules/datasquirel/users/get-user.js","../../../node_modules/datasquirel/users/get-token.js","../../../node_modules/datasquirel/users/validate-token.js","../../../node_modules/datasquirel/users/social/google-auth.js","../../../node_modules/datasquirel/users/social/github-auth.js","../../../node_modules/datasquirel/utils/functions/sanitizeSql.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useTheme.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../node_modules/@mui/material/node/Paper/Paper.js","../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/nodemailer/lib/mailer/index.js","../../../node_modules/nodemailer/lib/shared/index.js","../../../node_modules/nodemailer/lib/smtp-pool/index.js","../../../node_modules/nodemailer/lib/sendmail-transport/index.js","../../../node_modules/nodemailer/lib/smtp-transport/index.js","../../../node_modules/nodemailer/lib/stream-transport/index.js","../../../node_modules/nodemailer/lib/ses-transport/index.js","../../../node_modules/nodemailer/lib/json-transport/index.js","../../../node_modules/nodemailer/lib/fetch/index.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/Grow/index.js","../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/datasquirel/engine/user/one-time-code.html","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/datasquirel/functions/decrypt.js","../../../node_modules/datasquirel/utils/functions/parseCookies.js","../../../node_modules/mysql/index.js","../../../node_modules/escape-string-regexp/index.js","../../../node_modules/htmlparser2/package.json","../../../node_modules/htmlparser2/lib/index.js","../../../node_modules/is-plain-object/package.json","../../../node_modules/is-plain-object/dist/is-plain-object.js","../../../node_modules/deepmerge/package.json","../../../node_modules/deepmerge/dist/cjs.js","../../../node_modules/parse-srcset/package.json","../../../node_modules/parse-srcset/src/parse-srcset.js","../../../node_modules/postcss/package.json","../../../node_modules/postcss/lib/postcss.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/datasquirel/functions/encrypt.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/datasquirel/engine/user/get-user.js","../../../node_modules/datasquirel/engine/user/update-user.js","../../../node_modules/datasquirel/engine/user/add-user.js","../../../node_modules/datasquirel/engine/user/reauth-user.js","../../../node_modules/datasquirel/engine/user/login-user.js","../../../node_modules/datasquirel/engine/user/send-email-code.js","../../../node_modules/datasquirel/engine/query/post.js","../../../node_modules/datasquirel/engine/query/get.js","../../../node_modules/datasquirel/engine/user/social/google-auth.js","../../../node_modules/datasquirel/engine/user/social/github-auth.js","../../../node_modules/mysql/package.json","../../../node_modules/escape-string-regexp/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/base/node/index.js","../../../node_modules/nodemailer/lib/mailer/mail-message.js","../../../node_modules/nodemailer/lib/smtp-connection/http-proxy-client.js","../../../node_modules/nodemailer/lib/smtp-pool/pool-resource.js","../../../node_modules/nodemailer/lib/fetch/cookies.js","../../../node_modules/nodemailer/lib/mime-funcs/mime-types.js","../../../node_modules/nodemailer/lib/mime-node/le-windows.js","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/Grow/Grow.js","../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/scheduler/package.json","../../../node_modules/scheduler/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/htmlparser2/lib/Parser.js","../../../node_modules/htmlparser2/lib/Tokenizer.js","../../../node_modules/postcss/lib/result.js","../../../node_modules/@mui/base/useSnackbar/package.json","../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/postcss/lib/css-syntax-error.js","../../../node_modules/postcss/lib/lazy-result.js","../../../node_modules/postcss/lib/declaration.js","../../../node_modules/postcss/lib/container.js","../../../node_modules/postcss/lib/processor.js","../../../node_modules/postcss/lib/stringify.js","../../../node_modules/postcss/lib/fromJSON.js","../../../node_modules/postcss/lib/document.js","../../../node_modules/postcss/lib/warning.js","../../../node_modules/postcss/lib/comment.js","../../../node_modules/postcss/lib/at-rule.js","../../../node_modules/postcss/lib/input.js","../../../node_modules/postcss/lib/parse.js","../../../node_modules/postcss/lib/list.js","../../../node_modules/postcss/lib/rule.js","../../../node_modules/postcss/lib/root.js","../../../node_modules/postcss/lib/node.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/nodemailer/lib/mail-composer/index.js","../../../node_modules/nodemailer/lib/dkim/index.js","../../../node_modules/nodemailer/lib/smtp-connection/index.js","../../../node_modules/nodemailer/lib/well-known/index.js","../../../node_modules/nodemailer/lib/xoauth2/index.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/datasquirel/engine/engine/addUsersTableToDb.js","../../../node_modules/datasquirel/engine/engine/utils/varDatabaseDbHandler.js","../../../node_modules/datasquirel/engine/engine/utils/camelJoinedtoCamelSpace.js","../../../node_modules/datasquirel/engine/query/utils/runQuery.js","../../../node_modules/datasquirel/engine/query/utils/addDbEntry.js","../../../node_modules/datasquirel/engine/query/utils/updateDbEntry.js","../../../node_modules/datasquirel/engine/user/social/utils/handleSocialDb.js","../../../node_modules/datasquirel/engine/user/social/utils/httpsRequest.js","../../../node_modules/datasquirel/engine/user/social/utils/githubLogin.js","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../node_modules/scheduler/cjs/scheduler.development.js","../../../node_modules/@mui/material/node/transitions/utils.js","../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../node_modules/@mui/base/node/NoSsr/index.js","../../../node_modules/@mui/base/node/Portal/index.js","../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/postcss/lib/terminal-highlight.js","../../../node_modules/postcss/lib/symbols.js","../../../node_modules/postcss/lib/map-generator.js","../../../node_modules/postcss/lib/warn-once.js","../../../node_modules/postcss/lib/no-work-result.js","../../../node_modules/postcss/lib/stringifier.js","../../../node_modules/postcss/lib/previous-map.js","../../../node_modules/postcss/lib/parser.js","../../../node_modules/nodemailer/lib/mime-funcs/index.js","../../../node_modules/nodemailer/lib/mime-node/index.js","../../../node_modules/nodemailer/lib/well-known/services.json","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/nodemailer/lib/smtp-connection/data-stream.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/base/node/utils/index.js","../../../node_modules/@mui/base/node/Badge/index.js","../../../node_modules/@mui/base/node/Button/index.js","../../../node_modules/@mui/base/node/Dropdown/index.js","../../../node_modules/@mui/base/node/FormControl/index.js","../../../node_modules/@mui/base/node/Input/index.js","../../../node_modules/@mui/base/node/Menu/index.js","../../../node_modules/@mui/base/node/MenuButton/index.js","../../../node_modules/@mui/base/node/MenuItem/index.js","../../../node_modules/@mui/base/node/Modal/index.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../node_modules/@mui/base/node/Option/index.js","../../../node_modules/@mui/base/node/Popper/index.js","../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../node_modules/@mui/base/node/Select/index.js","../../../node_modules/@mui/base/node/Slider/index.js","../../../node_modules/@mui/base/node/Snackbar/index.js","../../../node_modules/@mui/base/node/Switch/index.js","../../../node_modules/@mui/base/node/TablePagination/index.js","../../../node_modules/@mui/base/node/TabPanel/index.js","../../../node_modules/@mui/base/node/TabsList/index.js","../../../node_modules/@mui/base/node/Tabs/index.js","../../../node_modules/@mui/base/node/Tab/index.js","../../../node_modules/@mui/base/node/Transitions/index.js","../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../node_modules/@mui/base/node/useBadge/index.js","../../../node_modules/@mui/base/node/useButton/index.js","../../../node_modules/@mui/base/node/useDropdown/index.js","../../../node_modules/@mui/base/node/useInput/index.js","../../../node_modules/@mui/base/node/useMenu/index.js","../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../node_modules/@mui/base/node/useOption/index.js","../../../node_modules/@mui/base/node/useSelect/index.js","../../../node_modules/@mui/base/node/useSlider/index.js","../../../node_modules/@mui/base/node/useSwitch/index.js","../../../node_modules/@mui/base/node/useTab/index.js","../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../node_modules/@mui/base/node/useTabs/index.js","../../../node_modules/@mui/base/node/useTabsList/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/nodemailer/lib/dkim/message-parser.js","../../../node_modules/nodemailer/lib/dkim/sign.js","../../../node_modules/nodemailer/lib/dkim/relaxed-body.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/entities/package.json","../../../node_modules/entities/lib/decode.js","../../../node_modules/domelementtype/package.json","../../../node_modules/domelementtype/lib/index.js","../../../node_modules/domhandler/package.json","../../../node_modules/domhandler/lib/index.js","../../../node_modules/domutils/package.json","../../../node_modules/domutils/lib/index.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/datasquirel/engine/engine/data/presets/users.json","../../../node_modules/datasquirel/engine/query/update-api-schema-from-local-db.js","../../../node_modules/datasquirel/engine/engine/utils/parseDbResults.js","../../../node_modules/datasquirel/engine/engine/utils/dbHandler.js","../../../node_modules/datasquirel/engine/query/utils/deleteDbEntry.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/react-transition-group/package.json","../../../node_modules/react-transition-group/cjs/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../node_modules/@mui/base/node/Portal/Portal.js","../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/postcss/lib/tokenize.js","../../../node_modules/nodemailer/lib/mime-node/last-newline.js","../../../node_modules/nodemailer/lib/mime-node/le-unix.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/picocolors/package.json","../../../node_modules/picocolors/picocolors.js","../../../node_modules/source-map-js/package.json","../../../node_modules/source-map-js/source-map.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../node_modules/@mui/base/node/utils/types.js","../../../node_modules/@mui/base/node/Badge/Badge.js","../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../node_modules/@mui/base/node/Button/Button.js","../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../node_modules/@mui/base/node/Button/Button.types.js","../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../node_modules/@mui/base/node/Input/Input.js","../../../node_modules/@mui/base/node/Input/Input.types.js","../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../node_modules/@mui/base/node/Menu/Menu.js","../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../node_modules/@mui/base/node/Modal/Modal.js","../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../node_modules/@mui/base/node/Option/Option.js","../../../node_modules/@mui/base/node/Option/Option.types.js","../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../node_modules/@mui/base/node/Popper/Popper.js","../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../node_modules/@mui/base/node/Select/Select.js","../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../node_modules/@mui/base/node/Select/Select.types.js","../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../node_modules/@mui/base/node/Slider/Slider.js","../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../node_modules/@mui/base/node/Switch/Switch.js","../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../node_modules/@mui/base/node/Tab/Tab.js","../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../node_modules/@mui/base/node/useButton/useButton.js","../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../node_modules/@mui/base/node/useInput/useInput.js","../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../node_modules/@mui/base/node/useOption/useOption.js","../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../node_modules/@mui/base/node/useTab/useTab.js","../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/domhandler/lib/node.js","../../../node_modules/entities/lib/decode_codepoint.js","../../../node_modules/domutils/lib/stringify.js","../../../node_modules/domutils/lib/manipulation.js","../../../node_modules/domutils/lib/traversal.js","../../../node_modules/domutils/lib/querying.js","../../../node_modules/domutils/lib/legacy.js","../../../node_modules/domutils/lib/helpers.js","../../../node_modules/domutils/lib/feeds.js","../../../node_modules/datasquirel/engine/engine/utils/defaultFieldsRegexp.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/entities/lib/generated/decode-data-xml.js","../../../node_modules/entities/lib/generated/decode-data-html.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/nodemailer/lib/base64/index.js","../../../node_modules/nodemailer/lib/qp/index.js","../../../node_modules/nodemailer/lib/punycode/index.js","../../../node_modules/nodemailer/lib/addressparser/index.js","../../../node_modules/datasquirel/ssl/ca-cert.pem","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/nanoid/non-secure/package.json","../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../node_modules/react-transition-group/cjs/Transition.js","../../../node_modules/react-transition-group/cjs/config.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/nanoid/package.json","../../../node_modules/nanoid/non-secure/index.cjs","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../node_modules/@mui/base/node/useList/ListContext.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/source-map-js/lib/source-map-generator.js","../../../node_modules/source-map-js/lib/source-map-consumer.js","../../../node_modules/source-map-js/lib/source-node.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../node_modules/@mui/base/node/useList/index.js","../../../node_modules/@mui/base/node/useTransition/index.js","../../../node_modules/@mui/base/node/useCompound/index.js","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/dom-serializer/package.json","../../../node_modules/dom-serializer/lib/index.js","../../../node_modules/source-map-js/lib/base64-vlq.js","../../../node_modules/source-map-js/lib/util.js","../../../node_modules/source-map-js/lib/array-set.js","../../../node_modules/source-map-js/lib/mapping-list.js","../../../node_modules/source-map-js/lib/binary-search.js","../../../node_modules/source-map-js/lib/quick-sort.js","../../../node_modules/@floating-ui/react-dom/package.json","../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../node_modules/@popperjs/core/package.json","../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@mui/base/node/useList/useList.js","../../../node_modules/@mui/base/node/useList/useList.types.js","../../../node_modules/@mui/base/node/useList/useListItem.js","../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../node_modules/@mui/base/node/useList/listReducer.js","../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/dom-serializer/lib/foreignNames.js","../../../node_modules/source-map-js/lib/base64.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/dom-helpers/addClass/package.json","../../../node_modules/dom-helpers/cjs/addClass.js","../../../node_modules/dom-helpers/removeClass/package.json","../../../node_modules/dom-helpers/cjs/removeClass.js","../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/entities/lib/index.js","../../../node_modules/dom-helpers/package.json","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/entities/lib/escape.js","../../../node_modules/entities/lib/encode.js","../../../node_modules/dom-helpers/cjs/hasClass.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@floating-ui/dom/package.json","../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/entities/lib/generated/encode-html.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/@floating-ui/core/package.json","../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs.js b/dsql-app/.local_dist/server/pages/docs.js new file mode 100644 index 0000000..1a8cd77 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs.js @@ -0,0 +1,448 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3172; +exports.ids = [3172]; +exports.modules = { + +/***/ 1732: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ Homepage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/GeneralLayout.jsx + 1 modules +var GeneralLayout = __webpack_require__(6217); +// EXTERNAL MODULE: ./components/general/PageHeadTags.jsx +var PageHeadTags = __webpack_require__(4097); +// EXTERNAL MODULE: ./functions/frontend/clientAuthUser.js +var clientAuthUser = __webpack_require__(9922); +// EXTERNAL MODULE: ./components/pages/docs/DocsAside.jsx +var DocsAside = __webpack_require__(6000); +;// CONCATENATED MODULE: ./components/pages/docs/DocsHomeHero.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DocsHomeHero(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "py-14", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "w-full gap-10 justify-between flex-col lg:flex-row relative z-10", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-center lg:items-start max-w-lg text-center lg:text-left", + style: { + minWidth: "45%" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "text-2xl m-0 leading-tight", + children: "Documentation" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-normal", + children: "Learn the ins and outs of datasquirel." + }) + ] + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("img", { + src: "/images/grid.webp", + alt: "Dotted image background", + className: "absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0" + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: external "lucide-react" +var external_lucide_react_ = __webpack_require__(2423); +;// CONCATENATED MODULE: ./components/cards/LinkCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.title + * @param {string} props.description + * @param {string} props.url + */ function LinkCard({ title , description , url }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: url, + className: "card", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col items-start", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "text-2xl font-semibold", + children: title + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "max-w-md text-slate-600", + children: description + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(external_lucide_react_.ChevronDown, { + size: 20 + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/pages/docs/DocsHomeLinks.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function DocsHomeLinks(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "py-14", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "grid grid-cols-1 sl:grid-cols-2 gap-4 w-full items-stretch", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(LinkCard, { + title: "Quick Start Guide", + description: "Get Started.", + url: "/docs/quick-start" + }), + /*#__PURE__*/ jsx_runtime_.jsx(LinkCard, { + title: "GUI Reference", + description: "Learn how to complete basic data tasks from your dashboard", + url: "/docs/gui-reference" + }), + /*#__PURE__*/ jsx_runtime_.jsx(LinkCard, { + title: "API Reference", + description: "Interact with your database from a backend server using REST API", + url: "/docs/api-reference" + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./pages/docs/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +// import DB_HANDLER from "@/package-shared/utils/backend/global-db/DB_HANDLER"; +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any[]} props.pages + * @param {any} props.targetPage + */ function Homepage({ pages , targetPage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${targetPage.title} | Datasquirel docs`; + const pageDescription = targetPage.description; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx(PageHeadTags/* default */.Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [user, setUser] = external_react_default().useState(null); + external_react_default().useEffect(()=>{ + (0,clientAuthUser/* default */.Z)({ + setUser + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(GeneralLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "items-stretch w-full gap-0 flex-col-reverse lg:flex-row", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(DocsAside/* default */.Z, { + pages: pages + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("main", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(DocsHomeHero, {}), + /*#__PURE__*/ jsx_runtime_.jsx(DocsHomeLinks, {}) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ query }) { + /** + * Redirect to default page + */ /** @type {any[]} */ // const defaultPage = await DB_HANDLER( + // `SELECT slug FROM docs_pages WHERE level='1' AND page_order = '1'` + // ); + // if (!defaultPage || !defaultPage[0]) { + // return { + // redirect: { + // destination: `/`, + // permanent: false, + // }, + // }; + // } + return { + redirect: { + destination: `/docs/getting-started`, + permanent: false + } + }; +/** + * Data fetching + */ // const pages = await dbHandler(`SELECT id, title, slug, level, parent_id FROM docs_pages ORDER BY page_order ASC`); +// const targetPage = await dbHandler(`SELECT title, slug, description, content FROM docs_pages WHERE level='1' AND page_order = '1'`); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +/** + * Server props return + * + * @description Return data fetched on the server side + */ // return { +// props: { +// user: null, +// pages, +// targetPage: targetPage[0] ? targetPage[0] : {}, +// }, +// }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,913,9360,6217,4097,9922,6000], () => (__webpack_exec__(1732))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs.js.nft.json b/dsql-app/.local_dist/server/pages/docs.js.nft.json new file mode 100644 index 0000000..696e7ea --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/6000.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/[page].js b/dsql-app/.local_dist/server/pages/docs/[page].js new file mode 100644 index 0000000..6d109b6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/[page].js @@ -0,0 +1,283 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3749; +exports.ids = [3749]; +exports.modules = { + +/***/ 203: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Homepage), +/* harmony export */ "getStaticPaths": () => (/* binding */ getStaticPaths), +/* harmony export */ "getStaticProps": () => (/* binding */ getStaticProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6217); +/* harmony import */ var _components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4097); +/* harmony import */ var _functions_frontend_clientAuthUser__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(9922); +/* harmony import */ var _components_pages_docs_DocsAside__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6000); +/* harmony import */ var _components_pages_docs_DocsGenereicHero__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9350); +/* harmony import */ var _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1273); +/* harmony import */ var _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any[]} props.pages + * @param {any} props.targetPage + */ function Homepage({ pages , targetPage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ if (true) { + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + window.location.href = "https://datasquirel.com/docs/getting-started"; + }, []); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), {}); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${targetPage.title} | Datasquirel docs`; + const pageDescription = targetPage.description; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [user, setUser] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_clientAuthUser__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)({ + setUser + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "items-stretch w-full gap-0 flex-col-reverse lg:flex-row", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_pages_docs_DocsAside__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + pages: pages + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("main", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_pages_docs_DocsGenereicHero__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + title: targetPage.title, + description: targetPage.description + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "RTE-DOCS pl-4 sm:pl-10 pt-4 pb-20 pr-4", + dangerouslySetInnerHTML: { + __html: targetPage.content + } + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Server Side Props or Static Props + * @type {import("next").GetStaticProps} + */ async function getStaticProps({ params }) { + /** + * User Auth + * + * @description User Auth + */ const pages = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT id, title, slug, level, parent_id FROM docs_pages ORDER BY page_order ASC`); + /** @type {any[]} */ // @ts-ignore + const targetPage = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT title, slug, description, content FROM docs_pages WHERE slug = ?`, [ + params?.page + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: null, + pages, + targetPage: targetPage[0] ? targetPage[0] : {} + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** + * + * Static Props + * @type {import("next").GetStaticPaths} + */ async function getStaticPaths() { + try { + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {any[]} */ // @ts-ignore + const entries = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT id, title, slug, level, parent_id FROM docs_pages WHERE level = 1`); + const paths = entries.map((entry)=>{ + return { + params: { + page: entry.slug + } + }; + }); + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + paths: paths, + fallback: false + }; + } catch (/** @type {any} */ error) { + /** + * Error Response + * + * @description Return data fetched on the server side + */ console.log("Error =>", error.message); + return { + paths: [], + fallback: false + }; + } +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,913,9360,6217,4097,7023,9922,6000,2896], () => (__webpack_exec__(203))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/[page].js.nft.json b/dsql-app/.local_dist/server/pages/docs/[page].js.nft.json new file mode 100644 index 0000000..9490c6f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/[page].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5449.js","../../chunks/913.js","../../chunks/9360.js","../../chunks/6217.js","../../chunks/4097.js","../../chunks/7023.js","../../chunks/9922.js","../../chunks/6000.js","../../chunks/2896.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/mysql/index.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js b/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js new file mode 100644 index 0000000..ba703d9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js @@ -0,0 +1,310 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4656; +exports.ids = [4656]; +exports.modules = { + +/***/ 629: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Homepage), +/* harmony export */ "getStaticPaths": () => (/* binding */ getStaticPaths), +/* harmony export */ "getStaticProps": () => (/* binding */ getStaticProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6217); +/* harmony import */ var _components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4097); +/* harmony import */ var _functions_frontend_clientAuthUser__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(9922); +/* harmony import */ var _components_pages_docs_DocsAside__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6000); +/* harmony import */ var _components_pages_docs_DocsGenereicHero__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9350); +/* harmony import */ var _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1273); +/* harmony import */ var _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any[]} props.pages + * @param {any} props.targetPage + */ function Homepage({ pages , targetPage }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ if (true) { + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + window.location.href = "https://datasquirel.com/docs/getting-started"; + }, []); + return null; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = `${targetPage.title} | Datasquirel docs`; + const pageDescription = targetPage.description; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [user, setUser] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + (0,_functions_frontend_clientAuthUser__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)({ + setUser + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "items-stretch w-full gap-0 flex-col-reverse lg:flex-row", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_pages_docs_DocsAside__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + pages: pages + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("main", { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_pages_docs_DocsGenereicHero__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + title: targetPage.title, + description: targetPage.description + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "RTE-DOCS pl-4 sm:pl-10 pt-4 pb-20 pr-4", + dangerouslySetInnerHTML: { + __html: targetPage.content + } + }) + ] + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Server Side Props or Static Props + * @type {import("next").GetStaticProps} + */ async function getStaticProps({ params }) { + /** + * Data Fetching + * + * @description Data Fetching + */ // const page = params.page; + const subPage = params?.["sub-page"]; + /** @type {any[] | null} */ // @ts-ignore + const pages = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT id, title, slug, level, parent_id FROM docs_pages ORDER BY page_order ASC`); + const targetRootPage = pages?.filter((page)=>page.slug === params?.page && page.level == 1); + if (!targetRootPage) { + return { + redirect: { + destination: "/docs", + permanent: false + } + }; + } + /** @type {any[] | null} */ // @ts-ignore + const targetPage = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT title, slug, description, content FROM docs_pages WHERE slug = ? AND level = ? AND parent_id = ?`, [ + subPage, + 2, + targetRootPage[0]?.id + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: null, + pages, + targetPage: targetPage?.[0] ? targetPage[0] : {} + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** + * + * Static Props + * @type {import("next").GetStaticPaths} + */ async function getStaticPaths() { + try { + /** + * Page/Site Data Data Fetching + */ /** @type {any[] | null} */ // @ts-ignore + const entries = await _package_shared_functions_backend_dbHandler__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT id, title, slug, level, parent_id FROM docs_pages`); + const subEntries = entries?.filter((entry)=>parseInt(entry?.level) == 2); + /** @type {any[]} */ let paths = []; + const rootEntries = entries?.filter((entry)=>entry?.level == 1); + if (!rootEntries?.[0]) { + return { + paths: [], + fallback: false + }; + } + rootEntries.forEach((entry)=>{ + const rootSubEntries = subEntries?.filter((subEntry)=>subEntry.parent_id == entry?.id); + rootSubEntries?.forEach((rootSubEntry)=>{ + paths.push({ + params: { + page: entry.slug, + "sub-page": rootSubEntry.slug + } + }); + }); + }); + // console.log(JSON.stringify(paths, null, 4)); + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + paths: paths, + fallback: false + }; + } catch (/** @type {any} */ error) { + /** + * Error Response + * + * @description Return data fetched on the server side + */ console.log("Error =>", error.message); + return { + paths: [], + fallback: false + }; + } +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,913,9360,6217,4097,7023,9922,6000,2896], () => (__webpack_exec__(629))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js.nft.json b/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js.nft.json new file mode 100644 index 0000000..3abf3cb --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/[page]/[sub-page].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/913.js","../../../chunks/9360.js","../../../chunks/6217.js","../../../chunks/4097.js","../../../chunks/7023.js","../../../chunks/9922.js","../../../chunks/6000.js","../../../chunks/2896.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference.html b/dsql-app/.local_dist/server/pages/docs/api-reference.html new file mode 100644 index 0000000..feeff81 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D-3602862f9a9542f8.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"API Reference","slug":"api-reference","description":"\u003cp\u003eAccess data from external sources. Datasquirel is platform-agnostic so all you need is a HTTP request with the right credentials. Our NPM module abstracts this aspect for ease of use when using node.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eAll data stored in your databases can be accessed through our integrated API. There are two sets of API keys, each with different scope. If you want to just fetch data use the \u003cstrong\u003eRead Only \u003c/strong\u003eAPI key. If you want to have full access to every aspect of your account, use the \u003cstrong\u003eFull Access \u003c/strong\u003eAPI key. Learn how to add API keys \u003ca href=\"docs/quick-start\"\u003ehere\u003c/a\u003e.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eGetting started\u003c/h2\u003e\u003cp\u003eAfter you have your API keys, you can start making calls using our API integration. We have an NPM module for node projects, but you only need a HTTPS client to make the calls.\u003c/p\u003e\u003cpre class=\"language-markup\"\u003enpm install datasquirel\u003c/pre\u003e\u003ch2\u003e\u003cbr /\u003e\u003c/h2\u003e\u003ch2\u003eFetching Data using the \u003cem\u003eget\u003c/em\u003e method\u003c/h2\u003e\u003cp\u003eThe get method only retrieves data. It cannot be used to write or update data. It was created to be the fastest way to access your data, that explains the key length. You can get data using the npm module or via any HTTP request.\u003c/p\u003e\u003cul\u003e\u003cli\u003eUsing CURL:\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-markup\"\u003eCURL \n https://datasquirel.com/api/query/get?db=db_name\u0026amp;query=SELECT+*+FROM+table_name \n-H \n \"Authorization:READ_ONLY_API_KEY\";Content-Type:application/json\u003c/pre\u003e\u003c/li\u003e\u003cli\u003eUsing node module\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003eget\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edb\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"test\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eDATASQUIREL_READ_ONLY_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"SELECT title, slug, body FROM blog_posts\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eThe response from this method returns a JSON payload with two fields: \u003cstrong\u003esuccess\u003c/strong\u003e: which could be either \u003ccode style=\"display:inline\"\u003etrue\u003c/code\u003e or \u003ccode style=\"display:inline\"\u003efalse\u003c/code\u003e, and \u003cstrong\u003epayload: \u003c/strong\u003ewhich is an array of values when the operation is successfull, or anything from \u003ccode style=\"display:inline\"\u003enull\u003c/code\u003e to a string to an object with an error message. This is a sample of a successful response object:\u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003etrue\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e[\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eid\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003etitle\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"Hello World\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eslug\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"hello-world\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ebody\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"This is a test blog post.\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e]\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003cp\u003eA failed response could return any of three results:\u003c/p\u003e\u003cul\u003e\u003cli\u003eA \u003ccode style=\"display:inline\"\u003enull\u003c/code\u003e payload.\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token keyword\"\u003enull\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003cbr /\u003e\u003c/li\u003e\u003cli\u003eAn error string payload\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"ERROR: no such table as 'blog_posts'\"\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003cli\u003eAn object payload containing an error field\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e \u003cspan class=\"token literal-property property\"\u003eerror\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"MYSQL ERROR: syntax error in your sql\"\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eIn each case, the success key refurns a value of \u003ccode style=\"display:inline\"\u003efalse\u003c/code\u003e , meaning the query failed.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eUsing the \u003cem\u003epost\u003c/em\u003e method\u003c/h2\u003e\u003cp\u003eThe post method contains the full spectrum of CRUD operations. And it works \u003cstrong\u003e*only \u003c/strong\u003ewith the \u003cstrong\u003eFull Access \u003c/strong\u003eAPI key. The read only API key will not work for post methods.\u003c/p\u003e\u003cul\u003e\u003cli\u003eUsing CURL\u003cbr /\u003e\u003cpre class=\"language-markup\"\u003eCURL --json\n '{ \n \"database\": \"social_network\",\n \"query\": \"UPDATE users SET name = 'John' WHERE id = 1\"\n }'\n https://datasquirel.com/api/query/post \n-H \n \"Authorization:FULL_ACCESS_API_KEY\"`\u003c/pre\u003e\u003cbr /\u003e\u003c/li\u003e\u003cli\u003eUsing our npm module\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003epost\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edatabase\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"social_network\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eFULL_ACCESS_API_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"UPDATE users SET name = 'John' WHERE id = 1\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eThe process yeilds simalar results, but with a slight difference: for operations like \u003cstrong\u003einsert \u003c/strong\u003eand \u003cstrong\u003eupdate\u003c/strong\u003e, the \u003ccode style=\"display:inline\"\u003esuccess\u003c/code\u003e field yeilds \u003ccode style=\"display:inline\"\u003etrue\u003c/code\u003e while the \u003ccode style=\"display:inline\"\u003epayload\u003c/code\u003e field yeilds an object containing fields like \u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003etrue\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eserverStatus\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e37\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eaffectedRows\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003cp\u003eThe post method can also take an object as the \u003ccode style=\"display:inline\"\u003equery\u003c/code\u003e instead of a string. Example:\u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003epost\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edatabase\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"social_network\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eFULL_ACCESS_API_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eaction\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"update\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003etable\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"users\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edata\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ename\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"John\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eidentifierColumnName\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"id\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eidentifierValue\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003cp\u003eThis yields the exact same result as before. Learn more about the post method \u003ca href=\"api-reference/post\"\u003ehere\u003c/a\u003e.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]","query":{"page":"api-reference"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference.json b/dsql-app/.local_dist/server/pages/docs/api-reference.json new file mode 100644 index 0000000..3a0ba99 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"API Reference","slug":"api-reference","description":"<p>Access data from external sources. Datasquirel is platform-agnostic so all you need is a HTTP request with the right credentials. Our NPM module abstracts this aspect for ease of use when using node.</p>","content":"<h2>Overview</h2><p>All data stored in your databases can be accessed through our integrated API. There are two sets of API keys, each with different scope. If you want to just fetch data use the <strong>Read Only </strong>API key. If you want to have full access to every aspect of your account, use the <strong>Full Access </strong>API key. Learn how to add API keys <a href=\"docs/quick-start\">here</a>.</p><p><br /></p><h2>Getting started</h2><p>After you have your API keys, you can start making calls using our API integration. We have an NPM module for node projects, but you only need a HTTPS client to make the calls.</p><pre class=\"language-markup\">npm install datasquirel</pre><h2><br /></h2><h2>Fetching Data using the <em>get</em> method</h2><p>The get method only retrieves data. It cannot be used to write or update data. It was created to be the fastest way to access your data, that explains the key length. You can get data using the npm module or via any HTTP request.</p><ul><li>Using CURL:<br /><br /><pre class=\"language-markup\">CURL \n https://datasquirel.com/api/query/get?db=db_name&query=SELECT+*+FROM+table_name \n-H \n \"Authorization:READ_ONLY_API_KEY\";Content-Type:application/json</pre></li><li>Using node module<br /><br /><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">get</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">db</span><span class=\"token operator\">:</span> <span class=\"token string\">\"test\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">DATASQUIREL_READ_ONLY_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token string\">\"SELECT title, slug, body FROM blog_posts\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre></li></ul><p>The response from this method returns a JSON payload with two fields: <strong>success</strong>: which could be either <code style=\"display:inline\">true</code> or <code style=\"display:inline\">false</code>, and <strong>payload: </strong>which is an array of values when the operation is successfull, or anything from <code style=\"display:inline\">null</code> to a string to an object with an error message. This is a sample of a successful response object:</p><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">true</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">[</span>\n <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">id</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">title</span><span class=\"token operator\">:</span> <span class=\"token string\">\"Hello World\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">slug</span><span class=\"token operator\">:</span> <span class=\"token string\">\"hello-world\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">body</span><span class=\"token operator\">:</span> <span class=\"token string\">\"This is a test blog post.\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">]</span><span class=\"token punctuation\">,</span>\n<span class=\"token punctuation\">}</span></pre><p>A failed response could return any of three results:</p><ul><li>A <code style=\"display:inline\">null</code> payload.<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token keyword\">null</span>\n<span class=\"token punctuation\">}</span></pre><br /></li><li>An error string payload<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token string\">\"ERROR: no such table as 'blog_posts'\"</span>\n<span class=\"token punctuation\">}</span></pre></li><li>An object payload containing an error field<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span> <span class=\"token literal-property property\">error</span><span class=\"token operator\">:</span> <span class=\"token string\">\"MYSQL ERROR: syntax error in your sql\"</span> <span class=\"token punctuation\">}</span>\n<span class=\"token punctuation\">}</span></pre></li></ul><p>In each case, the success key refurns a value of <code style=\"display:inline\">false</code> , meaning the query failed.</p><p><br /></p><h2>Using the <em>post</em> method</h2><p>The post method contains the full spectrum of CRUD operations. And it works <strong>*only </strong>with the <strong>Full Access </strong>API key. The read only API key will not work for post methods.</p><ul><li>Using CURL<br /><pre class=\"language-markup\">CURL --json\n '{ \n \"database\": \"social_network\",\n \"query\": \"UPDATE users SET name = 'John' WHERE id = 1\"\n }'\n https://datasquirel.com/api/query/post \n-H \n \"Authorization:FULL_ACCESS_API_KEY\"`</pre><br /></li><li>Using our npm module<br /><br /><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">post</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">database</span><span class=\"token operator\">:</span> <span class=\"token string\">\"social_network\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">FULL_ACCESS_API_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token string\">\"UPDATE users SET name = 'John' WHERE id = 1\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre></li></ul><p>The process yeilds simalar results, but with a slight difference: for operations like <strong>insert </strong>and <strong>update</strong>, the <code style=\"display:inline\">success</code> field yeilds <code style=\"display:inline\">true</code> while the <code style=\"display:inline\">payload</code> field yeilds an object containing fields like </p><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">true</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">serverStatus</span><span class=\"token operator\">:</span> <span class=\"token number\">37</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">affectedRows</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span>\n<span class=\"token punctuation\">}</span></pre><p>The post method can also take an object as the <code style=\"display:inline\">query</code> instead of a string. Example:</p><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">post</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">database</span><span class=\"token operator\">:</span> <span class=\"token string\">\"social_network\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">FULL_ACCESS_API_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">action</span><span class=\"token operator\">:</span> <span class=\"token string\">\"update\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">table</span><span class=\"token operator\">:</span> <span class=\"token string\">\"users\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">data</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">name</span><span class=\"token operator\">:</span> <span class=\"token string\">\"John\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">identifierColumnName</span><span class=\"token operator\">:</span> <span class=\"token string\">\"id\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">identifierValue</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre><p>This yields the exact same result as before. Learn more about the post method <a href=\"api-reference/post\">here</a>.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference/get.html b/dsql-app/.local_dist/server/pages/docs/api-reference/get.html new file mode 100644 index 0000000..8a19483 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference/get.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Get","slug":"get","description":"\u003cp\u003eFetch data from your database quickly and securely.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eThe get method only retrieves data. It cannot be used to write or update data. It was created to be the fastest way to access your data, that explains the key length. You can get data using the npm module or via any HTTP request.\u003c/p\u003e\u003ch3\u003eUsing CURL\u003c/h3\u003e\u003cpre class=\"language-markup\"\u003eCURL \n https://datasquirel.com/api/query/get?db=db_name\u0026amp;query=SELECT+*+FROM+table_name \n-H \n \"Authorization:READ_ONLY_API_KEY\";Content-Type:application/json\u003c/pre\u003e\u003ch3\u003e\u003cbr /\u003e\u003c/h3\u003e\u003ch3\u003eUsing node module\u003c/h3\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003eget\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edb\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"test\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eDATASQUIREL_READ_ONLY_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"SELECT title, slug, body FROM blog_posts\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eThe response\u003c/h2\u003e\u003cp\u003eThe response from this method returns a JSON payload with two fields: \u003cstrong\u003esuccess\u003c/strong\u003e: which could be either \u003ccode style=\"display:inline\"\u003etrue\u003c/code\u003e or \u003ccode style=\"display:inline\"\u003efalse\u003c/code\u003e, and \u003cstrong\u003epayload: \u003c/strong\u003ewhich is an array of values when the operation is successfull, or anything from \u003ccode style=\"display:inline\"\u003enull\u003c/code\u003e to a string to an object with an error message. This is a sample of a successful response object:\u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003etrue\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e[\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eid\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003etitle\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"Hello World\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eslug\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"hello-world\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ebody\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"This is a test blog post.\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e]\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003cp\u003eA failed response could return any of three results:\u003c/p\u003e\u003cul\u003e\u003cli\u003eA \u003ccode style=\"display:inline\"\u003enull\u003c/code\u003e payload.\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token keyword\"\u003enull\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003cli\u003eAn error string payload\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"ERROR: no such table as 'blog_posts'\"\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003cli\u003eAn object payload containing an error field\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003efalse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e \u003cspan class=\"token literal-property property\"\u003eerror\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"MYSQL ERROR: syntax error in your sql\"\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eIn each case, the success key refurns a value of \u003ccode style=\"display:inline\"\u003efalse\u003c/code\u003e , meaning the query failed.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"api-reference","sub-page":"get"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference/get.json b/dsql-app/.local_dist/server/pages/docs/api-reference/get.json new file mode 100644 index 0000000..519215e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference/get.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Get","slug":"get","description":"<p>Fetch data from your database quickly and securely.</p>","content":"<h2>Overview</h2><p>The get method only retrieves data. It cannot be used to write or update data. It was created to be the fastest way to access your data, that explains the key length. You can get data using the npm module or via any HTTP request.</p><h3>Using CURL</h3><pre class=\"language-markup\">CURL \n https://datasquirel.com/api/query/get?db=db_name&query=SELECT+*+FROM+table_name \n-H \n \"Authorization:READ_ONLY_API_KEY\";Content-Type:application/json</pre><h3><br /></h3><h3>Using node module</h3><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">get</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">db</span><span class=\"token operator\">:</span> <span class=\"token string\">\"test\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">DATASQUIREL_READ_ONLY_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token string\">\"SELECT title, slug, body FROM blog_posts\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre><p><br /></p><h2>The response</h2><p>The response from this method returns a JSON payload with two fields: <strong>success</strong>: which could be either <code style=\"display:inline\">true</code> or <code style=\"display:inline\">false</code>, and <strong>payload: </strong>which is an array of values when the operation is successfull, or anything from <code style=\"display:inline\">null</code> to a string to an object with an error message. This is a sample of a successful response object:</p><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">true</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">[</span>\n <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">id</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">title</span><span class=\"token operator\">:</span> <span class=\"token string\">\"Hello World\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">slug</span><span class=\"token operator\">:</span> <span class=\"token string\">\"hello-world\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">body</span><span class=\"token operator\">:</span> <span class=\"token string\">\"This is a test blog post.\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">]</span><span class=\"token punctuation\">,</span>\n<span class=\"token punctuation\">}</span></pre><p>A failed response could return any of three results:</p><ul><li>A <code style=\"display:inline\">null</code> payload.<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token keyword\">null</span>\n<span class=\"token punctuation\">}</span></pre></li><li>An error string payload<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token string\">\"ERROR: no such table as 'blog_posts'\"</span>\n<span class=\"token punctuation\">}</span></pre></li><li>An object payload containing an error field<br /><br /><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">false</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span> <span class=\"token literal-property property\">error</span><span class=\"token operator\">:</span> <span class=\"token string\">\"MYSQL ERROR: syntax error in your sql\"</span> <span class=\"token punctuation\">}</span>\n<span class=\"token punctuation\">}</span></pre></li></ul><p>In each case, the success key refurns a value of <code style=\"display:inline\">false</code> , meaning the query failed.</p><p><br /></p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference/post.html b/dsql-app/.local_dist/server/pages/docs/api-reference/post.html new file mode 100644 index 0000000..fd617d8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference/post.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Post","slug":"post","description":"\u003cp\u003eFull CRUD operations on your database using our feature-rich API integration.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eThe \u003ccode style=\"display:inline\"\u003epost\u003c/code\u003e  method expands on the \u003ccode style=\"display:inline\"\u003eget\u003c/code\u003e method. It adds the ability to insert, update, and delete data, as well as add and delete images from your static files directories.\u003c/p\u003e\u003cp\u003eThe post method contains the full spectrum of CRUD operations. And it works \u003cstrong\u003e*only \u003c/strong\u003ewith the \u003cstrong\u003eFull Access \u003c/strong\u003eAPI key. The read only API key will not work for post methods.\u003c/p\u003e\u003ch3\u003eUsing CURL\u003cbr /\u003e\u003c/h3\u003e\u003cpre class=\"language-markup\"\u003eCURL --json\n '{ \n \"database\": \"social_network\",\n \"query\": \"UPDATE users SET name = 'John' WHERE id = 1\"\n }'\n https://datasquirel.com/api/query/post \n-H \n \"Authorization:FULL_ACCESS_API_KEY\"`\u003c/pre\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch3\u003eUsing our npm module\u003cbr /\u003e\u003c/h3\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003epost\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edatabase\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"social_network\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eFULL_ACCESS_API_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"UPDATE users SET name = 'John' WHERE id = 1\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003ch2\u003e\u003cbr /\u003e\u003c/h2\u003e\u003ch2\u003eThe Response\u003c/h2\u003e\u003cp\u003eThe process yeilds simalar results, but with a slight difference: for operations like \u003cstrong\u003einsert \u003c/strong\u003eand \u003cstrong\u003eupdate\u003c/strong\u003e, the \u003ccode style=\"display:inline\"\u003esuccess\u003c/code\u003e field yeilds \u003ccode style=\"display:inline\"\u003etrue\u003c/code\u003e while the \u003ccode style=\"display:inline\"\u003epayload\u003c/code\u003e field yeilds an object containing fields like \u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003esuccess\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token boolean\"\u003etrue\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eserverStatus\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e37\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eaffectedRows\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\n\u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003c/pre\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003ePost with object \u003cem\u003equery\u003c/em\u003e\u003c/h2\u003e\u003cp\u003eThe post method can also take an object as the \u003ccode style=\"display:inline\"\u003equery\u003c/code\u003e instead of a string. Example:\u003c/p\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003epost\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edatabase\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"social_network\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eFULL_ACCESS_API_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eaction\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"update\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003etable\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"users\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edata\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ename\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"John\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eidentifierColumnName\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"id\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eidentifierValue\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e1\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003cp\u003eThis yields the exact same result as before.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eAdding media\u003c/h2\u003e\u003cp\u003eIn addition to the full CRUD operations the \u003ccode style=\"display:inline\"\u003epost\u003c/code\u003e method offers, you can also add media to your static files directory. This uses the same post method, but with sligtly different parameters. Also, the media you send \u003cstrong\u003e*must \u003c/strong\u003ebe in \u003ccode style=\"display:inline\"\u003ebase64\u003c/code\u003e format. You can use our npm client module to convert images and documents to \u003ccode style=\"display:inline\"\u003ebase64\u003c/code\u003e format.\u003c/p\u003e\u003ch3\u003eUsing our node module\u003c/h3\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003emedia\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003euploadImage\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eDATASQUIREL_FULL_ACCESS_API_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003epayload\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eimageData\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"--------- LONG BASE64 STRING ---------\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003eimageName\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"sunflower\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003efolder\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"flowers\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e \u003cspan class=\"token comment\"\u003e// Optional\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003emimeType\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"jpeg\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e \u003cspan class=\"token comment\"\u003e// Optional\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ethumbnailSize\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token number\"\u003e300\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e \u003cspan class=\"token comment\"\u003e// Optional\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"api-reference","sub-page":"post"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/api-reference/post.json b/dsql-app/.local_dist/server/pages/docs/api-reference/post.json new file mode 100644 index 0000000..31a75cc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/api-reference/post.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Post","slug":"post","description":"<p>Full CRUD operations on your database using our feature-rich API integration.</p>","content":"<h2>Overview</h2><p>The <code style=\"display:inline\">post</code>  method expands on the <code style=\"display:inline\">get</code> method. It adds the ability to insert, update, and delete data, as well as add and delete images from your static files directories.</p><p>The post method contains the full spectrum of CRUD operations. And it works <strong>*only </strong>with the <strong>Full Access </strong>API key. The read only API key will not work for post methods.</p><h3>Using CURL<br /></h3><pre class=\"language-markup\">CURL --json\n '{ \n \"database\": \"social_network\",\n \"query\": \"UPDATE users SET name = 'John' WHERE id = 1\"\n }'\n https://datasquirel.com/api/query/post \n-H \n \"Authorization:FULL_ACCESS_API_KEY\"`</pre><p><br /></p><h3>Using our npm module<br /></h3><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">post</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">database</span><span class=\"token operator\">:</span> <span class=\"token string\">\"social_network\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">FULL_ACCESS_API_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token string\">\"UPDATE users SET name = 'John' WHERE id = 1\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre><h2><br /></h2><h2>The Response</h2><p>The process yeilds simalar results, but with a slight difference: for operations like <strong>insert </strong>and <strong>update</strong>, the <code style=\"display:inline\">success</code> field yeilds <code style=\"display:inline\">true</code> while the <code style=\"display:inline\">payload</code> field yeilds an object containing fields like </p><pre class=\"language-javascript\"><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">success</span><span class=\"token operator\">:</span> <span class=\"token boolean\">true</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">serverStatus</span><span class=\"token operator\">:</span> <span class=\"token number\">37</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">affectedRows</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span>\n<span class=\"token punctuation\">}</span></pre><p><br /></p><h2>Post with object <em>query</em></h2><p>The post method can also take an object as the <code style=\"display:inline\">query</code> instead of a string. Example:</p><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">post</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">database</span><span class=\"token operator\">:</span> <span class=\"token string\">\"social_network\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">FULL_ACCESS_API_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">action</span><span class=\"token operator\">:</span> <span class=\"token string\">\"update\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">table</span><span class=\"token operator\">:</span> <span class=\"token string\">\"users\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">data</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">name</span><span class=\"token operator\">:</span> <span class=\"token string\">\"John\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">identifierColumnName</span><span class=\"token operator\">:</span> <span class=\"token string\">\"id\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">identifierValue</span><span class=\"token operator\">:</span> <span class=\"token number\">1</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre><p>This yields the exact same result as before.</p><p><br /></p><h2>Adding media</h2><p>In addition to the full CRUD operations the <code style=\"display:inline\">post</code> method offers, you can also add media to your static files directory. This uses the same post method, but with sligtly different parameters. Also, the media you send <strong>*must </strong>be in <code style=\"display:inline\">base64</code> format. You can use our npm client module to convert images and documents to <code style=\"display:inline\">base64</code> format.</p><h3>Using our node module</h3><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel<span class=\"token punctuation\">.</span>media\n <span class=\"token punctuation\">.</span><span class=\"token function\">uploadImage</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">DATASQUIREL_FULL_ACCESS_API_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">payload</span><span class=\"token operator\">:</span> <span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">imageData</span><span class=\"token operator\">:</span> <span class=\"token string\">\"--------- LONG BASE64 STRING ---------\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">imageName</span><span class=\"token operator\">:</span> <span class=\"token string\">\"sunflower\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">folder</span><span class=\"token operator\">:</span> <span class=\"token string\">\"flowers\"</span><span class=\"token punctuation\">,</span> <span class=\"token comment\">// Optional</span>\n <span class=\"token literal-property property\">mimeType</span><span class=\"token operator\">:</span> <span class=\"token string\">\"jpeg\"</span><span class=\"token punctuation\">,</span> <span class=\"token comment\">// Optional</span>\n <span class=\"token literal-property property\">thumbnailSize</span><span class=\"token operator\">:</span> <span class=\"token number\">300</span><span class=\"token punctuation\">,</span> <span class=\"token comment\">// Optional</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference.html b/dsql-app/.local_dist/server/pages/docs/database-reference.html new file mode 100644 index 0000000..98a6470 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D-3602862f9a9542f8.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Database Reference","slug":"database-reference","description":"\u003cp\u003eUnderstanding SQL and its syntax.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eSQL (Sequential Query Language) is the industry-standard, battle-tested database querying language used to interact with relational databases. While datasquirel aims to abstract much of it, knowing the basics is still very important to get the full power of datasquirel management system.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]","query":{"page":"database-reference"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference.json b/dsql-app/.local_dist/server/pages/docs/database-reference.json new file mode 100644 index 0000000..f3dfe62 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Database Reference","slug":"database-reference","description":"<p>Understanding SQL and its syntax.</p>","content":"<h2>Overview</h2><p>SQL (Sequential Query Language) is the industry-standard, battle-tested database querying language used to interact with relational databases. While datasquirel aims to abstract much of it, knowing the basics is still very important to get the full power of datasquirel management system.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.html b/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.html new file mode 100644 index 0000000..fd14aec --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Data types","slug":"data-types","description":"\u003cp\u003eRelational database data types\u003c/p\u003e","content":"\u003ch2\u003eVARCHAR\u003c/h2\u003e\u003cp\u003eThe varchar datatype is probably the most commonly used datatype. It's basically text and numbers that max out at 255 characters. Varchar type is usually annoted in the form \u003ccode style=\"display:inline\"\u003eVARCHAR(20)\u003c/code\u003e .\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"database-reference","sub-page":"data-types"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.json b/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.json new file mode 100644 index 0000000..2874617 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference/data-types.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Data types","slug":"data-types","description":"<p>Relational database data types</p>","content":"<h2>VARCHAR</h2><p>The varchar datatype is probably the most commonly used datatype. It's basically text and numbers that max out at 255 characters. Varchar type is usually annoted in the form <code style=\"display:inline\">VARCHAR(20)</code> .</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.html b/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.html new file mode 100644 index 0000000..a52e5bc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Querying Data","slug":"querying-data","description":"\u003cp\u003eUsing SQL to query data from your database\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eQuerying data will eventually be the most common thing you do with your datasquirel account. So it's important to know some essential querying syntax, our node module abstraction will not give you the same level of control as direct sql querying.\u003c/p\u003e\u003ch2\u003eSELECT Keyword\u003c/h2\u003e\u003cpre class=\"language-markup\"\u003eSELECT * FROM blog_posts\u003c/pre\u003e\u003cp\u003eThe select keyword is the most basic and used keyword. In the example above, we're selecting every row(or entry) from the table \u003ccode style=\"display:inline\"\u003eblog_posts\u003c/code\u003e . The \"*\" sign stands for \"all columns\". To dial down to specific columns, you can replace the \"*\" symbol with the column(s) you want to select. Example:\u003c/p\u003e\u003cpre class=\"language-markup\"\u003eSELECT title, body FROM blog_posts\u003c/pre\u003e\u003cp\u003eThis query only targets the \u003ccode style=\"display:inline\"\u003etitle\u003c/code\u003e and \u003ccode style=\"display:inline\"\u003ebody\u003c/code\u003e columns(or fields) in the \u003ccode style=\"display:inline\"\u003eblog_posts\u003c/code\u003e table.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"database-reference","sub-page":"querying-data"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.json b/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.json new file mode 100644 index 0000000..e4fcdfe --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/database-reference/querying-data.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Querying Data","slug":"querying-data","description":"<p>Using SQL to query data from your database</p>","content":"<h2>Overview</h2><p>Querying data will eventually be the most common thing you do with your datasquirel account. So it's important to know some essential querying syntax, our node module abstraction will not give you the same level of control as direct sql querying.</p><h2>SELECT Keyword</h2><pre class=\"language-markup\">SELECT * FROM blog_posts</pre><p>The select keyword is the most basic and used keyword. In the example above, we're selecting every row(or entry) from the table <code style=\"display:inline\">blog_posts</code> . The \"*\" sign stands for \"all columns\". To dial down to specific columns, you can replace the \"*\" symbol with the column(s) you want to select. Example:</p><pre class=\"language-markup\">SELECT title, body FROM blog_posts</pre><p>This query only targets the <code style=\"display:inline\">title</code> and <code style=\"display:inline\">body</code> columns(or fields) in the <code style=\"display:inline\">blog_posts</code> table.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/getting-started.html b/dsql-app/.local_dist/server/pages/docs/getting-started.html new file mode 100644 index 0000000..94ec4f6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/getting-started.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D-3602862f9a9542f8.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Getting Started","slug":"getting-started","description":"\u003cp\u003eIntroduction to datasquirel. Read the \u003ca href=\"../../../docs/quick-start\"\u003equick-start guide\u003c/a\u003e to get started with a new account.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003ca href=\"https://vitejs.dev/guide/#overview\"\u003e​\u003c/a\u003e\u003c/h2\u003e\u003cp\u003eDatasquirel is an SQL-based data management system that aims to manage SQL databases with the lowest level of opinionation. Datasquirel consists of 2 main parts:\u003c/p\u003e\u003col\u003e\u003cli\u003eA full-fledged SQL server that runs multiple isolated databases for different users, interfacing with an online Graphical user interface and a REST API integration.\u003c/li\u003e\u003cli\u003eAn all-purpose static files server using NGINX to serve static files on demand. Files uploaded to datasquirel static file server are public by default, but the can be made private, in which case they can only be accessed via secure encrypted credentials.\u003c/li\u003e\u003c/ol\u003e\u003cdiv style=\"flex-wrap:wrap;max-width:800px\"\u003e\u003cdiv style=\"padding:30px;border-radius:5px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;background-color:rgb(246, 244, 248);position:relative;overflow:hidden;flex-grow:1\"\u003e\u003ch3 style=\"margin:0px;color:rgb(30, 41, 59)\"\u003eGUI Reference\u003c/h3\u003e\u003cdiv\u003eSQL through your bowser\u003c/div\u003e\u003ca href=\"../../../docs/gui-reference\" class=\"button\"\u003eLearn More\u003c/a\u003e \u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/icons/ui-design.png\" style=\"position:absolute;bottom:-100px;right:-50px;opacity:0.2\" width=\"250\" height=\"250\" /\u003e\u003c/div\u003e\u003c/div\u003e\u003cp\u003eDatasquirel's Graphical User Interface aims to narrow down the the complexities of SQL to a simple user interface with columns, rows, and entries.\u003c/p\u003e\u003cdiv style=\"flex-wrap:wrap;max-width:800px\"\u003e\u003cdiv style=\"padding:30px;border-radius:5px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;background-color:rgb(246, 244, 248);position:relative;overflow:hidden;flex-grow:1\"\u003e\u003ch3 style=\"margin:0px;color:rgb(30, 41, 59)\"\u003eAPI Reference\u003c/h3\u003e\u003cdiv\u003eSQL over the cloud using REST\u003c/div\u003e\u003ca href=\"../../../docs/api-reference\" class=\"button\"\u003eLearn More\u003c/a\u003e \u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/icons/world-wide-web.png\" style=\"position:absolute;bottom:-100px;right:-50px;opacity:0.2\" width=\"250\" height=\"250\" /\u003e\u003c/div\u003e\u003c/div\u003e\u003cp\u003eDatasquirel's API reference uses our NPM module \u003ca href=\"https://www.npmjs.com/package/datasquirel\"\u003edatasquirel\u003c/a\u003e. This can be installed via npm:\u003c/p\u003e\u003cpre class=\"language-markup\"\u003enpm install datasquirel\u003c/pre\u003e\u003cp\u003eLearn more by reading the \u003ca href=\"docs/api-reference\"\u003eapi documentation\u003c/a\u003e\u003c/p\u003e\u003ch2\u003e\u003cbr /\u003e\u003c/h2\u003e\u003ch2\u003eKey Concepts\u003c/h2\u003e\u003ch3\u003eSQL\u003c/h3\u003e\u003cp\u003eSQL stands for \"Sequential Query language\". This is the standard language for relational databases like MySQL and Postgres. Datasquirel uses MySQL and is compatible with all known SQL syntax.\u003c/p\u003e\u003ch3\u003eDatabase\u003c/h3\u003e\u003cp\u003eA database in datasquirel is an isolated MySQL database running on our MySQL servers. A database consists of tables, which in turn consists of columns, rows, and entries. Each database can be exported at anytime, and also populated using a .sql dump file at any time.\u003c/p\u003e\u003ch3\u003eCRUD\u003c/h3\u003e\u003cp\u003eCRUD stands for \u003cstrong\u003eCreate, Read, Update, Delete\u003c/strong\u003e. This is the basic spectrum of the capabilities of any database, and it is useful for managing data.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]","query":{"page":"getting-started"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/getting-started.json b/dsql-app/.local_dist/server/pages/docs/getting-started.json new file mode 100644 index 0000000..dd4fcf3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/getting-started.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Getting Started","slug":"getting-started","description":"<p>Introduction to datasquirel. Read the <a href=\"../../../docs/quick-start\">quick-start guide</a> to get started with a new account.</p>","content":"<h2>Overview<a href=\"https://vitejs.dev/guide/#overview\">​</a></h2><p>Datasquirel is an SQL-based data management system that aims to manage SQL databases with the lowest level of opinionation. Datasquirel consists of 2 main parts:</p><ol><li>A full-fledged SQL server that runs multiple isolated databases for different users, interfacing with an online Graphical user interface and a REST API integration.</li><li>An all-purpose static files server using NGINX to serve static files on demand. Files uploaded to datasquirel static file server are public by default, but the can be made private, in which case they can only be accessed via secure encrypted credentials.</li></ol><div style=\"flex-wrap:wrap;max-width:800px\"><div style=\"padding:30px;border-radius:5px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;background-color:rgb(246, 244, 248);position:relative;overflow:hidden;flex-grow:1\"><h3 style=\"margin:0px;color:rgb(30, 41, 59)\">GUI Reference</h3><div>SQL through your bowser</div><a href=\"../../../docs/gui-reference\" class=\"button\">Learn More</a> <img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/icons/ui-design.png\" style=\"position:absolute;bottom:-100px;right:-50px;opacity:0.2\" width=\"250\" height=\"250\" /></div></div><p>Datasquirel's Graphical User Interface aims to narrow down the the complexities of SQL to a simple user interface with columns, rows, and entries.</p><div style=\"flex-wrap:wrap;max-width:800px\"><div style=\"padding:30px;border-radius:5px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;background-color:rgb(246, 244, 248);position:relative;overflow:hidden;flex-grow:1\"><h3 style=\"margin:0px;color:rgb(30, 41, 59)\">API Reference</h3><div>SQL over the cloud using REST</div><a href=\"../../../docs/api-reference\" class=\"button\">Learn More</a> <img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/icons/world-wide-web.png\" style=\"position:absolute;bottom:-100px;right:-50px;opacity:0.2\" width=\"250\" height=\"250\" /></div></div><p>Datasquirel's API reference uses our NPM module <a href=\"https://www.npmjs.com/package/datasquirel\">datasquirel</a>. This can be installed via npm:</p><pre class=\"language-markup\">npm install datasquirel</pre><p>Learn more by reading the <a href=\"docs/api-reference\">api documentation</a></p><h2><br /></h2><h2>Key Concepts</h2><h3>SQL</h3><p>SQL stands for \"Sequential Query language\". This is the standard language for relational databases like MySQL and Postgres. Datasquirel uses MySQL and is compatible with all known SQL syntax.</p><h3>Database</h3><p>A database in datasquirel is an isolated MySQL database running on our MySQL servers. A database consists of tables, which in turn consists of columns, rows, and entries. Each database can be exported at anytime, and also populated using a .sql dump file at any time.</p><h3>CRUD</h3><p>CRUD stands for <strong>Create, Read, Update, Delete</strong>. This is the basic spectrum of the capabilities of any database, and it is useful for managing data.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference.html b/dsql-app/.local_dist/server/pages/docs/gui-reference.html new file mode 100644 index 0000000..7ea080b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D-3602862f9a9542f8.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"GUI Reference","slug":"gui-reference","description":"\u003cp\u003eDatasquirel Graphic User Interface provides a way to manage database instances from your browser\u003c/p\u003e","content":"\u003cp\u003eA lot can be done using our web interface. Everyhing going on you admin dashboard is essentially running SQL queries on your isolated database, and saving and retrieving static files. Our integrated SQL shell for each database takes this concept to the next level. Giving you the ability to run SQL queries directly via your browser. To get started using our GUI, follow these steps:\u003c/p\u003e\u003ch3\u003e1. Create Account\u003c/h3\u003e\u003cp\u003eCreate a free account \u003ca href=\"../../../create-account\"\u003ehere\u003c/a\u003e\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"700\" height=\"506\" /\u003e\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch3\u003e2. Create Database\u003c/h3\u003e\u003cp\u003eNavigate to your \u003ca href=\"../../../admin\"\u003eDashboard\u003c/a\u003e or \u003ca href=\"../../../admin/databases\"\u003eDatabases page\u003c/a\u003e. Click the \"Add Database\" button to add a new database.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"700\" height=\"371\" /\u003e\u003c/p\u003e\u003cp\u003eOn the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003cp\u003eCreating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003ch3\u003e3. Add a table\u003c/h3\u003e\u003cp\u003eDatabases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"700\" height=\"697\" /\u003e\u003c/p\u003e\u003cp\u003eOn each table form you have access to the table fields(or column titles). Each field contains a few options:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eField Name\u003c/strong\u003e: Name of field(or column title)\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eData Type\u003c/strong\u003e: type of data to be stored on that field: \u003ca class=\"inline\" href=\"docs/db-reference/data-types\"\u003eSee All Datatypes\u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eRequired\u003c/strong\u003e: Choose whether the field must have a value or not\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eDefault Value\u003c/strong\u003e: Default value of field in the case no value is entered.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eMore:\u003c/strong\u003e The \"More\" button contains options for encryption and foreign keys\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eAfter these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003cp\u003eAfter creating a table you now have access to the tables list.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch3\u003e4. Add an Entry\u003c/h3\u003e\u003cp\u003eSelect the newly created Table and on the designated table page click on \"Add New Table Entry\"\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"700\" height=\"504\" /\u003e\u003c/p\u003e\u003cp\u003eFill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"700\" height=\"554\" /\u003e\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]","query":{"page":"gui-reference"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference.json b/dsql-app/.local_dist/server/pages/docs/gui-reference.json new file mode 100644 index 0000000..39462e3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"GUI Reference","slug":"gui-reference","description":"<p>Datasquirel Graphic User Interface provides a way to manage database instances from your browser</p>","content":"<p>A lot can be done using our web interface. Everyhing going on you admin dashboard is essentially running SQL queries on your isolated database, and saving and retrieving static files. Our integrated SQL shell for each database takes this concept to the next level. Giving you the ability to run SQL queries directly via your browser. To get started using our GUI, follow these steps:</p><h3>1. Create Account</h3><p>Create a free account <a href=\"../../../create-account\">here</a></p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"700\" height=\"506\" /></p><p><br /></p><h3>2. Create Database</h3><p>Navigate to your <a href=\"../../../admin\">Dashboard</a> or <a href=\"../../../admin/databases\">Databases page</a>. Click the \"Add Database\" button to add a new database.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"700\" height=\"371\" /></p><p>On the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"700\" height=\"327\" /></p><p>Creating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"700\" height=\"327\" /></p><h3>3. Add a table</h3><p>Databases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"700\" height=\"697\" /></p><p>On each table form you have access to the table fields(or column titles). Each field contains a few options:</p><ul><li><strong>Field Name</strong>: Name of field(or column title)</li><li><strong>Data Type</strong>: type of data to be stored on that field: <a class=\"inline\" href=\"docs/db-reference/data-types\">See All Datatypes</a></li><li><strong>Required</strong>: Choose whether the field must have a value or not</li><li><strong>Default Value</strong>: Default value of field in the case no value is entered.</li><li><strong>More:</strong> The \"More\" button contains options for encryption and foreign keys</li></ul><p>After these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"700\" height=\"327\" /></p><p>After creating a table you now have access to the tables list.</p><p><br /></p><h3>4. Add an Entry</h3><p>Select the newly created Table and on the designated table page click on \"Add New Table Entry\"</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"700\" height=\"504\" /></p><p>Fill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"700\" height=\"554\" /></p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.html b/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.html new file mode 100644 index 0000000..7f662de --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Getting Started","slug":"getting-started","description":"\u003cp\u003eGet started creating databases and making entries.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eDatasquirel GUI is focused on the process of creating databases, defining and adding tables, and adding entries to these tables. We will go through these steps here.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003e1. Create Account\u003c/h2\u003e\u003cp\u003eCreate a free account \u003ca href=\"../../../create-account\"\u003ehere\u003c/a\u003e\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"700\" height=\"506\" /\u003e\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003e2. Create Database\u003c/h2\u003e\u003cp\u003eNavigate to your \u003ca href=\"../../../admin\"\u003eDashboard\u003c/a\u003e or \u003ca href=\"../../../admin/databases\"\u003eDatabases page\u003c/a\u003e. Click the \"Add Database\" button to add a new database.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"700\" height=\"371\" /\u003e\u003c/p\u003e\u003cp\u003eOn the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003cp\u003eCreating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003ch2\u003e3. Add a table\u003c/h2\u003e\u003cp\u003eDatabases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"700\" height=\"697\" /\u003e\u003c/p\u003e\u003cp\u003eOn each table form you have access to the table fields(or column titles). Each field contains a few options:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eField Name\u003c/strong\u003e: Name of field(or column title)\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eData Type\u003c/strong\u003e: type of data to be stored on that field: \u003ca class=\"inline\" href=\"docs/db-reference/data-types\"\u003eSee All Datatypes\u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eRequired\u003c/strong\u003e: Choose whether the field must have a value or not\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eDefault Value\u003c/strong\u003e: Default value of field in the case no value is entered.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eMore:\u003c/strong\u003e The \"More\" button contains options for encryption and foreign keys\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eAfter these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"700\" height=\"327\" /\u003e\u003c/p\u003e\u003cp\u003eAfter creating a table you now have access to the tables list.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003e4. Add an Entry\u003c/h2\u003e\u003cp\u003eSelect the newly created Table and on the designated table page click on \"Add New Table Entry\"\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"700\" height=\"504\" /\u003e\u003c/p\u003e\u003cp\u003eFill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"700\" height=\"554\" /\u003e\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"gui-reference","sub-page":"getting-started"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.json b/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.json new file mode 100644 index 0000000..cf91b6f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference/getting-started.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Getting Started","slug":"getting-started","description":"<p>Get started creating databases and making entries.</p>","content":"<h2>Overview</h2><p>Datasquirel GUI is focused on the process of creating databases, defining and adding tables, and adding entries to these tables. We will go through these steps here.</p><p><br /></p><h2>1. Create Account</h2><p>Create a free account <a href=\"../../../create-account\">here</a></p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"700\" height=\"506\" /></p><p><br /></p><h2>2. Create Database</h2><p>Navigate to your <a href=\"../../../admin\">Dashboard</a> or <a href=\"../../../admin/databases\">Databases page</a>. Click the \"Add Database\" button to add a new database.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"700\" height=\"371\" /></p><p>On the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"700\" height=\"327\" /></p><p>Creating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"700\" height=\"327\" /></p><h2>3. Add a table</h2><p>Databases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"700\" height=\"697\" /></p><p>On each table form you have access to the table fields(or column titles). Each field contains a few options:</p><ul><li><strong>Field Name</strong>: Name of field(or column title)</li><li><strong>Data Type</strong>: type of data to be stored on that field: <a class=\"inline\" href=\"docs/db-reference/data-types\">See All Datatypes</a></li><li><strong>Required</strong>: Choose whether the field must have a value or not</li><li><strong>Default Value</strong>: Default value of field in the case no value is entered.</li><li><strong>More:</strong> The \"More\" button contains options for encryption and foreign keys</li></ul><p>After these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"700\" height=\"327\" /></p><p>After creating a table you now have access to the tables list.</p><p><br /></p><h2>4. Add an Entry</h2><p>Select the newly created Table and on the designated table page click on \"Add New Table Entry\"</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"700\" height=\"504\" /></p><p>Fill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"700\" height=\"554\" /></p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.html b/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.html new file mode 100644 index 0000000..847a1f9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D/%5Bsub-page%5D-b3641ae1942e2312.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Upload Media","slug":"upload-media","description":"\u003cp\u003eDatasquirel comes baked with an integrated static file directory. This makes it easy to upload public and private files and access it from anywhere.\u003c/p\u003e","content":"\u003ch2\u003eOverview\u003c/h2\u003e\u003cp\u003eMedia management is a bigger problem than it sounds at first. Images tend to get out of hand when adding them to web projects: your images need to be well optimized for fast loading, easily accessible, and maintain clarity so that your website doesn't look like it's from the 80's. Datasquirel does this all for you in a few clicks.\u003c/p\u003e\u003ch2\u003eAdding Media\u003c/h2\u003e\u003cp\u003eEvery datasquirel account is created with two directories for media storage: one is public, and the other is private. To start adding media, follow these steps:\u003c/p\u003e\u003ch3\u003e1. Navigate to \"\u003cstrong\u003eMedia\" \u003c/strong\u003efrom your dashboard\u003c/h3\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/media-page-with-folder.png\" width=\"800\" height=\"373\" /\u003e\u003c/p\u003e\u003cp\u003eIf you created a database already, with an image for this database, your media folder will be pre-populated with a folder named after your database (\u003ccode style=\"display:inline\"\u003etest\u003c/code\u003e  in this case), and it will contain the image you uploaded when you created the database. \u003c/p\u003e\u003ch3\u003e2. Select Media files\u003c/h3\u003e\u003cp\u003eTo add a new media, click on \u003cstrong\u003eAdd Media\u003c/strong\u003e button. This will open a modal for you to choose which type of media you want to add.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/chose-media-type-to-upload.png\" width=\"800\" height=\"373\" /\u003e\u003c/p\u003e\u003cp\u003eThere are two options available at this time: \u003cstrong\u003eImages\u003c/strong\u003e, and \u003cstrong\u003eFiles\u003c/strong\u003e. Image uploads only allow the image types listed in the description, the same applies with files. Click on the desired type and select the files you want to upload. You can upload multiple files at the same time.\u003c/p\u003e\u003ch3\u003e3. Edit selected files and upload files\u003c/h3\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/select-images-to-upload.png\" width=\"800\" height=\"373\" /\u003e\u003c/p\u003e\u003cp\u003eThe next modal gives you the option to further change attributes of the images before uploading. These attributes include the \u003cstrong\u003eimage name\u003c/strong\u003e, and \u003cstrong\u003eprivacy\u003c/strong\u003e. Private images can only be accessed via out API using your \u003cstrong\u003eRead Only \u003c/strong\u003eor \u003cstrong\u003eFull Access\u003c/strong\u003e API keys.\u003c/p\u003e\u003cp\u003eAfter you're set, click on \"Upload Media\". This process uploads selected media to their respective directories. But that's not all, each media is compressed automatically, using a max width of \u003cstrong\u003e1800px\u003c/strong\u003e, and each media comes with an automatically generated thumbnail. So For each image you upload, you have two images. The thumbnail image contains a suffix \u003ccode style=\"display:inline\"\u003e_thumbnail\u003c/code\u003e added to the original image's name.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/media-with-added-images.png\" width=\"800\" height=\"599\" /\u003e\u003c/p\u003e\u003cp\u003eAfter images have been uploaded, you can now copy the link for *public images and share anywhere, you can also copy the thumbnail link. NOTE, you cannot share private images publicly, private images don't have a public URL, they can only be accessed through OUR API with valid credentials.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eAdding Folders\u003c/h2\u003e\u003cp\u003eAdding folders help to better organize media. We currently have 2 depths of folder structure. So you can create a folder, and a sub-folder. To create a folder, simply navigate to your \u003cstrong\u003eMedia \u003c/strong\u003eadmin page and click \"\u003cstrong\u003eAdd Folder\u003c/strong\u003e\".\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-folder-screen.png\" width=\"800\" height=\"376\" /\u003e\u003c/p\u003e\u003cp\u003eAdd a folder name and click \"\u003cstrong\u003eAdd New Folder\u003c/strong\u003e\". Your new folder is now ready to go. Click on the new folder and you can upload images and files to that folder.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]/[sub-page]","query":{"page":"gui-reference","sub-page":"upload-media"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.json b/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.json new file mode 100644 index 0000000..fa20385 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/gui-reference/upload-media.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Upload Media","slug":"upload-media","description":"<p>Datasquirel comes baked with an integrated static file directory. This makes it easy to upload public and private files and access it from anywhere.</p>","content":"<h2>Overview</h2><p>Media management is a bigger problem than it sounds at first. Images tend to get out of hand when adding them to web projects: your images need to be well optimized for fast loading, easily accessible, and maintain clarity so that your website doesn't look like it's from the 80's. Datasquirel does this all for you in a few clicks.</p><h2>Adding Media</h2><p>Every datasquirel account is created with two directories for media storage: one is public, and the other is private. To start adding media, follow these steps:</p><h3>1. Navigate to \"<strong>Media\" </strong>from your dashboard</h3><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/media-page-with-folder.png\" width=\"800\" height=\"373\" /></p><p>If you created a database already, with an image for this database, your media folder will be pre-populated with a folder named after your database (<code style=\"display:inline\">test</code>  in this case), and it will contain the image you uploaded when you created the database. </p><h3>2. Select Media files</h3><p>To add a new media, click on <strong>Add Media</strong> button. This will open a modal for you to choose which type of media you want to add.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/chose-media-type-to-upload.png\" width=\"800\" height=\"373\" /></p><p>There are two options available at this time: <strong>Images</strong>, and <strong>Files</strong>. Image uploads only allow the image types listed in the description, the same applies with files. Click on the desired type and select the files you want to upload. You can upload multiple files at the same time.</p><h3>3. Edit selected files and upload files</h3><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/select-images-to-upload.png\" width=\"800\" height=\"373\" /></p><p>The next modal gives you the option to further change attributes of the images before uploading. These attributes include the <strong>image name</strong>, and <strong>privacy</strong>. Private images can only be accessed via out API using your <strong>Read Only </strong>or <strong>Full Access</strong> API keys.</p><p>After you're set, click on \"Upload Media\". This process uploads selected media to their respective directories. But that's not all, each media is compressed automatically, using a max width of <strong>1800px</strong>, and each media comes with an automatically generated thumbnail. So For each image you upload, you have two images. The thumbnail image contains a suffix <code style=\"display:inline\">_thumbnail</code> added to the original image's name.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/media-with-added-images.png\" width=\"800\" height=\"599\" /></p><p>After images have been uploaded, you can now copy the link for *public images and share anywhere, you can also copy the thumbnail link. NOTE, you cannot share private images publicly, private images don't have a public URL, they can only be accessed through OUR API with valid credentials.</p><p><br /></p><h2>Adding Folders</h2><p>Adding folders help to better organize media. We currently have 2 depths of folder structure. So you can create a folder, and a sub-folder. To create a folder, simply navigate to your <strong>Media </strong>admin page and click \"<strong>Add Folder</strong>\".</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-folder-screen.png\" width=\"800\" height=\"376\" /></p><p>Add a folder name and click \"<strong>Add New Folder</strong>\". Your new folder is now ready to go. Click on the new folder and you can upload images and files to that folder.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/quick-start.html b/dsql-app/.local_dist/server/pages/docs/quick-start.html new file mode 100644 index 0000000..1ff5ca5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/quick-start.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/docs/%5Bpage%5D-3602862f9a9542f8.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Quick Start","slug":"quick-start","description":"\u003cp\u003eStart saving and retrieving data now. Set up and start deploying in minutes.\u003c/p\u003e","content":"\u003ch2\u003eStarting up your Datasquirel instance\u003c/h2\u003e\u003cp\u003eTo get started with datasquirel you need an account online. The datasquirel npm module will hit this account via out API integration using your API credentials. Without an account, you cannout query any data on our API. Follow these steps to create an account:\u003c/p\u003e\u003ch3\u003e1. Create Account\u003c/h3\u003e\u003cp\u003eCreate a free account \u003ca href=\"https://datasquirel.com/create-account\"\u003ehere\u003c/a\u003e\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"800\" height=\"578\" /\u003e\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch3\u003e2. Create Database\u003c/h3\u003e\u003cp\u003eNavigate to your \u003ca href=\"https://datasquirel.com/admin\"\u003eDashboard\u003c/a\u003e or \u003ca href=\"https://datasquirel.com/admin/databases\"\u003eDatabases page\u003c/a\u003e. Click the \"Add Database\" button to add a new database.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"800\" height=\"424\" /\u003e\u003c/p\u003e\u003cp\u003eOn the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"800\" height=\"374\" /\u003e\u003c/p\u003e\u003cp\u003eCreating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"800\" height=\"374\" /\u003e\u003c/p\u003e\u003ch3\u003e3. Add a table\u003c/h3\u003e\u003cp\u003eDatabases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"800\" height=\"797\" /\u003e\u003c/p\u003e\u003cp\u003eOn each table form you have access to the table fields(or column titles). Each field contains a few options:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eField Name\u003c/strong\u003e: Name of field(or column title)\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eData Type\u003c/strong\u003e: type of data to be stored on that field: \u003ca class=\"inline\" href=\"docs/db-reference/data-types\"\u003eSee All Datatypes\u003c/a\u003e\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eRequired\u003c/strong\u003e: Choose whether the field must have a value or not\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eDefault Value\u003c/strong\u003e: Default value of field in the case no value is entered.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eMore:\u003c/strong\u003e The \"More\" button contains options for encryption and foreign keys\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eAfter these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"800\" height=\"374\" /\u003e\u003c/p\u003e\u003cp\u003eAfter creating a table you now have access to the tables list.\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch3\u003e4. Add an Entry\u003c/h3\u003e\u003cp\u003eSelect the newly created Table and on the designated table page click on \"Add New Table Entry\"\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"800\" height=\"576\" /\u003e\u003c/p\u003e\u003cp\u003eFill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.\u003c/p\u003e\u003cp\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"800\" height=\"633\" /\u003e\u003c/p\u003e\u003cp\u003e\u003cbr /\u003e\u003c/p\u003e\u003ch2\u003eFetching Data\u003c/h2\u003e\u003cp\u003eto start fetching data from your datasquirel account, you need to go through 3 steps:\u003c/p\u003e\u003ch3\u003e1. Create an API key\u003c/h3\u003e\u003cp\u003eYour api key is your gateway to all your data. There are two sets of API keys available for use: \u003cstrong\u003eRead Only \u003c/strong\u003eAPI keys, and \u003cstrong\u003eFull Access \u003c/strong\u003eAPI keys. They function as their names sound: Read only API keys only read data, Full Access API keys can read, write, delete, update, and also add media to your media storage directory.\u003c/p\u003e\u003cp\u003eTo create an API key, follow these steps:\u003c/p\u003e\u003cul\u003e\u003cli\u003eLogin to your admin dashboard and navigate to \"API keys\" page\u003cbr /\u003e\u003cbr /\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/api-keys-page.png\" width=\"700\" height=\"327\" /\u003e\u003c/li\u003e\u003cli\u003eClick on \"Add API key\" and fill in the form. Give your API key a name and select which the scope you wich to cover with the key (\"Read Only\" for just reading data, \"Full Access\" for reading and writing data).\u003cbr /\u003e\u003cbr /\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-api-key-dialogue.png\" width=\"700\" height=\"327\" /\u003e\u003c/li\u003e\u003cli\u003eOnce your API key is created, copy the API key by clicking \"Copy API key\". Keep this key safe and secured.\u003cbr /\u003e\u003cbr /\u003e\u003cimg src=\"https://static.datasquirel.com/images/user-images/user-2/docs/api-keys-list.png\" width=\"700\" height=\"327\" /\u003e\u003c/li\u003e\u003c/ul\u003e\u003ch3\u003e\u003cbr /\u003e\u003c/h3\u003e\u003ch3\u003e2. Use your API key to make a request\u003c/h3\u003e\u003cp\u003eAfter creating your API key, then comes the backend section.\u003c/p\u003e\u003cul\u003e\u003cli\u003eFirst add the datasquirel package via NPM\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-markup\"\u003enpm install datasquirel\u003c/pre\u003e\u003c/li\u003e\u003cli\u003eNext import the datasquirel module into your project, choose the database you will be querying, add your API key, and then run the query.\u003cbr /\u003e\u003cbr /\u003e\u003cpre class=\"language-javascript\"\u003e\u003cspan class=\"token keyword\"\u003econst\u003c/span\u003e datasquirel \u003cspan class=\"token operator\"\u003e=\u003c/span\u003e \u003cspan class=\"token function\"\u003erequire\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token string\"\u003e\"datasquirel\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n\ndatasquirel\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003eget\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003edb\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"test\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003ekey\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e process\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003eenv\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token constant\"\u003eDATASQUIREL_READ_ONLY_KEY\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token literal-property property\"\u003equery\u003c/span\u003e\u003cspan class=\"token operator\"\u003e:\u003c/span\u003e \u003cspan class=\"token string\"\u003e\"SELECT title, slug, body FROM blog_posts\"\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e,\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003ethen\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003e\u003cspan class=\"token parameter\"\u003eresponse\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e \u003cspan class=\"token operator\"\u003e=\u0026gt;\u003c/span\u003e \u003cspan class=\"token punctuation\"\u003e{\u003c/span\u003e\n console\u003cspan class=\"token punctuation\"\u003e.\u003c/span\u003e\u003cspan class=\"token function\"\u003elog\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e(\u003c/span\u003eresponse\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\n \u003cspan class=\"token punctuation\"\u003e}\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e)\u003c/span\u003e\u003cspan class=\"token punctuation\"\u003e;\u003c/span\u003e\u003c/pre\u003e\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eRead our \u003ca href=\"../../../docs/api-reference\"\u003eAPI Reference\u003c/a\u003e for more.\u003c/p\u003e"}},"__N_SSG":true},"page":"/docs/[page]","query":{"page":"quick-start"},"buildId":"vsppBJBDbOVrlLfYIAYwv","isFallback":false,"gsp":true,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/docs/quick-start.json b/dsql-app/.local_dist/server/pages/docs/quick-start.json new file mode 100644 index 0000000..a8ed6b9 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/docs/quick-start.json @@ -0,0 +1 @@ +{"pageProps":{"user":null,"pages":[{"id":8,"title":"Getting Started","slug":"getting-started","level":1,"parent_id":null},{"id":9,"title":"Getting Started","slug":"getting-started","level":2,"parent_id":3},{"id":2,"title":"Quick Start","slug":"quick-start","level":1,"parent_id":null},{"id":3,"title":"GUI Reference","slug":"gui-reference","level":1,"parent_id":null},{"id":4,"title":"API Reference","slug":"api-reference","level":1,"parent_id":null},{"id":10,"title":"Get","slug":"get","level":2,"parent_id":4},{"id":12,"title":"Database Reference","slug":"database-reference","level":1,"parent_id":null},{"id":11,"title":"Post","slug":"post","level":2,"parent_id":4},{"id":13,"title":"Data types","slug":"data-types","level":2,"parent_id":12},{"id":14,"title":"Querying Data","slug":"querying-data","level":2,"parent_id":12},{"id":15,"title":"Upload Media","slug":"upload-media","level":2,"parent_id":3}],"targetPage":{"title":"Quick Start","slug":"quick-start","description":"<p>Start saving and retrieving data now. Set up and start deploying in minutes.</p>","content":"<h2>Starting up your Datasquirel instance</h2><p>To get started with datasquirel you need an account online. The datasquirel npm module will hit this account via out API integration using your API credentials. Without an account, you cannout query any data on our API. Follow these steps to create an account:</p><h3>1. Create Account</h3><p>Create a free account <a href=\"https://datasquirel.com/create-account\">here</a></p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/create-account.png\" width=\"800\" height=\"578\" /></p><p><br /></p><h3>2. Create Database</h3><p>Navigate to your <a href=\"https://datasquirel.com/admin\">Dashboard</a> or <a href=\"https://datasquirel.com/admin/databases\">Databases page</a>. Click the \"Add Database\" button to add a new database.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-2023-07-16-13_35_04.png\" width=\"800\" height=\"424\" /></p><p>On the next screen that appears, fill in the form and add a database image if you wish. Click on \"Create Database\" to add the new database</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-add-database-2023-07-17-11_01_28.png\" width=\"800\" height=\"374\" /></p><p>Creating a new database takes you to the database page. This page allows you to import a pre-existing database using an SQL export file, or create a new table inside the newly-formed database. More operations for your database can be found in the database dropdown on the top left, or the \"more\" dropdown on the top right.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/screencapture-localhost-7070-admin-databases-test-2023-07-17-11_09_52.png\" width=\"800\" height=\"374\" /></p><h3>3. Add a table</h3><p>Databases consists of Tables: each with fields(or columns) and entries(or rows). Select a database from your database list to access the single database pages. Click on \"Add Table\" and fill in the new table form.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-table-form.png\" width=\"800\" height=\"797\" /></p><p>On each table form you have access to the table fields(or column titles). Each field contains a few options:</p><ul><li><strong>Field Name</strong>: Name of field(or column title)</li><li><strong>Data Type</strong>: type of data to be stored on that field: <a class=\"inline\" href=\"docs/db-reference/data-types\">See All Datatypes</a></li><li><strong>Required</strong>: Choose whether the field must have a value or not</li><li><strong>Default Value</strong>: Default value of field in the case no value is entered.</li><li><strong>More:</strong> The \"More\" button contains options for encryption and foreign keys</li></ul><p>After these fields are filled, click \"Add Field\". Add as much field as you need. These fields serve as column titles for your table.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/tables-list.png\" width=\"800\" height=\"374\" /></p><p>After creating a table you now have access to the tables list.</p><p><br /></p><h3>4. Add an Entry</h3><p>Select the newly created Table and on the designated table page click on \"Add New Table Entry\"</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/table-page.png\" width=\"800\" height=\"576\" /></p><p>Fill in the required fields and click on \"Add Entry\". Congrats, you have now created your first datasquirel data entry, you can now access this data from any platform using your api key.</p><p><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-entry.png\" width=\"800\" height=\"633\" /></p><p><br /></p><h2>Fetching Data</h2><p>to start fetching data from your datasquirel account, you need to go through 3 steps:</p><h3>1. Create an API key</h3><p>Your api key is your gateway to all your data. There are two sets of API keys available for use: <strong>Read Only </strong>API keys, and <strong>Full Access </strong>API keys. They function as their names sound: Read only API keys only read data, Full Access API keys can read, write, delete, update, and also add media to your media storage directory.</p><p>To create an API key, follow these steps:</p><ul><li>Login to your admin dashboard and navigate to \"API keys\" page<br /><br /><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/api-keys-page.png\" width=\"700\" height=\"327\" /></li><li>Click on \"Add API key\" and fill in the form. Give your API key a name and select which the scope you wich to cover with the key (\"Read Only\" for just reading data, \"Full Access\" for reading and writing data).<br /><br /><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/add-api-key-dialogue.png\" width=\"700\" height=\"327\" /></li><li>Once your API key is created, copy the API key by clicking \"Copy API key\". Keep this key safe and secured.<br /><br /><img src=\"https://static.datasquirel.com/images/user-images/user-2/docs/api-keys-list.png\" width=\"700\" height=\"327\" /></li></ul><h3><br /></h3><h3>2. Use your API key to make a request</h3><p>After creating your API key, then comes the backend section.</p><ul><li>First add the datasquirel package via NPM<br /><br /><pre class=\"language-markup\">npm install datasquirel</pre></li><li>Next import the datasquirel module into your project, choose the database you will be querying, add your API key, and then run the query.<br /><br /><pre class=\"language-javascript\"><span class=\"token keyword\">const</span> datasquirel <span class=\"token operator\">=</span> <span class=\"token function\">require</span><span class=\"token punctuation\">(</span><span class=\"token string\">\"datasquirel\"</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n\ndatasquirel\n <span class=\"token punctuation\">.</span><span class=\"token function\">get</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">{</span>\n <span class=\"token literal-property property\">db</span><span class=\"token operator\">:</span> <span class=\"token string\">\"test\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">key</span><span class=\"token operator\">:</span> process<span class=\"token punctuation\">.</span>env<span class=\"token punctuation\">.</span><span class=\"token constant\">DATASQUIREL_READ_ONLY_KEY</span><span class=\"token punctuation\">,</span>\n <span class=\"token literal-property property\">query</span><span class=\"token operator\">:</span> <span class=\"token string\">\"SELECT title, slug, body FROM blog_posts\"</span><span class=\"token punctuation\">,</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span>\n <span class=\"token punctuation\">.</span><span class=\"token function\">then</span><span class=\"token punctuation\">(</span><span class=\"token punctuation\">(</span><span class=\"token parameter\">response</span><span class=\"token punctuation\">)</span> <span class=\"token operator\">=></span> <span class=\"token punctuation\">{</span>\n console<span class=\"token punctuation\">.</span><span class=\"token function\">log</span><span class=\"token punctuation\">(</span>response<span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span>\n <span class=\"token punctuation\">}</span><span class=\"token punctuation\">)</span><span class=\"token punctuation\">;</span></pre></li></ul><p>Read our <a href=\"../../../docs/api-reference\">API Reference</a> for more.</p>"}},"__N_SSG":true} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/email-verification.js b/dsql-app/.local_dist/server/pages/email-verification.js new file mode 100644 index 0000000..254c19e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/email-verification.js @@ -0,0 +1,415 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4772; +exports.ids = [4772]; +exports.modules = { + +/***/ 5004: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ VerifyEmail), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(968); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_head__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(6729); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5304); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6217); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2317); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_7__); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_8__); +// @ts-check +/** + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {import("@/package-shared/types").UserType} props.user + * @param {boolean} props.verified + */ function VerifyEmail({ user , verified }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + /** @type {[ state: any, dispatch: React.Dispatch<React.SetStateAction<any>> ]} */ // @ts-ignore + let [notification, setNotification] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ if (verified) { + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + try { + setTimeout(()=>{ + window.location.pathname = `/admin`; + }, 2000); + } catch (/** @type {any} */ error) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)("/api/admin/clientError", { + method: "post", + body: { + component: "email-verification/index-page-component/lines-72-74", + message: error.message, + user: user + } + }); + window.location.pathname = `/logout`; + } + }, []); + return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + head: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: "Verify Email Address" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: "Verify your email address" + }) + ] + }), + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("main", { + className: "flex items-center justify-center w-full p-8", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "login-block gap-2", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center gap-4", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/checkmark.svg", + alt: "check-mark", + width: 30 + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "text-xl", + children: "Email Verification Successfull!" + }) + ] + }) + }) + }) + }); + } + /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ function verifyEmail(/** @type {any} */ e) { + e.preventDefault(); + setLoading(true); + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z)("/api/sendEmailVerificationLink").then((res)=>{ + setLoading(false); + if (res.success) { + setNotification({ + msg: "Email Sent. Please check mailbox", + class: "bg-emerald-100" + }); + } + }); + } + /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + head: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: "Verify Email Address" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: "Verify your email address" + }) + ] + }), + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("main", { + className: "flex flex-col items-center p-8 justify-center w-full", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "login-block gap-2 flex-col max-w-lg", + children: [ + notification && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: notification.class + " w-full rounded py-2 px-4 flex justify-center", + children: notification.msg + }), + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + position: "absolute" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "text-2xl m-0 ", + children: "Verify Email Address" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Please click the button below to send verification link" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "w-full", + onClick: verifyEmail, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Send Verification Link" + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + className: "w-full outlined", + onClick: (e)=>{ + window.history.back(); + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Go Back" + }) + }) + ] + }) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * Declare core variables + * + * @description Declare core variables + */ let user; + let isUserVerified = false; + try { + /** + * User Authentication + * + * @description User authentication + */ user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_3___default()(req, res); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ /** @type {string | null} */ // @ts-ignore + let token = query?.token; + if (token) { + let decryptedToken = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_5___default()(token.toString()); + if (decryptedToken) { + try { + user = JSON.parse(decryptedToken); + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_7___default()({ + component: "email-verification/index-page-component/getServerSideProps/line-255", + message: error.message, + user: {} + }); + user = null; + token = null; + } + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (!user) return { + redirect: { + destination: "/logout", + permanent: false + } + }; + if (user.verification_status?.toString().match(/^[1-5]$/)) return { + redirect: { + destination: `/admin`, + permanent: false + } + }; + let existingVerification = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_8___default()(`SELECT id FROM users WHERE verification_status > 0 AND id='${user.id}'`); + if (existingVerification && existingVerification[0]) return { + redirect: { + destination: `/admin`, + permanent: false + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (user?.dateCode) { + let issueTime = user.dateCode; + if (Date.now() - parseInt(issueTime) > 1800000) { + user = null; + token = null; + } else { + await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_8___default()(`UPDATE users SET verification_status='1' WHERE id='${user.id}'`); + isUserVerified = true; + } + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (/** @type {any} */ error1) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_7___default()({ + component: "email-verification/index-page-component/getServerSideProps/main-catch-error", + message: error1.message, + user: {} + }); + return { + redirect: { + destination: "/logout", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + verified: isUserVerified + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,9360,6217,2317], () => (__webpack_exec__(5004))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/email-verification.js.nft.json b/dsql-app/.local_dist/server/pages/email-verification.js.nft.json new file mode 100644 index 0000000..328accf --- /dev/null +++ b/dsql-app/.local_dist/server/pages/email-verification.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/9360.js","../chunks/6217.js","../chunks/2317.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/index.html b/dsql-app/.local_dist/server/pages/index.html new file mode 100644 index 0000000..04bc282 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/index.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><link rel="preload" href="/_next/static/css/65efe10b506f9812.css" as="style"/><link rel="stylesheet" href="/_next/static/css/65efe10b506f9812.css" data-n-p=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/3935-eea593fa60dfd620.js" defer=""></script><script src="/_next/static/chunks/pages/index-c2ab88c2111475dd.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/index.js.nft.json b/dsql-app/.local_dist/server/pages/index.js.nft.json new file mode 100644 index 0000000..5cd59c5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/index.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/4598.js","../chunks/8095.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../node_modules/@mui/icons-material/ArticleTwoTone.js","../../../node_modules/@mui/icons-material/CloudDoneTwoTone.js","../../../node_modules/@mui/icons-material/ThumbUpAltTwoTone.js","../../../node_modules/@mui/icons-material/DynamicFormTwoTone.js","../../../node_modules/@mui/icons-material/StorageTwoTone.js","../../../node_modules/@mui/icons-material/LockOpenTwoTone.js","../../../node_modules/@mui/icons-material/BackupTableTwoTone.js","../../../node_modules/@mui/icons-material/SendToMobileTwoTone.js","../../../node_modules/@mui/icons-material/TipsAndUpdatesTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/login.js b/dsql-app/.local_dist/server/pages/login.js new file mode 100644 index 0000000..1291a9c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/login.js @@ -0,0 +1,527 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3459; +exports.ids = [3459]; +exports.modules = { + +/***/ 9168: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ Login), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: external "next/head" +var head_ = __webpack_require__(968); +var head_default = /*#__PURE__*/__webpack_require__.n(head_); +// EXTERNAL MODULE: ./functions/frontend/clearCaches.js +var clearCaches = __webpack_require__(9137); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./functions/frontend/userLogin.js +// @ts-check + + +/** + * user login form submit function + * ============================================================================== + * @param {object} params + * @param {any} params.e + * @param {React.Dispatch<React.SetStateAction<string | boolean>>} params.setAlert + * @param {React.Dispatch<React.SetStateAction<boolean>>} params.setLoading + * @param {any} params.query + */ async function userLogin({ e , setAlert , setLoading , query }) { + /** Initialize + * ============================================================================== + */ e.preventDefault(); + setLoading(true); + let email = e.target["email-or-username-input"]; + let password = e.target["password"]; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** Sanitize + * ============================================================================== + */ if (email?.value === "" && password?.value === "") { + email.classList.add("warning"); + password.classList.add("warning"); + setAlert("No Email or Password Provided"); + setLoading(false); + return; + } else if (password?.value === "") { + setAlert(false); + password.classList.add("warning"); + setAlert(true); + setLoading(false); + return; + } else { + email.classList.remove("warning"); + password.classList.remove("warning"); + setAlert(false); + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + let postBodyObject = { + email: email.value, + password: password.value, + query: query + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + (0,fetchApi/* default */.Z)("/api/loginUser", { + method: "post", + body: postBodyObject + }).then(async (res)=>{ + console.log(res); + if (res.user && res.user.auth) { + localStorage.setItem("userid", res.user.userid); + localStorage.setItem("csrf", res.user.csrf_k); + localStorage.setItem("user", JSON.stringify(res.userPayload)); + (0,clearCaches/* default */.Z)().then(()=>{ + window.location.reload(); + }); + } else { + setAlert(res.msg); + setLoading(false); + } + }); +} + +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./components/pages/login/SocialLogin.jsx + 3 modules +var SocialLogin = __webpack_require__(8374); +;// CONCATENATED MODULE: ./components/pages/login/LoginForm.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("@/package-shared/types").LoginFormContextType} */ // @ts-ignore +const init = {}; +const LoginFormContext = /*#__PURE__*/ external_react_default().createContext(init); +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {import("@/package-shared/types").UserType | null} [props.user] + * @param {any} props.query + */ function LoginForm({ user , query }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ alert: string | boolean, setAlert: React.Dispatch<React.SetStateAction<string | boolean>> ]} */ // @ts-ignore + let { 0: alert , 1: setAlert } = (0,external_react_.useState)(null); + let { 0: loading , 1: setLoading } = (0,external_react_.useState)(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)(LoginFormContext.Provider, { + value: { + loading, + setLoading, + alert, + setAlert, + user + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(SocialLogin/* default */.Z, { + user: user, + userType: "admin", + setLoading: setLoading + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-center relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "bg-white dark:bg-slate-800 px-3 relative z-10", + children: "OR" + }), + /*#__PURE__*/ jsx_runtime_.jsx("hr", { + className: "absolute" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col items-stretch gap-4", + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + alert && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "p-2 justify-center text-sm border border-solid border-orange-400 rounded bg-orange-50", + children: alert + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "flex flex-col gap-2 w-full", + onSubmit: (/** @type {any} */ e)=>{ + userLogin({ + e, + setAlert, + setLoading, + query: query + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + name: "email-or-username-input", + id: "email-or-username-input", + placeholder: "Email or username", + defaultValue: query?.email ? query.email : "", + required: true, + onInput: (e)=>{ + if (alert) setAlert(false); + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "password", + name: "password", + id: "password-input", + placeholder: "Password", + required: true, + onInput: (e)=>{ + if (alert) setAlert(false); + } + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + type: "submit", + children: "Login" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex flex-col items-center w-full mb-2", + children: /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/send-password-reset-link", + className: "text-secondary font-semibold", + children: "Forgot Password?" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex items-center gap-2 justify-center w-full mb-2 flex-wrap", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Dont have an account yet?" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/create-account", + className: "text-secondary font-semibold", + children: "Register Now" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "justify-center text-sm text-secondary", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/terms", + className: "text-secondary", + children: "Terms and Conditions" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/privacy", + className: "text-secondary", + children: "Privacy Policy" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./components/general/Logo.jsx +var Logo = __webpack_require__(4017); +// EXTERNAL MODULE: ./components/general/LoadingScreen.jsx +var LoadingScreen = __webpack_require__(6478); +;// CONCATENATED MODULE: ./pages/login.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.query + */ function Login(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const user = {}; + external_react_default().useEffect(()=>{ + setTimeout(()=>{ + if (props.query.invite && props.user) { + window.location.pathname = "/create-account"; + } + }, 1000); + if (!props.query.invite) { + localStorage.setItem("user", "{}"); + } + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + if (props.query.invite && props.user) { + return /*#__PURE__*/ jsx_runtime_.jsx(LoadingScreen/* default */.Z, {}); + } + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)((head_default()), { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: "Login to your account" + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: "Login to your account" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("main", { + className: "w-screen h-screen flex items-center justify-center p-4 md:p-8", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "card col items-center no-hover max-w-md w-full bg-white p-4 sm:p-6 overflow-auto minimal-scrollbars", + style: { + maxHeight: "calc(100vh - 40px)" + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(Logo/* default */.Z, {}), + /*#__PURE__*/ jsx_runtime_.jsx("hr", {}), + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "m-0 text-lg font-semibold", + children: "Login to your account" + }), + /*#__PURE__*/ jsx_runtime_.jsx(LoginForm, { + user: props.user, + query: props.query + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** @type {import("next").GetServerSideProps} */ async function getServerSideProps({ req , res , query }) { + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User Authentication + * + * @description User authentication + */ const user = await userAuth_default()(req, res); + if (user) { + return { + redirect: { + destination: `/admin`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + query + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 6843: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ContentCopy"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 9174: +/***/ ((module) => { + +module.exports = require("@mui/material/Snackbar"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,5264,6729,5304,9395,370,8374,6478], () => (__webpack_exec__(9168))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/login.js.nft.json b/dsql-app/.local_dist/server/pages/login.js.nft.json new file mode 100644 index 0000000..611e86f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/login.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/5264.js","../chunks/6729.js","../chunks/5304.js","../chunks/9395.js","../chunks/370.js","../chunks/8374.js","../chunks/6478.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/react-dom/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/@mui/material/Snackbar/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/react-dom/index.js","../../../node_modules/@mui/material/node/Snackbar/index.js","../../../node_modules/@mui/material/node/Paper/index.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/ContentCopy.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../node_modules/react-dom/cjs/react-dom.development.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useTheme.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../node_modules/@mui/material/node/Paper/Paper.js","../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/Grow/index.js","../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/base/node/index.js","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/Grow/Grow.js","../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/scheduler/package.json","../../../node_modules/scheduler/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/@mui/base/useSnackbar/package.json","../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../node_modules/scheduler/cjs/scheduler.development.js","../../../node_modules/@mui/material/node/transitions/utils.js","../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../node_modules/@mui/base/node/NoSsr/index.js","../../../node_modules/@mui/base/node/Portal/index.js","../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/base/node/utils/index.js","../../../node_modules/@mui/base/node/Badge/index.js","../../../node_modules/@mui/base/node/Button/index.js","../../../node_modules/@mui/base/node/Dropdown/index.js","../../../node_modules/@mui/base/node/FormControl/index.js","../../../node_modules/@mui/base/node/Input/index.js","../../../node_modules/@mui/base/node/Menu/index.js","../../../node_modules/@mui/base/node/MenuButton/index.js","../../../node_modules/@mui/base/node/MenuItem/index.js","../../../node_modules/@mui/base/node/Modal/index.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../node_modules/@mui/base/node/Option/index.js","../../../node_modules/@mui/base/node/Popper/index.js","../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../node_modules/@mui/base/node/Select/index.js","../../../node_modules/@mui/base/node/Slider/index.js","../../../node_modules/@mui/base/node/Snackbar/index.js","../../../node_modules/@mui/base/node/Switch/index.js","../../../node_modules/@mui/base/node/TablePagination/index.js","../../../node_modules/@mui/base/node/TabPanel/index.js","../../../node_modules/@mui/base/node/TabsList/index.js","../../../node_modules/@mui/base/node/Tabs/index.js","../../../node_modules/@mui/base/node/Tab/index.js","../../../node_modules/@mui/base/node/Transitions/index.js","../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../node_modules/@mui/base/node/useBadge/index.js","../../../node_modules/@mui/base/node/useButton/index.js","../../../node_modules/@mui/base/node/useDropdown/index.js","../../../node_modules/@mui/base/node/useInput/index.js","../../../node_modules/@mui/base/node/useMenu/index.js","../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../node_modules/@mui/base/node/useOption/index.js","../../../node_modules/@mui/base/node/useSelect/index.js","../../../node_modules/@mui/base/node/useSlider/index.js","../../../node_modules/@mui/base/node/useSwitch/index.js","../../../node_modules/@mui/base/node/useTab/index.js","../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../node_modules/@mui/base/node/useTabs/index.js","../../../node_modules/@mui/base/node/useTabsList/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/react-transition-group/package.json","../../../node_modules/react-transition-group/cjs/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../node_modules/@mui/base/node/Portal/Portal.js","../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../node_modules/@mui/base/node/utils/types.js","../../../node_modules/@mui/base/node/Badge/Badge.js","../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../node_modules/@mui/base/node/Button/Button.js","../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../node_modules/@mui/base/node/Button/Button.types.js","../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../node_modules/@mui/base/node/Input/Input.js","../../../node_modules/@mui/base/node/Input/Input.types.js","../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../node_modules/@mui/base/node/Menu/Menu.js","../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../node_modules/@mui/base/node/Modal/Modal.js","../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../node_modules/@mui/base/node/Option/Option.js","../../../node_modules/@mui/base/node/Option/Option.types.js","../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../node_modules/@mui/base/node/Popper/Popper.js","../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../node_modules/@mui/base/node/Select/Select.js","../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../node_modules/@mui/base/node/Select/Select.types.js","../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../node_modules/@mui/base/node/Slider/Slider.js","../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../node_modules/@mui/base/node/Switch/Switch.js","../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../node_modules/@mui/base/node/Tab/Tab.js","../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../node_modules/@mui/base/node/useButton/useButton.js","../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../node_modules/@mui/base/node/useInput/useInput.js","../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../node_modules/@mui/base/node/useOption/useOption.js","../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../node_modules/@mui/base/node/useTab/useTab.js","../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../node_modules/react-transition-group/cjs/Transition.js","../../../node_modules/react-transition-group/cjs/config.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../node_modules/@mui/base/node/useList/ListContext.js","../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../node_modules/@mui/base/node/useList/index.js","../../../node_modules/@mui/base/node/useTransition/index.js","../../../node_modules/@mui/base/node/useCompound/index.js","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/@floating-ui/react-dom/package.json","../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../node_modules/@popperjs/core/package.json","../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@mui/base/node/useList/useList.js","../../../node_modules/@mui/base/node/useList/useList.types.js","../../../node_modules/@mui/base/node/useList/useListItem.js","../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../node_modules/@mui/base/node/useList/listReducer.js","../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/dom-helpers/addClass/package.json","../../../node_modules/dom-helpers/cjs/addClass.js","../../../node_modules/dom-helpers/removeClass/package.json","../../../node_modules/dom-helpers/cjs/removeClass.js","../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/dom-helpers/package.json","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/dom-helpers/cjs/hasClass.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@floating-ui/dom/package.json","../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/@floating-ui/core/package.json","../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/logout.js b/dsql-app/.local_dist/server/pages/logout.js new file mode 100644 index 0000000..012d6f3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/logout.js @@ -0,0 +1,352 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 765; +exports.ids = [765]; +exports.modules = { + +/***/ 9137: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ clearCaches) +/* harmony export */ }); +// @ts-check +/** + * Clear Caches function + * ============================================================================== + */ async function clearCaches() { + try { + /** Initialize + * ============================================================================== + */ /** ********************* Variables */ const keys = await caches.keys(); + if (keys[0]) { + await Promise.all(keys.map((key)=>{ + return caches.delete(key); + })); + } + } catch (/** @type {any} */ error) { + console.log("Error in clearing cache =>", error.message); + } +} + + +/***/ }), + +/***/ 1780: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Login), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(968); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_head__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6729); +/* harmony import */ var _functions_frontend_clearCaches__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9137); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5264); +/** + * Imports + * ============================================================================== + */ + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +const userAuth = __webpack_require__(370); + + + +/** + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - React component props including { children } + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.query + */ function Login({ user , query }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + // ## Head Items + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: "Loging Out | Datasquirel" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: "Login you out" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "https://accounts.google.com/gsi/client" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("script", { + src: "https://connect.facebook.net/en_US/sdk.js", + crossOrigin: "anonymous" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + localStorage.setItem("user", "{}"); + localStorage.removeItem("csrf"); + // window.location.pathname = "/" + }, []); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + function redirect() { + if (query?.invite && query?.login) { + return window.location.href = `/login` + window.location.search; + // return window.location.href = `/login?email=${query.email}`; + } + if (query?.login) { + return window.location.href = `/login`; + } + if (localStorage.getItem("logoutParadigm")?.match(/reset/)) { + return window.location.href = "/login"; + } + if (user?.social_platform?.match(/google/)) { + localStorage.setItem("google_prompt_skipped", "logout"); + } + window.location.pathname = "/"; + } + //////////////////////////////////////// + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/logoutUser").then(async (res)=>{ + await (0,_functions_frontend_clearCaches__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)(); + let regs = await navigator.serviceWorker.getRegistrations(); + for(let i = 0; i < regs.length; i++){ + const reg = regs[i]; + await reg.unregister(); + } + try { + FB.init({ + appId: "2910275882608968", + cookie: true, + xfbml: true, + version: "v13.0" + }); + FB.getLoginStatus((response)=>{ + if (response.authResponse) { + FB.logout((res)=>{ + redirect(); + }); + } else { + google.accounts.id.initialize({ + client_id: "392696781563-imb0ddojfn6m4bdokjk5v80jn546t9tq.apps.googleusercontent.com" + }); + if (user?.social_platform?.match(/google/) && user.social_id) { + google.accounts.id.revoke(); + google.accounts.id.revoke(user.social_id, (done)=>{ + console.log(done.error); + redirect(); + }); + } else { + redirect(); + } + } + }); + } catch (error) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z)("/api/admin/clientError", { + method: "post", + body: { + component: "logout-page-component/lines-111-142", + message: error.message, + user: user + } + }); + } + }); + }, []); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_head__WEBPACK_IMPORTED_MODULE_2___default()), { + children: head + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("main", { + className: "w-screen h-screen flex items-center justify-center p-4 md:p-8", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "card max-w-md flex-col items-center bg-white p-6 rounded border border-slate-200 border-solid", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("a", { + href: "/", + className: "flex items-center gap-2", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("img", { + src: "/images/logo-icon-alt-2.png", + alt: "Logo Icon", + width: 37 + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "font-bold text-2xl", + children: "Datasquirel" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h3", { + className: "text-lg m-0 mt-4 text-slate-400", + children: "Logging out" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + position: "relative", + width: "20px" + }) + ] + }) + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + // ## Environment processes + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User Authentication + * + * @description User authentication + */ const user = await userAuth(req, res); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ res.setHeader("Set-Cookie", [ + "datasquirelAuthKey=none;max-age=0", + "usertype=none;max-age=0", + `refresh_properties=1;Max-Age=7000`, + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + logged_out: true, + query + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [5264,6729,5304,9395,370], () => (__webpack_exec__(1780))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/logout.js.nft.json b/dsql-app/.local_dist/server/pages/logout.js.nft.json new file mode 100644 index 0000000..f3a8188 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/logout.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/5264.js","../chunks/6729.js","../chunks/5304.js","../chunks/9395.js","../chunks/370.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/pricing.html b/dsql-app/.local_dist/server/pages/pricing.html new file mode 100644 index 0000000..d07507c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/pricing.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="next-head-count" content="2"/><meta name="author" content="Datasquirel"/><meta name="Copyright" content="Copyright (c) 2024 Datasquirel"/><meta name="robots" content="noindex,nofollow"/><link rel="preconnect" crossorigin="anonymous" data-href="https://fonts.googleapis.com/"/><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="anonymous"/><script src="/scripts/themeSelector.js"></script><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/><meta property="og:site_name" content="DATASQUIREL"/><meta property="og:type" content="website"/><meta name="twitter:card" content="summary"/><meta property="og:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta itemProp="image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><meta name="twitter:image" content="https://static.datasquirel.com/images/user-images/user-2/email-banner.jpeg"/><link rel="stylesheet" href="/styles/prism.css"/><script src="/scripts/prism.js" async=""></script><script>var DSQL = {}</script><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /><link rel="preload" href="/_next/static/css/c83c1473ba7928cd.css" as="style"/><link rel="stylesheet" href="/_next/static/css/c83c1473ba7928cd.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-309fbebe2073f18c.js" defer=""></script><script src="/_next/static/chunks/framework-4ed89e9640adfb9e.js" defer=""></script><script src="/_next/static/chunks/main-fd9fe2eccf11c307.js" defer=""></script><script src="/_next/static/chunks/pages/_app-881c4f419bb13dab.js" defer=""></script><script src="/_next/static/chunks/pages/pricing-e193043fd895ccd5.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_buildManifest.js" defer=""></script><script src="/_next/static/vsppBJBDbOVrlLfYIAYwv/_ssgManifest.js" defer=""></script><style data-href="https://fonts.googleapis.com/css?family=Poppins">@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfedA.woff) format('woff')}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJnecnFHGPezSQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Poppins';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/poppins/v21/pxiEyp8kv8JHgFVrJJfecnFHGPc.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=Inter">@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjg.woff) format('woff')}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZJhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZthjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZNhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+1F00-1FFF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZxhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZBhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZFhjp-Ek-_EeAmM.woff) format('woff');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'Inter';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfAZ9hjp-Ek-_EeA.woff) format('woff');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style><style data-href="https://fonts.googleapis.com/css?family=IBM+Plex+Mono">@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q0Q.woff) format('woff')}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iIq131nj-otFQ.woff2) format('woff2');unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1isq131nj-otFQ.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iAq131nj-otFQ.woff2) format('woff2');unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1iEq131nj-otFQ.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:'IBM Plex Mono';font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/ibmplexmono/v19/-F63fjptAgt5VM-kVkqdyU8n1i8q131nj-o.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}</style></head><body><div id="__next"></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{}},"page":"/pricing","query":{},"buildId":"vsppBJBDbOVrlLfYIAYwv","nextExport":true,"autoExport":true,"isFallback":false,"scriptLoader":[]}</script></body></html> \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/pricing.js.nft.json b/dsql-app/.local_dist/server/pages/pricing.js.nft.json new file mode 100644 index 0000000..3e76c01 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/pricing.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/privacy.html b/dsql-app/.local_dist/server/pages/privacy.html new file mode 100644 index 0000000..f4498b0 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/privacy.html @@ -0,0 +1 @@ +<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><title>Privacy Policy | Datasquirel

Privacy Policy

Privacy Policy for Datasquirel
Dotted image background

At datasquirel.com, accessible from https://datasquirel.com, one of our main priorities is the privacy of our visitors. This Privacy Policy document contains types of information that is collected and recorded by datasquirel.com and how we use it.

If you have additional questions or require more information about our Privacy Policy, do not hesitate to contact us.

This Privacy Policy applies only to our online activities and is valid for visitors to our website with regards to the information that they shared and/or collect in datasquirel.com. This policy is not applicable to any information collected offline or via channels other than this website.

Consent

By using our website, you hereby consent to our Privacy Policy and agree to its terms.

Information we collect

The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information.

If you contact us directly, we may receive additional information about you such as your name, email address, phone number, the contents of the message and/or attachments you may send us, and any other information you may choose to provide.

When you register for an Account, we may ask for your contact information, including items such as name, company name, address, email address, and telephone number.

How we use your information

We use the information we collect in various ways, including to:

  • Provide, operate, and maintain our website
  • Improve, personalize, and expand our website
  • Understand and analyze how you use our website
  • Develop new products, services, features, and functionality
  • Communicate with you, either directly or through one of our partners, including for customer service, to provide you with updates and other information relating to the website, and for marketing and promotional purposes
  • Send you emails
  • Find and prevent fraud

Log Files

datasquirel.com follows a standard procedure of using log files. These files log visitors when they visit websites. All hosting companies do this and a part of hosting services' analytics. The information collected by log files include internet protocol (IP) addresses, browser type, Internet Service Provider (ISP), date and time stamp, referring/exit pages, and possibly the number of clicks. These are not linked to any information that is personally identifiable. The purpose of the information is for analyzing trends, administering the site, tracking users' movement on the website, and gathering demographic information.

Cookies and Web Beacons

Like any other website, datasquirel.com uses 'cookies'. These cookies are used to store information including visitors' preferences, and the pages on the website that the visitor accessed or visited. The information is used to optimize the users' experience by customizing our web page content based on visitors' browser type and/or other information.

Advertising Partners Privacy Policies

You may consult this list to find the Privacy Policy for each of the advertising partners of datasquirel.com.

Third-party ad servers or ad networks uses technologies like cookies, JavaScript, or Web Beacons that are used in their respective advertisements and links that appear on datasquirel.com, which are sent directly to users' browser. They automatically receive your IP address when this occurs. These technologies are used to measure the effectiveness of their advertising campaigns and/or to personalize the advertising content that you see on websites that you visit.

Note that datasquirel.com has no access to or control over these cookies that are used by third-party advertisers.

Third Party Privacy Policies

datasquirel.com's Privacy Policy does not apply to other advertisers or websites. Thus, we are advising you to consult the respective Privacy Policies of these third-party ad servers for more detailed information. It may include their practices and instructions about how to opt-out of certain options.

You can choose to disable cookies through your individual browser options. To know more detailed information about cookie management with specific web browsers, it can be found at the browsers' respective websites.

CCPA Privacy Rights (Do Not Sell My Personal Information)

Under the CCPA, among other rights, California consumers have the right to:

Request that a business that collects a consumer's personal data disclose the categories and specific pieces of personal data that a business has collected about consumers.

Request that a business delete any personal data about the consumer that a business has collected.

Request that a business that sells a consumer's personal data, not sell the consumer's personal data.

If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.

GDPR Data Protection Rights

We would like to make sure you are fully aware of all of your data protection rights. Every user is entitled to the following:

The right to access – You have the right to request copies of your personal data. We may charge you a small fee for this service.

The right to rectification – You have the right to request that we correct any information you believe is inaccurate. You also have the right to request that we complete the information you believe is incomplete.

The right to erasure – You have the right to request that we erase your personal data, under certain conditions.

The right to restrict processing – You have the right to request that we restrict the processing of your personal data, under certain conditions.

The right to object to processing – You have the right to object to our processing of your personal data, under certain conditions.

The right to data portability – You have the right to request that we transfer the data that we have collected to another organization, or directly to you, under certain conditions.

If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.

Children's Information

Another part of our priority is adding protection for children while using the internet. We encourage parents and guardians to observe, participate in, and/or monitor and guide their online activity.

datasquirel.com does not knowingly collect any Personal Identifiable Information from children under the age of 13. If you think that your child provided this kind of information on our website, we strongly encourage you to contact us immediately and we will do our best efforts to promptly remove such information from our records.

\ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/privacy.js.nft.json b/dsql-app/.local_dist/server/pages/privacy.js.nft.json new file mode 100644 index 0000000..6d6cd19 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/privacy.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/4598.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/redirect.html b/dsql-app/.local_dist/server/pages/redirect.html new file mode 100644 index 0000000..5e8ea42 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/redirect.html @@ -0,0 +1 @@ +
Datasquirel Logo
\ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/redirect.js.nft.json b/dsql-app/.local_dist/server/pages/redirect.js.nft.json new file mode 100644 index 0000000..ba6a3d6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/redirect.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/reset-password.js b/dsql-app/.local_dist/server/pages/reset-password.js new file mode 100644 index 0000000..898e313 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/reset-password.js @@ -0,0 +1,413 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8006; +exports.ids = [8006]; +exports.modules = { + +/***/ 5082: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "ResetPasswordContext": () => (/* binding */ ResetPasswordContext), +/* harmony export */ "default": () => (/* binding */ ResetPasswordPage), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6217); +/* harmony import */ var _components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4097); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5264); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6729); +/* harmony import */ var _components_general_FormSuccessBlock__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2186); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(5304); +/* harmony import */ var _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_7__); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2317); +/* harmony import */ var _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_serverError__WEBPACK_IMPORTED_MODULE_8__); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(6517); +/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_9__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + + + +/** ****************************************************************************** */ /** @type {{ user: import("@/package-shared/types").UserType | null }} */ // @ts-ignore +const init = {}; +const ResetPasswordContext = /*#__PURE__*/ react__WEBPACK_IMPORTED_MODULE_1___default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.email + * @param {import("@/package-shared/types").UserType} props.user + */ function ResetPasswordPage(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ const { email } = props; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Reset Password | Datasquirel"; + const pageDescription = "Set a new password"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + const [passwordReset, setPasswordReset] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, { + head: head, + user: props.user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(ResetPasswordContext.Provider, { + value: { + user: props.user + }, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("main", { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, {}), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "main-container flex-col items-start", + children: passwordReset ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_FormSuccessBlock__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, { + message: "Password Updated Sucessfully. Redirecting you ..." + }) : /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "m-0 text-4xl", + children: "Reset Password" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + children: "Please enter new passord and confirm it" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + className: "max-w-xl w-full flex flex-col items-stretch gap-4", + onSubmit: (e)=>{ + setLoading(true); + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + const password = formEl["password"].value; + const passwordConfirmationFailed = formEl["confirm-password"].classList.contains("warning"); + if (password?.length < 8) { + window.alert("Password must be at least 8 characters"); + setTimeout(()=>{ + setLoading(false); + }, 500); + return; + } + if (passwordConfirmationFailed) { + window.alert("Passwords don't match"); + setTimeout(()=>{ + setLoading(false); + }, 500); + return; + } + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)(`/api/resetPassword?email=${email}&password=${password}`).then((res)=>{ + setTimeout(()=>{ + setLoading(false); + }, 500); + setTimeout(()=>{ + window.location.href = `/logout?login=true`; + }, 1000); + if (res.success) { + setPasswordReset(true); + } + }); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "password", + id: "password", + className: "w-full", + placeholder: "New Password", + required: true + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "confirm-password", + id: "confirm-password", + className: "w-full", + placeholder: "Confirm New Password", + required: true, + onInput: (e)=>{ + let match = false; + /** @type {HTMLInputElement} */ // @ts-ignore + const inputEl = e.target; + /** @type {HTMLFormElement} */ // @ts-ignore + const form = inputEl.closest("form"); + try { + const password = form["password"].value; + if (password.match(new RegExp(`^${lodash__WEBPACK_IMPORTED_MODULE_9___default().escapeRegExp(inputEl.value)}$`))) { + inputEl.classList.remove("warning"); + match = true; + } else { + inputEl.classList.add("warning"); + } + } catch (/** @type {any} */ error) { + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z)("/api/admin/clientError", { + method: "post", + body: { + component: "reset-password-page-component/lines-170-177", + message: error.message, + user: {} + } + }); + // @ts-ignore + e.target.classList.add("warning"); + } + } + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + children: "Reset Password" + }) + ] + }) + ] + }) + }) + ] + }) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_5___default()(req, res); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User Auth + * + * @description User Auth + */ if (!query?.token?.toString()?.match(/./)) { + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + let email = null; + try { + const decryptedPayload = _package_shared_functions_backend_decrypt__WEBPACK_IMPORTED_MODULE_7___default()(query.token.toString()); + const payloadObject = JSON.parse(decryptedPayload || ""); + const hourInMilliseconds = 1000 * 60 * 60; + if (Date.now() - payloadObject.dateCode > hourInMilliseconds) { + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + email = payloadObject.email; + } catch (/** @type {any} */ error) { + _functions_backend_serverError__WEBPACK_IMPORTED_MODULE_8___default()({ + component: "reset-password-page-component/getServersideProps/lines-251-260", + message: error.message, + user: user + }); + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + if (!email?.match(/./)) { + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + email: email + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 6517: +/***/ ((module) => { + +module.exports = require("lodash"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,9360,6217,4097,2317,2186], () => (__webpack_exec__(5082))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/reset-password.js.nft.json b/dsql-app/.local_dist/server/pages/reset-password.js.nft.json new file mode 100644 index 0000000..b1dbb89 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/reset-password.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/2317.js","../chunks/2186.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lodash/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lodash/lodash.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/send-password-reset-link.js b/dsql-app/.local_dist/server/pages/send-password-reset-link.js new file mode 100644 index 0000000..f607a63 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/send-password-reset-link.js @@ -0,0 +1,355 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3851; +exports.ids = [3851]; +exports.modules = { + +/***/ 1725: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "SendPassResetContext": () => (/* binding */ SendPassResetContext), + "default": () => (/* binding */ SendPasswordResetLinkPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./layouts/GeneralLayout.jsx + 1 modules +var GeneralLayout = __webpack_require__(6217); +// EXTERNAL MODULE: ./components/general/PageHeadTags.jsx +var PageHeadTags = __webpack_require__(4097); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/backend/userAuth.js +var userAuth = __webpack_require__(370); +var userAuth_default = /*#__PURE__*/__webpack_require__.n(userAuth); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/FormSuccessBlock.jsx +var FormSuccessBlock = __webpack_require__(2186); +;// CONCATENATED MODULE: external "@mui/icons-material/InfoTwoTone" +const InfoTwoTone_namespaceObject = require("@mui/icons-material/InfoTwoTone"); +var InfoTwoTone_default = /*#__PURE__*/__webpack_require__.n(InfoTwoTone_namespaceObject); +;// CONCATENATED MODULE: ./components/general/InfoBlock.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.message + */ function InfoBlock({ message }) { + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "info gray", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((InfoTwoTone_default()), { + fontSize: "small", + color: "inherit", + className: "opacity-50 text-gray-600" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "font-normal", + children: message + }) + ] + }); +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./pages/send-password-reset-link.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + + + + + + +/** ****************************************************************************** */ /** @type {{ user: import("@/package-shared/types").UserType | null }} */ // @ts-ignore +const init = {}; +const SendPassResetContext = /*#__PURE__*/ external_react_default().createContext(init); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + */ function SendPasswordResetLinkPage(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Cloudbased SQL data management system | Datasquirel"; + const pageDescription = "Datasquirel is a fast and efficient cloud-based SQL data management system that takes away the entire hassle of dealing with data both locally and across different platforms."; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ jsx_runtime_.jsx(PageHeadTags/* default */.Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [emailSent, setEmailSent] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(GeneralLayout/* default */.Z, { + head: head, + user: props.user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SendPassResetContext.Provider, { + value: { + user: props.user + }, + children: /*#__PURE__*/ jsx_runtime_.jsx("main", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + emailSent ? /*#__PURE__*/ jsx_runtime_.jsx(FormSuccessBlock/* default */.Z, { + message: "Email Sent. Please check your email address and follow the link provided", + className: "whitespace-nowrap" + }) : /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "paper", + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "max-w-xl flex-col items-stretch", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h1", { + className: "m-0 text-4xl", + children: "Send Password Reset Link" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Please enter your email address to receive a password reset link" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "w-full flex flex-col items-stretch gap-4", + onSubmit: (e)=>{ + setLoading(true); + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + const email = formEl["email-address"].value; + (0,fetchApi/* default */.Z)(`/api/sendPasswordResetLink?email=${email}`).then((res)=>{ + console.log(res); + setTimeout(()=>{ + setLoading(false); + }, 500); + if (res.success) { + setEmailSent(true); + } + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: "text", + autoComplete: "email", + name: "email-address", + id: "email-address", + className: "w-full", + placeholder: "Email Address", + defaultValue: props?.user?.logged_in_status ? props.user.email : "", + required: true + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + children: "Send password reset Email" + }), + /*#__PURE__*/ jsx_runtime_.jsx(InfoBlock, { + message: "Please note that this link will expire after 1 hour" + }) + ] + }) + ] + }) + }) + ] + }) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res }) { + /** + * User Auth + * + * @description User Auth + */ const user = await userAuth_default()(req, res); + if (user?.social_login) { + return { + redirect: { + destination: "/", + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,9360,6217,4097,2186], () => (__webpack_exec__(1725))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/send-password-reset-link.js.nft.json b/dsql-app/.local_dist/server/pages/send-password-reset-link.js.nft.json new file mode 100644 index 0000000..287cad4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/send-password-reset-link.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/2186.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/InfoTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su.js b/dsql-app/.local_dist/server/pages/su.js new file mode 100644 index 0000000..8e3bd70 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su.js @@ -0,0 +1,277 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3663; +exports.ids = [3663]; +exports.modules = { + +/***/ 9011: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Dashboard), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_SuDashboardContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4187); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function Dashboard({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_SuDashboardContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM users ORDER BY id DESC`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + users + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5304,9395,1503,5313,1336,4187], () => (__webpack_exec__(9011))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su.js.nft.json b/dsql-app/.local_dist/server/pages/su.js.nft.json new file mode 100644 index 0000000..ae1f472 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5304.js","../chunks/9395.js","../chunks/1503.js","../chunks/5313.js","../chunks/1336.js","../chunks/4187.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/backups.js b/dsql-app/.local_dist/server/pages/su/backups.js new file mode 100644 index 0000000..4c85813 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/backups.js @@ -0,0 +1,402 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3159; +exports.ids = [3159]; +exports.modules = { + +/***/ 8188: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ Backups), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/su/SuErrorLogsContent.jsx +var SuErrorLogsContent = __webpack_require__(6251); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: external "@mui/icons-material/StyleTwoTone" +var StyleTwoTone_ = __webpack_require__(723); +var StyleTwoTone_default = /*#__PURE__*/__webpack_require__.n(StyleTwoTone_); +;// CONCATENATED MODULE: ./components/su/SuBackupsContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + */ function SuBackupsContent(props) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ backups: string[], setBackups: React.Dispatch> ]} */ // @ts-ignore + const [backups, setBackups] = external_react_default().useState([]); + const [refresh, setRefresh] = external_react_default().useState(0); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/grabBackups").then((res)=>{ + setBackups(res.backups); + }); + }, [ + refresh + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Backups" + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + if (window.confirm("Create new backup?")) { + setLoading(true); + (0,fetchApi/* default */.Z)("/api/admin/createNewBackup").then((res)=>{ + setRefresh((prev)=>prev + 1); + setTimeout(()=>{ + setLoading(false); + }, 2000); + }); + } + }, + className: "relative", + children: "Create New Backup" + }) + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: backups && backups[0] ? "p-0 gap-4" : "paper", + children: [ + !backups && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, {}), + backups && backups[0] && backups.sort((a, b)=>{ + if (parseInt(a) > parseInt(b)) return -1; + return 1; + }).map((backup, index)=>{ + const backupDate = new Date(parseInt(backup)); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/backups/${backup}`, + className: "card w-full items-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((StyleTwoTone_default()), { + color: "inherit", + className: "opacity-40 text-slate-500" + }), + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "Backup:" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: backupDate.toString() + }) + ] + }, backup); + }), + backups && !backups[0] && /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No Backups Yet" + }) + ] + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./pages/su/backups.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} [props.data] + */ function Backups({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Backups | Datasquirel"; + const pageDescription = "Databases backups"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuBackupsContent, {}) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 723: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StyleTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5304,1503,5313,6251], () => (__webpack_exec__(8188))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/backups.js.nft.json b/dsql-app/.local_dist/server/pages/su/backups.js.nft.json new file mode 100644 index 0000000..91e7bc4 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/backups.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5304.js","../../chunks/1503.js","../../chunks/5313.js","../../chunks/6251.js","../../../package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/@mui/icons-material/StyleTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/console.js b/dsql-app/.local_dist/server/pages/su/console.js new file mode 100644 index 0000000..464fdb0 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/console.js @@ -0,0 +1,546 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 1973; +exports.ids = [1973]; +exports.modules = { + +/***/ 240: +/***/ ((module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try { +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ SuConsoleContent) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var socket_io_client__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4612); +/* harmony import */ var _xterm__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(920); +/* harmony import */ var ansi_regex__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8844); +var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([socket_io_client__WEBPACK_IMPORTED_MODULE_2__, ansi_regex__WEBPACK_IMPORTED_MODULE_4__]); +([socket_io_client__WEBPACK_IMPORTED_MODULE_2__, ansi_regex__WEBPACK_IMPORTED_MODULE_4__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +let isMouseInLogHistory = false; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {string} props.socketDomain + */ function SuConsoleContent({ socketDomain }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ state: Socket, dispatch: React.Dispatch> ]} */ // @ts-ignore + const [socket, setSocket] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + /** @type {[ state: import("xterm").Terminal, dispatch: React.Dispatch> ]} */ // @ts-ignore + const [terminal, setTerminal] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(null); + const [log, setLog] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(""); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + const domain = socketDomain; + console.log("Socket Domain =>", domain); + if (!domain) return; + /** @type {Socket} */ const socketIo = (0,socket_io_client__WEBPACK_IMPORTED_MODULE_2__.io)(domain, { + extraHeaders: { + "X-Socket-Paradigm": "Console" + } + }); + socketIo.on("connect", ()=>{ + setSocket(socketIo); + console.log("Socket Connected!"); + }); + setInterval(()=>{ + socketIo.emit("get-log"); + }, 1000); + socketIo.on("console-log", (message)=>{ + console.log("Fetched Log", message); + setLog(message.replace((0,ansi_regex__WEBPACK_IMPORTED_MODULE_4__["default"])(), "")); + setTimeout(()=>{ + const wrapper = document.getElementById("logHistoryWrapper"); + if (wrapper && !isMouseInLogHistory) { + wrapper.scrollTop = wrapper.scrollHeight; + } + }, 200); + }); + }, []); + react__WEBPACK_IMPORTED_MODULE_1___default().useEffect(()=>{ + if (!socket) return; + (0,_xterm__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({ + socket: socket + }).then((res)=>{ + setTerminal(res); + }); + return function cleanup() { + document.getElementById("terminal")?.childNodes.forEach((child)=>{ + child.parentNode?.removeChild(child); + }); + document.getElementById("shell")?.childNodes.forEach((child)=>{ + child.parentNode?.removeChild(child); + }); + terminal?.dispose(); + }; + }, [ + socket + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "text-2xl m-0", + children: "Console" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + onClick: (e)=>{ + if (socket) { + socket.emit("log", "Logging to the console"); + } + }, + children: "Log console" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "grid grid-cols-2 gap-6 w-full items-stretch", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("section", { + className: "paper bg-slate-900", + id: "terminalWrapper", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex flex-col w-full gap-10 items-start justify-start terminal", + children: true && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "m-0 text-white text-base", + children: "Shell" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "opacity-20" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + id: "shell", + className: "relative grow z-50 overflow-hidden w-full h-[340px]" + }) + ] + }) + }) + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("section", { + className: "paper bg-slate-500", + id: "terminalWrapper", + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + className: "flex flex-col w-full gap-10 items-start justify-start terminal", + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-start w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h2", { + className: "m-0 text-white text-base", + children: "Server Log" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("hr", { + className: "opacity-20" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", { + id: "terminal", + className: "relative grow z-50 overflow-hidden w-full" + ( true ? " h-[150px]" : 0) + }) + ] + }) + }) + }) + ] + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +__webpack_async_result__(); +} catch(e) { __webpack_async_result__(e); } }); + +/***/ }), + +/***/ 920: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "Z": () => (/* binding */ xterm) +/* harmony export */ }); +// @ts-check +/** + * # Main Terminal Function + * @param {object} param0 + * @param {import("socket.io-client").Socket} param0.socket - Websocket using Socket.Io paradigm + * @returns + */ async function xterm({ socket }) { + const { Terminal } = __webpack_require__(2803); + const { FitAddon } = __webpack_require__(4040); + const fitAddon = new FitAddon(); + /** @type {HTMLElement} */ // @ts-ignore + const terminalWrapper = document.getElementById("terminalWrapper"); + /** @type {HTMLElement} */ // @ts-ignore + const terminalElement = document.getElementById("terminal"); + const terminalWrapperWidth = terminalWrapper.clientWidth; + const calculatedCols = Math.round(terminalWrapperWidth / 12); + const terminal = new Terminal({ + cols: calculatedCols, + rows: true ? 6 : 0 + }); + terminal.open(terminalElement); + fitAddon.fit(); + socket.on("console", (message)=>{ + terminal.write(message); + }); + //////////////////////////////////// + //////////////////////////////////// + //////////////////////////////////// + if (true) { + const shellFit = new FitAddon(); + /** @type {HTMLElement} */ // @ts-ignore + const shellElement = document.getElementById("shell"); + const shell = new Terminal({ + cols: calculatedCols, + rows: 17 + }); + shell.open(shellElement); + shellFit.fit(); + socket.on("shell", (message)=>{ + shell.write(message); + }); + shell.onKey((arg1, arg2)=>{ + socket.emit("shell", arg1.key); + }); + } + return terminal; +} + + +/***/ }), + +/***/ 9239: +/***/ ((module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try { +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Console), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_SuConsoleContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(240); +var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_components_su_SuConsoleContent__WEBPACK_IMPORTED_MODULE_4__]); +_components_su_SuConsoleContent__WEBPACK_IMPORTED_MODULE_4__ = (__webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__)[0]; +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} [props.data] + * @param {string} props.socketDomain + */ function Console({ user , data , socketDomain }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Console | Datasquirel"; + const pageDescription = "Databases Console"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_SuConsoleContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + socketDomain: socketDomain + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + const socketDomain = process.env.DSQL_SOCKET_DOMAIN; + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + socketDomain: socketDomain || "" + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + +__webpack_async_result__(); +} catch(e) { __webpack_async_result__(e); } }); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2803: +/***/ ((module) => { + +module.exports = require("xterm"); + +/***/ }), + +/***/ 4040: +/***/ ((module) => { + +module.exports = require("xterm-addon-fit"); + +/***/ }), + +/***/ 8844: +/***/ ((module) => { + +module.exports = import("ansi-regex");; + +/***/ }), + +/***/ 4612: +/***/ ((module) => { + +module.exports = import("socket.io-client");; + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5304,1503,5313], () => (__webpack_exec__(9239))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/console.js.nft.json b/dsql-app/.local_dist/server/pages/su/console.js.nft.json new file mode 100644 index 0000000..12e5609 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/console.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5304.js","../../chunks/1503.js","../../chunks/5313.js","../../../package.json","../../../../node_modules/xterm/package.json","../../../../node_modules/xterm-addon-fit/package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/xterm/lib/xterm.js","../../../../node_modules/xterm-addon-fit/lib/xterm-addon-fit.js","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/ansi-regex/package.json","../../../../node_modules/ansi-regex/index.js","../../../../node_modules/socket.io-client/package.json","../../../../node_modules/socket.io-client/build/esm-debug/index.js","../../../../node_modules/socket.io-client/build/esm-debug/package.json","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/socket.io-client/build/esm-debug/url.js","../../../../node_modules/socket.io-client/build/esm-debug/manager.js","../../../../node_modules/socket.io-client/build/esm-debug/socket.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/socket.io-client/build/esm-debug/on.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/socket.io-client/build/esm-debug/contrib/backo2.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/debug/package.json","../../../../node_modules/debug/src/index.js","../../../../node_modules/socket.io-parser/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/@socket.io/component-emitter/package.json","../../../../node_modules/@socket.io/component-emitter/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/engine.io-client/package.json","../../../../node_modules/socket.io-parser/build/esm-debug/index.js","../../../../node_modules/socket.io-parser/build/cjs/index.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/socket.io-parser/build/esm-debug/package.json","../../../../node_modules/socket.io-parser/build/cjs/package.json","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/engine.io-client/build/esm-debug/index.js","../../../../node_modules/engine.io-client/build/cjs/index.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/debug/src/browser.js","../../../../node_modules/debug/src/node.js","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/engine.io-client/build/esm-debug/package.json","../../../../node_modules/engine.io-client/build/cjs/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/socket.io-parser/build/esm-debug/binary.js","../../../../node_modules/socket.io-parser/build/esm-debug/is-binary.js","../../../../node_modules/socket.io-parser/build/cjs/is-binary.js","../../../../node_modules/socket.io-parser/build/cjs/binary.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/engine.io-client/build/esm-debug/socket.js","../../../../node_modules/engine.io-client/build/esm-debug/transport.js","../../../../node_modules/engine.io-client/build/esm-debug/util.js","../../../../node_modules/engine.io-client/build/cjs/socket.js","../../../../node_modules/engine.io-client/build/cjs/transport.js","../../../../node_modules/engine.io-client/build/cjs/util.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/index.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/websocket-constructor.js","../../../../node_modules/engine.io-client/build/esm-debug/contrib/parseuri.js","../../../../node_modules/debug/src/common.js","../../../../node_modules/engine.io-client/build/cjs/transports/index.js","../../../../node_modules/engine.io-client/build/cjs/transports/websocket-constructor.js","../../../../node_modules/engine.io-client/build/cjs/contrib/parseuri.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/engine.io-client/build/esm-debug/contrib/parseqs.js","../../../../node_modules/engine.io-client/build/esm-debug/globalThis.js","../../../../node_modules/engine.io-client/build/cjs/contrib/parseqs.js","../../../../node_modules/engine.io-client/build/cjs/globalThis.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/websocket.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/polling.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/webtransport.js","../../../../node_modules/engine.io-client/build/cjs/transports/polling.js","../../../../node_modules/engine.io-client/build/cjs/transports/webtransport.js","../../../../node_modules/engine.io-client/build/cjs/transports/websocket.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/supports-color/index.js","../../../../node_modules/engine.io-client/build/esm-debug/contrib/yeast.js","../../../../node_modules/engine.io-client/build/esm-debug/transports/xmlhttprequest.js","../../../../node_modules/supports-color/package.json","../../../../node_modules/engine.io-client/build/cjs/contrib/yeast.js","../../../../node_modules/engine.io-client/build/cjs/transports/xmlhttprequest.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/ms/package.json","../../../../node_modules/ms/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/ws/package.json","../../../../node_modules/ws/index.js","../../../../node_modules/engine.io-parser/package.json","../../../../node_modules/engine.io-parser/build/cjs/index.js","../../../../node_modules/ws/wrapper.mjs","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/engine.io-parser/build/cjs/package.json","../../../../node_modules/engine.io-parser/build/esm/index.js","../../../../node_modules/engine.io-parser/build/esm/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/ws/lib/stream.js","../../../../node_modules/ws/lib/receiver.js","../../../../node_modules/ws/lib/sender.js","../../../../node_modules/ws/lib/websocket.js","../../../../node_modules/ws/lib/websocket-server.js","../../../../node_modules/xmlhttprequest-ssl/package.json","../../../../node_modules/xmlhttprequest-ssl/lib/XMLHttpRequest.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/has-flag/index.js","../../../../node_modules/engine.io-parser/build/cjs/encodePacket.js","../../../../node_modules/engine.io-parser/build/cjs/decodePacket.js","../../../../node_modules/engine.io-parser/build/cjs/commons.js","../../../../node_modules/has-flag/package.json","../../../../node_modules/engine.io-parser/build/esm/encodePacket.js","../../../../node_modules/engine.io-parser/build/esm/decodePacket.js","../../../../node_modules/engine.io-parser/build/esm/commons.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/ws/lib/constants.js","../../../../node_modules/ws/lib/permessage-deflate.js","../../../../node_modules/ws/lib/validation.js","../../../../node_modules/ws/lib/buffer-util.js","../../../../node_modules/ws/lib/event-target.js","../../../../node_modules/ws/lib/extension.js","../../../../node_modules/ws/lib/subprotocol.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/ws/lib/limiter.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/socket.io-client/build/cjs/index.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/socket.io-client/build/cjs/url.js","../../../../node_modules/socket.io-client/build/cjs/manager.js","../../../../node_modules/socket.io-client/build/cjs/socket.js","../../../../node_modules/socket.io-client/build/cjs/on.js","../../../../node_modules/socket.io-client/build/cjs/contrib/backo2.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs.js b/dsql-app/.local_dist/server/pages/su/docs.js new file mode 100644 index 0000000..a69b2a8 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs.js @@ -0,0 +1,292 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3036; +exports.ids = [3036]; +exports.modules = { + +/***/ 1376: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ DocsPage), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_docs_SuDocsPageListContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2435); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function DocsPage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_docs_SuDocsPageListContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const docPages = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM docs_pages WHERE level=1 ORDER BY page_order ASC`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + docPages: docPages, + env: "dev_dev" + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4118: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AccountTreeTwoTone"); + +/***/ }), + +/***/ 1891: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArticleTwoTone"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,9395,1503,5313,2435], () => (__webpack_exec__(1376))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs.js.nft.json b/dsql-app/.local_dist/server/pages/su/docs.js.nft.json new file mode 100644 index 0000000..383f9d5 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5449.js","../../chunks/5304.js","../../chunks/9395.js","../../chunks/1503.js","../../chunks/5313.js","../../chunks/2435.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/@mui/icons-material/ArticleTwoTone.js","../../../../node_modules/@mui/icons-material/AccountTreeTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/mysql/index.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/create-page.js b/dsql-app/.local_dist/server/pages/su/docs/create-page.js new file mode 100644 index 0000000..a60530d --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/create-page.js @@ -0,0 +1,383 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7363; +exports.ids = [7363]; +exports.modules = { + +/***/ 7585: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ CreatePage), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_docs_CreatePageContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2378); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function CreatePage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_docs_CreatePageContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + data: data, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const docPages = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM docs_pages WHERE level=0`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + docPages: docPages + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 371: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdsClickTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6502: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 9361: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DoDisturbAltTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 328: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/HighlightAltTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 282: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipNextTwoTone"); + +/***/ }), + +/***/ 3729: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipPreviousTwoTone"); + +/***/ }), + +/***/ 723: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StyleTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 1358: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateUpTwoTone"); + +/***/ }), + +/***/ 4864: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateVerticalTwoTone"); + +/***/ }), + +/***/ 5139: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ViewTimelineTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,9395,424,1781,7901,4114,1503,5313,2378], () => (__webpack_exec__(7585))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/create-page.js.nft.json b/dsql-app/.local_dist/server/pages/su/docs/create-page.js.nft.json new file mode 100644 index 0000000..0a4fa97 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/create-page.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/9395.js","../../../chunks/424.js","../../../chunks/1781.js","../../../chunks/7901.js","../../../chunks/4114.js","../../../chunks/1503.js","../../../chunks/5313.js","../../../chunks/2378.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/material/node/index.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../node_modules/@mui/icons-material/StyleTwoTone.js","../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../node_modules/@mui/icons-material/Close.js","../../../../../node_modules/@mui/icons-material/AdsClickTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteTwoTone.js","../../../../../node_modules/@mui/icons-material/DoDisturbAltTwoTone.js","../../../../../node_modules/@mui/icons-material/HighlightAltTwoTone.js","../../../../../node_modules/@mui/icons-material/SkipNextTwoTone.js","../../../../../node_modules/@mui/icons-material/SkipPreviousTwoTone.js","../../../../../node_modules/@mui/icons-material/TextRotateUpTwoTone.js","../../../../../node_modules/@mui/icons-material/TextRotateVerticalTwoTone.js","../../../../../node_modules/@mui/icons-material/ViewTimelineTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../node_modules/@mui/material/node/List/index.js","../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/base/node/index.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../node_modules/@mui/material/node/List/List.js","../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../node_modules/@mui/base/Portal/package.json","../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/material/node/className/index.js","../../../../../node_modules/@mui/base/utils/package.json","../../../../../node_modules/@mui/base/Popper/package.json","../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../node_modules/react-transition-group/package.json","../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../node_modules/@popperjs/core/package.json","../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/dom-helpers/package.json","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@floating-ui/dom/package.json","../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/@floating-ui/core/package.json","../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/edit-page.js b/dsql-app/.local_dist/server/pages/su/docs/edit-page.js new file mode 100644 index 0000000..3a06cad --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/edit-page.js @@ -0,0 +1,391 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3412; +exports.ids = [3412]; +exports.modules = { + +/***/ 6046: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ UpdatePage), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_docs_CreatePageContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2378); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function UpdatePage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_docs_CreatePageContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + data: data, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const targetDocPage = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM docs_pages WHERE id=?`, [ + query.id + ]); + if (!targetDocPage || !Array.isArray(targetDocPage) || !targetDocPage[0]) { + return { + redirect: { + destination: `/su/docs`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: targetDocPage[0] + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 371: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdsClickTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6502: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 9361: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DoDisturbAltTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 328: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/HighlightAltTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 282: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipNextTwoTone"); + +/***/ }), + +/***/ 3729: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipPreviousTwoTone"); + +/***/ }), + +/***/ 723: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StyleTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 1358: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateUpTwoTone"); + +/***/ }), + +/***/ 4864: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateVerticalTwoTone"); + +/***/ }), + +/***/ 5139: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ViewTimelineTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,9395,424,1781,7901,4114,1503,5313,2378], () => (__webpack_exec__(6046))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/edit-page.js.nft.json b/dsql-app/.local_dist/server/pages/su/docs/edit-page.js.nft.json new file mode 100644 index 0000000..0a4fa97 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/edit-page.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/9395.js","../../../chunks/424.js","../../../chunks/1781.js","../../../chunks/7901.js","../../../chunks/4114.js","../../../chunks/1503.js","../../../chunks/5313.js","../../../chunks/2378.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/material/node/index.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../node_modules/@mui/icons-material/StyleTwoTone.js","../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../node_modules/@mui/icons-material/Close.js","../../../../../node_modules/@mui/icons-material/AdsClickTwoTone.js","../../../../../node_modules/@mui/icons-material/DeleteTwoTone.js","../../../../../node_modules/@mui/icons-material/DoDisturbAltTwoTone.js","../../../../../node_modules/@mui/icons-material/HighlightAltTwoTone.js","../../../../../node_modules/@mui/icons-material/SkipNextTwoTone.js","../../../../../node_modules/@mui/icons-material/SkipPreviousTwoTone.js","../../../../../node_modules/@mui/icons-material/TextRotateUpTwoTone.js","../../../../../node_modules/@mui/icons-material/TextRotateVerticalTwoTone.js","../../../../../node_modules/@mui/icons-material/ViewTimelineTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../node_modules/@mui/material/node/List/index.js","../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/base/node/index.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../node_modules/@mui/material/node/List/List.js","../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../node_modules/@mui/base/Portal/package.json","../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/material/node/className/index.js","../../../../../node_modules/@mui/base/utils/package.json","../../../../../node_modules/@mui/base/Popper/package.json","../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../node_modules/react-transition-group/package.json","../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../node_modules/@popperjs/core/package.json","../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/dom-helpers/package.json","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@floating-ui/dom/package.json","../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/@floating-ui/core/package.json","../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/pages.js b/dsql-app/.local_dist/server/pages/su/docs/pages.js new file mode 100644 index 0000000..9489036 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/pages.js @@ -0,0 +1,292 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3281; +exports.ids = [3281]; +exports.modules = { + +/***/ 6103: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ DocsPage), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_docs_SuDocsPageListContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2435); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function DocsPage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_docs_SuDocsPageListContent__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const docPages = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_5___default()(`SELECT * FROM docs_pages WHERE level=1 ORDER BY page_order ASC`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + docPages: docPages, + env: "dev_dev" + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 4118: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AccountTreeTwoTone"); + +/***/ }), + +/***/ 1891: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArticleTwoTone"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,9395,1503,5313,2435], () => (__webpack_exec__(6103))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/pages.js.nft.json b/dsql-app/.local_dist/server/pages/su/docs/pages.js.nft.json new file mode 100644 index 0000000..2d21766 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/pages.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5449.js","../../../chunks/5304.js","../../../chunks/9395.js","../../../chunks/1503.js","../../../chunks/5313.js","../../../chunks/2435.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../node_modules/@mui/icons-material/ArticleTwoTone.js","../../../../../node_modules/@mui/icons-material/AccountTreeTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js b/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js new file mode 100644 index 0000000..2bcb81a --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js @@ -0,0 +1,457 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 9025; +exports.ids = [9025]; +exports.modules = { + +/***/ 9242: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ UpdatePage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/su/docs/CreatePageContent.jsx + 5 modules +var CreatePageContent = __webpack_require__(2378); +;// CONCATENATED MODULE: ./components/su/docs/SuSingleDocPageContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + * @param {any} props.user + */ function SuSingleDocPageContent({ data , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const { targetDocPage } = data; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx(CreatePageContent/* default */.Z, { + data: targetDocPage, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/su/docs/pages/[id].jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function UpdatePage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuSingleDocPageContent, { + data: data, + user: user + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const targetDocPage = await DB_HANDLER_default()(`SELECT * FROM docs_pages WHERE id=?`, [ + query.id + ]); + if (!targetDocPage || !Array.isArray(targetDocPage) || !targetDocPage[0]) { + return { + redirect: { + destination: `/su/docs`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + targetDocPage: targetDocPage[0] + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 371: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/AdsClickTwoTone"); + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 4173: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/Close"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6502: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DeleteTwoTone"); + +/***/ }), + +/***/ 930: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DifferenceTwoTone"); + +/***/ }), + +/***/ 9361: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DoDisturbAltTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 328: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/HighlightAltTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 282: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipNextTwoTone"); + +/***/ }), + +/***/ 3729: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/SkipPreviousTwoTone"); + +/***/ }), + +/***/ 723: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StyleTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 1358: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateUpTwoTone"); + +/***/ }), + +/***/ 4864: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TextRotateVerticalTwoTone"); + +/***/ }), + +/***/ 5139: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ViewTimelineTwoTone"); + +/***/ }), + +/***/ 5692: +/***/ ((module) => { + +module.exports = require("@mui/material"); + +/***/ }), + +/***/ 6451: +/***/ ((module) => { + +module.exports = require("@tinymce/tinymce-react"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,9395,424,1781,7901,4114,1503,5313,2378], () => (__webpack_exec__(9242))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js.nft.json b/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js.nft.json new file mode 100644 index 0000000..a1e743b --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/docs/pages/[id].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../../webpack-runtime.js","../../../../chunks/4017.js","../../../../chunks/8313.js","../../../../chunks/5264.js","../../../../chunks/6729.js","../../../../chunks/5449.js","../../../../chunks/5304.js","../../../../chunks/9395.js","../../../../chunks/424.js","../../../../chunks/1781.js","../../../../chunks/7901.js","../../../../chunks/4114.js","../../../../chunks/1503.js","../../../../chunks/5313.js","../../../../chunks/2378.js","../../../../../package.json","../../../../../../ssl/ca-cert.pem","../../../../../../node_modules/serverless-mysql/package.json","../../../../../../node_modules/react-dom/package.json","../../../../../../node_modules/lucide-react/package.json","../../../../../../node_modules/@mui/material/package.json","../../../../../../node_modules/@tinymce/tinymce-react/package.json","../../../../../../node_modules/serverless-mysql/index.js","../../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../../node_modules/@mui/material/node/index.js","../../../../../../node_modules/react-dom/index.js","../../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/index.js","../../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../../node_modules/@mui/icons-material/package.json","../../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../../node_modules/next/head.js","../../../../../../node_modules/next/package.json","../../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../../node_modules/@mui/icons-material/DifferenceTwoTone.js","../../../../../../node_modules/@mui/icons-material/StyleTwoTone.js","../../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../../node_modules/@mui/icons-material/Close.js","../../../../../../node_modules/@mui/icons-material/AdsClickTwoTone.js","../../../../../../node_modules/@mui/icons-material/DeleteTwoTone.js","../../../../../../node_modules/@mui/icons-material/DoDisturbAltTwoTone.js","../../../../../../node_modules/@mui/icons-material/HighlightAltTwoTone.js","../../../../../../node_modules/@mui/icons-material/SkipNextTwoTone.js","../../../../../../node_modules/@mui/icons-material/SkipPreviousTwoTone.js","../../../../../../node_modules/@mui/icons-material/TextRotateUpTwoTone.js","../../../../../../node_modules/@mui/icons-material/TextRotateVerticalTwoTone.js","../../../../../../node_modules/@mui/icons-material/ViewTimelineTwoTone.js","../../../../../../node_modules/react/package.json","../../../../../../node_modules/react/index.js","../../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../../node_modules/react/jsx-runtime.js","../../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../../node_modules/react/cjs/react.production.min.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../../node_modules/react/cjs/react.development.js","../../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/Editor.js","../../../../../../node_modules/@mui/material/node/colors/index.js","../../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../../node_modules/@mui/material/node/Accordion/index.js","../../../../../../node_modules/@mui/material/node/AccordionActions/index.js","../../../../../../node_modules/@mui/material/node/AccordionSummary/index.js","../../../../../../node_modules/@mui/material/node/AccordionDetails/index.js","../../../../../../node_modules/@mui/material/node/Alert/index.js","../../../../../../node_modules/@mui/material/node/AlertTitle/index.js","../../../../../../node_modules/@mui/material/node/Autocomplete/index.js","../../../../../../node_modules/@mui/material/node/AppBar/index.js","../../../../../../node_modules/@mui/material/node/Avatar/index.js","../../../../../../node_modules/@mui/material/node/AvatarGroup/index.js","../../../../../../node_modules/@mui/material/node/Backdrop/index.js","../../../../../../node_modules/@mui/material/node/Badge/index.js","../../../../../../node_modules/@mui/material/node/BottomNavigation/index.js","../../../../../../node_modules/@mui/material/node/Box/index.js","../../../../../../node_modules/@mui/material/node/Breadcrumbs/index.js","../../../../../../node_modules/@mui/material/node/BottomNavigationAction/index.js","../../../../../../node_modules/@mui/material/node/Button/index.js","../../../../../../node_modules/@mui/material/node/ButtonBase/index.js","../../../../../../node_modules/@mui/material/node/ButtonGroup/index.js","../../../../../../node_modules/@mui/material/node/Card/index.js","../../../../../../node_modules/@mui/material/node/CardActionArea/index.js","../../../../../../node_modules/@mui/material/node/CardActions/index.js","../../../../../../node_modules/@mui/material/node/CardContent/index.js","../../../../../../node_modules/@mui/material/node/CardHeader/index.js","../../../../../../node_modules/@mui/material/node/CardMedia/index.js","../../../../../../node_modules/@mui/material/node/Checkbox/index.js","../../../../../../node_modules/@mui/material/node/Chip/index.js","../../../../../../node_modules/@mui/material/node/CircularProgress/index.js","../../../../../../node_modules/@mui/material/node/ClickAwayListener/index.js","../../../../../../node_modules/@mui/material/node/Collapse/index.js","../../../../../../node_modules/@mui/material/node/Container/index.js","../../../../../../node_modules/@mui/material/node/CssBaseline/index.js","../../../../../../node_modules/@mui/material/node/darkScrollbar/index.js","../../../../../../node_modules/@mui/material/node/Dialog/index.js","../../../../../../node_modules/@mui/material/node/DialogActions/index.js","../../../../../../node_modules/@mui/material/node/DialogContent/index.js","../../../../../../node_modules/@mui/material/node/DialogContentText/index.js","../../../../../../node_modules/@mui/material/node/DialogTitle/index.js","../../../../../../node_modules/@mui/material/node/Divider/index.js","../../../../../../node_modules/@mui/material/node/Drawer/index.js","../../../../../../node_modules/@mui/material/node/Fab/index.js","../../../../../../node_modules/@mui/material/node/Fade/index.js","../../../../../../node_modules/@mui/material/node/FilledInput/index.js","../../../../../../node_modules/@mui/material/node/FormControl/index.js","../../../../../../node_modules/@mui/material/node/FormControlLabel/index.js","../../../../../../node_modules/@mui/material/node/FormGroup/index.js","../../../../../../node_modules/@mui/material/node/FormHelperText/index.js","../../../../../../node_modules/@mui/material/node/FormLabel/index.js","../../../../../../node_modules/@mui/material/node/Grid/index.js","../../../../../../node_modules/@mui/material/node/Unstable_Grid2/index.js","../../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../../node_modules/@mui/material/node/Hidden/index.js","../../../../../../node_modules/@mui/material/node/Icon/index.js","../../../../../../node_modules/@mui/material/node/IconButton/index.js","../../../../../../node_modules/@mui/material/node/ImageList/index.js","../../../../../../node_modules/@mui/material/node/ImageListItem/index.js","../../../../../../node_modules/@mui/material/node/ImageListItemBar/index.js","../../../../../../node_modules/@mui/material/node/Input/index.js","../../../../../../node_modules/@mui/material/node/InputAdornment/index.js","../../../../../../node_modules/@mui/material/node/InputBase/index.js","../../../../../../node_modules/@mui/material/node/InputLabel/index.js","../../../../../../node_modules/@mui/material/node/LinearProgress/index.js","../../../../../../node_modules/@mui/material/node/Link/index.js","../../../../../../node_modules/@mui/material/node/List/index.js","../../../../../../node_modules/@mui/material/node/ListItem/index.js","../../../../../../node_modules/@mui/material/node/ListItemAvatar/index.js","../../../../../../node_modules/@mui/material/node/ListItemButton/index.js","../../../../../../node_modules/@mui/material/node/ListItemIcon/index.js","../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/index.js","../../../../../../node_modules/@mui/material/node/ListItemText/index.js","../../../../../../node_modules/@mui/material/node/ListSubheader/index.js","../../../../../../node_modules/@mui/material/node/Menu/index.js","../../../../../../node_modules/@mui/material/node/MenuItem/index.js","../../../../../../node_modules/@mui/material/node/MenuList/index.js","../../../../../../node_modules/@mui/material/node/MobileStepper/index.js","../../../../../../node_modules/@mui/material/node/Modal/index.js","../../../../../../node_modules/@mui/material/node/NativeSelect/index.js","../../../../../../node_modules/@mui/material/node/NoSsr/index.js","../../../../../../node_modules/@mui/material/node/OutlinedInput/index.js","../../../../../../node_modules/@mui/material/node/Pagination/index.js","../../../../../../node_modules/@mui/material/node/PaginationItem/index.js","../../../../../../node_modules/@mui/material/node/Popover/index.js","../../../../../../node_modules/@mui/material/node/Popper/index.js","../../../../../../node_modules/@mui/material/node/Portal/index.js","../../../../../../node_modules/@mui/material/node/Radio/index.js","../../../../../../node_modules/@mui/material/node/RadioGroup/index.js","../../../../../../node_modules/@mui/material/node/Rating/index.js","../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/index.js","../../../../../../node_modules/@mui/material/node/Select/index.js","../../../../../../node_modules/@mui/material/node/Skeleton/index.js","../../../../../../node_modules/@mui/material/node/Slide/index.js","../../../../../../node_modules/@mui/material/node/Slider/index.js","../../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../../node_modules/@mui/material/node/SpeedDial/index.js","../../../../../../node_modules/@mui/material/node/SpeedDialAction/index.js","../../../../../../node_modules/@mui/material/node/SpeedDialIcon/index.js","../../../../../../node_modules/@mui/material/node/Stack/index.js","../../../../../../node_modules/@mui/material/node/Step/index.js","../../../../../../node_modules/@mui/material/node/StepButton/index.js","../../../../../../node_modules/@mui/material/node/StepConnector/index.js","../../../../../../node_modules/@mui/material/node/StepContent/index.js","../../../../../../node_modules/@mui/material/node/StepIcon/index.js","../../../../../../node_modules/@mui/material/node/StepLabel/index.js","../../../../../../node_modules/@mui/material/node/Stepper/index.js","../../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../../node_modules/@mui/material/node/SwipeableDrawer/index.js","../../../../../../node_modules/@mui/material/node/Switch/index.js","../../../../../../node_modules/@mui/material/node/Tab/index.js","../../../../../../node_modules/@mui/material/node/TableFooter/index.js","../../../../../../node_modules/@mui/material/node/TablePagination/index.js","../../../../../../node_modules/@mui/material/node/TableSortLabel/index.js","../../../../../../node_modules/@mui/material/node/Tabs/index.js","../../../../../../node_modules/@mui/material/node/TabScrollButton/index.js","../../../../../../node_modules/@mui/material/node/TextField/index.js","../../../../../../node_modules/@mui/material/node/TextareaAutosize/index.js","../../../../../../node_modules/@mui/material/node/ToggleButton/index.js","../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/index.js","../../../../../../node_modules/@mui/material/node/Toolbar/index.js","../../../../../../node_modules/@mui/material/node/Tooltip/index.js","../../../../../../node_modules/@mui/material/node/Typography/index.js","../../../../../../node_modules/@mui/material/node/useMediaQuery/index.js","../../../../../../node_modules/@mui/material/node/usePagination/index.js","../../../../../../node_modules/@mui/material/node/useScrollTrigger/index.js","../../../../../../node_modules/@mui/material/node/Zoom/index.js","../../../../../../node_modules/@mui/material/node/useAutocomplete/index.js","../../../../../../node_modules/@mui/material/node/GlobalStyles/index.js","../../../../../../node_modules/@mui/material/node/generateUtilityClass/index.js","../../../../../../node_modules/@mui/material/node/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/material/node/Unstable_TrapFocus/index.js","../../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../../node_modules/@swc/helpers/package.json","../../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../../node_modules/mysql/index.js","../../../../../../node_modules/@babel/runtime/package.json","../../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../../node_modules/@mui/system/package.json","../../../../../../node_modules/@mui/system/index.js","../../../../../../node_modules/mysql/package.json","../../../../../../node_modules/@mui/utils/package.json","../../../../../../node_modules/@mui/utils/index.js","../../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../../node_modules/@mui/base/package.json","../../../../../../node_modules/@mui/base/node/index.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/ScriptLoader2.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/TinyMCE.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/Utils.js","../../../../../../node_modules/@tinymce/tinymce-react/lib/cjs/main/ts/components/EditorPropTypes.js","../../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../../node_modules/@mui/material/node/colors/pink.js","../../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../../node_modules/@mui/material/node/colors/deepPurple.js","../../../../../../node_modules/@mui/material/node/colors/indigo.js","../../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../../node_modules/@mui/material/node/colors/cyan.js","../../../../../../node_modules/@mui/material/node/colors/teal.js","../../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../../node_modules/@mui/material/node/colors/lightGreen.js","../../../../../../node_modules/@mui/material/node/colors/lime.js","../../../../../../node_modules/@mui/material/node/colors/yellow.js","../../../../../../node_modules/@mui/material/node/colors/amber.js","../../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../../node_modules/@mui/material/node/colors/deepOrange.js","../../../../../../node_modules/@mui/material/node/colors/brown.js","../../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../../node_modules/@mui/material/node/colors/blueGrey.js","../../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/material/node/AccordionActions/AccordionActions.js","../../../../../../node_modules/@mui/material/node/AccordionActions/accordionActionsClasses.js","../../../../../../node_modules/@mui/material/node/AccordionSummary/AccordionSummary.js","../../../../../../node_modules/@mui/material/node/AccordionSummary/accordionSummaryClasses.js","../../../../../../node_modules/@mui/material/node/Accordion/Accordion.js","../../../../../../node_modules/@mui/material/node/Accordion/accordionClasses.js","../../../../../../node_modules/@mui/material/node/AccordionDetails/AccordionDetails.js","../../../../../../node_modules/@mui/material/node/AccordionDetails/accordionDetailsClasses.js","../../../../../../node_modules/@mui/material/node/AlertTitle/AlertTitle.js","../../../../../../node_modules/@mui/material/node/AlertTitle/alertTitleClasses.js","../../../../../../node_modules/@mui/material/node/Alert/Alert.js","../../../../../../node_modules/@mui/material/node/Alert/alertClasses.js","../../../../../../node_modules/@mui/material/node/Autocomplete/autocompleteClasses.js","../../../../../../node_modules/@mui/material/node/Autocomplete/Autocomplete.js","../../../../../../node_modules/@mui/material/node/AppBar/AppBar.js","../../../../../../node_modules/@mui/material/node/AppBar/appBarClasses.js","../../../../../../node_modules/@mui/material/node/AvatarGroup/AvatarGroup.js","../../../../../../node_modules/@mui/material/node/AvatarGroup/avatarGroupClasses.js","../../../../../../node_modules/@mui/material/node/Avatar/Avatar.js","../../../../../../node_modules/@mui/material/node/Avatar/avatarClasses.js","../../../../../../node_modules/@mui/material/node/Backdrop/Backdrop.js","../../../../../../node_modules/@mui/material/node/Backdrop/backdropClasses.js","../../../../../../node_modules/@mui/material/node/Badge/Badge.js","../../../../../../node_modules/@mui/material/node/Badge/badgeClasses.js","../../../../../../node_modules/@mui/material/node/BottomNavigation/BottomNavigation.js","../../../../../../node_modules/@mui/material/node/BottomNavigation/bottomNavigationClasses.js","../../../../../../node_modules/@mui/material/node/Breadcrumbs/Breadcrumbs.js","../../../../../../node_modules/@mui/material/node/Breadcrumbs/breadcrumbsClasses.js","../../../../../../node_modules/@mui/material/node/Box/Box.js","../../../../../../node_modules/@mui/material/node/Box/boxClasses.js","../../../../../../node_modules/@mui/material/node/BottomNavigationAction/BottomNavigationAction.js","../../../../../../node_modules/@mui/material/node/BottomNavigationAction/bottomNavigationActionClasses.js","../../../../../../node_modules/@mui/material/node/Button/Button.js","../../../../../../node_modules/@mui/material/node/Button/buttonClasses.js","../../../../../../node_modules/@mui/material/node/ButtonBase/ButtonBase.js","../../../../../../node_modules/@mui/material/node/ButtonBase/buttonBaseClasses.js","../../../../../../node_modules/@mui/material/node/ButtonBase/touchRippleClasses.js","../../../../../../node_modules/@mui/material/node/Card/Card.js","../../../../../../node_modules/@mui/material/node/Card/cardClasses.js","../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroup.js","../../../../../../node_modules/@mui/material/node/ButtonGroup/buttonGroupClasses.js","../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupContext.js","../../../../../../node_modules/@mui/material/node/ButtonGroup/ButtonGroupButtonContext.js","../../../../../../node_modules/@mui/material/node/CardActionArea/CardActionArea.js","../../../../../../node_modules/@mui/material/node/CardActionArea/cardActionAreaClasses.js","../../../../../../node_modules/@mui/material/node/CardActions/CardActions.js","../../../../../../node_modules/@mui/material/node/CardActions/cardActionsClasses.js","../../../../../../node_modules/@mui/material/node/CardContent/CardContent.js","../../../../../../node_modules/@mui/material/node/CardContent/cardContentClasses.js","../../../../../../node_modules/@mui/material/node/CardHeader/CardHeader.js","../../../../../../node_modules/@mui/material/node/CardHeader/cardHeaderClasses.js","../../../../../../node_modules/@mui/material/node/CardMedia/CardMedia.js","../../../../../../node_modules/@mui/material/node/CardMedia/cardMediaClasses.js","../../../../../../node_modules/@mui/material/node/Checkbox/Checkbox.js","../../../../../../node_modules/@mui/material/node/Checkbox/checkboxClasses.js","../../../../../../node_modules/@mui/material/node/Chip/Chip.js","../../../../../../node_modules/@mui/material/node/Chip/chipClasses.js","../../../../../../node_modules/@mui/material/node/CircularProgress/CircularProgress.js","../../../../../../node_modules/@mui/material/node/CircularProgress/circularProgressClasses.js","../../../../../../node_modules/@mui/material/node/Collapse/Collapse.js","../../../../../../node_modules/@mui/material/node/Collapse/collapseClasses.js","../../../../../../node_modules/@mui/material/node/Container/Container.js","../../../../../../node_modules/@mui/material/node/Container/containerClasses.js","../../../../../../node_modules/@mui/material/node/CssBaseline/CssBaseline.js","../../../../../../node_modules/@mui/material/node/DialogActions/DialogActions.js","../../../../../../node_modules/@mui/material/node/DialogActions/dialogActionsClasses.js","../../../../../../node_modules/@mui/material/node/Dialog/Dialog.js","../../../../../../node_modules/@mui/material/node/Dialog/dialogClasses.js","../../../../../../node_modules/@mui/material/node/DialogContentText/DialogContentText.js","../../../../../../node_modules/@mui/material/node/DialogContentText/dialogContentTextClasses.js","../../../../../../node_modules/@mui/material/node/DialogTitle/DialogTitle.js","../../../../../../node_modules/@mui/material/node/DialogTitle/dialogTitleClasses.js","../../../../../../node_modules/@mui/material/node/DialogContent/DialogContent.js","../../../../../../node_modules/@mui/material/node/DialogContent/dialogContentClasses.js","../../../../../../node_modules/@mui/material/node/Divider/Divider.js","../../../../../../node_modules/@mui/material/node/Divider/dividerClasses.js","../../../../../../node_modules/@mui/material/node/Drawer/Drawer.js","../../../../../../node_modules/@mui/material/node/Drawer/drawerClasses.js","../../../../../../node_modules/@mui/material/node/Fab/Fab.js","../../../../../../node_modules/@mui/material/node/Fab/fabClasses.js","../../../../../../node_modules/@mui/material/node/FilledInput/FilledInput.js","../../../../../../node_modules/@mui/material/node/FilledInput/filledInputClasses.js","../../../../../../node_modules/@mui/material/node/Fade/Fade.js","../../../../../../node_modules/@mui/material/node/FormControl/FormControl.js","../../../../../../node_modules/@mui/material/node/FormControl/useFormControl.js","../../../../../../node_modules/@mui/material/node/FormControl/formControlClasses.js","../../../../../../node_modules/@mui/material/node/FormControlLabel/formControlLabelClasses.js","../../../../../../node_modules/@mui/material/node/FormControlLabel/FormControlLabel.js","../../../../../../node_modules/@mui/material/node/FormHelperText/FormHelperText.js","../../../../../../node_modules/@mui/material/node/FormHelperText/formHelperTextClasses.js","../../../../../../node_modules/@mui/material/node/FormGroup/FormGroup.js","../../../../../../node_modules/@mui/material/node/FormGroup/formGroupClasses.js","../../../../../../node_modules/@mui/material/node/FormLabel/FormLabel.js","../../../../../../node_modules/@mui/material/node/FormLabel/formLabelClasses.js","../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2.js","../../../../../../node_modules/@mui/material/node/Unstable_Grid2/Grid2Props.js","../../../../../../node_modules/@mui/material/node/Unstable_Grid2/grid2Classes.js","../../../../../../node_modules/@mui/material/node/Grid/Grid.js","../../../../../../node_modules/@mui/material/node/Grid/gridClasses.js","../../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../../node_modules/@mui/material/node/Icon/Icon.js","../../../../../../node_modules/@mui/material/node/Icon/iconClasses.js","../../../../../../node_modules/@mui/material/node/Hidden/Hidden.js","../../../../../../node_modules/@mui/material/node/IconButton/IconButton.js","../../../../../../node_modules/@mui/material/node/IconButton/iconButtonClasses.js","../../../../../../node_modules/@mui/material/node/ImageList/ImageList.js","../../../../../../node_modules/@mui/material/node/ImageList/imageListClasses.js","../../../../../../node_modules/@mui/material/node/ImageListItem/imageListItemClasses.js","../../../../../../node_modules/@mui/material/node/ImageListItem/ImageListItem.js","../../../../../../node_modules/@mui/material/node/ImageListItemBar/ImageListItemBar.js","../../../../../../node_modules/@mui/material/node/ImageListItemBar/imageListItemBarClasses.js","../../../../../../node_modules/@mui/material/node/Input/Input.js","../../../../../../node_modules/@mui/material/node/Input/inputClasses.js","../../../../../../node_modules/@mui/material/node/InputBase/InputBase.js","../../../../../../node_modules/@mui/material/node/InputBase/inputBaseClasses.js","../../../../../../node_modules/@mui/material/node/InputAdornment/InputAdornment.js","../../../../../../node_modules/@mui/material/node/InputAdornment/inputAdornmentClasses.js","../../../../../../node_modules/@mui/material/node/InputLabel/inputLabelClasses.js","../../../../../../node_modules/@mui/material/node/InputLabel/InputLabel.js","../../../../../../node_modules/@mui/material/node/LinearProgress/LinearProgress.js","../../../../../../node_modules/@mui/material/node/LinearProgress/linearProgressClasses.js","../../../../../../node_modules/@mui/material/node/Link/Link.js","../../../../../../node_modules/@mui/material/node/Link/linkClasses.js","../../../../../../node_modules/@mui/material/node/List/List.js","../../../../../../node_modules/@mui/material/node/List/listClasses.js","../../../../../../node_modules/@mui/material/node/ListItem/ListItem.js","../../../../../../node_modules/@mui/material/node/ListItem/listItemClasses.js","../../../../../../node_modules/@mui/material/node/ListItemAvatar/ListItemAvatar.js","../../../../../../node_modules/@mui/material/node/ListItemAvatar/listItemAvatarClasses.js","../../../../../../node_modules/@mui/material/node/ListItemButton/ListItemButton.js","../../../../../../node_modules/@mui/material/node/ListItemButton/listItemButtonClasses.js","../../../../../../node_modules/@mui/material/node/ListItemIcon/ListItemIcon.js","../../../../../../node_modules/@mui/material/node/ListItemIcon/listItemIconClasses.js","../../../../../../node_modules/@mui/material/node/ListItemText/ListItemText.js","../../../../../../node_modules/@mui/material/node/ListItemText/listItemTextClasses.js","../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/ListItemSecondaryAction.js","../../../../../../node_modules/@mui/material/node/ListItemSecondaryAction/listItemSecondaryActionClasses.js","../../../../../../node_modules/@mui/material/node/ListSubheader/ListSubheader.js","../../../../../../node_modules/@mui/material/node/ListSubheader/listSubheaderClasses.js","../../../../../../node_modules/@mui/material/node/Menu/Menu.js","../../../../../../node_modules/@mui/material/node/Menu/menuClasses.js","../../../../../../node_modules/@mui/material/node/MenuItem/MenuItem.js","../../../../../../node_modules/@mui/material/node/MenuItem/menuItemClasses.js","../../../../../../node_modules/@mui/material/node/MenuList/MenuList.js","../../../../../../node_modules/@mui/material/node/Modal/Modal.js","../../../../../../node_modules/@mui/material/node/Modal/modalClasses.js","../../../../../../node_modules/@mui/material/node/MobileStepper/MobileStepper.js","../../../../../../node_modules/@mui/material/node/MobileStepper/mobileStepperClasses.js","../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelect.js","../../../../../../node_modules/@mui/material/node/NativeSelect/nativeSelectClasses.js","../../../../../../node_modules/@mui/material/node/OutlinedInput/OutlinedInput.js","../../../../../../node_modules/@mui/material/node/OutlinedInput/outlinedInputClasses.js","../../../../../../node_modules/@mui/material/node/Pagination/Pagination.js","../../../../../../node_modules/@mui/material/node/Pagination/paginationClasses.js","../../../../../../node_modules/@mui/material/node/Popover/Popover.js","../../../../../../node_modules/@mui/material/node/Popover/popoverClasses.js","../../../../../../node_modules/@mui/material/node/PaginationItem/PaginationItem.js","../../../../../../node_modules/@mui/material/node/PaginationItem/paginationItemClasses.js","../../../../../../node_modules/@mui/material/node/Popper/Popper.js","../../../../../../node_modules/@mui/material/node/Radio/Radio.js","../../../../../../node_modules/@mui/material/node/Radio/radioClasses.js","../../../../../../node_modules/@mui/material/node/Rating/Rating.js","../../../../../../node_modules/@mui/material/node/Rating/ratingClasses.js","../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroup.js","../../../../../../node_modules/@mui/material/node/RadioGroup/useRadioGroup.js","../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/ScopedCssBaseline.js","../../../../../../node_modules/@mui/material/node/ScopedCssBaseline/scopedCssBaselineClasses.js","../../../../../../node_modules/@mui/material/node/Skeleton/Skeleton.js","../../../../../../node_modules/@mui/material/node/Skeleton/skeletonClasses.js","../../../../../../node_modules/@mui/material/node/Select/selectClasses.js","../../../../../../node_modules/@mui/material/node/Select/Select.js","../../../../../../node_modules/@mui/material/node/Slide/Slide.js","../../../../../../node_modules/@mui/material/node/Slider/Slider.js","../../../../../../node_modules/@mui/material/node/Slider/sliderClasses.js","../../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../../node_modules/@mui/material/node/SpeedDial/SpeedDial.js","../../../../../../node_modules/@mui/material/node/SpeedDial/speedDialClasses.js","../../../../../../node_modules/@mui/material/node/SpeedDialAction/SpeedDialAction.js","../../../../../../node_modules/@mui/material/node/SpeedDialAction/speedDialActionClasses.js","../../../../../../node_modules/@mui/material/node/SpeedDialIcon/SpeedDialIcon.js","../../../../../../node_modules/@mui/material/node/SpeedDialIcon/speedDialIconClasses.js","../../../../../../node_modules/@mui/material/node/Stack/Stack.js","../../../../../../node_modules/@mui/material/node/Stack/stackClasses.js","../../../../../../node_modules/@mui/material/node/Step/Step.js","../../../../../../node_modules/@mui/material/node/Step/StepContext.js","../../../../../../node_modules/@mui/material/node/Step/stepClasses.js","../../../../../../node_modules/@mui/material/node/StepConnector/StepConnector.js","../../../../../../node_modules/@mui/material/node/StepConnector/stepConnectorClasses.js","../../../../../../node_modules/@mui/material/node/StepContent/StepContent.js","../../../../../../node_modules/@mui/material/node/StepContent/stepContentClasses.js","../../../../../../node_modules/@mui/material/node/StepIcon/StepIcon.js","../../../../../../node_modules/@mui/material/node/StepIcon/stepIconClasses.js","../../../../../../node_modules/@mui/material/node/Stepper/stepperClasses.js","../../../../../../node_modules/@mui/material/node/Stepper/Stepper.js","../../../../../../node_modules/@mui/material/node/Stepper/StepperContext.js","../../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeableDrawer.js","../../../../../../node_modules/@mui/material/node/Tab/Tab.js","../../../../../../node_modules/@mui/material/node/Tab/tabClasses.js","../../../../../../node_modules/@mui/material/node/Switch/switchClasses.js","../../../../../../node_modules/@mui/material/node/Switch/Switch.js","../../../../../../node_modules/@mui/material/node/TableFooter/TableFooter.js","../../../../../../node_modules/@mui/material/node/TableFooter/tableFooterClasses.js","../../../../../../node_modules/@mui/material/node/TablePagination/TablePagination.js","../../../../../../node_modules/@mui/material/node/TablePagination/tablePaginationClasses.js","../../../../../../node_modules/@mui/material/node/TableSortLabel/TableSortLabel.js","../../../../../../node_modules/@mui/material/node/TableSortLabel/tableSortLabelClasses.js","../../../../../../node_modules/@mui/material/node/Tabs/Tabs.js","../../../../../../node_modules/@mui/material/node/Tabs/tabsClasses.js","../../../../../../node_modules/@mui/material/node/TabScrollButton/TabScrollButton.js","../../../../../../node_modules/@mui/material/node/TabScrollButton/tabScrollButtonClasses.js","../../../../../../node_modules/@mui/material/node/TextField/TextField.js","../../../../../../node_modules/@mui/material/node/TextField/textFieldClasses.js","../../../../../../node_modules/@mui/material/node/ToggleButton/ToggleButton.js","../../../../../../node_modules/@mui/material/node/ToggleButton/toggleButtonClasses.js","../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/ToggleButtonGroup.js","../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/toggleButtonGroupClasses.js","../../../../../../node_modules/@mui/material/node/Tooltip/tooltipClasses.js","../../../../../../node_modules/@mui/material/node/Tooltip/Tooltip.js","../../../../../../node_modules/@mui/material/node/Toolbar/Toolbar.js","../../../../../../node_modules/@mui/material/node/Toolbar/toolbarClasses.js","../../../../../../node_modules/@mui/material/node/Typography/Typography.js","../../../../../../node_modules/@mui/material/node/Typography/typographyClasses.js","../../../../../../node_modules/@mui/material/node/useMediaQuery/useMediaQuery.js","../../../../../../node_modules/@mui/material/node/usePagination/usePagination.js","../../../../../../node_modules/@mui/material/node/useScrollTrigger/useScrollTrigger.js","../../../../../../node_modules/@mui/material/node/Zoom/Zoom.js","../../../../../../node_modules/@mui/material/node/StepButton/StepButton.js","../../../../../../node_modules/@mui/material/node/StepButton/stepButtonClasses.js","../../../../../../node_modules/@mui/material/node/useAutocomplete/useAutocomplete.js","../../../../../../node_modules/@mui/material/node/StepLabel/StepLabel.js","../../../../../../node_modules/@mui/material/node/StepLabel/stepLabelClasses.js","../../../../../../node_modules/@mui/material/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../../node_modules/prop-types/package.json","../../../../../../node_modules/prop-types/index.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../../node_modules/scheduler/package.json","../../../../../../node_modules/scheduler/index.js","../../../../../../node_modules/@mui/material/utils/package.json","../../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../../node_modules/clsx/package.json","../../../../../../node_modules/clsx/dist/clsx.js","../../../../../../node_modules/@mui/system/borders.js","../../../../../../node_modules/@mui/system/breakpoints.js","../../../../../../node_modules/@mui/system/compose.js","../../../../../../node_modules/@mui/system/display.js","../../../../../../node_modules/@mui/system/flexbox.js","../../../../../../node_modules/@mui/system/cssGrid.js","../../../../../../node_modules/@mui/system/palette.js","../../../../../../node_modules/@mui/system/positions.js","../../../../../../node_modules/@mui/system/sizing.js","../../../../../../node_modules/@mui/system/spacing.js","../../../../../../node_modules/@mui/system/shadows.js","../../../../../../node_modules/@mui/system/style.js","../../../../../../node_modules/@mui/system/typography.js","../../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../../node_modules/@mui/system/createBox.js","../../../../../../node_modules/@mui/system/createStyled.js","../../../../../../node_modules/@mui/system/styled.js","../../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../../node_modules/@mui/system/useTheme.js","../../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../../node_modules/mysql/lib/Connection.js","../../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../../node_modules/mysql/lib/Pool.js","../../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../../node_modules/@mui/utils/refType.js","../../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../../node_modules/@mui/utils/setRef.js","../../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../../node_modules/@mui/system/Container/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../../node_modules/@mui/system/Stack/package.json","../../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../../node_modules/@mui/material/node/Accordion/AccordionContext.js","../../../../../../node_modules/@mui/material/node/Breadcrumbs/BreadcrumbCollapsed.js","../../../../../../node_modules/@mui/material/node/ButtonBase/TouchRipple.js","../../../../../../node_modules/@mui/material/node/Dialog/DialogContext.js","../../../../../../node_modules/@mui/material/node/InputBase/utils.js","../../../../../../node_modules/@mui/material/node/FormControl/FormControlContext.js","../../../../../../node_modules/@mui/material/node/FormControl/formControlState.js","../../../../../../node_modules/@mui/material/node/Grid/GridContext.js","../../../../../../node_modules/@mui/material/node/Hidden/HiddenCss.js","../../../../../../node_modules/@mui/material/node/Hidden/HiddenJs.js","../../../../../../node_modules/@mui/material/node/ImageList/ImageListContext.js","../../../../../../node_modules/@mui/material/node/Link/getTextDecoration.js","../../../../../../node_modules/@mui/material/node/List/ListContext.js","../../../../../../node_modules/@mui/material/node/utils/getScrollbarSize.js","../../../../../../node_modules/@mui/material/node/NativeSelect/NativeSelectInput.js","../../../../../../node_modules/@mui/material/node/OutlinedInput/NotchedOutline.js","../../../../../../node_modules/@mui/material/node/Radio/RadioButtonIcon.js","../../../../../../node_modules/@mui/material/node/RadioGroup/RadioGroupContext.js","../../../../../../node_modules/@mui/material/node/Select/SelectInput.js","../../../../../../node_modules/@mui/material/node/Slider/SliderValueLabel.js","../../../../../../node_modules/@mui/material/node/utils/shouldSpreadAdditionalProps.js","../../../../../../node_modules/@mui/material/node/SwipeableDrawer/SwipeArea.js","../../../../../../node_modules/@mui/material/node/TablePagination/TablePaginationActions.js","../../../../../../node_modules/@mui/material/node/utils/scrollLeft.js","../../../../../../node_modules/@mui/material/node/Tabs/ScrollbarSize.js","../../../../../../node_modules/@mui/material/node/ToggleButtonGroup/isValueSelected.js","../../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../../node_modules/@mui/material/node/internal/SwitchBase.js","../../../../../../node_modules/@mui/material/node/internal/animate.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/SuccessOutlined.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/ReportProblemOutlined.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/ErrorOutline.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/InfoOutlined.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Close.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDropDown.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Person.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBoxOutlineBlank.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckBox.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/IndeterminateCheckBox.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Cancel.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/FirstPage.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/LastPage.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateBefore.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/NavigateNext.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Star.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/StarBorder.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Add.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/ArrowDownward.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowRight.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/KeyboardArrowLeft.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/Warning.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/CheckCircle.js","../../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../../node_modules/@mui/base/unstable_useModal/package.json","../../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../../node_modules/@mui/base/NoSsr/package.json","../../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../../node_modules/@mui/base/Portal/package.json","../../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../../node_modules/@mui/base/TextareaAutosize/package.json","../../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../../node_modules/@mui/base/FocusTrap/package.json","../../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../../node_modules/@mui/system/Container/index.js","../../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../../node_modules/@mui/system/Stack/index.js","../../../../../../node_modules/@mui/system/merge.js","../../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../../node_modules/@mui/system/memoize.js","../../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../../node_modules/@mui/system/Box/package.json","../../../../../../node_modules/@mui/system/Box/index.js","../../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../../node_modules/@mui/utils/useId/package.json","../../../../../../node_modules/@mui/utils/useId/index.js","../../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../../node_modules/@mui/material/node/className/index.js","../../../../../../node_modules/@mui/base/utils/package.json","../../../../../../node_modules/@mui/base/Popper/package.json","../../../../../../node_modules/@mui/base/useBadge/package.json","../../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../../node_modules/@mui/styled-engine/package.json","../../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../../node_modules/@mui/base/useSlider/package.json","../../../../../../node_modules/@mui/base/useAutocomplete/package.json","../../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../../node_modules/react-is/package.json","../../../../../../node_modules/react-is/index.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/MoreHoriz.js","../../../../../../node_modules/@mui/material/node/ButtonBase/Ripple.js","../../../../../../node_modules/@mui/material/node/Hidden/hiddenCssClasses.js","../../../../../../node_modules/@mui/material/node/Hidden/withWidth.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonUnchecked.js","../../../../../../node_modules/@mui/material/node/internal/svg-icons/RadioButtonChecked.js","../../../../../../node_modules/react-transition-group/package.json","../../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../../node_modules/@mui/material/node/internal/switchBaseClasses.js","../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../../node_modules/prop-types/lib/has.js","../../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../../node_modules/@mui/system/Container/Container.js","../../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../../node_modules/@mui/system/Box/Box.js","../../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@mui/private-theming/package.json","../../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../../node_modules/sqlstring/index.js","../../../../../../node_modules/object-assign/index.js","../../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../../node_modules/sqlstring/package.json","../../../../../../node_modules/object-assign/package.json","../../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../../node_modules/@emotion/styled/package.json","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../../node_modules/@emotion/react/package.json","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../../node_modules/readable-stream/package.json","../../../../../../node_modules/readable-stream/readable.js","../../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../../node_modules/@popperjs/core/package.json","../../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../../node_modules/dom-helpers/package.json","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../../node_modules/@emotion/styled/base/package.json","../../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../../node_modules/@emotion/cache/package.json","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../../node_modules/@floating-ui/dom/package.json","../../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../../node_modules/@emotion/utils/package.json","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../../node_modules/@emotion/serialize/package.json","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../../node_modules/string_decoder/package.json","../../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../../node_modules/process-nextick-args/package.json","../../../../../../node_modules/process-nextick-args/index.js","../../../../../../node_modules/isarray/package.json","../../../../../../node_modules/isarray/index.js","../../../../../../node_modules/inherits/package.json","../../../../../../node_modules/inherits/inherits.js","../../../../../../node_modules/util-deprecate/package.json","../../../../../../node_modules/util-deprecate/node.js","../../../../../../node_modules/core-util-is/package.json","../../../../../../node_modules/core-util-is/lib/util.js","../../../../../../node_modules/inherits/inherits_browser.js","../../../../../../node_modules/@emotion/sheet/package.json","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../../node_modules/@emotion/memoize/package.json","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../../node_modules/@floating-ui/core/package.json","../../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../../node_modules/stylis/package.json","../../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../../node_modules/stylis/dist/umd/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../../node_modules/@emotion/hash/package.json","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../../node_modules/@emotion/unitless/package.json","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/envar.js b/dsql-app/.local_dist/server/pages/su/envar.js new file mode 100644 index 0000000..b0896ab --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/envar.js @@ -0,0 +1,530 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7775; +exports.ids = [7775]; +exports.modules = { + +/***/ 3667: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ Console), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +;// CONCATENATED MODULE: external "os" +const external_os_namespaceObject = require("os"); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +;// CONCATENATED MODULE: ./components/su/SuEnvCard.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +let isMouseInLogHistory = false; +/** @type {any} */ let timeout; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.envObject + * @param {string} props.envKey + */ function SuEnvCard({ envObject , envKey }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const [visible, setVisible] = external_react_default().useState(false); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [value, setValue] = external_react_default().useState(envObject[envKey]); + const [focused, setFocused] = external_react_default().useState(false); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("form", { + className: "grid grid-cols-2 items-center gap2 w-full hover:bg-slate-100 py-2 px-4 relative", + onSubmit: (e)=>{ + e.preventDefault(); + if (!visible) return; + setLoading(true); + setTimeout(()=>{ + setLoading(false); + }, 1000); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: envKey + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("input", { + type: visible ? "text" : "password", + onFocus: (e)=>{ + if (e.target.type == "password") { + e.target.type = "text"; + } + setFocused(true); + setVisible(true); + }, + onBlur: (e)=>{ + window.clearTimeout(timeout); + timeout = setTimeout(()=>{ + if (e.target.type == "text") { + e.target.type = "password"; + } + setFocused(false); + setVisible(false); + }, 2000); + }, + value: value, + onChange: (e)=>{ + setValue(e.target.value); + } + }), + focused ? /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button secondary", + onClick: (e)=>{ + e.preventDefault(); + if (!visible) return; + setLoading(true); + (0,fetchApi/* default */.Z)("/api/admin/updateEnv", { + method: "post", + body: { + key: envKey, + value: value + } + }).then((res)=>{ + if (res.success) { + window.location.reload(); + } else { + window.alert(res.error); + } + }).finally(()=>{ + setTimeout(()=>{ + setLoading(false); + }, 1000); + }); + }, + children: "Update" + }) : /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "button outlined", + onClick: (e)=>{ + setVisible(!visible); + setFocused(true); + }, + children: "Reveal" + }) + ] + }) + ] + }) + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/SuEnvContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +let SuEnvContent_isMouseInLogHistory = false; +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {{ envObject: any }} props.data + */ function SuEnvContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const { envObject } = data; + const [env, setEnv] = external_react_default().useState(envObject); + const envKeys = Object.keys(env); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-2xl m-0", + children: "Environment Variables" + }), + /*#__PURE__*/ jsx_runtime_.jsx("button", { + onClick: (e)=>{ + const newEnvName = window.prompt("What is the new ENV name?"); + const newEnvValue = window.prompt("ENV Value"); + if (newEnvName && newEnvValue) { + setEnv((/** @type {any} */ prev)=>{ + const newObject = { + ...prev + }; + newObject[newEnvName] = newEnvValue; + return newObject; + }); + } + }, + children: "Add Environment Variable" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: envKeys.map((key, index)=>/*#__PURE__*/ jsx_runtime_.jsx(SuEnvCard, { + envObject: env, + envKey: key + }, index)) + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./pages/su/envar.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +const fs = __webpack_require__(7147); +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} [props.data] + */ function Console({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Console | Datasquirel"; + const pageDescription = "Databases Console"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuEnvContent, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + if (false) {} + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const env = fs.readFileSync("./.env", "utf-8"); + const envLines = env.split(/\n|\r/); + /** @type {any} */ const envObject = {}; + envLines.forEach((line)=>{ + if (!line.match(/=/)) return; + if (line.match(/^\#/)) return; + const envArray = line.split("="); + envObject[envArray[0]] = envArray[1]; + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + envObject + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5304,1503,5313], () => (__webpack_exec__(3667))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/envar.js.nft.json b/dsql-app/.local_dist/server/pages/su/envar.js.nft.json new file mode 100644 index 0000000..5dcb55f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/envar.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5304.js","../../chunks/1503.js","../../chunks/5313.js","../../../package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/error-logs.js b/dsql-app/.local_dist/server/pages/su/error-logs.js new file mode 100644 index 0000000..129be5c --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/error-logs.js @@ -0,0 +1,249 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 3753; +exports.ids = [3753]; +exports.modules = { + +/***/ 1300: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ ErrorLogs), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8282); +/* harmony import */ var _components_su_SuDashboardContent__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4187); +/* harmony import */ var _components_su_SuErrorLogsContent__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6251); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function ErrorLogs({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_SuAdminLayout__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + head: head, + user: user, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_su_SuErrorLogsContent__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, {}) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_2___default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5304,1503,5313,1336,4187,6251], () => (__webpack_exec__(1300))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/error-logs.js.nft.json b/dsql-app/.local_dist/server/pages/su/error-logs.js.nft.json new file mode 100644 index 0000000..cb38bdd --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/error-logs.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5264.js","../../chunks/6729.js","../../chunks/5304.js","../../chunks/1503.js","../../chunks/5313.js","../../chunks/1336.js","../../chunks/4187.js","../../chunks/6251.js","../../../package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/login.js b/dsql-app/.local_dist/server/pages/su/login.js new file mode 100644 index 0000000..ec9d0b6 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/login.js @@ -0,0 +1,313 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 7570; +exports.ids = [7570]; +exports.modules = { + +/***/ 4211: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Dashboard), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(968); +/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_head__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1503); +/* harmony import */ var _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6729); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {null} props.user + */ function Dashboard({ user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Super User Login | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + className: "w-full h-screen justify-center items-center", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_head__WEBPACK_IMPORTED_MODULE_2___default()), { + children: head + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "p-6 bg-slate-100 rounded w-full max-w-2xl flex flex-col items-center", + children: [ + true && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(SuInfo, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + onSubmit: (e)=>{ + e.preventDefault(); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z)("/api/admin/loginSuUser", { + method: "post", + body: { + email: formEl["email"].value, + password: formEl["password"].value, + authKey: formEl["auth-key"].value + } + }).then((res)=>{ + window.location.reload(); + }); + }, + className: "flex flex-col items-stretch gap-4 w-full", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "text", + name: "email", + id: "email", + placeholder: "Email Address" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "password", + id: "password", + placeholder: "Password" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "password", + name: "auth-key", + id: "auth-key", + placeholder: "Auth Key" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + children: "Login" + }) + ] + }) + ] + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res, true); + if (user?.id == 1 && "true") { + console.log("Admin User Detected ..."); + } + const suAdminUser = await _functions_backend_suAdminUserAuth__WEBPACK_IMPORTED_MODULE_3___default()(req); + if (suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +function SuInfo() { + return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex flex-col items-center gap-2 text-center", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "text-2xl text-center m-0", + children: "Super User Login" + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", { + children: [ + "This area is reserved only for the owner of this Admin. To login use the info in your ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: "dsql.env" + }), + " File. Use the env variables as follows. Your ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("i", { + children: "email address" + }), + " is the same address used to register the first user account" + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("ul", { + className: "p-0", + children: [ + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("li", { + children: [ + "Password:", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("i", { + className: "info small w-auto inline", + children: "dsql.env::" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: " DSQL_USER_KEY" + }) + ] + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("li", { + children: [ + "Auth Key:", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("i", { + className: "info small w-auto inline", + children: "dsql.env::" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("b", { + children: " DSQL_SPECIAL_KEY" + }) + ] + }) + ] + }) + ] + }); +} + + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [6729,5304,9395,370,1503], () => (__webpack_exec__(4211))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/login.js.nft.json b/dsql-app/.local_dist/server/pages/su/login.js.nft.json new file mode 100644 index 0000000..dea97ee --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/login.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/6729.js","../../chunks/5304.js","../../chunks/9395.js","../../chunks/370.js","../../chunks/1503.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/mysql/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users.js b/dsql-app/.local_dist/server/pages/su/users.js new file mode 100644 index 0000000..c8d5925 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users.js @@ -0,0 +1,362 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 6881; +exports.ids = [6881]; +exports.modules = { + +/***/ 2948: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ UsersPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/su/components/UserCard.jsx +var UserCard = __webpack_require__(1336); +;// CONCATENATED MODULE: ./components/su/SuUsersContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + */ function SuUsersContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "items-start justify-start p-6", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex flex-row items-center w-full gap-20 mb-6 justify-between", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Users" + }), + /*#__PURE__*/ jsx_runtime_.jsx("a", { + href: "/su/users/new", + className: "button", + children: "Add User" + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-stretch gap-10 w-full", + children: data.users.map((/** @type {import("@/package-shared/types").UserType} */ userObject, /** @type {Number} */ index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(UserCard/* default */.Z, { + userObject: userObject + }, index + 1); + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/su/users/index.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function UsersPage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuUsersContent, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const users = await DB_HANDLER_default()(`SELECT * FROM users`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + users: users.reverse() + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5304,9395,1503,5313,1336], () => (__webpack_exec__(2948))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users.js.nft.json b/dsql-app/.local_dist/server/pages/su/users.js.nft.json new file mode 100644 index 0000000..18b00de --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../webpack-runtime.js","../../chunks/4017.js","../../chunks/8313.js","../../chunks/5304.js","../../chunks/9395.js","../../chunks/1503.js","../../chunks/5313.js","../../chunks/1336.js","../../../package.json","../../../../ssl/ca-cert.pem","../../../../node_modules/serverless-mysql/package.json","../../../../node_modules/lucide-react/package.json","../../../../node_modules/@mui/material/package.json","../../../../node_modules/serverless-mysql/index.js","../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../node_modules/@mui/icons-material/package.json","../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../node_modules/next/head.js","../../../../node_modules/next/package.json","../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../node_modules/react/package.json","../../../../node_modules/react/index.js","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/react/jsx-runtime.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/react/cjs/react.production.min.js","../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../node_modules/react/cjs/react.development.js","../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../node_modules/@mui/material/node/styles/styled.js","../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/@mui/material/node/utils/index.js","../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/mysql/index.js","../../../../node_modules/@babel/runtime/package.json","../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../node_modules/@mui/system/package.json","../../../../node_modules/@mui/system/index.js","../../../../node_modules/mysql/package.json","../../../../node_modules/@mui/utils/package.json","../../../../node_modules/@mui/utils/index.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/@mui/base/package.json","../../../../node_modules/@mui/material/node/colors/common.js","../../../../node_modules/@mui/material/node/colors/red.js","../../../../node_modules/@mui/material/node/colors/purple.js","../../../../node_modules/@mui/material/node/colors/blue.js","../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../node_modules/@mui/material/node/colors/green.js","../../../../node_modules/@mui/material/node/colors/orange.js","../../../../node_modules/@mui/material/node/colors/grey.js","../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../node_modules/@mui/material/node/utils/useId.js","../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../node_modules/prop-types/package.json","../../../../node_modules/prop-types/index.js","../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../node_modules/@mui/material/utils/package.json","../../../../node_modules/@mui/base/composeClasses/package.json","../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../node_modules/clsx/package.json","../../../../node_modules/clsx/dist/clsx.js","../../../../node_modules/@mui/system/borders.js","../../../../node_modules/@mui/system/breakpoints.js","../../../../node_modules/@mui/system/compose.js","../../../../node_modules/@mui/system/display.js","../../../../node_modules/@mui/system/flexbox.js","../../../../node_modules/@mui/system/cssGrid.js","../../../../node_modules/@mui/system/palette.js","../../../../node_modules/@mui/system/positions.js","../../../../node_modules/@mui/system/sizing.js","../../../../node_modules/@mui/system/spacing.js","../../../../node_modules/@mui/system/shadows.js","../../../../node_modules/@mui/system/style.js","../../../../node_modules/@mui/system/typography.js","../../../../node_modules/@mui/system/getThemeValue.js","../../../../node_modules/@mui/system/createBox.js","../../../../node_modules/@mui/system/createStyled.js","../../../../node_modules/@mui/system/styled.js","../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../node_modules/@mui/system/createTheme/shape.js","../../../../node_modules/@mui/system/useTheme.js","../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../node_modules/@mui/system/colorManipulator.js","../../../../node_modules/@mui/system/responsivePropType.js","../../../../node_modules/@mui/system/Container/createContainer.js","../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../node_modules/@mui/system/Stack/Stack.js","../../../../node_modules/mysql/lib/Connection.js","../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../node_modules/mysql/lib/PoolCluster.js","../../../../node_modules/mysql/lib/PoolConfig.js","../../../../node_modules/mysql/lib/Pool.js","../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../node_modules/@mui/utils/deepmerge.js","../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../node_modules/@mui/utils/getDisplayName.js","../../../../node_modules/@mui/utils/refType.js","../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../node_modules/@mui/utils/isMuiElement.js","../../../../node_modules/@mui/utils/setRef.js","../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../node_modules/@mui/utils/scrollLeft.js","../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../node_modules/@mui/utils/integerPropType.js","../../../../node_modules/@mui/utils/resolveProps.js","../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../node_modules/@mui/system/createTheme/package.json","../../../../node_modules/@mui/system/Container/package.json","../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../node_modules/@mui/system/Stack/package.json","../../../../node_modules/@mui/system/cssVars/package.json","../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../node_modules/@mui/system/createTheme/index.js","../../../../node_modules/@mui/system/Container/index.js","../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../node_modules/@mui/system/Stack/index.js","../../../../node_modules/@mui/system/merge.js","../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../node_modules/@mui/system/memoize.js","../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../node_modules/@mui/system/propsToClassKey.js","../../../../node_modules/@mui/system/Box/package.json","../../../../node_modules/@mui/system/Box/index.js","../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../node_modules/@mui/utils/exactProp/package.json","../../../../node_modules/@mui/utils/exactProp/index.js","../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../node_modules/@mui/utils/capitalize/package.json","../../../../node_modules/@mui/utils/capitalize/index.js","../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../node_modules/@mui/utils/debounce/package.json","../../../../node_modules/@mui/utils/debounce/index.js","../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../node_modules/@mui/utils/useId/package.json","../../../../node_modules/@mui/utils/useId/index.js","../../../../node_modules/@mui/utils/useControlled/package.json","../../../../node_modules/@mui/utils/useControlled/index.js","../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../node_modules/mysql/lib/PoolConnection.js","../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../node_modules/mysql/lib/PoolSelector.js","../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../node_modules/@mui/styled-engine/package.json","../../../../node_modules/@mui/styled-engine/node/index.js","../../../../node_modules/@mui/system/Stack/createStack.js","../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../node_modules/react-is/package.json","../../../../node_modules/react-is/index.js","../../../../node_modules/prop-types/checkPropTypes.js","../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../node_modules/prop-types/lib/has.js","../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../node_modules/@mui/system/Container/Container.js","../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../node_modules/@mui/system/Box/Box.js","../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../node_modules/@mui/utils/useId/useId.js","../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@mui/private-theming/package.json","../../../../node_modules/@mui/private-theming/node/index.js","../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../node_modules/sqlstring/index.js","../../../../node_modules/object-assign/index.js","../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../node_modules/sqlstring/package.json","../../../../node_modules/object-assign/package.json","../../../../node_modules/@emotion/styled/package.json","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../node_modules/@emotion/react/package.json","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../node_modules/readable-stream/package.json","../../../../node_modules/readable-stream/readable.js","../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../node_modules/sqlstring/lib/SqlString.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../node_modules/@emotion/styled/base/package.json","../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../node_modules/@emotion/cache/package.json","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../node_modules/@emotion/utils/package.json","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../node_modules/@emotion/serialize/package.json","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../node_modules/hoist-non-react-statics/package.json","../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../node_modules/@emotion/weak-memoize/package.json","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../node_modules/string_decoder/package.json","../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../node_modules/process-nextick-args/package.json","../../../../node_modules/process-nextick-args/index.js","../../../../node_modules/isarray/package.json","../../../../node_modules/isarray/index.js","../../../../node_modules/inherits/package.json","../../../../node_modules/inherits/inherits.js","../../../../node_modules/util-deprecate/package.json","../../../../node_modules/util-deprecate/node.js","../../../../node_modules/core-util-is/package.json","../../../../node_modules/core-util-is/lib/util.js","../../../../node_modules/inherits/inherits_browser.js","../../../../node_modules/@emotion/sheet/package.json","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../node_modules/@emotion/memoize/package.json","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../node_modules/stylis/package.json","../../../../node_modules/stylis/dist/umd/stylis.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../node_modules/stylis/dist/umd/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../node_modules/@emotion/hash/package.json","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../node_modules/@emotion/unitless/package.json","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users/[single].js b/dsql-app/.local_dist/server/pages/su/users/[single].js new file mode 100644 index 0000000..53ad1d3 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users/[single].js @@ -0,0 +1,1421 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 4916; +exports.ids = [4916]; +exports.modules = { + +/***/ 8858: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ UsersPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/su/components/UserCard.jsx +var UserCard = __webpack_require__(1336); +// EXTERNAL MODULE: ./components/general/BackButton.jsx +var BackButton = __webpack_require__(1781); +// EXTERNAL MODULE: ./components/general/LoadingBlock.jsx +var LoadingBlock = __webpack_require__(5264); +// EXTERNAL MODULE: ./functions/frontend/fetchApi.js +var fetchApi = __webpack_require__(6729); +// EXTERNAL MODULE: external "@mui/icons-material/StyleTwoTone" +var StyleTwoTone_ = __webpack_require__(723); +var StyleTwoTone_default = /*#__PURE__*/__webpack_require__.n(StyleTwoTone_); +;// CONCATENATED MODULE: ./components/su/components/UserBackups.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {number} props.refresh + * @param {React.Dispatch>} props.setRefresh + */ function UserBackups({ user , refresh , setRefresh }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + /** @type {[ backups: string[], setBackups: React.Dispatch> ]} */ // @ts-ignore + const [backups, setBackups] = external_react_default().useState([]); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/getUserBackups", { + method: "post", + body: { + user + } + }).then((res)=>{ + setBackups(res.backups); + }); + }, [ + refresh + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "User Backups" + }), + !backups && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px", + position: "relative" + }), + backups && !backups[0] && /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: "This user has no backups" + }), + backups && backups[0] && backups.sort((a, b)=>{ + if (parseInt(a) > parseInt(b)) return -1; + return 1; + }).map((backup, index)=>{ + const backupDate = new Date(parseInt(backup)); + return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("a", { + href: `/su/users/${user.id}/${backup}`, + className: "card w-full items-center", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((StyleTwoTone_default()), { + color: "inherit", + className: "opacity-40 text-slate-500" + }), + /*#__PURE__*/ jsx_runtime_.jsx("b", { + children: "Backup:" + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: backupDate.toString() + }) + ] + }, backup); + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +// EXTERNAL MODULE: ./components/general/CodeBlock.jsx +var CodeBlock = __webpack_require__(1095); +// EXTERNAL MODULE: external "@mui/icons-material/FolderCopyTwoTone" +var FolderCopyTwoTone_ = __webpack_require__(8398); +var FolderCopyTwoTone_default = /*#__PURE__*/__webpack_require__.n(FolderCopyTwoTone_); +;// CONCATENATED MODULE: external "@mui/icons-material/InsertDriveFileTwoTone" +const InsertDriveFileTwoTone_namespaceObject = require("@mui/icons-material/InsertDriveFileTwoTone"); +var InsertDriveFileTwoTone_default = /*#__PURE__*/__webpack_require__.n(InsertDriveFileTwoTone_namespaceObject); +;// CONCATENATED MODULE: external "@mui/icons-material/KeyboardArrowDownRounded" +const KeyboardArrowDownRounded_namespaceObject = require("@mui/icons-material/KeyboardArrowDownRounded"); +var KeyboardArrowDownRounded_default = /*#__PURE__*/__webpack_require__.n(KeyboardArrowDownRounded_namespaceObject); +;// CONCATENATED MODULE: ./components/su/components/UserSingleFile.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {object} props.user + * @param {import("@/package-shared/types").UserFileObject2} props.file + * @param {import("@/package-shared/types").UserFileObject} props.activeFile + * @param {React.Dispatch>} props.setActiveFile + */ function UserSingleFile({ user , file , activeFile , setActiveFile , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "justify-start gap-4" + (activeFile?.path === `${file.root}/${file.name}` ? " dark" : " light-gray"), + onClick: (e)=>{ + (0,fetchApi/* default */.Z)("/api/admin/grabFile", { + method: "post", + body: { + user, + type: "file", + path: `${file.root}/${file.name}` + } + }).then((res)=>{ + if (res.success) { + try { + setActiveFile({ + title: file.name, + path: `${file.root}/${file.name}`, + data: JSON.stringify(JSON.parse(res.data), null, 4) + }); + } catch (error) { + setActiveFile({ + title: file.name, + path: `${file.root}/${file.name}`, + data: res.data + }); + } + } + }); + }, + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((InsertDriveFileTwoTone_default()), { + fontSize: "small", + className: "text-slate-400" + }), + file.name + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/components/UserFolder.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {object} props.user + * @param {import("@/package-shared/types").UserFileObject2} props.file + * @param {import("@/package-shared/types").UserFileObject} props.activeFile + * @param {React.Dispatch>} props.setActiveFile + */ function UserFolder({ user , file , activeFile , setActiveFile }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [files, setFiles] = external_react_default().useState(null); + const [loading, setLoading] = external_react_default().useState(false); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "flex-col w-full items-start relative", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((FolderCopyTwoTone_default()), { + fontSize: "small", + className: "text-slate-400" + }), + file.name, + /*#__PURE__*/ jsx_runtime_.jsx((KeyboardArrowDownRounded_default()), { + className: "ml-auto absolute right-2" + }) + ] + }), + file.content && /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col w-full pl-4 items-start ml-2", + style: { + borderLeft: "1px solid var(--slate-200)" + }, + children: file.content.map((nest, index)=>{ + if (nest?.type?.match(/file/i)) { + return /*#__PURE__*/ jsx_runtime_.jsx(UserSingleFile, { + user: user, + file: nest, + activeFile: activeFile, + setActiveFile: setActiveFile + }, index); + } else { + return /*#__PURE__*/ jsx_runtime_.jsx(UserFolder, { + user: user, + file: nest, + activeFile: activeFile, + setActiveFile: setActiveFile + }, index); + } + }) + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/components/UserFiles.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any[]} props.rootFilesArray + */ function UserFiles({ user , rootFilesArray }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {[ activeFile: import("@/package-shared/types").UserFileObject, setActiveFile: React.Dispatch> ]} */ // @ts-ignore + const [activeFile, setActiveFile] = external_react_default().useState(null); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "paper", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "text-lg m-0", + children: "User Files" + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full items-start max-w-7xl", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex-col items-stretch w-[40%]", + children: rootFilesArray.map((/** @type {import("@/package-shared/types").UserFileObject2} */ file, index)=>{ + if (file?.type?.match(/file/)) { + return /*#__PURE__*/ jsx_runtime_.jsx(UserSingleFile, { + user: user, + file: file, + activeFile: activeFile, + setActiveFile: setActiveFile + }, index); + } else { + return /*#__PURE__*/ jsx_runtime_.jsx(UserFolder, { + user: user, + file: file, + activeFile: activeFile, + setActiveFile: setActiveFile + }, index); + } + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "grow flex-col items-start justify-start w-[60%] h-full -mt-4", + children: activeFile && /*#__PURE__*/ jsx_runtime_.jsx(CodeBlock/* default */.Z, { + content: activeFile.data || "", + language: "javascript" + }) + }) + ] + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +// EXTERNAL MODULE: ./components/general/Breadcrumbs.jsx +var Breadcrumbs = __webpack_require__(424); +// EXTERNAL MODULE: external "@mui/material/styles" +var styles_ = __webpack_require__(8442); +// EXTERNAL MODULE: external "@mui/material/Table" +var Table_ = __webpack_require__(9181); +var Table_default = /*#__PURE__*/__webpack_require__.n(Table_); +// EXTERNAL MODULE: external "@mui/material/TableBody" +var TableBody_ = __webpack_require__(8823); +var TableBody_default = /*#__PURE__*/__webpack_require__.n(TableBody_); +// EXTERNAL MODULE: external "@mui/material/TableCell" +var TableCell_ = __webpack_require__(5612); +var TableCell_default = /*#__PURE__*/__webpack_require__.n(TableCell_); +// EXTERNAL MODULE: external "@mui/material/TableContainer" +var TableContainer_ = __webpack_require__(443); +var TableContainer_default = /*#__PURE__*/__webpack_require__.n(TableContainer_); +// EXTERNAL MODULE: external "@mui/material/TableHead" +var TableHead_ = __webpack_require__(5953); +var TableHead_default = /*#__PURE__*/__webpack_require__.n(TableHead_); +// EXTERNAL MODULE: external "@mui/material/TableRow" +var TableRow_ = __webpack_require__(4848); +var TableRow_default = /*#__PURE__*/__webpack_require__.n(TableRow_); +// EXTERNAL MODULE: external "@mui/material/Paper" +var Paper_ = __webpack_require__(1168); +var Paper_default = /*#__PURE__*/__webpack_require__.n(Paper_); +;// CONCATENATED MODULE: ./components/su/components/UserDbShellQueryResult.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ const StyledTableCell = (0,styles_.styled)((TableCell_default()))(({ theme })=>({ + [`&.${TableCell_.tableCellClasses.head}`]: { + backgroundColor: "var(--slate-800)", + color: "white" + }, + [`&.${TableCell_.tableCellClasses.body}`]: { + } + })); +/** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + * @param {import("@/package-shared/types").UserType} [props.user] + */ function UserDbShellQueryResult({ data , user }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const headers = Object.keys(data[0]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "p-4 bg-slate-200 rounded-md overflow-hidden w-full max-w-6xl", + children: /*#__PURE__*/ jsx_runtime_.jsx((TableContainer_default()), { + component: (Paper_default()), + sx: { + width: "100%" + }, + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)((Table_default()), { + sx: { + minWidth: 650 + }, + "aria-label": "simple table", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx((TableHead_default()), { + children: /*#__PURE__*/ jsx_runtime_.jsx((TableRow_default()), { + children: headers && headers[0] && headers.map((header, index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(StyledTableCell, { + align: "left", + children: header + }, index + 1); + }) + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx((TableBody_default()), { + children: data && data[0] && data.map((/** @type {any} */ dataObject, /** @type {Number} */ index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx((TableRow_default()), { + sx: { + "&:last-child td, &:last-child th": { + border: 0 + } + }, + children: headers.map((header, _index)=>{ + return /*#__PURE__*/ jsx_runtime_.jsx(StyledTableCell, { + align: "left", + children: dataObject[header] + }, _index + 1); + }) + }, index + 1); + }) + }) + ] + }) + }) + }) + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "No results" + }) + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./components/form/FormSelect.jsx +var FormSelect = __webpack_require__(4114); +;// CONCATENATED MODULE: ./components/su/components/UserDbShell.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {string[]} props.databases + */ function UserDbShell({ user , databases }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + try { + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ /** @type {React.MutableRefObject} */ const sqlEditorRef = external_react_default().useRef(); + /** @type {React.MutableRefObject} */ const editorRef = external_react_default().useRef(); + const dbRef = external_react_default().useRef(databases[0]); + const [loading, setLoading] = external_react_default().useState(false); + const [data, setData] = external_react_default().useState(false); + const [refresh, setRefresh] = external_react_default().useState(0); + const [targetDb, setTargetDb] = external_react_default().useState(databases[0]); + function runQuery() { + setLoading(true); + const query = editorRef.current ? editorRef.current.getValue() : null; + if (!query?.match(/./)) return; + const formattedQuery = query.replace(/^--.*/gm, "").replace(/\n|\r|\n\r/gm, "").replace(/ {2,}/g, " "); + (0,fetchApi/* default */.Z)("/api/admin/runUserDbQuery", { + method: "post", + body: { + database: dbRef.current, + query: formattedQuery + } + }, true).then((res)=>{ + if (res.success) { + setData(res.result); + } else if (res.msg) { + window.alert(res.msg); + } + setTimeout(()=>{ + setLoading(false); + }, 500); + }); + } + external_react_default().useEffect(()=>{ + if (!ace?.edit) { + setTimeout(()=>{ + setRefresh((prev)=>prev + 1); + }, 1000); + return; + } + const editor = ace.edit("ace-editor-wrapper"); + editor.setOptions({ + mode: "ace/mode/mysql", + theme: "ace/theme/twilight", + value: `SELECT * FROM table_name`, + placeholder: "Type an SQL query", + enableBasicAutocompletion: true, + enableLiveAutocompletion: true + }); + editor.commands.addCommand({ + name: "myCommand", + bindKey: { + win: "Ctrl-Enter", + mac: "Command-Enter" + }, + exec: function(editor) { + runQuery(); + }, + readOnly: true + }); + editorRef.current = editor; + }, [ + refresh + ]); + /** @type {[dbTables: string[], setDbTables: React.Dispatch> ]} */ // @ts-ignore + const [dbTables, setDbTables] = external_react_default().useState([]); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)(`/api/admin/getTablesForUserDatabase?database=${targetDb}`).then((res)=>{ + if (res.success) { + setDbTables(res.tables); + } + }); + }, [ + targetDb, + refresh + ]); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h3", { + className: "text-lg m-0", + children: /*#__PURE__*/ jsx_runtime_.jsx("span", { + children: "Database Shell" + }) + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: databases.map((db)=>{ + return { + payload: db, + title: db?.replace(new RegExp(`datasquirel_user_${user.id}_`), "") + }; + }), + name: "select-database", + onChangeHandler: (e)=>{ + setTargetDb(e.target.value); + dbRef.current = e.target.value; + }, + title: "Databases" + }), + targetDb && dbTables && /*#__PURE__*/ jsx_runtime_.jsx(FormSelect/* default */.Z, { + selectOptions: dbTables.map((table)=>{ + return { + payload: table, + title: table + }; + }), + name: "select-database-table", + title: "Tables" + }) + ] + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full flex-col relative", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + // @ts-ignore + ref: sqlEditorRef, + id: "ace-editor-wrapper", + style: { + height: "100px" + } + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + className: "absolute right-4 bottom-4" + (loading ? " pointer-events-none opacity-70" : ""), + onClick: (e)=>{ + runQuery(); + }, + children: [ + loading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + position: "relative", + width: "15px", + borderWidth: "3px", + style: { + backgroundColor: "transparent" + } + }), + loading ? "Running Query ..." : "Run Query" + ] + }) + ] + }), + data && !loading && /*#__PURE__*/ jsx_runtime_.jsx(UserDbShellQueryResult, { + data: data, + user: user + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + } catch (error) { + console.log(error); + return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "card", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "Shell not available at this time" + }) + }) + }); + } +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./components/su/components/UserData.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////////////// +/** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {number} props.refresh + * @param {React.Dispatch>} [props.setRefresh] + */ function UserData({ user , refresh , setRefresh }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = external_react_default().useState(false); + const [userData, setUserData] = external_react_default().useState(null); + const [userDbs, setUserDbs] = external_react_default().useState(null); + external_react_default().useEffect(()=>{ + (0,fetchApi/* default */.Z)("/api/admin/getUserData", { + method: "post", + body: { + user + } + }).then((res)=>{ + console.log(res); + if (res.success) { + setUserData(res.data); + setUserDbs(res.databases); + } + }); + }, [ + refresh + ]); + //////////////////////////////////////////////// + //////////////////////////////////////////////// + //////////////////////////////////////////////// + /** + * Function Return + * + * @description Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "paper w-full", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "User Data" + }), + userData && /*#__PURE__*/ jsx_runtime_.jsx(UserFiles, { + user: user, + rootFilesArray: userData + }), + userDbs && /*#__PURE__*/ jsx_runtime_.jsx(UserDbShell, { + user: user, + databases: userDbs + }) + ] + }); +//////////////////////////////////////////////// +//////////////////////////////////////////////// +//////////////////////////////////////////////// +} ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////////////// + +;// CONCATENATED MODULE: ./components/su/SuSingleUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + */ function SuSingleUserContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const user = data.user; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [refresh, setRefresh] = external_react_default().useState(0); + const [addBackupLoading, setAddBackupLoading] = external_react_default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + className: "w-full justify-between", + children: [ + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("div", { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx(BackButton/* default */.Z, {}), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)("h1", { + className: "text-3xl m-0", + children: [ + user.first_name, + " ", + user.last_name + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("span", { + className: "info w-auto gray font-normal", + children: user.email + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx("div", { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("button", { + onClick: (e)=>{ + if (window.confirm(`Create a new backup for ${user.first_name}?`)) { + setAddBackupLoading(true); + (0,fetchApi/* default */.Z)("/api/admin/addUserBackup", { + method: "post", + body: { + user + } + }).then((res)=>{ + console.log(res); + if (res.success) { + setRefresh((prev)=>prev + 1); + } + setTimeout(()=>{ + setAddBackupLoading(false); + }, 1000); + }); + } + }, + className: "relative", + children: [ + addBackupLoading && /*#__PURE__*/ jsx_runtime_.jsx(LoadingBlock/* default */.Z, { + width: "20px" + }), + "Backup User" + ] + }) + }) + ] + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserCard/* default */.Z, { + userObject: user, + userPage: true + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserBackups, { + user: user, + refresh: refresh, + setRefresh: setRefresh + }), + /*#__PURE__*/ jsx_runtime_.jsx(UserData, { + user: user, + refresh: refresh, + setRefresh: setRefresh + }) + ] + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +// EXTERNAL MODULE: ./package-shared/utils/backend/global-db/DB_HANDLER.js +var DB_HANDLER = __webpack_require__(9395); +var DB_HANDLER_default = /*#__PURE__*/__webpack_require__.n(DB_HANDLER); +;// CONCATENATED MODULE: ./pages/su/users/[single].jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function UsersPage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ (0,jsx_runtime_.jsxs)((external_react_default()).Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ace.min.js", + integrity: "sha512-q6CTB0jS+VuJnSct82rVcWlI06LGzNjaG3CWenHWVUncRvc4UQMFkA3a5Ip880xr+lBx38FcHDclOxPdSg+sBw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }), + /*#__PURE__*/ jsx_runtime_.jsx("script", { + src: "https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ext-language_tools.min.js", + integrity: "sha512-6g6cvocV7eT/J8L44lL8gJKqq9onqQeYGgJO0DmrsYFcCfRl6wYkYA/KHS768r4QVTB4JxsCcMQ9gIezxpTCZw==", + crossOrigin: "anonymous", + referrerPolicy: "no-referrer" + }) + ] + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuSingleUserContent, { + data: data + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const user = await DB_HANDLER_default()(`SELECT * FROM users WHERE id='${query.single}'`); + if (!user?.[0]) return { + redirect: { + destination: "/su/users", + permanent: false + } + }; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser, + data: { + user: user?.[0] || {} + } + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 3257: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ArrowBackIosRounded"); + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 6843: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ContentCopy"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 8398: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/FolderCopyTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 723: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/StyleTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 1168: +/***/ ((module) => { + +module.exports = require("@mui/material/Paper"); + +/***/ }), + +/***/ 9174: +/***/ ((module) => { + +module.exports = require("@mui/material/Snackbar"); + +/***/ }), + +/***/ 9181: +/***/ ((module) => { + +module.exports = require("@mui/material/Table"); + +/***/ }), + +/***/ 8823: +/***/ ((module) => { + +module.exports = require("@mui/material/TableBody"); + +/***/ }), + +/***/ 5612: +/***/ ((module) => { + +module.exports = require("@mui/material/TableCell"); + +/***/ }), + +/***/ 443: +/***/ ((module) => { + +module.exports = require("@mui/material/TableContainer"); + +/***/ }), + +/***/ 5953: +/***/ ((module) => { + +module.exports = require("@mui/material/TableHead"); + +/***/ }), + +/***/ 4848: +/***/ ((module) => { + +module.exports = require("@mui/material/TableRow"); + +/***/ }), + +/***/ 8442: +/***/ ((module) => { + +module.exports = require("@mui/material/styles"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5304,9395,424,1781,4114,1503,5313,1336,2434], () => (__webpack_exec__(8858))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users/[single].js.nft.json b/dsql-app/.local_dist/server/pages/su/users/[single].js.nft.json new file mode 100644 index 0000000..ed65bdc --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users/[single].js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5264.js","../../../chunks/6729.js","../../../chunks/5304.js","../../../chunks/9395.js","../../../chunks/424.js","../../../chunks/1781.js","../../../chunks/4114.js","../../../chunks/1503.js","../../../chunks/5313.js","../../../chunks/1336.js","../../../chunks/2434.js","../../../../package.json","../../../../../ssl/ca-cert.pem","../../../../../node_modules/serverless-mysql/package.json","../../../../../node_modules/react-dom/package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/@mui/material/styles/package.json","../../../../../node_modules/@mui/material/Snackbar/package.json","../../../../../node_modules/@mui/material/Paper/package.json","../../../../../node_modules/@mui/material/Table/package.json","../../../../../node_modules/@mui/material/TableBody/package.json","../../../../../node_modules/@mui/material/TableCell/package.json","../../../../../node_modules/@mui/material/TableContainer/package.json","../../../../../node_modules/@mui/material/TableHead/package.json","../../../../../node_modules/@mui/material/TableRow/package.json","../../../../../node_modules/serverless-mysql/index.js","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/react-dom/index.js","../../../../../node_modules/@mui/material/node/styles/index.js","../../../../../node_modules/@mui/material/node/Snackbar/index.js","../../../../../node_modules/@mui/material/node/Paper/index.js","../../../../../node_modules/@mui/material/node/Table/index.js","../../../../../node_modules/@mui/material/node/TableBody/index.js","../../../../../node_modules/@mui/material/node/TableCell/index.js","../../../../../node_modules/@mui/material/node/TableContainer/index.js","../../../../../node_modules/@mui/material/node/TableHead/index.js","../../../../../node_modules/@mui/material/node/TableRow/index.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../node_modules/@mui/icons-material/ContentCopy.js","../../../../../node_modules/@mui/icons-material/StyleTwoTone.js","../../../../../node_modules/@mui/icons-material/FolderCopyTwoTone.js","../../../../../node_modules/@mui/icons-material/ArrowBackIosRounded.js","../../../../../node_modules/@mui/icons-material/InsertDriveFileTwoTone.js","../../../../../node_modules/@mui/icons-material/KeyboardArrowDownRounded.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react-dom/cjs/react-dom.production.min.js","../../../../../node_modules/react-dom/cjs/react-dom.development.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/adaptV4Theme.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createStyles.js","../../../../../node_modules/@mui/material/node/styles/createMuiStrictModeTheme.js","../../../../../node_modules/@mui/material/node/styles/cssUtils.js","../../../../../node_modules/@mui/material/node/styles/responsiveFontSizes.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useTheme.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/ThemeProvider.js","../../../../../node_modules/@mui/material/node/styles/makeStyles.js","../../../../../node_modules/@mui/material/node/styles/withStyles.js","../../../../../node_modules/@mui/material/node/styles/withTheme.js","../../../../../node_modules/@mui/material/node/styles/CssVarsProvider.js","../../../../../node_modules/@mui/material/node/styles/experimental_extendTheme.js","../../../../../node_modules/@mui/material/node/styles/getOverlayAlpha.js","../../../../../node_modules/@mui/material/node/styles/shouldSkipGeneratingVar.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/material/node/styles/excludeVariablesFromRoot.js","../../../../../node_modules/@mui/material/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/material/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/material/node/Paper/Paper.js","../../../../../node_modules/@mui/material/node/Paper/paperClasses.js","../../../../../node_modules/@mui/material/node/TableCell/TableCell.js","../../../../../node_modules/@mui/material/node/TableCell/tableCellClasses.js","../../../../../node_modules/@mui/material/node/Table/Table.js","../../../../../node_modules/@mui/material/node/Table/tableClasses.js","../../../../../node_modules/@mui/material/node/TableBody/TableBody.js","../../../../../node_modules/@mui/material/node/TableBody/tableBodyClasses.js","../../../../../node_modules/@mui/material/node/TableContainer/TableContainer.js","../../../../../node_modules/@mui/material/node/TableContainer/tableContainerClasses.js","../../../../../node_modules/@mui/material/node/TableHead/TableHead.js","../../../../../node_modules/@mui/material/node/TableHead/tableHeadClasses.js","../../../../../node_modules/@mui/material/node/TableRow/TableRow.js","../../../../../node_modules/@mui/material/node/TableRow/tableRowClasses.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/Grow/index.js","../../../../../node_modules/@mui/material/node/SnackbarContent/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@mui/material/node/Table/TableContext.js","../../../../../node_modules/@mui/material/node/Table/Tablelvl2Context.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/mysql/index.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/mysql/package.json","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/base/node/index.js","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/Grow/Grow.js","../../../../../node_modules/@mui/material/node/SnackbarContent/SnackbarContent.js","../../../../../node_modules/@mui/material/node/SnackbarContent/snackbarContentClasses.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/scheduler/package.json","../../../../../node_modules/scheduler/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/@mui/base/useSnackbar/package.json","../../../../../node_modules/@mui/base/node/useSnackbar/index.js","../../../../../node_modules/@mui/base/ClickAwayListener/package.json","../../../../../node_modules/@mui/base/node/ClickAwayListener/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/mysql/lib/Connection.js","../../../../../node_modules/mysql/lib/ConnectionConfig.js","../../../../../node_modules/mysql/lib/PoolCluster.js","../../../../../node_modules/mysql/lib/PoolConfig.js","../../../../../node_modules/mysql/lib/Pool.js","../../../../../node_modules/mysql/lib/protocol/SqlString.js","../../../../../node_modules/mysql/lib/protocol/constants/types.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/scheduler/cjs/scheduler.production.min.js","../../../../../node_modules/scheduler/cjs/scheduler.development.js","../../../../../node_modules/@mui/material/node/transitions/utils.js","../../../../../node_modules/@mui/base/node/unstable_useModal/index.js","../../../../../node_modules/@mui/base/node/NoSsr/index.js","../../../../../node_modules/@mui/base/node/Portal/index.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/index.js","../../../../../node_modules/@mui/base/node/FocusTrap/index.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.js","../../../../../node_modules/@mui/base/node/useSnackbar/useSnackbar.types.js","../../../../../node_modules/@mui/base/node/ClickAwayListener/ClickAwayListener.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/@mui/base/node/utils/index.js","../../../../../node_modules/@mui/base/node/Badge/index.js","../../../../../node_modules/@mui/base/node/Button/index.js","../../../../../node_modules/@mui/base/node/Dropdown/index.js","../../../../../node_modules/@mui/base/node/FormControl/index.js","../../../../../node_modules/@mui/base/node/Input/index.js","../../../../../node_modules/@mui/base/node/Menu/index.js","../../../../../node_modules/@mui/base/node/MenuButton/index.js","../../../../../node_modules/@mui/base/node/MenuItem/index.js","../../../../../node_modules/@mui/base/node/Modal/index.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/index.js","../../../../../node_modules/@mui/base/node/OptionGroup/index.js","../../../../../node_modules/@mui/base/node/Option/index.js","../../../../../node_modules/@mui/base/node/Popper/index.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/index.js","../../../../../node_modules/@mui/base/node/Select/index.js","../../../../../node_modules/@mui/base/node/Slider/index.js","../../../../../node_modules/@mui/base/node/Snackbar/index.js","../../../../../node_modules/@mui/base/node/Switch/index.js","../../../../../node_modules/@mui/base/node/TablePagination/index.js","../../../../../node_modules/@mui/base/node/TabPanel/index.js","../../../../../node_modules/@mui/base/node/TabsList/index.js","../../../../../node_modules/@mui/base/node/Tabs/index.js","../../../../../node_modules/@mui/base/node/Tab/index.js","../../../../../node_modules/@mui/base/node/Transitions/index.js","../../../../../node_modules/@mui/base/node/useAutocomplete/index.js","../../../../../node_modules/@mui/base/node/useBadge/index.js","../../../../../node_modules/@mui/base/node/useButton/index.js","../../../../../node_modules/@mui/base/node/useDropdown/index.js","../../../../../node_modules/@mui/base/node/useInput/index.js","../../../../../node_modules/@mui/base/node/useMenu/index.js","../../../../../node_modules/@mui/base/node/useMenuButton/index.js","../../../../../node_modules/@mui/base/node/useMenuItem/index.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/index.js","../../../../../node_modules/@mui/base/node/useOption/index.js","../../../../../node_modules/@mui/base/node/useSelect/index.js","../../../../../node_modules/@mui/base/node/useSlider/index.js","../../../../../node_modules/@mui/base/node/useSwitch/index.js","../../../../../node_modules/@mui/base/node/useTab/index.js","../../../../../node_modules/@mui/base/node/useTabPanel/index.js","../../../../../node_modules/@mui/base/node/useTabs/index.js","../../../../../node_modules/@mui/base/node/useTabsList/index.js","../../../../../node_modules/mysql/lib/protocol/Protocol.js","../../../../../node_modules/mysql/lib/PoolConnection.js","../../../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../../../node_modules/mysql/lib/protocol/constants/client.js","../../../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../../../node_modules/mysql/lib/PoolNamespace.js","../../../../../node_modules/mysql/lib/PoolSelector.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/react-transition-group/package.json","../../../../../node_modules/react-transition-group/cjs/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.js","../../../../../node_modules/@mui/base/node/NoSsr/NoSsr.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.js","../../../../../node_modules/@mui/base/node/unstable_useModal/useModal.types.js","../../../../../node_modules/@mui/base/node/unstable_useModal/ModalManager.js","../../../../../node_modules/@mui/base/node/Portal/Portal.js","../../../../../node_modules/@mui/base/node/Portal/Portal.types.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.js","../../../../../node_modules/@mui/base/node/TextareaAutosize/TextareaAutosize.types.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.js","../../../../../node_modules/@mui/base/node/FocusTrap/FocusTrap.types.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/base/node/utils/extractEventHandlers.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/mysql/lib/protocol/Parser.js","../../../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/base/node/utils/appendOwnerState.js","../../../../../node_modules/@mui/base/node/utils/ClassNameConfigurator.js","../../../../../node_modules/@mui/base/node/utils/areArraysEqual.js","../../../../../node_modules/@mui/base/node/utils/isHostComponent.js","../../../../../node_modules/@mui/base/node/utils/resolveComponentProps.js","../../../../../node_modules/@mui/base/node/utils/useSlotProps.js","../../../../../node_modules/@mui/base/node/utils/mergeSlotProps.js","../../../../../node_modules/@mui/base/node/utils/prepareForSlot.js","../../../../../node_modules/@mui/base/node/utils/PolymorphicComponent.js","../../../../../node_modules/@mui/base/node/utils/types.js","../../../../../node_modules/@mui/base/node/Badge/Badge.js","../../../../../node_modules/@mui/base/node/Badge/Badge.types.js","../../../../../node_modules/@mui/base/node/Badge/badgeClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.js","../../../../../node_modules/@mui/base/node/Button/buttonClasses.js","../../../../../node_modules/@mui/base/node/Button/Button.types.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.js","../../../../../node_modules/@mui/base/node/Dropdown/Dropdown.types.js","../../../../../node_modules/@mui/base/node/FormControl/FormControl.js","../../../../../node_modules/@mui/base/node/FormControl/FormControlContext.js","../../../../../node_modules/@mui/base/node/FormControl/formControlClasses.js","../../../../../node_modules/@mui/base/node/FormControl/useFormControlContext.js","../../../../../node_modules/@mui/base/node/Input/Input.js","../../../../../node_modules/@mui/base/node/Input/Input.types.js","../../../../../node_modules/@mui/base/node/Input/inputClasses.js","../../../../../node_modules/@mui/base/node/Menu/Menu.js","../../../../../node_modules/@mui/base/node/Menu/Menu.types.js","../../../../../node_modules/@mui/base/node/Menu/menuClasses.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.js","../../../../../node_modules/@mui/base/node/MenuButton/MenuButton.types.js","../../../../../node_modules/@mui/base/node/MenuButton/menuButtonClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.js","../../../../../node_modules/@mui/base/node/MenuItem/menuItemClasses.js","../../../../../node_modules/@mui/base/node/MenuItem/MenuItem.types.js","../../../../../node_modules/@mui/base/node/Modal/Modal.js","../../../../../node_modules/@mui/base/node/Modal/Modal.types.js","../../../../../node_modules/@mui/base/node/Modal/modalClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/numberInputClasses.js","../../../../../node_modules/@mui/base/node/Unstable_NumberInput/NumberInput.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.js","../../../../../node_modules/@mui/base/node/OptionGroup/OptionGroup.types.js","../../../../../node_modules/@mui/base/node/OptionGroup/optionGroupClasses.js","../../../../../node_modules/@mui/base/node/Option/Option.js","../../../../../node_modules/@mui/base/node/Option/Option.types.js","../../../../../node_modules/@mui/base/node/Option/optionClasses.js","../../../../../node_modules/@mui/base/node/Popper/Popper.js","../../../../../node_modules/@mui/base/node/Popper/popperClasses.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/Popup.types.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/popupClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.js","../../../../../node_modules/@mui/base/node/Select/selectClasses.js","../../../../../node_modules/@mui/base/node/Select/Select.types.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.js","../../../../../node_modules/@mui/base/node/Snackbar/Snackbar.types.js","../../../../../node_modules/@mui/base/node/Snackbar/snackbarClasses.js","../../../../../node_modules/@mui/base/node/Slider/Slider.js","../../../../../node_modules/@mui/base/node/Slider/Slider.types.js","../../../../../node_modules/@mui/base/node/Slider/sliderClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.js","../../../../../node_modules/@mui/base/node/Switch/switchClasses.js","../../../../../node_modules/@mui/base/node/Switch/Switch.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePagination.types.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.js","../../../../../node_modules/@mui/base/node/TablePagination/TablePaginationActions.types.js","../../../../../node_modules/@mui/base/node/TablePagination/tablePaginationClasses.js","../../../../../node_modules/@mui/base/node/TablePagination/common.types.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.js","../../../../../node_modules/@mui/base/node/TabsList/TabsList.types.js","../../../../../node_modules/@mui/base/node/TabsList/tabsListClasses.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.js","../../../../../node_modules/@mui/base/node/Tabs/tabsClasses.js","../../../../../node_modules/@mui/base/node/Tabs/TabsContext.js","../../../../../node_modules/@mui/base/node/Tabs/Tabs.types.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.js","../../../../../node_modules/@mui/base/node/TabPanel/TabPanel.types.js","../../../../../node_modules/@mui/base/node/TabPanel/tabPanelClasses.js","../../../../../node_modules/@mui/base/node/Transitions/CssAnimation.js","../../../../../node_modules/@mui/base/node/Transitions/CssTransition.js","../../../../../node_modules/@mui/base/node/Tab/Tab.js","../../../../../node_modules/@mui/base/node/Tab/Tab.types.js","../../../../../node_modules/@mui/base/node/Tab/tabClasses.js","../../../../../node_modules/@mui/base/node/useAutocomplete/useAutocomplete.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.js","../../../../../node_modules/@mui/base/node/useBadge/useBadge.types.js","../../../../../node_modules/@mui/base/node/useButton/useButton.js","../../../../../node_modules/@mui/base/node/useButton/useButton.types.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.js","../../../../../node_modules/@mui/base/node/useDropdown/useDropdown.types.js","../../../../../node_modules/@mui/base/node/useDropdown/DropdownContext.js","../../../../../node_modules/@mui/base/node/useInput/useInput.js","../../../../../node_modules/@mui/base/node/useInput/useInput.types.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.js","../../../../../node_modules/@mui/base/node/useMenu/useMenu.types.js","../../../../../node_modules/@mui/base/node/useMenu/MenuProvider.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.js","../../../../../node_modules/@mui/base/node/useMenuButton/useMenuButton.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItem.types.js","../../../../../node_modules/@mui/base/node/useMenuItem/useMenuItemContextStabilizer.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/useNumberInput.types.js","../../../../../node_modules/@mui/base/node/useOption/useOption.js","../../../../../node_modules/@mui/base/node/useOption/useOption.types.js","../../../../../node_modules/@mui/base/node/useOption/useOptionContextStabilizer.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.js","../../../../../node_modules/@mui/base/node/useSelect/SelectProvider.js","../../../../../node_modules/@mui/base/node/useSelect/useSelect.types.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.js","../../../../../node_modules/@mui/base/node/useSlider/useSlider.types.js","../../../../../node_modules/@mui/base/node/useTab/useTab.js","../../../../../node_modules/@mui/base/node/useTab/useTab.types.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.js","../../../../../node_modules/@mui/base/node/useSwitch/useSwitch.types.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.js","../../../../../node_modules/@mui/base/node/useTabPanel/useTabPanel.types.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.js","../../../../../node_modules/@mui/base/node/useTabs/useTabs.types.js","../../../../../node_modules/@mui/base/node/useTabs/TabsProvider.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.js","../../../../../node_modules/@mui/base/node/useTabsList/useTabsList.types.js","../../../../../node_modules/@mui/base/node/useTabsList/TabsListProvider.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../../../node_modules/react-transition-group/cjs/CSSTransition.js","../../../../../node_modules/react-transition-group/cjs/ReplaceTransition.js","../../../../../node_modules/react-transition-group/cjs/SwitchTransition.js","../../../../../node_modules/react-transition-group/cjs/TransitionGroup.js","../../../../../node_modules/react-transition-group/cjs/Transition.js","../../../../../node_modules/react-transition-group/cjs/config.js","../../../../../node_modules/mysql/lib/protocol/packets/index.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../../../node_modules/mysql/lib/protocol/BufferList.js","../../../../../node_modules/@mui/base/node/utils/omitEventHandlers.js","../../../../../node_modules/@mui/base/node/Unstable_Popup/PopupContext.js","../../../../../node_modules/@mui/base/node/useSelect/defaultOptionStringifier.js","../../../../../node_modules/@mui/base/node/utils/useControllableReducer.js","../../../../../node_modules/@mui/base/node/useDropdown/dropdownReducer.js","../../../../../node_modules/@mui/base/node/useMenu/menuReducer.js","../../../../../node_modules/@mui/base/node/utils/combineHooksSlotProps.js","../../../../../node_modules/@mui/base/node/useList/ListContext.js","../../../../../node_modules/@mui/base/node/unstable_useNumberInput/utils.js","../../../../../node_modules/@mui/base/node/useSelect/selectReducer.js","../../../../../node_modules/@mui/base/node/useTabsList/tabsListReducer.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../../../node_modules/mysql/lib/protocol/Timer.js","../../../../../node_modules/sqlstring/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../../../node_modules/sqlstring/package.json","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/react-transition-group/cjs/TransitionGroupContext.js","../../../../../node_modules/react-transition-group/cjs/utils/PropTypes.js","../../../../../node_modules/react-transition-group/cjs/utils/reflow.js","../../../../../node_modules/react-transition-group/cjs/utils/ChildMapping.js","../../../../../node_modules/@mui/base/node/generateUtilityClass/index.js","../../../../../node_modules/@mui/base/node/generateUtilityClasses/index.js","../../../../../node_modules/@mui/base/node/useList/index.js","../../../../../node_modules/@mui/base/node/useTransition/index.js","../../../../../node_modules/@mui/base/node/useCompound/index.js","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../../../node_modules/readable-stream/package.json","../../../../../node_modules/readable-stream/readable.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../../../node_modules/@floating-ui/react-dom/package.json","../../../../../node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.umd.js","../../../../../node_modules/@popperjs/core/package.json","../../../../../node_modules/@popperjs/core/dist/cjs/popper.js","../../../../../node_modules/mysql/lib/protocol/Auth.js","../../../../../node_modules/sqlstring/lib/SqlString.js","../../../../../node_modules/@mui/base/node/useList/useList.js","../../../../../node_modules/@mui/base/node/useList/useList.types.js","../../../../../node_modules/@mui/base/node/useList/useListItem.js","../../../../../node_modules/@mui/base/node/useList/useListItem.types.js","../../../../../node_modules/@mui/base/node/useList/listReducer.js","../../../../../node_modules/@mui/base/node/useList/listActions.types.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionStateManager.js","../../../../../node_modules/@mui/base/node/useTransition/useTransitionTrigger.js","../../../../../node_modules/@mui/base/node/useTransition/TransitionContext.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundParent.js","../../../../../node_modules/@mui/base/node/useCompound/useCompoundItem.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/readable-stream/lib/_stream_readable.js","../../../../../node_modules/readable-stream/lib/_stream_writable.js","../../../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../../../node_modules/readable-stream/lib/_stream_transform.js","../../../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/dom-helpers/addClass/package.json","../../../../../node_modules/dom-helpers/cjs/addClass.js","../../../../../node_modules/dom-helpers/removeClass/package.json","../../../../../node_modules/dom-helpers/cjs/removeClass.js","../../../../../node_modules/@mui/base/node/utils/useTextNavigation.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/dom-helpers/package.json","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../../../node_modules/dom-helpers/cjs/hasClass.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@floating-ui/dom/package.json","../../../../../node_modules/@floating-ui/dom/dist/floating-ui.dom.umd.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../../../node_modules/string_decoder/package.json","../../../../../node_modules/string_decoder/lib/string_decoder.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/process-nextick-args/package.json","../../../../../node_modules/process-nextick-args/index.js","../../../../../node_modules/isarray/package.json","../../../../../node_modules/isarray/index.js","../../../../../node_modules/inherits/package.json","../../../../../node_modules/inherits/inherits.js","../../../../../node_modules/util-deprecate/package.json","../../../../../node_modules/util-deprecate/node.js","../../../../../node_modules/core-util-is/package.json","../../../../../node_modules/core-util-is/lib/util.js","../../../../../node_modules/inherits/inherits_browser.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/@floating-ui/core/package.json","../../../../../node_modules/@floating-ui/core/dist/floating-ui.core.umd.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users/new.js b/dsql-app/.local_dist/server/pages/su/users/new.js new file mode 100644 index 0000000..5a37aca --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users/new.js @@ -0,0 +1,315 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 8021; +exports.ids = [8021]; +exports.modules = { + +/***/ 5740: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +// ESM COMPAT FLAG +__webpack_require__.r(__webpack_exports__); + +// EXPORTS +__webpack_require__.d(__webpack_exports__, { + "default": () => (/* binding */ UsersPage), + "getServerSideProps": () => (/* binding */ getServerSideProps) +}); + +// EXTERNAL MODULE: external "react/jsx-runtime" +var jsx_runtime_ = __webpack_require__(997); +// EXTERNAL MODULE: external "react" +var external_react_ = __webpack_require__(6689); +var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_); +// EXTERNAL MODULE: ./functions/backend/suAdminUserAuth.js +var suAdminUserAuth = __webpack_require__(1503); +var suAdminUserAuth_default = /*#__PURE__*/__webpack_require__.n(suAdminUserAuth); +// EXTERNAL MODULE: ./layouts/SuAdminLayout.jsx + 2 modules +var SuAdminLayout = __webpack_require__(8282); +// EXTERNAL MODULE: ./components/su/components/UserCard.jsx +var UserCard = __webpack_require__(1336); +;// CONCATENATED MODULE: ./components/su/SuNewUserContent.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {any} props.data + */ function SuNewUserContent({ data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx((external_react_default()).Fragment, { + children: /*#__PURE__*/ (0,jsx_runtime_.jsxs)("section", { + className: "items-start justify-start p-6", + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("div", { + className: "flex flex-row items-center w-full gap-20 mb-6 justify-between", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-xl m-0", + children: "New User" + }) + }), + /*#__PURE__*/ jsx_runtime_.jsx("section", { + className: "paper", + children: /*#__PURE__*/ jsx_runtime_.jsx("h2", { + className: "text-base m-0", + children: "Info" + }) + }) + ] + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ + +;// CONCATENATED MODULE: ./pages/su/users/new.jsx +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType} props.user + * @param {any} props.data + */ function UsersPage({ user , data }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "User Dashboard | Datasquirel"; + const pageDescription = "Welcome to your data app"; + let head = /*#__PURE__*/ (0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, { + children: [ + /*#__PURE__*/ jsx_runtime_.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ jsx_runtime_.jsx("meta", { + name: "description", + content: pageDescription + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ jsx_runtime_.jsx(SuAdminLayout/* default */.Z, { + head: head, + user: user, + children: /*#__PURE__*/ jsx_runtime_.jsx(SuNewUserContent, { + data: data + }) + }); +} +/** + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + /** + * User Auth + * + * @description User Auth + */ const suAdminUser = await suAdminUserAuth_default()(req); + if (!suAdminUser?.logged_in_status) { + return { + redirect: { + destination: `/su/login`, + permanent: false + } + }; + } + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: suAdminUser + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 9318: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/BackupTwoTone"); + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 6817: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/DocumentScannerTwoTone"); + +/***/ }), + +/***/ 6094: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/ErrorTwoTone"); + +/***/ }), + +/***/ 6547: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/LockPersonTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 8245: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/PeopleAltTwoTone"); + +/***/ }), + +/***/ 415: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/TerminalTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../../../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5304,1503,5313,1336], () => (__webpack_exec__(5740))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/su/users/new.js.nft.json b/dsql-app/.local_dist/server/pages/su/users/new.js.nft.json new file mode 100644 index 0000000..71d009f --- /dev/null +++ b/dsql-app/.local_dist/server/pages/su/users/new.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../../../webpack-runtime.js","../../../chunks/4017.js","../../../chunks/8313.js","../../../chunks/5304.js","../../../chunks/1503.js","../../../chunks/5313.js","../../../chunks/1336.js","../../../../package.json","../../../../../node_modules/lucide-react/package.json","../../../../../node_modules/@mui/material/package.json","../../../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../../../node_modules/@mui/icons-material/package.json","../../../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../../../node_modules/next/head.js","../../../../../node_modules/next/package.json","../../../../../node_modules/@mui/icons-material/BackupTwoTone.js","../../../../../node_modules/@mui/icons-material/DocumentScannerTwoTone.js","../../../../../node_modules/@mui/icons-material/ErrorTwoTone.js","../../../../../node_modules/@mui/icons-material/LockPersonTwoTone.js","../../../../../node_modules/@mui/icons-material/PeopleAltTwoTone.js","../../../../../node_modules/@mui/icons-material/TerminalTwoTone.js","../../../../../node_modules/react/package.json","../../../../../node_modules/react/index.js","../../../../../node_modules/next/dist/shared/lib/head.js","../../../../../node_modules/react/jsx-runtime.js","../../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../../node_modules/react/cjs/react.production.min.js","../../../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../../../node_modules/react/cjs/react.development.js","../../../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../../../node_modules/@mui/material/node/styles/identifier.js","../../../../../node_modules/@mui/material/node/styles/createTheme.js","../../../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../../../node_modules/@mui/material/node/styles/styled.js","../../../../../node_modules/@mui/material/node/styles/createTypography.js","../../../../../node_modules/@mui/material/node/styles/createMixins.js","../../../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../../node_modules/next/dist/shared/lib/utils.js","../../../../../node_modules/@mui/material/node/utils/index.js","../../../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../../../node_modules/@mui/material/node/styles/createPalette.js","../../../../../node_modules/@mui/material/node/styles/shadows.js","../../../../../node_modules/@mui/material/node/styles/zIndex.js","../../../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../../../node_modules/@mui/material/node/utils/capitalize.js","../../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../../node_modules/@swc/helpers/package.json","../../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../../node_modules/@babel/runtime/package.json","../../../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../../../node_modules/@babel/runtime/helpers/extends.js","../../../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../../../node_modules/@mui/system/package.json","../../../../../node_modules/@mui/system/index.js","../../../../../node_modules/@mui/utils/package.json","../../../../../node_modules/@mui/utils/index.js","../../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../../node_modules/@mui/base/package.json","../../../../../node_modules/@mui/material/node/colors/common.js","../../../../../node_modules/@mui/material/node/colors/red.js","../../../../../node_modules/@mui/material/node/colors/purple.js","../../../../../node_modules/@mui/material/node/colors/blue.js","../../../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../../../node_modules/@mui/material/node/colors/green.js","../../../../../node_modules/@mui/material/node/colors/orange.js","../../../../../node_modules/@mui/material/node/colors/grey.js","../../../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../../../node_modules/@mui/material/node/utils/debounce.js","../../../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../../../node_modules/@mui/material/node/utils/setRef.js","../../../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../../../node_modules/@mui/material/node/utils/useId.js","../../../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../../../node_modules/@mui/material/node/utils/useControlled.js","../../../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../../../node_modules/prop-types/package.json","../../../../../node_modules/prop-types/index.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../../../node_modules/@mui/material/utils/package.json","../../../../../node_modules/@mui/base/composeClasses/package.json","../../../../../node_modules/@mui/base/node/composeClasses/index.js","../../../../../node_modules/clsx/package.json","../../../../../node_modules/clsx/dist/clsx.js","../../../../../node_modules/@mui/system/borders.js","../../../../../node_modules/@mui/system/breakpoints.js","../../../../../node_modules/@mui/system/compose.js","../../../../../node_modules/@mui/system/display.js","../../../../../node_modules/@mui/system/flexbox.js","../../../../../node_modules/@mui/system/cssGrid.js","../../../../../node_modules/@mui/system/palette.js","../../../../../node_modules/@mui/system/positions.js","../../../../../node_modules/@mui/system/sizing.js","../../../../../node_modules/@mui/system/spacing.js","../../../../../node_modules/@mui/system/shadows.js","../../../../../node_modules/@mui/system/style.js","../../../../../node_modules/@mui/system/typography.js","../../../../../node_modules/@mui/system/getThemeValue.js","../../../../../node_modules/@mui/system/createBox.js","../../../../../node_modules/@mui/system/createStyled.js","../../../../../node_modules/@mui/system/styled.js","../../../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../../../node_modules/@mui/system/createTheme/shape.js","../../../../../node_modules/@mui/system/useTheme.js","../../../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../../../node_modules/@mui/system/colorManipulator.js","../../../../../node_modules/@mui/system/responsivePropType.js","../../../../../node_modules/@mui/system/Container/createContainer.js","../../../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../../../node_modules/@mui/system/Stack/Stack.js","../../../../../node_modules/@mui/utils/deepmerge.js","../../../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../../../node_modules/@mui/utils/getDisplayName.js","../../../../../node_modules/@mui/utils/refType.js","../../../../../node_modules/@mui/utils/createChainedFunction.js","../../../../../node_modules/@mui/utils/deprecatedPropType.js","../../../../../node_modules/@mui/utils/isMuiElement.js","../../../../../node_modules/@mui/utils/setRef.js","../../../../../node_modules/@mui/utils/requirePropFactory.js","../../../../../node_modules/@mui/utils/unsupportedProp.js","../../../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../../../node_modules/@mui/utils/getScrollbarSize.js","../../../../../node_modules/@mui/utils/scrollLeft.js","../../../../../node_modules/@mui/utils/getValidReactChildren.js","../../../../../node_modules/@mui/utils/usePreviousProps.js","../../../../../node_modules/@mui/utils/visuallyHidden.js","../../../../../node_modules/@mui/utils/integerPropType.js","../../../../../node_modules/@mui/utils/resolveProps.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../../../node_modules/@mui/system/createTheme/package.json","../../../../../node_modules/@mui/system/Container/package.json","../../../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../../../node_modules/@mui/system/Stack/package.json","../../../../../node_modules/@mui/system/cssVars/package.json","../../../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../../../node_modules/@mui/system/createTheme/index.js","../../../../../node_modules/@mui/system/Container/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../../../node_modules/@mui/system/Stack/index.js","../../../../../node_modules/@mui/system/merge.js","../../../../../node_modules/@mui/system/GlobalStyles/package.json","../../../../../node_modules/@mui/system/GlobalStyles/index.js","../../../../../node_modules/@mui/system/memoize.js","../../../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../../../node_modules/@mui/system/propsToClassKey.js","../../../../../node_modules/@mui/system/Box/package.json","../../../../../node_modules/@mui/system/Box/index.js","../../../../../node_modules/@mui/system/useThemeProps/package.json","../../../../../node_modules/@mui/system/useThemeProps/index.js","../../../../../node_modules/@mui/system/ThemeProvider/package.json","../../../../../node_modules/@mui/system/ThemeProvider/index.js","../../../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../../../node_modules/@mui/utils/exactProp/package.json","../../../../../node_modules/@mui/utils/exactProp/index.js","../../../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../../../node_modules/@mui/utils/capitalize/package.json","../../../../../node_modules/@mui/utils/capitalize/index.js","../../../../../node_modules/@mui/utils/ownerDocument/package.json","../../../../../node_modules/@mui/utils/ownerDocument/index.js","../../../../../node_modules/@mui/utils/debounce/package.json","../../../../../node_modules/@mui/utils/debounce/index.js","../../../../../node_modules/@mui/utils/ownerWindow/package.json","../../../../../node_modules/@mui/utils/ownerWindow/index.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../../../node_modules/@mui/utils/useId/package.json","../../../../../node_modules/@mui/utils/useId/index.js","../../../../../node_modules/@mui/utils/useControlled/package.json","../../../../../node_modules/@mui/utils/useControlled/index.js","../../../../../node_modules/@mui/utils/useEventCallback/package.json","../../../../../node_modules/@mui/utils/useEventCallback/index.js","../../../../../node_modules/@mui/utils/useForkRef/package.json","../../../../../node_modules/@mui/utils/useForkRef/index.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../../../node_modules/@mui/utils/composeClasses/package.json","../../../../../node_modules/@mui/utils/composeClasses/index.js","../../../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../../../node_modules/@mui/styled-engine/package.json","../../../../../node_modules/@mui/styled-engine/node/index.js","../../../../../node_modules/@mui/system/Stack/createStack.js","../../../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../../../node_modules/react-is/package.json","../../../../../node_modules/react-is/index.js","../../../../../node_modules/prop-types/checkPropTypes.js","../../../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../../../node_modules/prop-types/lib/has.js","../../../../../node_modules/@mui/system/createTheme/createTheme.js","../../../../../node_modules/@mui/system/Container/Container.js","../../../../../node_modules/@mui/system/Container/containerClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../../../node_modules/@mui/system/Stack/StackProps.js","../../../../../node_modules/@mui/system/Stack/stackClasses.js","../../../../../node_modules/prop-types/node_modules/react-is/package.json","../../../../../node_modules/prop-types/node_modules/react-is/index.js","../../../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../../../node_modules/@mui/system/Box/Box.js","../../../../../node_modules/@mui/system/Box/boxClasses.js","../../../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../../../node_modules/@mui/utils/debounce/debounce.js","../../../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../../../node_modules/@mui/utils/useId/useId.js","../../../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../../../node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@mui/private-theming/package.json","../../../../../node_modules/@mui/private-theming/node/index.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../../../node_modules/object-assign/index.js","../../../../../node_modules/object-assign/package.json","../../../../../node_modules/@emotion/styled/package.json","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../../../node_modules/@emotion/react/package.json","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../../../node_modules/@emotion/styled/base/package.json","../../../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../../../node_modules/@emotion/cache/package.json","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../../../node_modules/@emotion/is-prop-valid/package.json","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../../../node_modules/@emotion/utils/package.json","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../../../node_modules/@emotion/serialize/package.json","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../../../node_modules/hoist-non-react-statics/package.json","../../../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../../../node_modules/@emotion/weak-memoize/package.json","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../../../node_modules/@emotion/sheet/package.json","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../../../node_modules/@emotion/memoize/package.json","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../../../node_modules/stylis/package.json","../../../../../node_modules/stylis/dist/umd/stylis.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../../../node_modules/stylis/dist/umd/package.json","../../../../../node_modules/@emotion/hash/package.json","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../../../node_modules/@emotion/unitless/package.json","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/terms.html b/dsql-app/.local_dist/server/pages/terms.html new file mode 100644 index 0000000..979a671 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/terms.html @@ -0,0 +1 @@ +Terms and Conditions | Datasquirel

Terms and Conditions

Welcome to datasquirel.com!
Dotted image background

These terms and conditions outline the rules and regulations for the use of Datasquirel's Website, located at https://datasquirel.com.

By accessing this website we assume you accept these terms and conditions. Do not continue to use datasquirel.com if you do not agree to take all of the terms and conditions stated on this page.

The following terminology applies to these Terms and Conditions, Privacy Statement and Disclaimer Notice and all Agreements: "Client", "You" and "Your" refers to you, the person log on this website and compliant to the Company’s terms and conditions. "The Company", "Ourselves", "We", "Our" and "Us", refers to our Company. "Party", "Parties", or "Us", refers to both the Client and ourselves. All terms refer to the offer, acceptance and consideration of payment necessary to undertake the process of our assistance to the Client in the most appropriate manner for the express purpose of meeting the Client’s needs in respect of provision of the Company’s stated services, in accordance with and subject to, prevailing law of Netherlands. Any use of the above terminology or other words in the singular, plural, capitalization and/or he/she or they, are taken as interchangeable and therefore as referring to same.

Cookies

We employ the use of cookies. By accessing datasquirel.com, you agreed to use cookies in agreement with the Datasquirel's Privacy Policy.

Most interactive websites use cookies to let us retrieve the user’s details for each visit. Cookies are used by our website to enable the functionality of certain areas to make it easier for people visiting our website. Some of our affiliate/advertising partners may also use cookies.

License

Unless otherwise stated, Datasquirel and/or its licensors own the intellectual property rights for all material on datasquirel.com. All intellectual property rights are reserved. You may access this from datasquirel.com for your own personal use subjected to restrictions set in these terms and conditions.

You must not:

  • Republish material from datasquirel.com
  • Sell, rent or sub-license material from datasquirel.com
  • Reproduce, duplicate or copy material from datasquirel.com
  • Redistribute content from datasquirel.com

This Agreement shall begin on the date hereof.

Parts of this website offer an opportunity for users to post and exchange opinions and information in certain areas of the website. Datasquirel does not filter, edit, publish or review Comments prior to their presence on the website. Comments do not reflect the views and opinions of Datasquirel,its agents and/or affiliates. Comments reflect the views and opinions of the person who post their views and opinions. To the extent permitted by applicable laws, Datasquirel shall not be liable for the Comments or for any liability, damages or expenses caused and/or suffered as a result of any use of and/or posting of and/or appearance of the Comments on this website.

Datasquirel reserves the right to monitor all Comments and to remove any Comments which can be considered inappropriate, offensive or causes breach of these Terms and Conditions.

You warrant and represent that:

  • You are entitled to post the Comments on our website and have all necessary licenses and consents to do so;
  • The Comments do not invade any intellectual property right, including without limitation copyright, patent or trademark of any third party;
  • The Comments do not contain any defamatory, libelous, offensive, indecent or otherwise unlawful material which is an invasion of privacy
  • The Comments will not be used to solicit or promote business or custom or present commercial activities or unlawful activity.

You hereby grant Datasquirel a non-exclusive license to use, reproduce, edit and authorize others to use, reproduce and edit any of your Comments in any and all forms, formats or media.

Hyperlinking to our Content

The following organizations may link to our Website without prior written approval:

  • Government agencies;
  • Search engines;
  • News organizations;
  • Online directory distributors may link to our Website in the same manner as they hyperlink to the Websites of other listed businesses; and
  • System wide Accredited Businesses except soliciting non-profit organizations, charity shopping malls, and charity fundraising groups which may not hyperlink to our Web site.

These organizations may link to our home page, to publications or to other Website information so long as the link: (a) is not in any way deceptive; (b) does not falsely imply sponsorship, endorsement or approval of the linking party and its products and/or services; and (c) fits within the context of the linking party’s site.

We may consider and approve other link requests from the following types of organizations:

  • commonly-known consumer and/or business information sources;
  • dot.com community sites;
  • associations or other groups representing charities;
  • online directory distributors;
  • internet portals;
  • accounting, law and consulting firms; and
  • educational institutions and trade associations.

We will approve link requests from these organizations if we decide that: (a) the link would not make us look unfavorably to ourselves or to our accredited businesses; (b) the organization does not have any negative records with us; (c) the benefit to us from the visibility of the hyperlink compensates the absence of Datasquirel; and (d) the link is in the context of general resource information.

These organizations may link to our home page so long as the link: (a) is not in any way deceptive; (b) does not falsely imply sponsorship, endorsement or approval of the linking party and its products or services; and (c) fits within the context of the linking party’s site.

If you are one of the organizations listed in paragraph 2 above and are interested in linking to our website, you must inform us by sending an e-mail to Datasquirel. Please include your name, your organization name, contact information as well as the URL of your site, a list of any URLs from which you intend to link to our Website, and a list of the URLs on our site to which you would like to link. Wait 2-3 weeks for a response.

Approved organizations may hyperlink to our Website as follows:

  • By use of our corporate name; or
  • By use of the uniform resource locator being linked to; or
  • By use of any other description of our Website being linked to that makes sense within the context and format of content on the linking party’s site.

No use of Datasquirel's logo or other artwork will be allowed for linking absent a trademark license agreement.

iFrames

Without prior approval and written permission, you may not create frames around our Webpages that alter in any way the visual presentation or appearance of our Website.

Content Liability

We shall not be hold responsible for any content that appears on your Website. You agree to protect and defend us against all claims that is rising on your Website. No link(s) should appear on any Website that may be interpreted as libelous, obscene or criminal, or which infringes, otherwise violates, or advocates the infringement or other violation of, any third party rights.

Your Privacy

Please read Privacy Policy

Reservation of Rights

We reserve the right to request that you remove all links or any particular link to our Website. You approve to immediately remove all links to our Website upon request. We also reserve the right to amen these terms and conditions and it’s linking policy at any time. By continuously linking to our Website, you agree to be bound to and follow these linking terms and conditions.

Removal of links from our website

If you find any link on our Website that is offensive for any reason, you are free to contact and inform us any moment. We will consider requests to remove links but we are not obligated to or so or to respond to you directly.

We do not ensure that the information on this website is correct, we do not warrant its completeness or accuracy; nor do we promise to ensure that the website remains available or that the material on the website is kept up to date.

Disclaimer

To the maximum extent permitted by applicable law, we exclude all representations, warranties and conditions relating to our website and the use of this website. Nothing in this disclaimer will:

  • limit or exclude our or your liability for death or personal injury;
  • limit or exclude our or your liability for fraud or fraudulent misrepresentation;
  • limit any of our or your liabilities in any way that is not permitted under applicable law; or
  • exclude any of our or your liabilities that may not be excluded under applicable law.

The limitations and prohibitions of liability set in this Section and elsewhere in this disclaimer: (a) are subject to the preceding paragraph; and (b) govern all liabilities arising under the disclaimer, including liabilities arising in contract, in tort and for breach of statutory duty.

As long as the website and the information and services on the website are provided free of charge, we will not be liable for any loss or damage of any nature.

\ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/terms.js.nft.json b/dsql-app/.local_dist/server/pages/terms.js.nft.json new file mode 100644 index 0000000..6d6cd19 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/terms.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/913.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../chunks/9922.js","../chunks/4598.js","../../package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/unsubscribe.js b/dsql-app/.local_dist/server/pages/unsubscribe.js new file mode 100644 index 0000000..4e4799e --- /dev/null +++ b/dsql-app/.local_dist/server/pages/unsubscribe.js @@ -0,0 +1,333 @@ +"use strict"; +(() => { +var exports = {}; +exports.id = 5785; +exports.ids = [5785]; +exports.modules = { + +/***/ 5591: +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Contact), +/* harmony export */ "getServerSideProps": () => (/* binding */ getServerSideProps) +/* harmony export */ }); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5264); +/* harmony import */ var _components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4097); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(370); +/* harmony import */ var _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4__); +/* harmony import */ var _functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(6729); +/* harmony import */ var _layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6217); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(9395); +/* harmony import */ var _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6__); +// @ts-check +/** + * ============================================================================== + * Imports + * ============================================================================== + */ + + + + + +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// + + +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Main Component { Functional } + * ============================================================================== + * @param {Object} props - Server props + * @param {import("@/package-shared/types").UserType | null} props.user + * @param {string | null} props.email + * @param {string} props.productionEnvironment + * @param {any} props.existingAlerts + */ function Contact({ user , email , productionEnvironment , existingAlerts , }) { + /** + * Get Contexts + * + * @abstract { React.useContext } + */ //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Javascript Variables + * + * @abstract Non hook variables and functions + */ const pageTitle = "Unsubscribe | Datasquirel"; + const pageDescription = "Unsubscribe from email alerts"; + let head = /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, { + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", { + children: pageTitle + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", { + name: "description", + content: pageDescription + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_PageHeadTags__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, { + pageTitle: pageTitle, + pageDescription: pageDescription, + pagePathname: "/unsubscribe" + }) + ] + }); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * React Hooks + * + * @abstract { useState, useEffect, useRef, etc ... } + */ const [loading, setLoading] = react__WEBPACK_IMPORTED_MODULE_1___default().useState(false); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Function Return + * + * @abstract Main Function Return + */ return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((react__WEBPACK_IMPORTED_MODULE_1___default().Fragment), { + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_layouts_GeneralLayout__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z, { + head: head, + user: user, + productionEnvironment: productionEnvironment, + children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("main", { + children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("section", { + children: [ + loading && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_general_LoadingBlock__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {}), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex-col", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("h1", { + className: "text-2xl", + children: "Unsubscribe from Email alerts" + }), + !email && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("p", { + className: "max-w-md", + children: [ + "No email please ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", { + href: "/login", + children: "Login" + }), + " ", + "to Access Email Subscriptions or click on", + " ", + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("i", { + children: '"unsubscribe"' + }), + " from your mail box" + ] + }), + email && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("form", { + className: "flex flex-col items-start gap-4", + onSubmit: (e)=>{ + e.preventDefault(); + setLoading(true); + /** @type {HTMLFormElement} */ // @ts-ignore + const formEl = e.target; + (0,_functions_frontend_fetchApi__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .Z)("/api/unsubscribe", { + method: "post", + body: { + email: email, + alerts: formEl["alerts_checkbox"].checked, + userId: user?.id ? user.id : null + } + }).then((res)=>{ + console.log(res); + setLoading(false); + }); + }, + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", { + className: "bg-slate-100 py-1 px-3 rounded-full", + children: email + }), + /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { + className: "flex items-center gap-1", + children: [ + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("input", { + type: "checkbox", + name: "alerts_checkbox", + id: "alerts_checkbox", + defaultChecked: existingAlerts ? true : false, + className: "w-6 h-6" + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("label", { + htmlFor: "alerts_checkbox", + className: "text-base whitespace-nowrap text-slate-800", + children: "Alerts" + }) + ] + }), + /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", { + children: "Save Settings" + }) + ] + }) + ] + }) + ] + }) + }) + }) + }); +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} +/** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** ****************************************************************************** */ /** + * ============================================================================== + * Server Side Props or Static Props + * ============================================================================== + * @type {import("next").GetServerSideProps} + */ async function getServerSideProps({ req , res , query }) { + // ## Environment processes + const productionEnvironment = process.env.DSQL_HOST_ENV; + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * User Authentication + * + * @description User authentication + */ const user = await _functions_backend_userAuth__WEBPACK_IMPORTED_MODULE_4___default()(req, res); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Page/Site Data Data Fetching + * + * @description Fetch data on the server before returning + */ const email = query.email ? query.email : user?.email ? user.email : null; + let existingAlerts = await _package_shared_utils_backend_global_db_DB_HANDLER__WEBPACK_IMPORTED_MODULE_6___default()(`SELECT email FROM unsubscribes WHERE email='${email}' AND type='alerts'`); + //////////////////////////////////////// + //////////////////////////////////////// + //////////////////////////////////////// + /** + * Server props return + * + * @description Return data fetched on the server side + */ return { + props: { + user: user, + email: email, + productionEnvironment, + existingAlerts: existingAlerts[0] ? false : true + } + }; +//////////////////////////////////////// +//////////////////////////////////////// +//////////////////////////////////////// +} + + +/***/ }), + +/***/ 386: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/CottageTwoTone"); + +/***/ }), + +/***/ 5557: +/***/ ((module) => { + +module.exports = require("@mui/icons-material/MenuBookTwoTone"); + +/***/ }), + +/***/ 2423: +/***/ ((module) => { + +module.exports = require("lucide-react"); + +/***/ }), + +/***/ 968: +/***/ ((module) => { + +module.exports = require("next/head"); + +/***/ }), + +/***/ 6689: +/***/ ((module) => { + +module.exports = require("react"); + +/***/ }), + +/***/ 997: +/***/ ((module) => { + +module.exports = require("react/jsx-runtime"); + +/***/ }), + +/***/ 2261: +/***/ ((module) => { + +module.exports = require("serverless-mysql"); + +/***/ }), + +/***/ 4300: +/***/ ((module) => { + +module.exports = require("buffer"); + +/***/ }), + +/***/ 6113: +/***/ ((module) => { + +module.exports = require("crypto"); + +/***/ }), + +/***/ 7147: +/***/ ((module) => { + +module.exports = require("fs"); + +/***/ }), + +/***/ 3685: +/***/ ((module) => { + +module.exports = require("http"); + +/***/ }), + +/***/ 1017: +/***/ ((module) => { + +module.exports = require("path"); + +/***/ }) + +}; +; + +// load runtime +var __webpack_require__ = require("../webpack-runtime.js"); +__webpack_require__.C(exports); +var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) +var __webpack_exports__ = __webpack_require__.X(0, [4017,8313,5264,6729,5449,5304,913,9395,370,9360,6217,4097], () => (__webpack_exec__(5591))); +module.exports = __webpack_exports__; + +})(); \ No newline at end of file diff --git a/dsql-app/.local_dist/server/pages/unsubscribe.js.nft.json b/dsql-app/.local_dist/server/pages/unsubscribe.js.nft.json new file mode 100644 index 0000000..7707855 --- /dev/null +++ b/dsql-app/.local_dist/server/pages/unsubscribe.js.nft.json @@ -0,0 +1 @@ +{"version":1,"files":["../webpack-runtime.js","../chunks/4017.js","../chunks/8313.js","../chunks/5264.js","../chunks/6729.js","../chunks/5449.js","../chunks/5304.js","../chunks/913.js","../chunks/9395.js","../chunks/370.js","../chunks/9360.js","../chunks/6217.js","../chunks/4097.js","../../package.json","../../../ssl/ca-cert.pem","../../../node_modules/serverless-mysql/package.json","../../../node_modules/lucide-react/package.json","../../../node_modules/@mui/material/package.json","../../../node_modules/serverless-mysql/index.js","../../../node_modules/lucide-react/dist/cjs/lucide-react.js","../../../node_modules/@mui/icons-material/CottageTwoTone.js","../../../node_modules/@mui/icons-material/package.json","../../../node_modules/@mui/icons-material/MenuBookTwoTone.js","../../../node_modules/next/head.js","../../../node_modules/next/package.json","../../../node_modules/react/package.json","../../../node_modules/react/index.js","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/react/jsx-runtime.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/react/cjs/react.production.min.js","../../../node_modules/react/cjs/react-jsx-runtime.production.min.js","../../../node_modules/react/cjs/react.development.js","../../../node_modules/react/cjs/react-jsx-runtime.development.js","../../../node_modules/@mui/material/node/styles/identifier.js","../../../node_modules/@mui/material/node/styles/createTheme.js","../../../node_modules/@mui/material/node/styles/createTransitions.js","../../../node_modules/@mui/material/node/styles/useThemeProps.js","../../../node_modules/@mui/material/node/styles/styled.js","../../../node_modules/@mui/material/node/styles/createTypography.js","../../../node_modules/@mui/material/node/styles/createMixins.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/@mui/material/node/utils/index.js","../../../node_modules/@mui/material/node/SvgIcon/index.js","../../../node_modules/@mui/material/node/styles/createPalette.js","../../../node_modules/@mui/material/node/styles/shadows.js","../../../node_modules/@mui/material/node/styles/zIndex.js","../../../node_modules/@mui/material/node/styles/defaultTheme.js","../../../node_modules/@mui/material/node/utils/capitalize.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/mysql/index.js","../../../node_modules/@babel/runtime/package.json","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@babel/runtime/helpers/extends.js","../../../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/package.json","../../../node_modules/@mui/system/index.js","../../../node_modules/mysql/package.json","../../../node_modules/@mui/utils/package.json","../../../node_modules/@mui/utils/index.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/@mui/base/package.json","../../../node_modules/@mui/material/node/colors/common.js","../../../node_modules/@mui/material/node/colors/red.js","../../../node_modules/@mui/material/node/colors/purple.js","../../../node_modules/@mui/material/node/colors/blue.js","../../../node_modules/@mui/material/node/colors/lightBlue.js","../../../node_modules/@mui/material/node/colors/green.js","../../../node_modules/@mui/material/node/colors/orange.js","../../../node_modules/@mui/material/node/colors/grey.js","../../../node_modules/@mui/material/node/utils/createChainedFunction.js","../../../node_modules/@mui/material/node/utils/createSvgIcon.js","../../../node_modules/@mui/material/node/utils/debounce.js","../../../node_modules/@mui/material/node/utils/deprecatedPropType.js","../../../node_modules/@mui/material/node/utils/isMuiElement.js","../../../node_modules/@mui/material/node/utils/ownerDocument.js","../../../node_modules/@mui/material/node/utils/ownerWindow.js","../../../node_modules/@mui/material/node/utils/requirePropFactory.js","../../../node_modules/@mui/material/node/utils/setRef.js","../../../node_modules/@mui/material/node/utils/useEnhancedEffect.js","../../../node_modules/@mui/material/node/utils/useId.js","../../../node_modules/@mui/material/node/utils/unsupportedProp.js","../../../node_modules/@mui/material/node/utils/useControlled.js","../../../node_modules/@mui/material/node/utils/useEventCallback.js","../../../node_modules/@mui/material/node/utils/useForkRef.js","../../../node_modules/@mui/material/node/utils/useIsFocusVisible.js","../../../node_modules/@mui/material/node/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/node/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/index.js","../../../node_modules/@mui/utils/generateUtilityClass/package.json","../../../node_modules/@mui/utils/generateUtilityClass/index.js","../../../node_modules/prop-types/package.json","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/generateUtilityClasses/package.json","../../../node_modules/@mui/utils/generateUtilityClasses/index.js","../../../node_modules/@mui/material/utils/package.json","../../../node_modules/@mui/base/composeClasses/package.json","../../../node_modules/@mui/base/node/composeClasses/index.js","../../../node_modules/clsx/package.json","../../../node_modules/clsx/dist/clsx.js","../../../node_modules/@mui/system/borders.js","../../../node_modules/@mui/system/breakpoints.js","../../../node_modules/@mui/system/compose.js","../../../node_modules/@mui/system/display.js","../../../node_modules/@mui/system/flexbox.js","../../../node_modules/@mui/system/cssGrid.js","../../../node_modules/@mui/system/palette.js","../../../node_modules/@mui/system/positions.js","../../../node_modules/@mui/system/sizing.js","../../../node_modules/@mui/system/spacing.js","../../../node_modules/@mui/system/shadows.js","../../../node_modules/@mui/system/style.js","../../../node_modules/@mui/system/typography.js","../../../node_modules/@mui/system/getThemeValue.js","../../../node_modules/@mui/system/createBox.js","../../../node_modules/@mui/system/createStyled.js","../../../node_modules/@mui/system/styled.js","../../../node_modules/@mui/system/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/createTheme/createSpacing.js","../../../node_modules/@mui/system/createTheme/shape.js","../../../node_modules/@mui/system/useTheme.js","../../../node_modules/@mui/system/useThemeWithoutDefault.js","../../../node_modules/@mui/system/colorManipulator.js","../../../node_modules/@mui/system/responsivePropType.js","../../../node_modules/@mui/system/Container/createContainer.js","../../../node_modules/@mui/system/Unstable_Grid/Grid.js","../../../node_modules/@mui/system/Stack/Stack.js","../../../node_modules/mysql/lib/Connection.js","../../../node_modules/mysql/lib/ConnectionConfig.js","../../../node_modules/mysql/lib/PoolCluster.js","../../../node_modules/mysql/lib/PoolConfig.js","../../../node_modules/mysql/lib/Pool.js","../../../node_modules/mysql/lib/protocol/SqlString.js","../../../node_modules/mysql/lib/protocol/constants/types.js","../../../node_modules/@mui/utils/deepmerge.js","../../../node_modules/@mui/utils/elementAcceptingRef.js","../../../node_modules/@mui/utils/elementTypeAcceptingRef.js","../../../node_modules/@mui/utils/getDisplayName.js","../../../node_modules/@mui/utils/refType.js","../../../node_modules/@mui/utils/createChainedFunction.js","../../../node_modules/@mui/utils/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement.js","../../../node_modules/@mui/utils/setRef.js","../../../node_modules/@mui/utils/requirePropFactory.js","../../../node_modules/@mui/utils/unsupportedProp.js","../../../node_modules/@mui/utils/useIsFocusVisible.js","../../../node_modules/@mui/utils/getScrollbarSize.js","../../../node_modules/@mui/utils/scrollLeft.js","../../../node_modules/@mui/utils/getValidReactChildren.js","../../../node_modules/@mui/utils/usePreviousProps.js","../../../node_modules/@mui/utils/visuallyHidden.js","../../../node_modules/@mui/utils/integerPropType.js","../../../node_modules/@mui/utils/resolveProps.js","../../../node_modules/@mui/system/cssVars/createCssVarsProvider.js","../../../node_modules/@mui/system/cssVars/createGetCssVar.js","../../../node_modules/@mui/system/cssVars/cssVarsParser.js","../../../node_modules/@mui/system/cssVars/prepareCssVars.js","../../../node_modules/@mui/system/cssVars/createCssVarsTheme.js","../../../node_modules/@mui/system/createTheme/package.json","../../../node_modules/@mui/system/Container/package.json","../../../node_modules/@mui/system/Unstable_Grid/package.json","../../../node_modules/@mui/system/Stack/package.json","../../../node_modules/@mui/system/cssVars/package.json","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/base/ClassNameGenerator/package.json","../../../node_modules/@mui/base/node/ClassNameGenerator/index.js","../../../node_modules/@mui/system/createTheme/index.js","../../../node_modules/@mui/system/Container/index.js","../../../node_modules/@mui/system/Unstable_Grid/index.js","../../../node_modules/@mui/system/Stack/index.js","../../../node_modules/@mui/system/merge.js","../../../node_modules/@mui/system/GlobalStyles/package.json","../../../node_modules/@mui/system/GlobalStyles/index.js","../../../node_modules/@mui/system/memoize.js","../../../node_modules/@mui/system/styleFunctionSx/package.json","../../../node_modules/@mui/system/styleFunctionSx/index.js","../../../node_modules/@mui/system/propsToClassKey.js","../../../node_modules/@mui/system/Box/package.json","../../../node_modules/@mui/system/Box/index.js","../../../node_modules/@mui/system/useThemeProps/package.json","../../../node_modules/@mui/system/useThemeProps/index.js","../../../node_modules/@mui/system/ThemeProvider/package.json","../../../node_modules/@mui/system/ThemeProvider/index.js","../../../node_modules/@mui/utils/chainPropTypes/package.json","../../../node_modules/@mui/utils/chainPropTypes/index.js","../../../node_modules/@mui/utils/exactProp/package.json","../../../node_modules/@mui/utils/exactProp/index.js","../../../node_modules/@mui/utils/HTMLElementType/package.json","../../../node_modules/@mui/utils/HTMLElementType/index.js","../../../node_modules/@mui/utils/ponyfillGlobal/package.json","../../../node_modules/@mui/utils/ponyfillGlobal/index.js","../../../node_modules/@mui/utils/capitalize/package.json","../../../node_modules/@mui/utils/capitalize/index.js","../../../node_modules/@mui/utils/ownerDocument/package.json","../../../node_modules/@mui/utils/ownerDocument/index.js","../../../node_modules/@mui/utils/debounce/package.json","../../../node_modules/@mui/utils/debounce/index.js","../../../node_modules/@mui/utils/ownerWindow/package.json","../../../node_modules/@mui/utils/ownerWindow/index.js","../../../node_modules/@mui/utils/useEnhancedEffect/package.json","../../../node_modules/@mui/utils/useEnhancedEffect/index.js","../../../node_modules/@mui/utils/useId/package.json","../../../node_modules/@mui/utils/useId/index.js","../../../node_modules/@mui/utils/useControlled/package.json","../../../node_modules/@mui/utils/useControlled/index.js","../../../node_modules/@mui/utils/useEventCallback/package.json","../../../node_modules/@mui/utils/useEventCallback/index.js","../../../node_modules/@mui/utils/useForkRef/package.json","../../../node_modules/@mui/utils/useForkRef/index.js","../../../node_modules/@mui/utils/ClassNameGenerator/package.json","../../../node_modules/@mui/utils/ClassNameGenerator/index.js","../../../node_modules/@mui/utils/composeClasses/package.json","../../../node_modules/@mui/utils/composeClasses/index.js","../../../node_modules/mysql/lib/protocol/Protocol.js","../../../node_modules/mysql/lib/PoolConnection.js","../../../node_modules/mysql/lib/protocol/constants/charsets.js","../../../node_modules/mysql/lib/protocol/constants/client.js","../../../node_modules/mysql/lib/protocol/constants/ssl_profiles.js","../../../node_modules/mysql/lib/PoolNamespace.js","../../../node_modules/mysql/lib/PoolSelector.js","../../../node_modules/@mui/system/Unstable_Grid/createGrid.js","../../../node_modules/@mui/styled-engine/package.json","../../../node_modules/@mui/styled-engine/node/index.js","../../../node_modules/@mui/system/Stack/createStack.js","../../../node_modules/mysql/lib/protocol/sequences/Query.js","../../../node_modules/@mui/system/cssVars/getInitColorSchemeScript.js","../../../node_modules/@mui/system/cssVars/useCurrentColorScheme.js","../../../node_modules/react-is/package.json","../../../node_modules/react-is/index.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/@mui/system/createTheme/createTheme.js","../../../node_modules/@mui/system/Container/Container.js","../../../node_modules/@mui/system/Container/containerClasses.js","../../../node_modules/@mui/system/Unstable_Grid/GridProps.js","../../../node_modules/@mui/system/Unstable_Grid/gridClasses.js","../../../node_modules/@mui/system/Unstable_Grid/traverseBreakpoints.js","../../../node_modules/@mui/system/Stack/StackProps.js","../../../node_modules/@mui/system/Stack/stackClasses.js","../../../node_modules/prop-types/node_modules/react-is/package.json","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/@mui/system/GlobalStyles/GlobalStyles.js","../../../node_modules/@mui/system/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/styleFunctionSx/extendSxProp.js","../../../node_modules/@mui/system/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/Box/Box.js","../../../node_modules/@mui/system/Box/boxClasses.js","../../../node_modules/@mui/system/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/ThemeProvider/ThemeProvider.js","../../../node_modules/mysql/lib/protocol/Parser.js","../../../node_modules/mysql/lib/protocol/PacketWriter.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@mui/utils/ponyfillGlobal/ponyfillGlobal.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/system/Unstable_Grid/gridGenerator.js","../../../node_modules/mysql/lib/protocol/ResultSet.js","../../../node_modules/mysql/lib/protocol/sequences/Sequence.js","../../../node_modules/mysql/lib/protocol/constants/server_status.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/mysql/lib/protocol/sequences/index.js","../../../node_modules/mysql/lib/protocol/packets/index.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@mui/private-theming/package.json","../../../node_modules/@mui/private-theming/node/index.js","../../../node_modules/mysql/lib/protocol/PacketHeader.js","../../../node_modules/mysql/lib/protocol/BufferList.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/index.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/index.js","../../../node_modules/mysql/lib/protocol/constants/errors.js","../../../node_modules/mysql/lib/protocol/Timer.js","../../../node_modules/sqlstring/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/mysql/lib/protocol/sequences/ChangeUser.js","../../../node_modules/mysql/lib/protocol/sequences/Handshake.js","../../../node_modules/mysql/lib/protocol/sequences/Ping.js","../../../node_modules/mysql/lib/protocol/sequences/Quit.js","../../../node_modules/mysql/lib/protocol/sequences/Statistics.js","../../../node_modules/sqlstring/package.json","../../../node_modules/object-assign/package.json","../../../node_modules/@emotion/styled/package.json","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.js","../../../node_modules/@emotion/react/package.json","../../../node_modules/@emotion/react/dist/emotion-react.cjs.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/AuthSwitchResponsePacket.js","../../../node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComPingPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQueryPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComQuitPacket.js","../../../node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/EmptyPacket.js","../../../node_modules/mysql/lib/protocol/packets/EofPacket.js","../../../node_modules/mysql/lib/protocol/packets/ErrorPacket.js","../../../node_modules/mysql/lib/protocol/packets/Field.js","../../../node_modules/mysql/lib/protocol/packets/FieldPacket.js","../../../node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js","../../../node_modules/mysql/lib/protocol/packets/LocalInfileRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/OkPacket.js","../../../node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js","../../../node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js","../../../node_modules/mysql/lib/protocol/packets/RowDataPacket.js","../../../node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js","../../../node_modules/mysql/lib/protocol/packets/StatisticsPacket.js","../../../node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js","../../../node_modules/mysql/node_modules/safe-buffer/package.json","../../../node_modules/mysql/node_modules/safe-buffer/index.js","../../../node_modules/mysql/node_modules/bignumber.js/package.json","../../../node_modules/readable-stream/package.json","../../../node_modules/readable-stream/readable.js","../../../node_modules/@mui/styled-engine/node/StyledEngineProvider/StyledEngineProvider.js","../../../node_modules/@mui/styled-engine/node/GlobalStyles/GlobalStyles.js","../../../node_modules/mysql/node_modules/bignumber.js/bignumber.js","../../../node_modules/mysql/lib/protocol/Auth.js","../../../node_modules/sqlstring/lib/SqlString.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.prod.js","../../../node_modules/@emotion/styled/dist/emotion-styled.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.prod.js","../../../node_modules/@emotion/react/dist/emotion-react.cjs.dev.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/index.js","../../../node_modules/@mui/private-theming/node/useTheme/index.js","../../../node_modules/readable-stream/lib/_stream_readable.js","../../../node_modules/readable-stream/lib/_stream_writable.js","../../../node_modules/readable-stream/lib/_stream_duplex.js","../../../node_modules/readable-stream/lib/_stream_transform.js","../../../node_modules/readable-stream/lib/_stream_passthrough.js","../../../node_modules/@emotion/react/dist/emotion-element-48d2c2e4.cjs.dev.js","../../../node_modules/@emotion/react/dist/emotion-element-4300ad44.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.prod.js","../../../node_modules/@emotion/styled/base/dist/emotion-styled-base.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.dev.js","../../../node_modules/@emotion/react/_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.prod.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/nested.js","../../../node_modules/@mui/private-theming/node/ThemeProvider/ThemeProvider.js","../../../node_modules/@mui/private-theming/node/useTheme/useTheme.js","../../../node_modules/@emotion/styled/base/package.json","../../../node_modules/@emotion/react/_isolated-hnrs/package.json","../../../node_modules/@emotion/cache/package.json","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.js","../../../node_modules/readable-stream/lib/internal/streams/stream.js","../../../node_modules/readable-stream/lib/internal/streams/destroy.js","../../../node_modules/readable-stream/lib/internal/streams/BufferList.js","../../../node_modules/@mui/private-theming/node/useTheme/ThemeContext.js","../../../node_modules/@emotion/is-prop-valid/package.json","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.js","../../../node_modules/@emotion/utils/package.json","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.js","../../../node_modules/@emotion/serialize/package.json","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.js","../../../node_modules/hoist-non-react-statics/package.json","../../../node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/package.json","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.js","../../../node_modules/@emotion/weak-memoize/package.json","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.prod.js","../../../node_modules/@emotion/cache/dist/emotion-cache.cjs.dev.js","../../../node_modules/readable-stream/node_modules/safe-buffer/package.json","../../../node_modules/readable-stream/node_modules/safe-buffer/index.js","../../../node_modules/string_decoder/package.json","../../../node_modules/string_decoder/lib/string_decoder.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.prod.js","../../../node_modules/@emotion/utils/dist/emotion-utils.cjs.dev.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.prod.js","../../../node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.cjs.dev.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.prod.js","../../../node_modules/@emotion/serialize/dist/emotion-serialize.cjs.dev.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.prod.js","../../../node_modules/@emotion/weak-memoize/dist/emotion-weak-memoize.cjs.dev.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.prod.js","../../../node_modules/@emotion/use-insertion-effect-with-fallbacks/dist/emotion-use-insertion-effect-with-fallbacks.cjs.dev.js","../../../node_modules/process-nextick-args/package.json","../../../node_modules/process-nextick-args/index.js","../../../node_modules/isarray/package.json","../../../node_modules/isarray/index.js","../../../node_modules/inherits/package.json","../../../node_modules/inherits/inherits.js","../../../node_modules/util-deprecate/package.json","../../../node_modules/util-deprecate/node.js","../../../node_modules/core-util-is/package.json","../../../node_modules/core-util-is/lib/util.js","../../../node_modules/inherits/inherits_browser.js","../../../node_modules/@emotion/sheet/package.json","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.js","../../../node_modules/@emotion/memoize/package.json","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.js","../../../node_modules/stylis/package.json","../../../node_modules/stylis/dist/umd/stylis.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/package.json","../../../node_modules/hoist-non-react-statics/node_modules/react-is/index.js","../../../node_modules/stylis/dist/umd/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/package.json","../../../node_modules/string_decoder/node_modules/safe-buffer/index.js","../../../node_modules/@emotion/hash/package.json","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.js","../../../node_modules/@emotion/unitless/package.json","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.prod.js","../../../node_modules/@emotion/memoize/dist/emotion-memoize.cjs.dev.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.prod.js","../../../node_modules/@emotion/sheet/dist/emotion-sheet.cjs.dev.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.prod.js","../../../node_modules/@emotion/unitless/dist/emotion-unitless.cjs.dev.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.prod.js","../../../node_modules/@emotion/hash/dist/emotion-hash.cjs.dev.js","../../../package.json"]} \ No newline at end of file diff --git a/dsql-app/.local_dist/server/webpack-api-runtime.js b/dsql-app/.local_dist/server/webpack-api-runtime.js new file mode 100644 index 0000000..04b90e9 --- /dev/null +++ b/dsql-app/.local_dist/server/webpack-api-runtime.js @@ -0,0 +1,160 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({}); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ var threw = true; +/******/ try { +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ threw = false; +/******/ } finally { +/******/ if(threw) delete __webpack_module_cache__[moduleId]; +/******/ } +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/ensure chunk */ +/******/ (() => { +/******/ __webpack_require__.f = {}; +/******/ // This file contains only the entry chunk. +/******/ // The chunk loading function for additional chunks +/******/ __webpack_require__.e = (chunkId) => { +/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { +/******/ __webpack_require__.f[key](chunkId, promises); +/******/ return promises; +/******/ }, [])); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/get javascript chunk filename */ +/******/ (() => { +/******/ // This function allow to reference async chunks and sibling chunks for the entrypoint +/******/ __webpack_require__.u = (chunkId) => { +/******/ // return url for filenames based on template +/******/ return "" + chunkId + ".js"; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/startup entrypoint */ +/******/ (() => { +/******/ __webpack_require__.X = (result, chunkIds, fn) => { +/******/ // arguments: chunkIds, moduleId are deprecated +/******/ var moduleId = chunkIds; +/******/ if(!fn) chunkIds = result, fn = () => (__webpack_require__(__webpack_require__.s = moduleId)); +/******/ chunkIds.map(__webpack_require__.e, __webpack_require__) +/******/ var r = fn(); +/******/ return r === undefined ? result : r; +/******/ } +/******/ })(); +/******/ +/******/ /* webpack/runtime/require chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded chunks +/******/ // "1" means "loaded", otherwise not loaded yet +/******/ var installedChunks = { +/******/ 2165: 1 +/******/ }; +/******/ +/******/ // no on chunks loaded +/******/ +/******/ var installChunk = (chunk) => { +/******/ var moreModules = chunk.modules, chunkIds = chunk.ids, runtime = chunk.runtime; +/******/ for(var moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) runtime(__webpack_require__); +/******/ for(var i = 0; i < chunkIds.length; i++) +/******/ installedChunks[chunkIds[i]] = 1; +/******/ +/******/ }; +/******/ +/******/ // require() chunk loading for javascript +/******/ __webpack_require__.f.require = (chunkId, promises) => { +/******/ // "1" is the signal for "already loaded" +/******/ if(!installedChunks[chunkId]) { +/******/ if(2165 != chunkId) { +/******/ installChunk(require("./chunks/" + __webpack_require__.u(chunkId))); +/******/ } else installedChunks[chunkId] = 1; +/******/ } +/******/ }; +/******/ +/******/ module.exports = __webpack_require__; +/******/ __webpack_require__.C = installChunk; +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ +/******/ })() +; \ No newline at end of file diff --git a/dsql-app/.local_dist/server/webpack-runtime.js b/dsql-app/.local_dist/server/webpack-runtime.js new file mode 100644 index 0000000..d3218c4 --- /dev/null +++ b/dsql-app/.local_dist/server/webpack-runtime.js @@ -0,0 +1,229 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({}); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ var threw = true; +/******/ try { +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ threw = false; +/******/ } finally { +/******/ if(threw) delete __webpack_module_cache__[moduleId]; +/******/ } +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/async module */ +/******/ (() => { +/******/ var webpackQueues = typeof Symbol === "function" ? Symbol("webpack queues") : "__webpack_queues__"; +/******/ var webpackExports = typeof Symbol === "function" ? Symbol("webpack exports") : "__webpack_exports__"; +/******/ var webpackError = typeof Symbol === "function" ? Symbol("webpack error") : "__webpack_error__"; +/******/ var resolveQueue = (queue) => { +/******/ if(queue && !queue.d) { +/******/ queue.d = 1; +/******/ queue.forEach((fn) => (fn.r--)); +/******/ queue.forEach((fn) => (fn.r-- ? fn.r++ : fn())); +/******/ } +/******/ } +/******/ var wrapDeps = (deps) => (deps.map((dep) => { +/******/ if(dep !== null && typeof dep === "object") { +/******/ if(dep[webpackQueues]) return dep; +/******/ if(dep.then) { +/******/ var queue = []; +/******/ queue.d = 0; +/******/ dep.then((r) => { +/******/ obj[webpackExports] = r; +/******/ resolveQueue(queue); +/******/ }, (e) => { +/******/ obj[webpackError] = e; +/******/ resolveQueue(queue); +/******/ }); +/******/ var obj = {}; +/******/ obj[webpackQueues] = (fn) => (fn(queue)); +/******/ return obj; +/******/ } +/******/ } +/******/ var ret = {}; +/******/ ret[webpackQueues] = x => {}; +/******/ ret[webpackExports] = dep; +/******/ return ret; +/******/ })); +/******/ __webpack_require__.a = (module, body, hasAwait) => { +/******/ var queue; +/******/ hasAwait && ((queue = []).d = 1); +/******/ var depQueues = new Set(); +/******/ var exports = module.exports; +/******/ var currentDeps; +/******/ var outerResolve; +/******/ var reject; +/******/ var promise = new Promise((resolve, rej) => { +/******/ reject = rej; +/******/ outerResolve = resolve; +/******/ }); +/******/ promise[webpackExports] = exports; +/******/ promise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise["catch"](x => {})); +/******/ module.exports = promise; +/******/ body((deps) => { +/******/ currentDeps = wrapDeps(deps); +/******/ var fn; +/******/ var getResult = () => (currentDeps.map((d) => { +/******/ if(d[webpackError]) throw d[webpackError]; +/******/ return d[webpackExports]; +/******/ })) +/******/ var promise = new Promise((resolve) => { +/******/ fn = () => (resolve(getResult)); +/******/ fn.r = 0; +/******/ var fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn)))); +/******/ currentDeps.map((dep) => (dep[webpackQueues](fnQueue))); +/******/ }); +/******/ return fn.r ? promise : getResult(); +/******/ }, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue))); +/******/ queue && (queue.d = 0); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/ensure chunk */ +/******/ (() => { +/******/ __webpack_require__.f = {}; +/******/ // This file contains only the entry chunk. +/******/ // The chunk loading function for additional chunks +/******/ __webpack_require__.e = (chunkId) => { +/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { +/******/ __webpack_require__.f[key](chunkId, promises); +/******/ return promises; +/******/ }, [])); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/get javascript chunk filename */ +/******/ (() => { +/******/ // This function allow to reference async chunks and sibling chunks for the entrypoint +/******/ __webpack_require__.u = (chunkId) => { +/******/ // return url for filenames based on template +/******/ return "" + chunkId + ".js"; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/startup entrypoint */ +/******/ (() => { +/******/ __webpack_require__.X = (result, chunkIds, fn) => { +/******/ // arguments: chunkIds, moduleId are deprecated +/******/ var moduleId = chunkIds; +/******/ if(!fn) chunkIds = result, fn = () => (__webpack_require__(__webpack_require__.s = moduleId)); +/******/ chunkIds.map(__webpack_require__.e, __webpack_require__) +/******/ var r = fn(); +/******/ return r === undefined ? result : r; +/******/ } +/******/ })(); +/******/ +/******/ /* webpack/runtime/require chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded chunks +/******/ // "1" means "loaded", otherwise not loaded yet +/******/ var installedChunks = { +/******/ 6658: 1 +/******/ }; +/******/ +/******/ // no on chunks loaded +/******/ +/******/ var installChunk = (chunk) => { +/******/ var moreModules = chunk.modules, chunkIds = chunk.ids, runtime = chunk.runtime; +/******/ for(var moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) runtime(__webpack_require__); +/******/ for(var i = 0; i < chunkIds.length; i++) +/******/ installedChunks[chunkIds[i]] = 1; +/******/ +/******/ }; +/******/ +/******/ // require() chunk loading for javascript +/******/ __webpack_require__.f.require = (chunkId, promises) => { +/******/ // "1" is the signal for "already loaded" +/******/ if(!installedChunks[chunkId]) { +/******/ if(6658 != chunkId) { +/******/ installChunk(require("./chunks/" + __webpack_require__.u(chunkId))); +/******/ } else installedChunks[chunkId] = 1; +/******/ } +/******/ }; +/******/ +/******/ module.exports = __webpack_require__; +/******/ __webpack_require__.C = installChunk; +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ +/******/ })() +; \ No newline at end of file diff --git a/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_buildManifest.js b/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_buildManifest.js new file mode 100644 index 0000000..2902c56 --- /dev/null +++ b/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_buildManifest.js @@ -0,0 +1 @@ +self.__BUILD_MANIFEST=function(s,a,e,d,i,t,c,n,u,b,r,g,l,_,m,h,k,p,f,j,o,y,w,v,I,B,F,A,D,E,L,M,N){return{__rewrites:{beforeFiles:[],afterFiles:[],fallback:[]},"/":[B,"static/css/65efe10b506f9812.css","static/chunks/pages/index-c2ab88c2111475dd.js"],"/404":["static/chunks/pages/404-d04d8d42f75218d9.js"],"/500":["static/chunks/pages/500-7db225cc6b4dea2c.js"],"/_error":["static/chunks/pages/_error-f2496e8b9fdedb89.js"],"/about":[B,"static/chunks/pages/about-76deaa37497c062c.js"],"/admin":[s,b,p,"static/chunks/pages/admin-81e2733c0d783481.js"],"/admin/[user_id]":[s,b,p,"static/chunks/pages/admin/[user_id]-e36cc5d13c2aa929.js"],"/admin/[user_id]/api-keys":[s,"static/chunks/pages/admin/[user_id]/api-keys-ad926df40536b287.js"],"/admin/[user_id]/connect":[s,"static/chunks/pages/admin/[user_id]/connect-8973f4ea35b17adf.js"],"/admin/[user_id]/databases":[s,b,"static/chunks/pages/admin/[user_id]/databases-2ede91ae9bfe108a.js"],"/admin/[user_id]/databases/add-database":[i,s,e,c,f,"static/chunks/pages/admin/[user_id]/databases/add-database-e3a5509e700b0e80.js"],"/admin/[user_id]/databases/[single]":[s,a,t,"static/chunks/pages/admin/[user_id]/databases/[single]-35266a148b439139.js"],"/admin/[user_id]/databases/[single]/connect":[s,a,e,"static/chunks/pages/admin/[user_id]/databases/[single]/connect-6fe32fdcf255139c.js"],"/admin/[user_id]/databases/[single]/edit-database":[i,s,a,e,c,f,"static/chunks/pages/admin/[user_id]/databases/[single]/edit-database-a60b50dd21c29ae2.js"],"/admin/[user_id]/databases/[single]/schema":[i,u,j,s,a,e,t,c,f,F,"static/chunks/pages/admin/[user_id]/databases/[single]/schema-7b76b5c228e273d4.js"],"/admin/[user_id]/databases/[single]/shell":[A,s,a,"static/chunks/pages/admin/[user_id]/databases/[single]/shell-cb2910aa3bd12a22.js"],"/admin/[user_id]/databases/[single]/tables":[s,a,t,"static/chunks/pages/admin/[user_id]/databases/[single]/tables-512e452212994e35.js"],"/admin/[user_id]/databases/[single]/tables/add-table":[i,r,g,s,a,e,c,l,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/add-table-09cebcb0b429f6de.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]":[i,r,n,g,_,o,s,a,e,t,c,l,m,y,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]-0d9a8a82c8b584d3.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table":[i,r,g,s,a,e,t,c,l,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table-4d03eae9a64fe6a7.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries":[i,n,_,o,s,a,e,t,m,y,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries-3a14a471d2dc7b00.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry":[n,_,s,a,t,m,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry-0ecd226005afec57.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]":[i,n,_,o,s,a,e,t,m,y,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]-a15e553c68e1ca23.js"],"/admin/[user_id]/databases/[single]/tables/[single_table]/fields":[i,r,g,s,a,e,t,c,l,"static/chunks/pages/admin/[user_id]/databases/[single]/tables/[single_table]/fields-ab993bc50ce1e800.js"],"/admin/[user_id]/databases/[single]/users":[s,a,t,h,"static/chunks/pages/admin/[user_id]/databases/[single]/users-0afdf841aae9f757.js"],"/admin/[user_id]/databases/[single]/users/add-social-logins":[s,a,e,k,D,"static/chunks/pages/admin/[user_id]/databases/[single]/users/add-social-logins-3e4d353e902f53ae.js"],"/admin/[user_id]/databases/[single]/users/add-user":[s,a,e,k,D,"static/chunks/pages/admin/[user_id]/databases/[single]/users/add-user-36cc73c2fdadfc25.js"],"/admin/[user_id]/databases/[single]/users/[user]":[s,a,k,"static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]-f7cdffc0b0c094c6.js"],"/admin/[user_id]/databases/[single]/users/[user]/change-password":[s,a,"static/chunks/pages/admin/[user_id]/databases/[single]/users/[user]/change-password-21db218c89054e75.js"],"/admin/[user_id]/media":[s,E,"static/chunks/pages/admin/[user_id]/media-922d349166d14d18.js"],"/admin/[user_id]/media/[...folder]":[s,E,"static/chunks/pages/admin/[user_id]/media/[...folder]-773d7108b2688df4.js"],"/admin/[user_id]/schema":[u,j,s,a,F,"static/chunks/pages/admin/[user_id]/schema-d264203c84a34e72.js"],"/admin/[user_id]/settings":[i,s,e,c,b,w,p,L,"static/chunks/pages/admin/[user_id]/settings-7a69db8bd70bed09.js"],"/admin/[user_id]/users":[s,h,"static/chunks/pages/admin/[user_id]/users-8b4f68a1fd38c9b3.js"],"/admin/[user_id]/users/add-user":[s,"static/chunks/pages/admin/[user_id]/users/add-user-c50fb941e687320a.js"],"/admin/[user_id]/users/databases":[s,h,"static/chunks/pages/admin/[user_id]/users/databases-ee8daf5a492656f7.js"],"/admin/[user_id]/users/databases/[database]":[s,h,"static/chunks/pages/admin/[user_id]/users/databases/[database]-28052313a8523fc1.js"],"/admin/[user_id]/users/databases/[database]/[user]":[s,k,"static/chunks/pages/admin/[user_id]/users/databases/[database]/[user]-1922bb43b40f7cbb.js"],"/blog":["static/chunks/pages/blog-be6db5dd2389f8c4.js"],"/contact":["static/chunks/pages/contact-513427eea0db408d.js"],"/create-account":[w,L,"static/chunks/pages/create-account-c97da041b7809649.js"],"/docs":["static/chunks/pages/docs-de42203d30b1880d.js"],"/docs/[page]":["static/chunks/pages/docs/[page]-3602862f9a9542f8.js"],"/docs/[page]/[sub-page]":["static/chunks/pages/docs/[page]/[sub-page]-b3641ae1942e2312.js"],"/email-verification":["static/chunks/pages/email-verification-2643dd10f1b54d59.js"],"/login":[w,"static/chunks/pages/login-5453e8ec28f13db7.js"],"/logout":["static/chunks/pages/logout-043abd512c88b3d5.js"],"/pricing":["static/chunks/pages/pricing-e193043fd895ccd5.js"],"/privacy":["static/chunks/pages/privacy-6a6371ab4eda9c15.js"],"/redirect":["static/chunks/pages/redirect-f189e8f0d6ae1482.js"],"/reset-password":[i,"static/chunks/pages/reset-password-a754110c3b3e20fb.js"],"/send-password-reset-link":["static/chunks/pages/send-password-reset-link-62def12808387ec7.js"],"/su":[d,M,"static/chunks/pages/su-0929bdda8a625d2f.js"],"/su/backups":[d,"static/chunks/pages/su/backups-bca9ee6e12563d0e.js"],"/su/console":["static/chunks/ed150ef9-713e0b995a8779c6.js","static/chunks/493-ec86d71e0fece010.js",d,"static/css/85fa6dafca566008.css","static/chunks/pages/su/console-3a63684b22961749.js"],"/su/docs":[d,N,"static/chunks/pages/su/docs-b48cfe163578ba42.js"],"/su/docs/create-page":[n,u,v,e,d,I,"static/chunks/pages/su/docs/create-page-9be0d237216b00cd.js"],"/su/docs/edit-page":[n,u,v,e,d,I,"static/chunks/pages/su/docs/edit-page-4892c3a874c645b3.js"],"/su/docs/pages":[d,N,"static/chunks/pages/su/docs/pages-5eee4e47bc092505.js"],"/su/docs/pages/[id]":[n,u,v,e,d,I,"static/chunks/pages/su/docs/pages/[id]-abedeaddb98ac372.js"],"/su/envar":[d,"static/chunks/pages/su/envar-42f3065b06c71be8.js"],"/su/error-logs":[d,M,"static/chunks/pages/su/error-logs-3ec6556e012daf42.js"],"/su/login":["static/chunks/pages/su/login-229fe7b2cd7c2383.js"],"/su/users":[d,"static/chunks/pages/su/users-04679602ef8b1002.js"],"/su/users/[single]":[u,j,A,d,"static/chunks/pages/su/users/[single]-65b1051395f52052.js"],"/terms":["static/chunks/pages/terms-da8c5b5b6b17b132.js"],"/unsubscribe":["static/chunks/pages/unsubscribe-b9517fbaaacff29b.js"],sortedPages:["/","/404","/500","/_app","/_error","/about","/admin","/admin/[user_id]","/admin/[user_id]/api-keys","/admin/[user_id]/connect","/admin/[user_id]/databases","/admin/[user_id]/databases/add-database","/admin/[user_id]/databases/[single]","/admin/[user_id]/databases/[single]/connect","/admin/[user_id]/databases/[single]/edit-database","/admin/[user_id]/databases/[single]/schema","/admin/[user_id]/databases/[single]/shell","/admin/[user_id]/databases/[single]/tables","/admin/[user_id]/databases/[single]/tables/add-table","/admin/[user_id]/databases/[single]/tables/[single_table]","/admin/[user_id]/databases/[single]/tables/[single_table]/edit-table","/admin/[user_id]/databases/[single]/tables/[single_table]/entries","/admin/[user_id]/databases/[single]/tables/[single_table]/entries/add-entry","/admin/[user_id]/databases/[single]/tables/[single_table]/entries/[single_entry]","/admin/[user_id]/databases/[single]/tables/[single_table]/fields","/admin/[user_id]/databases/[single]/users","/admin/[user_id]/databases/[single]/users/add-social-logins","/admin/[user_id]/databases/[single]/users/add-user","/admin/[user_id]/databases/[single]/users/[user]","/admin/[user_id]/databases/[single]/users/[user]/change-password","/admin/[user_id]/media","/admin/[user_id]/media/[...folder]","/admin/[user_id]/schema","/admin/[user_id]/settings","/admin/[user_id]/users","/admin/[user_id]/users/add-user","/admin/[user_id]/users/databases","/admin/[user_id]/users/databases/[database]","/admin/[user_id]/users/databases/[database]/[user]","/blog","/contact","/create-account","/docs","/docs/[page]","/docs/[page]/[sub-page]","/email-verification","/login","/logout","/pricing","/privacy","/redirect","/reset-password","/send-password-reset-link","/su","/su/backups","/su/console","/su/docs","/su/docs/create-page","/su/docs/edit-page","/su/docs/pages","/su/docs/pages/[id]","/su/envar","/su/error-logs","/su/login","/su/users","/su/users/[single]","/terms","/unsubscribe"]}}("static/chunks/9365-101d5c9d637cef9a.js","static/chunks/194-da10d06ed5c55a8f.js","static/chunks/7901-841b99c96481dd31.js","static/chunks/5313-e7700a25826b1c4d.js","static/chunks/29107295-4a69275373f23f88.js","static/chunks/8264-5901ddfeb3cb03ce.js","static/chunks/9967-c027b915261dae19.js","static/chunks/1179-5a248a7a76a74928.js","static/chunks/4185-b4c9a571bd713be6.js","static/chunks/3181-e628e642754b0f35.js","static/chunks/94726e6d-f5320de901b4c44f.js","static/chunks/9572-f67b1194a0e6ae72.js","static/chunks/4893-e30c16360c86c67d.js","static/chunks/1502-965711da5f99a5c8.js","static/chunks/9788-84477f8e20625988.js","static/chunks/5949-b1c68b62cd5dbfee.js","static/chunks/2870-8e302171aed920f8.js","static/chunks/5667-9e7b94f8ce529764.js","static/chunks/8887-5917115e54cd417b.js","static/chunks/8473-1a1faf3d4d34beef.js","static/chunks/8446-a36a685092b53a06.js","static/chunks/9035-b11038b244e852f0.js","static/chunks/8374-f28680e628b18bd5.js","static/chunks/2452-ed265b549204d978.js","static/chunks/2378-3a97fbefe0f48bac.js","static/chunks/3935-eea593fa60dfd620.js","static/chunks/7200-4c384098300f07db.js","static/chunks/3795-b7a314b891092ea4.js","static/chunks/9719-14cc8b76a1deed3c.js","static/chunks/4156-a7c42d729046e9bc.js","static/chunks/5114-a70f18877cc7f8bc.js","static/chunks/3695-7acf198d2c47bd8e.js","static/chunks/5622-0b01b71a2de3acf8.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_ssgManifest.js b/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_ssgManifest.js new file mode 100644 index 0000000..db06d45 --- /dev/null +++ b/dsql-app/.local_dist/static/3R3kPKBRvQxy5eX-ojVmP/_ssgManifest.js @@ -0,0 +1 @@ +self.__SSG_MANIFEST=new Set(["\u002Fdocs\u002F[page]","\u002Fdocs\u002F[page]\u002F[sub-page]"]);self.__SSG_MANIFEST_CB&&self.__SSG_MANIFEST_CB() \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/1179-5a248a7a76a74928.js b/dsql-app/.local_dist/static/chunks/1179-5a248a7a76a74928.js new file mode 100644 index 0000000..1818dd4 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/1179-5a248a7a76a74928.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1179],{42065:function(n,e,t){"use strict";var o=t(64836);e.Z=void 0;var r=o(t(64938)),i=t(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");e.Z=a},96673:function(n,e,t){"use strict";var o=t(64836);e.Z=void 0;var r=o(t(64938)),i=t(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M14.17 3H8v14h11V7.83L14.17 3zm2.33 12h-6v-2h6v2zm0-6h-2v2h-2V9h-2V7h2V5h2v2h2v2z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M18 23H4c-1.1 0-2-.9-2-2V7h2v14h14v2zM14.5 7V5h-2v2h-2v2h2v2h2V9h2V7h-2zm2 6h-6v2h6v-2zM15 1H8c-1.1 0-1.99.9-1.99 2L6 17c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V7l-6-6zm4 16H8V3h6.17L19 7.83V17z"},"1")],"DifferenceTwoTone");e.Z=a},90918:function(n,e,t){"use strict";t.d(e,{M:function(){return S}});var o=t(67294),r=t(45697),i=function(){return i=Object.assign||function(n){for(var e,t=1,o=arguments.length;t0?setTimeout(a,o):a()},reinitialize:function(){for(var e=n.pop();null!=e;e=n.pop())e.deleteScripts()}}}(),C=function(n){var e=n;return e&&e.tinymce?e.tinymce:null},E=function(){var n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,e){n.__proto__=e}||function(n,e){for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t])},n(e,t)};return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function o(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)}}(),k=function(){return k=Object.assign||function(n){for(var e,t=1,o=arguments.length;t{const r=o(e);return n(r,t)}},66675:function(e){e.exports=(e,t={})=>{const r=t.char||" ",n=t.count||2;let o=0;const i=[];return e.reverse().reduce(((e,t)=>{i.length&&o&&i[o]&&i[o]===t.substring(1,i[o].length+1)&&(i.splice(o,1),o--);const c=[`${r.repeat(o?o*n:0)}${t}`,...e];return"e.trim().replace(/(^(\s|\t)+|(( |\t)+)$)/gm,"");e.exports={mergeAttributesWithElements:e=>{const r=t(e).split("\n"),n=[];let o="";for(let t=0;t")?(n.push(`${o}${e.slice(0,-2)} />`),o=""):e.endsWith(">")?(n.push(`${o}${e.startsWith(">")||e.startsWith("<")?"":" "}${e}`),o=""):o+=o.length?` ${e}`:e}return n},removeEmptyLines:t}},64998:function(e,t,r){"use strict";r.d(t,{Z:function(){return n}});const n=(0,r(45711).Z)("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},31571:function(e,t,r){"use strict";r.d(t,{Z:function(){return n}});const n=(0,r(45711).Z)("CircleMinus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]])},31325:function(e,t,r){"use strict";r.d(t,{Z:function(){return n}});const n=(0,r(45711).Z)("CirclePlus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]])},63764:function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(e){for(var t=1;t=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?e.apply(this,o):function(){for(var e=arguments.length,n=new Array(e),i=0;i1&&void 0!==arguments[1]?arguments[1]:{};g.initial(e),g.handler(t);var r={current:e},n=d(b)(r,t),o=d(y)(r),i=d(g.changes)(e),c=d(m)(r);function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(e){return e};return g.selector(e),e(r.current)}function a(e){f(n,o,i,c)(e)}return[u,a]}},M=w,j={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.43.0/min/vs"}};var O=function(e){return function t(){for(var r=this,n=arguments.length,o=new Array(n),i=0;i=e.length?e.apply(this,o):function(){for(var e=arguments.length,n=new Array(e),i=0;i{n.current=!1}:e,t)};function ee(){}function te(e,t,r,n){return function(e,t){return e.editor.getModel(re(e,t))}(e,n)||function(e,t,r,n){return e.editor.createModel(t,r,n?re(e,n):void 0)}(e,t,r,n)}function re(e,t){return e.Uri.parse(t)}var ne=function({original:e,modified:t,language:r,originalLanguage:n,modifiedLanguage:o,originalModelPath:i,modifiedModelPath:c,keepCurrentOriginalModel:u=!1,keepCurrentModifiedModel:a=!1,theme:l="light",loading:s="Loading...",options:f={},height:d="100%",width:h="100%",className:v,wrapperProps:p={},beforeMount:g=ee,onMount:m=ee}){let[y,b]=(0,U.useState)(!1),[w,M]=(0,U.useState)(!0),j=(0,U.useRef)(null),O=(0,U.useRef)(null),z=(0,U.useRef)(null),E=(0,U.useRef)(m),k=(0,U.useRef)(g),H=(0,U.useRef)(!1);Q((()=>{let e=F.init();return e.then((e=>(O.current=e)&&M(!1))).catch((e=>"cancelation"!==e?.type&&console.error("Monaco initialization: error:",e))),()=>j.current?function(){let e=j.current?.getModel();u||e?.original?.dispose(),a||e?.modified?.dispose(),j.current?.dispose()}():e.cancel()})),X((()=>{if(j.current&&O.current){let t=j.current.getOriginalEditor(),o=te(O.current,e||"",n||r||"text",i||"");o!==t.getModel()&&t.setModel(o)}}),[i],y),X((()=>{if(j.current&&O.current){let e=j.current.getModifiedEditor(),n=te(O.current,t||"",o||r||"text",c||"");n!==e.getModel()&&e.setModel(n)}}),[c],y),X((()=>{let e=j.current.getModifiedEditor();e.getOption(O.current.editor.EditorOption.readOnly)?e.setValue(t||""):t!==e.getValue()&&(e.executeEdits("",[{range:e.getModel().getFullModelRange(),text:t||"",forceMoveMarkers:!0}]),e.pushUndoStop())}),[t],y),X((()=>{j.current?.getModel()?.original.setValue(e||"")}),[e],y),X((()=>{let{original:e,modified:t}=j.current.getModel();O.current.editor.setModelLanguage(e,n||r||"text"),O.current.editor.setModelLanguage(t,o||r||"text")}),[r,n,o],y),X((()=>{O.current?.editor.setTheme(l)}),[l],y),X((()=>{j.current?.updateOptions(f)}),[f],y);let V=(0,U.useCallback)((()=>{if(!O.current)return;k.current(O.current);let u=te(O.current,e||"",n||r||"text",i||""),a=te(O.current,t||"",o||r||"text",c||"");j.current?.setModel({original:u,modified:a})}),[r,t,o,e,n,i,c]),x=(0,U.useCallback)((()=>{!H.current&&z.current&&(j.current=O.current.editor.createDiffEditor(z.current,{automaticLayout:!0,...f}),V(),O.current?.editor.setTheme(l),b(!0),H.current=!0)}),[f,l,V]);return(0,U.useEffect)((()=>{y&&E.current(j.current,O.current)}),[y]),(0,U.useEffect)((()=>{!w&&!y&&x()}),[w,y,x]),U.createElement(K,{width:h,height:d,isEditorReady:y,loading:s,_ref:z,className:v,wrapperProps:p})};(0,U.memo)(ne);var oe=function(e){let t=(0,U.useRef)();return(0,U.useEffect)((()=>{t.current=e}),[e]),t.current},ie=new Map;var ce=function({defaultValue:e,defaultLanguage:t,defaultPath:r,value:n,language:o,path:i,theme:c="light",line:u,loading:a="Loading...",options:l={},overrideServices:s={},saveViewState:f=!0,keepCurrentModel:d=!1,width:h="100%",height:v="100%",className:p,wrapperProps:g={},beforeMount:m=ee,onMount:y=ee,onChange:b,onValidate:w=ee}){let[M,j]=(0,U.useState)(!1),[O,z]=(0,U.useState)(!0),E=(0,U.useRef)(null),k=(0,U.useRef)(null),H=(0,U.useRef)(null),V=(0,U.useRef)(y),x=(0,U.useRef)(m),P=(0,U.useRef)(),T=(0,U.useRef)(n),R=oe(i),S=(0,U.useRef)(!1),L=(0,U.useRef)(!1);Q((()=>{let e=F.init();return e.then((e=>(E.current=e)&&z(!1))).catch((e=>"cancelation"!==e?.type&&console.error("Monaco initialization: error:",e))),()=>k.current?(P.current?.dispose(),d?f&&ie.set(i,k.current.saveViewState()):k.current.getModel()?.dispose(),void k.current.dispose()):e.cancel()})),X((()=>{let c=te(E.current,e||n||"",t||o||"",i||r||"");c!==k.current?.getModel()&&(f&&ie.set(R,k.current?.saveViewState()),k.current?.setModel(c),f&&k.current?.restoreViewState(ie.get(i)))}),[i],M),X((()=>{k.current?.updateOptions(l)}),[l],M),X((()=>{!k.current||void 0===n||(k.current.getOption(E.current.editor.EditorOption.readOnly)?k.current.setValue(n):n!==k.current.getValue()&&(L.current=!0,k.current.executeEdits("",[{range:k.current.getModel().getFullModelRange(),text:n,forceMoveMarkers:!0}]),k.current.pushUndoStop(),L.current=!1))}),[n],M),X((()=>{let e=k.current?.getModel();e&&o&&E.current?.editor.setModelLanguage(e,o)}),[o],M),X((()=>{void 0!==u&&k.current?.revealLine(u)}),[u],M),X((()=>{E.current?.editor.setTheme(c)}),[c],M);let C=(0,U.useCallback)((()=>{if(H.current&&E.current&&!S.current){x.current(E.current);let a=i||r,d=te(E.current,n||e||"",t||o||"",a||"");k.current=E.current?.editor.create(H.current,{model:d,automaticLayout:!0,...l},s),f&&k.current.restoreViewState(ie.get(a)),E.current.editor.setTheme(c),void 0!==u&&k.current.revealLine(u),j(!0),S.current=!0}}),[e,t,r,n,o,i,l,s,f,c,u]);return(0,U.useEffect)((()=>{M&&V.current(k.current,E.current)}),[M]),(0,U.useEffect)((()=>{!O&&!M&&C()}),[O,M,C]),T.current=n,(0,U.useEffect)((()=>{M&&b&&(P.current?.dispose(),P.current=k.current?.onDidChangeModelContent((e=>{L.current||b(k.current.getValue(),e)})))}),[M,b]),(0,U.useEffect)((()=>{if(M){let e=E.current.editor.onDidChangeMarkers((e=>{let t=k.current.getModel()?.uri;if(t&&e.find((e=>e.path===t.path))){let e=E.current.editor.getModelMarkers({resource:t});w?.(e)}}));return()=>{e?.dispose()}}return()=>{}}),[M,w]),U.createElement(K,{width:h,height:v,isEditorReady:M,loading:a,_ref:H,className:p,wrapperProps:g})};(0,U.memo)(ce)}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/194-da10d06ed5c55a8f.js b/dsql-app/.local_dist/static/chunks/194-da10d06ed5c55a8f.js new file mode 100644 index 0000000..87db245 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/194-da10d06ed5c55a8f.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[194],{61781:function(e,a,t){t.d(a,{Z:function(){return s}});var n=t(85893),l=(t(67294),t(42065));function s(){return(0,n.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:function(e){window.history.back()},children:(0,n.jsx)(l.Z,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},79230:function(e,a,t){t.d(a,{Z:function(){return s}});var n=t(85893),l=(t(67294),t(76915));function s(e){var a=e.slugText,t=e.justIcon,s=e.title,i=e.outlined;return(0,n.jsxs)("div",{className:"button small-text"+(i?" outlined gray bg-white":" ghost light-gray"),onClick:function(e){navigator.clipboard.writeText(a).then((function(){alert('Copied: "'.concat(a,'"'))}))},style:i?void 0:{padding:0},children:[(0,n.jsx)(l.Z,{size:i?15:20}),!t&&(0,n.jsx)("span",{className:"text-slate-500 dark:text-slate-300",children:s||"Copy Slug"})]})}},4423:function(e,a,t){t.d(a,{Z:function(){return x}});var n=t(828),l=t(85893),s=t(67294),i=t(79230),o=t(96355),d=t(87851),c=t(5467),r=t(57632),u=t(85541),m=t(86729),h=t(95264),f=t(8971),b=t(58261);function x(e){var a,t,d=e.database,c=(e.query,e.confirmedDelegetedUser),r=e.user,u=d.active_clone,m=(d.active_clone_parent_db,null===c||void 0===c?void 0:c.delegated),h=(null===c||void 0===c||null===(a=c.priviledges)||void 0===a||a.match(/Edit Tables/i),null===c||void 0===c||null===(t=c.priviledges)||void 0===t||t.match(/Delete Tables/i),(0,n.Z)(s.useState(null),2));h[0],h[1];return(0,l.jsxs)("div",{className:"flex-wrap justify-center gap-4",children:[(0,l.jsxs)("div",{className:"dropdown-wrapper gap-4",children:[(0,l.jsxs)("div",{className:"relative",children:[(0,l.jsxs)("div",{className:"w-8 h-8 relative",children:[(0,l.jsx)("img",{src:d.db_image,alt:"Database Image",width:20,className:"w-full h-full rounded-full object-cover"}),(null===c||void 0===c?void 0:c.delegated)&&(0,l.jsxs)("div",{className:" absolute -bottom-2 left-5 gap-1",children:[(0,l.jsx)("img",{src:c.rootUserImage,alt:"Root User Image",className:"w-5 h-5 rounded-full object-cover border-2 border-white dark:border-slate-800 border-solid"}),(0,l.jsx)("span",{className:"text-xs",children:c.rootUserEmail})]})]}),(0,l.jsx)("span",{className:"font-semibold text-base"+((null===c||void 0===c?void 0:c.delegated)?" -mt-3":""),children:d.db_name})]}),(0,l.jsx)(f.Z,{size:20}),(0,l.jsxs)("div",{className:"dropdown p-0",children:[(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("a",{href:"/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(d.db_slug,"/edit-database"),className:"button plain-text more-padding normal-weight",children:"Edit Database"}),(0,l.jsx)("hr",{className:"m-0"}),!u&&(0,l.jsxs)(s.Fragment,{children:[(0,l.jsx)("a",{href:"/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/add-database?duplicate=").concat(d.db_full_name),className:"button plain-text more-padding normal-weight",children:"Duplicate Database"}),(0,l.jsx)("hr",{className:"m-0"})]}),(0,l.jsx)("a",{href:"/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(d.db_slug,"/schema"),className:"button plain-text more-padding normal-weight",children:"Schema"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("a",{href:"/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(d.db_slug,"/users"),className:"button plain-text more-padding normal-weight",children:"Database Users"}),!m&&(0,l.jsx)(v,{database:d,user:r})]})]}),(0,l.jsx)("hr",{className:"vertical"}),(0,l.jsx)(i.Z,{slugText:d.db_slug,title:"Copy Database Slug"}),!m&&(0,l.jsxs)(s.Fragment,{children:[(0,l.jsx)("hr",{className:"vertical"}),(0,l.jsxs)("a",{href:"/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(d.db_slug,"/shell"),className:"button ghost small-text",style:{height:"30px",padding:0},children:[(0,l.jsx)(b.Z,{size:20}),(0,l.jsx)("span",{className:"text-sm font-semibold",children:"Shell"})]})]}),(0,l.jsx)("hr",{className:"vertical"}),(0,l.jsx)(o.Z,{})]})}function v(e){var a=e.database,t=e.user,i=(0,n.Z)(s.useState(!1),2),o=i[0],f=i[1],b=s.useRef();return(0,l.jsxs)(s.Fragment,{children:[o&&(0,l.jsx)(h.Z,{width:"20px"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("a",{href:"/admin/".concat(null===t||void 0===t?void 0:t.id,"/databases/").concat(a.db_slug,"/shell"),className:"button plain-text more-padding normal-weight",children:"Shell"}),(0,l.jsx)("hr",{className:"m-0"}),1==(null===a||void 0===a?void 0:a.remote_connected)?(0,l.jsx)(g,{database:a}):(0,l.jsx)("a",{href:"/admin/".concat(null===t||void 0===t?void 0:t.id,"/databases/").concat(a.db_slug,"/connect"),className:"button plain-text more-padding normal-weight",children:"Connect"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsxs)("button",{className:"button plain-text more-padding normal-weight w-full",onClick:function(e){(0,d.Z)({url:"/api/exportDatabase?dbName=".concat(a.db_full_name),fileName:"".concat(a.db_full_name,".sql")})},children:[(0,l.jsx)(c.Z,{fontSize:"small",color:"action",className:"opacity-50"}),(0,l.jsx)("span",{children:"Export Database"})]}),(0,l.jsx)("input",{type:"file",name:"upload-update-schema",id:"",ref:b,className:"hidden"}),(0,l.jsxs)("button",{className:"button green outlined more-padding normal-weight w-full rounded-none -mb-[1px]",onClick:function(e){var t;b.current&&(b.current.addEventListener("change",(function(e){var t,n=null===(t=e.target.files)||void 0===t?void 0:t[0];if(n){var l=new FileReader;l.onload=function(e){var t,n=null===(t=e.target)||void 0===t?void 0:t.result;n||alert("Invalid File!");try{var l=null===n||void 0===n?void 0:n.toString();if(!l)throw new Error("Invalid File!");var s=JSON.parse(l);window.confirm("Are you sure you want to use this schema file for the current database?")&&window.confirm("Remember if any existing table doesn't exist in the new schema file that table and all its content will be erased forever. Continue?")&&(f(!0),(0,m.Z)("/api/user-schema/replace-database-schema",{method:"POST",body:{schema:s,dbId:a.id}},!0).then((function(e){e.success&&window.location.reload()})).finally((function(){f(!1)})))}catch(i){alert("Invalid File. Please enter a valid JSON file")}},l.readAsText(n)}else alert("No File Selected")})),null===(t=b.current)||void 0===t||t.click())},children:[(0,l.jsx)(u.Z,{fontSize:"small",color:"action",className:"opacity-50 text-inherit"}),(0,l.jsx)("span",{children:"Update From Schema"})]}),(0,l.jsxs)("button",{className:"button secondary outlined more-padding normal-weight w-full rounded-none",onClick:function(e){(0,d.Z)({url:"/api/downloadDatabaseSchema?dbName=".concat(a.db_full_name),fileName:"".concat(a.db_full_name,".json")})},children:[(0,l.jsx)(r.Z,{fontSize:"small",color:"action",className:"opacity-50 text-inherit"}),(0,l.jsx)("span",{children:"Download Schema"})]})]})}function g(e){var a=e.database;return(0,l.jsx)("button",{className:"button plain-text more-padding normal-weight w-full",onClick:function(e){window.confirm("Disconnect this Database from the remote host?")&&(0,m.Z)("/api/connect/disconnect",{method:"POST",body:{dbId:a.id}},!0).then((function(e){e.success?window.location.reload():(console.log(e),alert(e.msg||"Remote disconnection failed. Please try again."))}))},children:"Disconnect"})}},87851:function(e,a,t){function n(e){var a=e.url,t=e.fileName,n=e.setLoading;n&&n(!0),fetch(a,{method:"GET",headers:{"x-csrf-auth":localStorage.getItem("csrf")}}).then((function(e){return e.body})).then((function(e){var a=null===e||void 0===e?void 0:e.getReader();if(a)return new ReadableStream({start:function(e){return function t(){return null===a||void 0===a?void 0:a.read().then((function(a){var n=a.done,l=a.value;if(!n)return e.enqueue(l),t();e.close()}))}()}})})).then((function(e){return new Response(e)})).then((function(e){return e.blob()})).then((function(e){return URL.createObjectURL(e)})).then((function(e){var a=document.createElement("a");a.href=e,a.download=t,a.style.display="none",document.body.appendChild(a),a.click(),URL.revokeObjectURL(e),document.body.removeChild(a),setTimeout((function(){n&&n(!1)}),1e3)})).catch((function(e){console.log(e),setTimeout((function(){n&&n(!1)}),1e3)}))}t.d(a,{Z:function(){return n}})}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/2378-3a97fbefe0f48bac.js b/dsql-app/.local_dist/static/chunks/2378-3a97fbefe0f48bac.js new file mode 100644 index 0000000..38818f6 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/2378-3a97fbefe0f48bac.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2378],{44114:function(e,t,l){l.d(t,{Z:function(){return a}});var n=l(85893),i=l(8971);l(67294);function a(e){var t=e.selectOptions,l=e.name,a=e.onChangeHandler,o=e.required,s=e.setAlert,r=e.title,d=e.defaultValue,c=e.info,u=e.id;try{var m=function(e){if(!(e.type.match(/enter/i)&&window.innerWidth<1200)){var t=e.target.closest(".info-wrapper"),l=t.querySelector(".info-dropdown");!e.type.match(/leave/i)||l.classList.contains("hidden")?e.type.match(/leave/i)&&l.classList.contains("hidden")||(t&&l.classList.contains("hidden")?l.classList.remove("hidden"):l.classList.add("hidden")):l.classList.add("hidden")}};return(0,n.jsxs)("div",{className:"form-select-block flex items-start flex-col gap-0.5 w-full relative"+(c?" pr-8":""),children:[r&&(0,n.jsxs)("label",{htmlFor:l,children:[r,o?"":" (optional)"]}),(0,n.jsxs)("div",{className:"flex items-center w-full relative",children:[(0,n.jsx)("select",{name:l,id:u||l,className:"w-full bg-white",required:o,onChange:function(e){s&&s(null),e.target.classList.remove("warning"),a&&a(e)},defaultValue:d||void 0,children:t.map((function(e,t){var l=e.payload,i=e.title;return(0,n.jsx)("option",{value:l,selected:!!e.default,children:i},t+1)}))}),(0,n.jsx)(i.Z,{className:"absolute right-2 text-base text-slate-500 pointer-events-none",size:20}),c&&(0,n.jsxs)("div",{className:"info-wrapper absolute -right-10 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10",style:{top:"50%",transform:"translate(0,-50%)"},onMouseEnter:m,onMouseLeave:m,onClick:m,children:[(0,n.jsx)("img",{src:"/images/info-outlined-black.png",alt:"",className:"w-6 h-6 object-contain opacity-60 pointer-events-none"}),(0,n.jsx)("div",{className:"info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid",children:(0,n.jsx)("span",{children:c})}),(0,n.jsx)("div",{className:"absolute -top-2 w-12",style:{height:"45px"}})]})]})]})}catch(h){return console.log("ERROR in FormSelect =>",h),(0,n.jsx)("div",{children:"Form Select Error"})}}},61781:function(e,t,l){l.d(t,{Z:function(){return a}});var n=l(85893),i=(l(67294),l(42065));function a(){return(0,n.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:function(e){window.history.back()},children:(0,n.jsx)(i.Z,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},424:function(e,t,l){l.d(t,{Z:function(){return o}});var n=l(828),i=l(85893),a=l(67294);function o(e){var t,l,o,s=e.confirmedDelegetedUser,r=e.linksArray,d=e.user,c=(null===s||void 0===s||s.delegated,null===s||void 0===s||null===(t=s.priviledges)||void 0===t||t.match(/Edit Tables/i),null===s||void 0===s||null===(l=s.priviledges)||void 0===l||l.match(/Delete Tables/i),null===s||void 0===s||null===(o=s.priviledges)||void 0===o||o.match(/Create Tables/i),a.useState(r||null)),u=(0,n.Z)(c,2),m=u[0],h=u[1];return a.useEffect((function(){var e;if(!r){var t=window.location.pathname,l=t.split("/"),n=[];n.push({title:"Home",path:t.match(/admin/)?"/admin":"/"});null===(e=window.location.search)||void 0===e||e.match(/delegated=true/);l.forEach((function(e,t,l){(null===e||void 0===e?void 0:e.match(/./))&&1!=t&&(e.match(/^\d+$/)&&d||n.push({title:e,path:function(){for(var e="",n=0;nt||!i.match(/./)||(e+="/".concat(i))}return e}()}))})),h(n)}}),[]),m&&m[1]?(0,i.jsx)("div",{className:"text-sm mt-2 flex-wrap",children:m.map((function(e,t,l){return t===m.length-1?(0,i.jsx)("a",{href:e.path,className:"text-slate-400 dark:text-slate-500 pointer-events-none",children:e.title},t):(0,i.jsxs)(a.Fragment,{children:[(0,i.jsx)("a",{href:e.path,className:"query-url",children:e.title}),(0,i.jsx)("span",{className:"opacity-20",children:"|"})]},t)}))}):(0,i.jsx)(a.Fragment,{})}},92378:function(e,t,l){l.d(t,{Z:function(){return F}});var n=l(828),i=l(85893),a=l(67294),o=l(27901),s=l(95264),r=l(90918),d=l(45449),c=l(64914),u=l(34999),m=l(96673),h=l(77533),v=l(54689),x=l(50594);function f(e){var t,l=e.targetElement,n=e.setOpenStyleModal;return l?(0,i.jsxs)("div",{className:"flex flex-col items-stretch p-6 max-w-lg",children:[(0,i.jsxs)("div",{className:"w-full justify-between",children:[(0,i.jsx)("span",{className:"text-xl",children:"Element Style"}),(0,i.jsx)("button",{className:"w-10 h-10 plain-text",onClick:function(){n(!1)},children:(0,i.jsx)(x.Z,{})})]}),(0,i.jsxs)("div",{className:"items-stretch p-2 bg-slate-100 rounded add-css-block",children:[(0,i.jsx)("input",{type:"text",placeholder:"CSS key"}),(0,i.jsx)("input",{type:"text",placeholder:"CSS Value",onKeyDownCapture:function(e){var t,n=e.target;if(null===(t=e.key)||void 0===t?void 0:t.match(/enter/i)){var i,a,o=null===(i=n.closest(".add-css-block"))||void 0===i?void 0:i.children[0],s=null===(a=n.closest(".add-css-block"))||void 0===a?void 0:a.children[1],r=null===o||void 0===o?void 0:o.value,d=null===s||void 0===s?void 0:s.value;if(!(null===r||void 0===r?void 0:r.match(/./))||!(null===d||void 0===d?void 0:d.match(/./)))return;l.style[r]=d}}}),(0,i.jsx)("button",{onClick:function(e){var t,n,i=e.target,a=null===(t=i.closest(".add-css-block"))||void 0===t?void 0:t.children[0],o=null===(n=i.closest(".add-css-block"))||void 0===n?void 0:n.children[1],s=null===a||void 0===a?void 0:a.value,r=null===o||void 0===o?void 0:o.value;(null===s||void 0===s?void 0:s.match(/./))&&(null===r||void 0===r?void 0:r.match(/./))&&(l.style[s]=r)},children:"Add"})]}),(0,i.jsxs)("div",{className:"flex-wrap",children:[(0,i.jsx)("button",{onClick:function(e){l.removeAttribute("style")},className:"secondary grow",children:"Reset"}),(0,i.jsx)("button",{onClick:function(e){l.style.display="flex",l.style.alignItems="center",l.style.gap="10px"},className:"outlined black grow",children:"Flex"}),(0,i.jsx)("button",{onClick:function(e){l.style.backgroundColor="rgb(241 245 249)"},className:"outlined black grow",children:"BG-Slate-100"}),(0,i.jsx)("button",{onClick:function(e){l.style.backgroundColor="#F6F4F8"},className:"outlined black grow",children:"BG-Main-light"}),(0,i.jsx)("button",{onClick:function(e){l.style.padding="10px"},className:"outlined black grow",children:"Padding-10px"}),(0,i.jsx)("button",{onClick:function(e){l.style.padding="10px 20px"},className:"outlined black grow",children:"Padding-10px-20px"}),(0,i.jsx)("button",{onClick:function(e){l.style.borderRadius="5px"},className:"outlined black grow",children:"Border-Radius-5px"}),(0,i.jsx)("button",{onClick:function(e){l.style.border="1px solid rgb(241 245 249)"},className:"outlined black grow",children:"Border-Slate-100"}),(0,i.jsx)("button",{onClick:function(e){l.style.border="1px solid rgb(226 232 240)"},className:"outlined black grow",children:"Border-Slate-200"}),(0,i.jsx)("button",{onClick:function(e){l.style.border="1px solid rgb(203 213 225)"},className:"outlined black grow",children:"Border-Slate-300"})]}),(0,i.jsx)("span",{className:"font-semibold text-xl mt-4",children:"Add class Name"}),(0,i.jsxs)("div",{className:"items-stretch p-2 bg-slate-100 rounded add-class-name-block",children:[(0,i.jsx)("input",{type:"text",placeholder:"Class Name",onKeyDownCapture:function(e){var t,n,i=null===(t=e.target.closest(".add-class-name-block"))||void 0===t?void 0:t.children[0];if(null===(n=e.key)||void 0===n?void 0:n.match(/enter/i)){var a=null===i||void 0===i?void 0:i.value;if(!(null===a||void 0===a?void 0:a.match(/./)))return;l.classList.add(a)}}}),(0,i.jsx)("button",{onClick:function(e){var t,n=null===(t=e.target.closest(".add-class-name-block"))||void 0===t?void 0:t.children[0],i=null===n||void 0===n?void 0:n.value;(null===i||void 0===i?void 0:i.match(/./))&&l.classList.add(i)},children:"Add"}),(0,i.jsx)("button",{onClick:function(e){var t,n=null===(t=e.target.closest(".add-class-name-block"))||void 0===t?void 0:t.children[0],i=null===n||void 0===n?void 0:n.value;(null===i||void 0===i?void 0:i.match(/./))&&l.classList.remove(i)},className:"outlined",children:"Remove"})]}),(null===l||void 0===l||null===(t=l.nodeName)||void 0===t?void 0:t.match(/^a$/i))?(0,i.jsxs)(a.Fragment,{children:[(0,i.jsx)("span",{className:"font-semibold text-xl mt-4",children:"Add URL"}),(0,i.jsxs)("div",{className:"items-stretch p-2 bg-slate-100 rounded href-block",children:[(0,i.jsx)("input",{type:"text",placeholder:"Class Name",onKeyDownCapture:function(e){var t,n,i=null===(t=e.target.closest(".href-block"))||void 0===t?void 0:t.children[0];if(null===(n=e.key)||void 0===n?void 0:n.match(/enter/i)){var a=null===i||void 0===i?void 0:i.value;if(!(null===a||void 0===a?void 0:a.match(/./)))return;l.href=a}},defaultValue:null===l||void 0===l?void 0:l.href}),(0,i.jsx)("button",{onClick:function(e){var t,n=null===(t=e.target.closest(".href-block"))||void 0===t?void 0:t.children[0],i=null===n||void 0===n?void 0:n.value;(null===i||void 0===i?void 0:i.match(/./))&&(l.href=i)},children:"Add"})]})]}):(0,i.jsx)(a.Fragment,{})]}):null}function p(e){var t=e.targetElement,l=e.back;if(t){var n=t.nextElementSibling,i=t.previousElementSibling;!l&&n?n.after(t):l&&i&&i.before(t)}}function g(e){var t,l,n,i=e.editor,a=e.node,o=e.setTargetElement;i.getDoc().querySelectorAll(".target-node").forEach((function(e){e.classList.remove("target-node")}));var s=null===(t=i.getWin().getSelection())||void 0===t||null===(l=t.anchorNode)||void 0===l?void 0:l.parentElement,r=a||(s||null);r&&(null===r||void 0===r||null===(n=r.classList)||void 0===n||n.add("target-node"),o&&o(r))}var b=l(2896),j=l(75307),y=l(71685),w=l(90629),k=l(86729);function N(e){var t=e.targetElement,l=e.setTargetElement,o=e.editor,r=e.setOpenSnippetsModal,d=(0,n.Z)(a.useState(!0),2),c=d[0],u=d[1],m=(0,n.Z)(a.useState([]),2),h=m[0],v=m[1];return a.useEffect((function(){(0,k.Z)("/api/admin/docs/get-snippets",{method:"post",body:{}}).then((function(e){e.success&&(v(e.result),u(!1))}))}),[]),(0,i.jsxs)(w.Z,{className:"m-auto p-6 flex flex-col max-w-xl w-full max-h-[90vh] overflow-y-auto relative",children:[(0,i.jsxs)("div",{className:"w-full justify-between",children:[(0,i.jsx)("span",{className:"text-xl",children:"Snippets"}),(0,i.jsx)("button",{className:"w-10 h-10 plain-text",onClick:function(){r(!1)},children:(0,i.jsx)(x.Z,{})})]}),(0,i.jsxs)("div",{className:"flex-wrap relative w-full min-h-[100px] items-start",children:[c&&(0,i.jsx)(s.Z,{}),h&&Array.isArray(h)&&h[0]&&h.map((function(e,n){return(0,i.jsxs)("div",{className:"flex flex-col w-full items-start p-4 border border-slate-200 border-solid rounded cursor-pointer hover:shadow-lg transition-all hover:bg-slate-100",onClick:function(n){if(t){var i=document.createElement("div");i.innerHTML=Object.values(e)[0];var a=i.firstChild;a&&(t.appendChild(a),g({editor:o,node:a,setTargetElement:l})),r(!1)}else o.insertContent(Object.values(e)[0],{}),r(!1)},children:[(0,i.jsx)("span",{className:"font-semibold text-lg",children:Object.keys(e)[0]}),(0,i.jsx)("div",{className:"w-full block border border-slate-300 border-solid rounded-sm",dangerouslySetInnerHTML:{__html:Object.values(e)[0]}})]},n)}))]})]})}var E=l(89798),C=l(84534),S=l(52521),Z=l(8317),T=l(51645);function L(e){var t=e.editorRef,l=(0,n.Z)(a.useState(null),2),o=l[0],s=l[1],r=(0,n.Z)(a.useState(!1),2),x=r[0],w=r[1],k=(0,n.Z)(a.useState(!1),2),L=k[0],A=k[1];return(0,i.jsxs)("div",{className:"absolute top-[60px] z-50 -left-[38px] w-[40px] flex flex-col items-end",style:{boxShadow:"0 0 40px rgba(15, 23, 42, 0.2)"},children:[(0,i.jsxs)(d.Z,{column:!0,className:"gap-[1px]",children:[(0,i.jsx)("div",{onClick:function(){g({editor:t.current,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button secondary",children:(0,i.jsx)(j.Z,{})}),(0,i.jsx)("div",{onClick:function(){p({targetElement:o,back:!0})},style:{width:"40px",height:"40px"},className:"button dark",children:(0,i.jsx)(T.Z,{})}),(0,i.jsx)("div",{onClick:function(){p({targetElement:o})},style:{width:"40px",height:"40px"},className:"button dark",children:(0,i.jsx)(Z.Z,{})}),(0,i.jsx)("div",{onClick:function(){A(!0)},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(c.Z,{})}),(0,i.jsx)("div",{onClick:function(){w(!0)},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(u.Z,{})}),(0,i.jsx)("div",{onClick:function(){!function(e){var t=e.editor,l=e.targetElement,n=e.setTargetElement;if(t.getWin(),l){var i=l.cloneNode(!0);i.nodeName.match(/html|document|body/i)||(l.insertAdjacentElement("afterend",i),l.classList.remove("target-node"),n(i))}}({editor:t.current,targetElement:o,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(m.Z,{})}),(0,i.jsx)("div",{onClick:function(){!function(e){var t=e.editor,l=e.targetElement,n=e.setTargetElement,i=(t.getWin(),l);if(i&&!i.nodeName.match(/html|document|body/i)){var a=i.parentElement;a||(n(i),g({editor:t,node:i,setTargetElement:n})),(null===a||void 0===a?void 0:a.nodeName.match(/html|document|body/i))?(n(i),g({editor:t,node:i,setTargetElement:n})):a&&(n(a),g({editor:t,node:a,setTargetElement:n}))}}({editor:t.current,targetElement:o,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(b.Z,{})}),(0,i.jsx)("div",{onClick:function(){!function(e){var t=e.editor,l=e.targetElement,n=e.setTargetElement,i=(t.getWin(),l);if(i){var a=i.children[0];a?(n(a),g({editor:t,node:a,setTargetElement:n})):(n(i),g({editor:t,node:i,setTargetElement:n}))}}({editor:t.current,targetElement:o,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(b.Z,{className:"rotate-180"})}),(0,i.jsx)("div",{onClick:function(){!function(e){var t=e.editor,l=e.targetElement,n=e.setTargetElement,i=l;if(i){var a=i.previousElementSibling;a?(n(a),g({editor:t,node:a,setTargetElement:n})):(n(i),g({editor:t,node:i,setTargetElement:n}))}}({editor:t.current,targetElement:o,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(C.Z,{})}),(0,i.jsx)("div",{onClick:function(){!function(e){var t=e.editor,l=e.targetElement,n=e.setTargetElement,i=l;if(i){var a=i.nextElementSibling;a?(n(a),g({editor:t,node:a,setTargetElement:n})):(n(i),g({editor:t,node:i,setTargetElement:n}))}}({editor:t.current,targetElement:o,setTargetElement:s})},style:{width:"40px",height:"40px"},className:"button",children:(0,i.jsx)(E.Z,{})}),(0,i.jsx)("div",{onClick:function(){if(o){var e=o.parentNode;e.removeChild(o),g({editor:t.current,node:e,setTargetElement:s})}},style:{width:"40px",height:"40px"},className:"button bg-red-500",children:(0,i.jsx)(S.Z,{})}),(0,i.jsx)("div",{onClick:function(){t.current.getDoc().querySelectorAll(".target-node").forEach((function(e){e.classList.remove("target-node")})),s(null)},style:{width:"40px",height:"40px"},className:"button white",children:(0,i.jsx)(y.Z,{className:"rotate-180"})})]}),(0,i.jsx)(h.ZP,{open:x,onClose:function(){w(!1)},anchor:"right",children:(0,i.jsx)(f,{targetElement:o,setOpenStyleModal:w})}),(0,i.jsx)(v.Z,{open:L,onClose:function(){A(!1)},children:(0,i.jsx)(N,{targetElement:o,setTargetElement:s,editor:t.current,setOpenSnippetsModal:A})})]})}function A(e){e.user;var t=e.blockObject,l=e.placeholder,o=e.editorRef,s=e.height,d=e.extend,c=(0,n.Z)(a.useState(!1),2);c[0],c[1];return(0,i.jsxs)("div",{className:"relative",children:[(0,i.jsx)(r.M,{tinymceScriptSrc:"/tinymce/tinymce.min.js",onInit:function(e,t){if(d){var l=t.getBody();l.style.padding="40px",l.className="RTE-DOCS"}o&&(o.current=t)},initialValue:t&&t.content?t.content:"",init:{height:s||400,width:"100%",relative_urls:!1,remove_script_host:!1,menubar:!1,plugins:d?["advlist","autolink","lists","link","image","charmap","anchor","searchreplace","visualblocks","code","fullscreen","insertdatetime","media","table","preview","help","wordcount","codesample"]:["link"],toolbar:d?"undo redo | blocks | bold italic forecolor | codesample link image | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | removeformat":"undo redo | blocks | link",content_style:"body { font-family:Helvetica,Arial,sans-serif; font-size:18px }",placeholder:l||"Type something ...",content_css:d?"/styles/tiny.css":void 0,statusbar:!!d}}),d&&o&&(0,i.jsx)(L,{editorRef:o})]})}var O,_=l(61781),R=l(44114),D=l(424);function F(e){var t=e.data,l=e.user,r=!!(null===t||void 0===t?void 0:t.title),d=(0,n.Z)(a.useState(!1),2),c=d[0],u=d[1],m=(0,n.Z)(a.useState(null===t||void 0===t?void 0:t.level),2),h=m[0],v=m[1],x=(0,n.Z)(a.useState(null===t||void 0===t?void 0:t.page_order),2),f=x[0],p=x[1],g=(0,n.Z)(a.useState(null),2),b=g[0],j=g[1],y=(0,n.Z)(a.useState(null),2),w=y[0],N=y[1],E=a.useRef(),C=a.useRef();return a.useEffect((function(){parseInt(h)>1?(window.clearTimeout(O),O=window.setTimeout((function(){(0,k.Z)("/api/admin/docs/grab-parent-pages",{method:"post",body:{pagesLevel:parseInt(h)-1,currentPageId:null===t||void 0===t?void 0:t.id}}).then((function(e){if(e.success&&e.result&&Array.isArray(e.result)&&e.result[0])if(j(e.result),t.parent_id){var l=e.result.filter((function(e){return e.id==t.parent_id}));l[0]?N(l[0]):N(e.result[0])}else N(e.result[0])}))}),500)):(j(null),N(null))}),[h]),(0,i.jsx)(a.Fragment,{children:(0,i.jsxs)("section",{className:"items-start justify-start p-6",children:[(0,i.jsxs)("div",{className:"mb-1",children:[(0,i.jsx)(_.Z,{}),(0,i.jsx)("h2",{className:"text-xl m-0",children:r?"Update page":"Create a new Docs Page"})]}),(0,i.jsx)("div",{className:"mb-4",children:(0,i.jsx)(D.Z,{user:l})}),(0,i.jsxs)("div",{className:"paper flex-col items-stretch gap-10 w-full relative",children:[c&&(0,i.jsx)(s.Z,{}),(0,i.jsxs)("form",{onSubmit:function(e){var l,n,i,a,o,s=function(e){var t=e.href;(null===t||void 0===t?void 0:t.match(/\~/))&&(e.href=t.replace(/.*?\~\//,"/")),(null===t||void 0===t?void 0:t.match(/\.\.\//))&&(e.href=t.replace(/.*?\.\.\//,"/"))};e.preventDefault(),u(!0);var d=e.target.title,c=null===(l=C.current)||void 0===l?void 0:l.getDoc(),m=null===(n=E.current)||void 0===n?void 0:n.getDoc();null===c||void 0===c||c.querySelectorAll(".target-node").forEach((function(e){return e.classList.remove("target-node")})),null===c||void 0===c||c.querySelectorAll("a").forEach((function(e){s(e)})),null===m||void 0===m||m.querySelectorAll("a").forEach((function(e){s(e)}));var v=null===(i=E.current)||void 0===i?void 0:i.getContent(),x=null===(a=C.current)||void 0===a?void 0:a.getBody().innerHTML,p=null===(o=C.current)||void 0===o?void 0:o.getBody().innerText,g={title:d.value,description:v,content:x,text_content:p,level:h,page_order:f};r&&(g.id=t.id),(null===w||void 0===w?void 0:w.id)&&(g.parent_id=w.id),(0,k.Z)("/api/admin/docs/".concat(r?"update-page":"add-page"),{method:"post",body:g}).then((function(e){e.success?window.location.reload():(alert("Operation Failed!"),setTimeout((function(){u(!1)}),1e3))}))},className:"flex flex-col gap-4 w-full",children:[(0,i.jsx)(o.Z,{placeholder:"Enter a title",fontSize:"30px",name:"title",defaultValue:r?t.title:null}),(0,i.jsxs)("div",{className:"card no-hover",children:[(0,i.jsx)(o.Z,{numberText:!0,placeholder:"Level",defaultValue:r?h:"1",maxWidth:"140px",minValue:1,maxValue:4,step:1,name:"page-level",title:"Page Level",setValue:v}),(0,i.jsx)(o.Z,{numberText:!0,placeholder:"Level",defaultValue:r?f:"1",maxWidth:"140px",minValue:1,step:1,name:"page-order",title:"Page Order",setValue:p}),b&&Array.isArray(b)&&(0,i.jsx)(R.Z,{selectOptions:b.map((function(e){return{title:e.title,payload:e.id,default:(null===w||void 0===w?void 0:w.id)==e.id}})),title:"Parent Page",required:!0,onChangeHandler:function(e){var t=b.filter((function(t){return t.id==e.target.value}));t[0]?N(t[0]):window.alert("No Matching parent page!")}})]}),(0,i.jsx)(A,{placeholder:"Describe this page briefly",editorRef:E,blockObject:r?{content:t.description}:null,height:200}),(0,i.jsx)(A,{placeholder:"Page Content",editorRef:C,blockObject:r?{content:t.content}:null,height:600,extend:!0}),(0,i.jsx)("button",{type:"submit",children:r?"Update Page":"Add Page"})]})]})]})})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/2452-ed265b549204d978.js b/dsql-app/.local_dist/static/chunks/2452-ed265b549204d978.js new file mode 100644 index 0000000..8d4e0ec --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/2452-ed265b549204d978.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2452],{75307:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M11.71 17.99C8.53 17.84 6 15.22 6 12c0-3.31 2.69-6 6-6 3.22 0 5.84 2.53 5.99 5.71l-2.1-.63C15.48 9.31 13.89 8 12 8c-2.21 0-4 1.79-4 4 0 1.89 1.31 3.48 3.08 3.89l.63 2.1zM22 12c0 .3-.01.6-.04.9l-1.97-.59c.01-.1.01-.21.01-.31 0-4.42-3.58-8-8-8s-8 3.58-8 8 3.58 8 8 8c.1 0 .21 0 .31-.01l.59 1.97c-.3.03-.6.04-.9.04-5.52 0-10-4.48-10-10S6.48 2 12 2s10 4.48 10 10zm-3.77 4.26L22 15l-10-3 3 10 1.26-3.77 4.27 4.27 1.98-1.98-4.28-4.26z"}),"AdsClickTwoTone");t.Z=a},50027:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"m19.21 12.04-1.53-.11-.3-1.5C16.88 7.86 14.62 6 12 6 9.94 6 8.08 7.14 7.12 8.96l-.5.95-1.07.11C3.53 10.24 2 11.95 2 14c0 2.21 1.79 4 4 4h13c1.65 0 3-1.35 3-3 0-1.55-1.22-2.86-2.79-2.96zm-5.76.96v3h-2.91v-3H8l4-4 4 4h-2.55z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95C8.08 7.14 9.94 6 12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11c1.56.1 2.78 1.41 2.78 2.96 0 1.65-1.35 3-3 3zM8 13h2.55v3h2.9v-3H16l-4-4z"},"1")],"BackupTwoTone");t.Z=a},50594:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close");t.Z=a},64689:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M18 19h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M12 3 6 7.58V6H4v3.11L1 11.4l1.21 1.59L4 11.62V21h16v-9.38l1.79 1.36L23 11.4 12 3zm6 16h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58V19zM10 1c0 1.66-1.34 3-3 3-.55 0-1 .45-1 1H4c0-1.66 1.34-3 3-3 .55 0 1-.45 1-1h2z"},"1")],"CottageTwoTone");t.Z=a},52521:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M8 9h8v10H8z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"m15.5 4-1-1h-5l-1 1H5v2h14V4zM6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM8 9h8v10H8V9z"},"1")],"DeleteTwoTone");t.Z=a},71685:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zM4 12c0-4.4 3.6-8 8-8 1.8 0 3.5.6 4.9 1.7L5.7 16.9C4.6 15.5 4 13.8 4 12zm8 8c-1.8 0-3.5-.6-4.9-1.7L18.3 7.1C19.4 8.5 20 10.2 20 12c0 4.4-3.6 8-8 8z"}),"DoDisturbAltTwoTone");t.Z=a},39269:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M12 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm1 13h-2v-2h2v2zm0-4h-2V7h2v6z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm-1-5h2v2h-2zm0-8h2v6h-2z"},"1")],"ErrorTwoTone");t.Z=a},2896:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M17 5h-2V3h2v2zm-2 10v6l2.29-2.29 2.3 2.29L21 19.59l-2.29-2.29L21 15h-6zm4-6h2V7h-2v2zm0 4h2v-2h-2v2zm-8 8h2v-2h-2v2zM7 5h2V3H7v2zM3 17h2v-2H3v2zm2 4v-2H3c0 1.1.9 2 2 2zM19 3v2h2c0-1.1-.9-2-2-2zm-8 2h2V3h-2v2zM3 9h2V7H3v2zm4 12h2v-2H7v2zm-4-8h2v-2H3v2zm0-8h2V3c-1.1 0-2 .9-2 2z"}),"HighlightAltTwoTone");t.Z=a},28466:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M6 10v10h5.29c-.19-.63-.29-1.3-.29-2 0-3.87 3.13-7 7-7v-1H6z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M6 20V10h12v1c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.42-.6-.75-1.28-.97-2H6zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6z"},"1"),(0,i.jsx)("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5zm0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32z"},"2")],"LockPersonTwoTone");t.Z=a},38544:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("circle",{cx:"9",cy:"8",r:"2",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M9 15c-2.7 0-5.8 1.29-6 2.01V18h12v-1c-.2-.71-3.3-2-6-2z",opacity:".3"},"1"),(0,i.jsx)("path",{d:"M16.67 13.13C18.04 14.06 19 15.32 19 17v3h4v-3c0-2.18-3.57-3.47-6.33-3.87zM15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4c-.47 0-.91.1-1.33.24C14.5 5.27 15 6.58 15 8s-.5 2.73-1.33 3.76c.42.14.86.24 1.33.24zm-6 0c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0-6c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm0 7c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4zm6 5H3v-.99C3.2 16.29 6.3 15 9 15s5.8 1.29 6 2v1z"},"2")],"PeopleAltTwoTone");t.Z=a},89798:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M8 9.86v4.28L11.03 12z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M14.5 12 6 6v12l8.5-6zM8 9.86 11.03 12 8 14.14V9.86zM16 6h2v12h-2z"},"1")],"SkipNextTwoTone");t.Z=a},84534:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M16 14.14V9.86L12.97 12z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M6 6h2v12H6zm12 12V6l-8.5 6 8.5 6zm-2-3.86L12.97 12 16 9.86v4.28z"},"1")],"SkipPreviousTwoTone");t.Z=a},34999:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M15.22 4.75 7.87 7.79l4.96 11.96 7.35-3.05-4.96-11.95zM11 10c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"m3.87 11.18-2.43 5.86c-.41 1.02.08 2.19 1.09 2.61l1.34.56v-9.03zm18.16 4.77L17.07 3.98c-.31-.75-1.04-1.21-1.81-1.23-.26 0-.53.04-.79.15L7.1 5.95c-.75.31-1.21 1.03-1.23 1.8-.01.27.04.54.15.8l4.96 11.97c.31.76 1.05 1.22 1.83 1.23.26 0 .52-.05.77-.15l7.36-3.05c1.02-.42 1.51-1.59 1.09-2.6zm-9.2 3.8L7.87 7.79l7.35-3.04h.01l4.95 11.95-7.35 3.05z"},"1"),(0,i.jsx)("circle",{cx:"11",cy:"9",r:"1"},"2"),(0,i.jsx)("path",{d:"m9.33 21.75-3.45-8.34v6.34c0 1.1.9 2 2 2h1.45z"},"3")],"StyleTwoTone");t.Z=a},51903:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M4 18h16V8H4v10zm8-3h6v2h-6v-2zm-5.91-4.59L7.5 9l4 4-4 4-1.41-1.41L8.67 13l-2.58-2.59z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M12 15h6v2h-6z"},"1"),(0,i.jsx)("path",{d:"M20 4H4c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm0 14H4V8h16v10z"},"2"),(0,i.jsx)("path",{d:"m7.5 17 4-4-4-4-1.41 1.41L8.67 13l-2.58 2.59z"},"3")],"TerminalTwoTone");t.Z=a},51645:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"m18 4-3 3h2v13h2V7h2l-3-3zm-6.2 11.5v-5l2.2-.9V7.5L3 12.25v1.5l11 4.75v-2.1l-2.2-.9zM4.98 13 10 11.13v3.74L4.98 13z"}),"TextRotateUpTwoTone");t.Z=a},8317:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)((0,i.jsx)("path",{d:"M15.75 5h-1.5L9.5 16h2.1l.9-2.2h5l.9 2.2h2.1L15.75 5zm-2.62 7L15 6.98 16.87 12h-3.74zM6 20l3-3H7V4H5v13H3l3 3z"}),"TextRotateVerticalTwoTone");t.Z=a},64914:function(e,t,n){var o=n(64836);t.Z=void 0;var r=o(n(64938)),i=n(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M5 19h14V5H5v14zm7-12h6v2h-6V7zm-3 4h6v2H9v-2zm-3 4h6v2H6v-2z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M6 15h6v2H6zm6-8h6v2h-6zm-3 4h6v2H9z"},"1"),(0,i.jsx)("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"},"2")],"ViewTimelineTwoTone");t.Z=a},77533:function(e,t,n){n.d(t,{ZP:function(){return L}});var o=n(63366),r=n(87462),i=n(67294),a=n(90512),s=n(94780),l=n(54689),c=n(84527),d=n(46644),u=n(51705),p=n(2734),h=n(30577),v=n(5340),f=n(85893);const m=["addEndListener","appear","children","container","direction","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function x(e,t,n){var o;const r=function(e,t,n){const o=t.getBoundingClientRect(),r=n&&n.getBoundingClientRect(),i=(0,v.Z)(t);let a;if(t.fakeTransform)a=t.fakeTransform;else{const e=i.getComputedStyle(t);a=e.getPropertyValue("-webkit-transform")||e.getPropertyValue("transform")}let s=0,l=0;if(a&&"none"!==a&&"string"===typeof a){const e=a.split("(")[1].split(")")[0].split(",");s=parseInt(e[4],10),l=parseInt(e[5],10)}return"left"===e?r?`translateX(${r.right+s-o.left}px)`:`translateX(${i.innerWidth+s-o.left}px)`:"right"===e?r?`translateX(-${o.right-r.left-s}px)`:`translateX(-${o.left+o.width-s}px)`:"up"===e?r?`translateY(${r.bottom+l-o.top}px)`:`translateY(${i.innerHeight+l-o.top}px)`:r?`translateY(-${o.top-r.top+o.height-l}px)`:`translateY(-${o.top+o.height-l}px)`}(e,t,"function"===typeof(o=n)?o():o);r&&(t.style.webkitTransform=r,t.style.transform=r)}var Z=i.forwardRef((function(e,t){const n=(0,p.Z)(),a={enter:n.transitions.easing.easeOut,exit:n.transitions.easing.sharp},s={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:l,appear:Z=!0,children:g,container:b,direction:y="down",easing:E=a,in:k,onEnter:z,onEntered:T,onEntering:w,onExit:M,onExited:R,onExiting:P,style:C,timeout:S=s,TransitionComponent:j=c.ZP}=e,L=(0,o.Z)(e,m),A=i.useRef(null),H=(0,u.Z)(g.ref,A,t),N=e=>t=>{e&&(void 0===t?e(A.current):e(A.current,t))},V=N(((e,t)=>{x(y,e,b),(0,h.n)(e),z&&z(e,t)})),I=N(((e,t)=>{const o=(0,h.C)({timeout:S,style:C,easing:E},{mode:"enter"});e.style.webkitTransition=n.transitions.create("-webkit-transform",(0,r.Z)({},o)),e.style.transition=n.transitions.create("transform",(0,r.Z)({},o)),e.style.webkitTransform="none",e.style.transform="none",w&&w(e,t)})),D=N(T),B=N(P),F=N((e=>{const t=(0,h.C)({timeout:S,style:C,easing:E},{mode:"exit"});e.style.webkitTransition=n.transitions.create("-webkit-transform",t),e.style.transition=n.transitions.create("transform",t),x(y,e,b),M&&M(e)})),O=N((e=>{e.style.webkitTransition="",e.style.transition="",R&&R(e)})),$=i.useCallback((()=>{A.current&&x(y,A.current,b)}),[y,b]);return i.useEffect((()=>{if(k||"down"===y||"right"===y)return;const e=(0,d.Z)((()=>{A.current&&x(y,A.current,b)})),t=(0,v.Z)(A.current);return t.addEventListener("resize",e),()=>{e.clear(),t.removeEventListener("resize",e)}}),[y,k,b]),i.useEffect((()=>{k||$()}),[k,$]),(0,f.jsx)(j,(0,r.Z)({nodeRef:A,onEnter:V,onEntered:D,onEntering:I,onExit:F,onExited:O,onExiting:B,addEndListener:e=>{l&&l(A.current,e)},appear:Z,in:k,timeout:S},L,{children:(e,t)=>i.cloneElement(g,(0,r.Z)({ref:H,style:(0,r.Z)({visibility:"exited"!==e||k?void 0:"hidden"},C,g.props.style)},t))}))})),g=n(90629),b=n(98216),y=n(54502),E=n(2641),k=n(1588),z=n(34867);function T(e){return(0,z.Z)("MuiDrawer",e)}(0,k.Z)("MuiDrawer",["root","docked","paper","paperAnchorLeft","paperAnchorRight","paperAnchorTop","paperAnchorBottom","paperAnchorDockedLeft","paperAnchorDockedRight","paperAnchorDockedTop","paperAnchorDockedBottom","modal"]);const w=["BackdropProps"],M=["anchor","BackdropProps","children","className","elevation","hideBackdrop","ModalProps","onClose","open","PaperProps","SlideProps","TransitionComponent","transitionDuration","variant"],R=(e,t)=>{const{ownerState:n}=e;return[t.root,("permanent"===n.variant||"persistent"===n.variant)&&t.docked,t.modal]},P=(0,E.ZP)(l.Z,{name:"MuiDrawer",slot:"Root",overridesResolver:R})((({theme:e})=>({zIndex:(e.vars||e).zIndex.drawer}))),C=(0,E.ZP)("div",{shouldForwardProp:E.FO,name:"MuiDrawer",slot:"Docked",skipVariantsResolver:!1,overridesResolver:R})({flex:"0 0 auto"}),S=(0,E.ZP)(g.Z,{name:"MuiDrawer",slot:"Paper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.paper,t[`paperAnchor${(0,b.Z)(n.anchor)}`],"temporary"!==n.variant&&t[`paperAnchorDocked${(0,b.Z)(n.anchor)}`]]}})((({theme:e,ownerState:t})=>(0,r.Z)({overflowY:"auto",display:"flex",flexDirection:"column",height:"100%",flex:"1 0 auto",zIndex:(e.vars||e).zIndex.drawer,WebkitOverflowScrolling:"touch",position:"fixed",top:0,outline:0},"left"===t.anchor&&{left:0},"top"===t.anchor&&{top:0,left:0,right:0,height:"auto",maxHeight:"100%"},"right"===t.anchor&&{right:0},"bottom"===t.anchor&&{top:"auto",left:0,bottom:0,right:0,height:"auto",maxHeight:"100%"},"left"===t.anchor&&"temporary"!==t.variant&&{borderRight:`1px solid ${(e.vars||e).palette.divider}`},"top"===t.anchor&&"temporary"!==t.variant&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`},"right"===t.anchor&&"temporary"!==t.variant&&{borderLeft:`1px solid ${(e.vars||e).palette.divider}`},"bottom"===t.anchor&&"temporary"!==t.variant&&{borderTop:`1px solid ${(e.vars||e).palette.divider}`}))),j={left:"right",right:"left",top:"down",bottom:"up"};var L=i.forwardRef((function(e,t){const n=(0,y.Z)({props:e,name:"MuiDrawer"}),l=(0,p.Z)(),c={enter:l.transitions.duration.enteringScreen,exit:l.transitions.duration.leavingScreen},{anchor:d="left",BackdropProps:u,children:h,className:v,elevation:m=16,hideBackdrop:x=!1,ModalProps:{BackdropProps:g}={},onClose:E,open:k=!1,PaperProps:z={},SlideProps:R,TransitionComponent:L=Z,transitionDuration:A=c,variant:H="temporary"}=n,N=(0,o.Z)(n.ModalProps,w),V=(0,o.Z)(n,M),I=i.useRef(!1);i.useEffect((()=>{I.current=!0}),[]);const D=function(e,t){return"rtl"===e.direction&&function(e){return-1!==["left","right"].indexOf(e)}(t)?j[t]:t}(l,d),B=d,F=(0,r.Z)({},n,{anchor:B,elevation:m,open:k,variant:H},V),O=(e=>{const{classes:t,anchor:n,variant:o}=e,r={root:["root"],docked:[("permanent"===o||"persistent"===o)&&"docked"],modal:["modal"],paper:["paper",`paperAnchor${(0,b.Z)(n)}`,"temporary"!==o&&`paperAnchorDocked${(0,b.Z)(n)}`]};return(0,s.Z)(r,T,t)})(F),$=(0,f.jsx)(S,(0,r.Z)({elevation:"temporary"===H?m:0,square:!0},z,{className:(0,a.Z)(O.paper,z.className),ownerState:F,children:h}));if("permanent"===H)return(0,f.jsx)(C,(0,r.Z)({className:(0,a.Z)(O.root,O.docked,v),ownerState:F,ref:t},V,{children:$}));const K=(0,f.jsx)(L,(0,r.Z)({in:k,direction:j[D],timeout:A,appear:I.current},R,{children:$}));return"persistent"===H?(0,f.jsx)(C,(0,r.Z)({className:(0,a.Z)(O.root,O.docked,v),ownerState:F,ref:t},V,{children:K})):(0,f.jsx)(P,(0,r.Z)({BackdropProps:(0,r.Z)({},u,g,{transitionDuration:A}),className:(0,a.Z)(O.root,O.modal,v),open:k,ownerState:F,onClose:E,hideBackdrop:x,ref:t},V,N,{children:K}))}))},54689:function(e,t,n){n.d(t,{Z:function(){return q}});var o=n(63366),r=n(87462),i=n(67294),a=n(90512),s=n(78987),l=n(33703),c=n(82690),d=n(59948),u=n(49064),p=n(30437),h=n(74161);function v(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function f(e){return parseInt((0,h.Z)(e).getComputedStyle(e).paddingRight,10)||0}function m(e,t,n,o,r){const i=[t,n,...o];[].forEach.call(e.children,(e=>{const t=-1===i.indexOf(e),n=!function(e){const t=-1!==["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName),n="INPUT"===e.tagName&&"hidden"===e.getAttribute("type");return t||n}(e);t&&n&&v(e,r)}))}function x(e,t){let n=-1;return e.some(((e,o)=>!!t(e)&&(n=o,!0))),n}function Z(e,t){const n=[],o=e.container;if(!t.disableScrollLock){if(function(e){const t=(0,c.Z)(e);return t.body===e?(0,h.Z)(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}(o)){const e=function(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}((0,c.Z)(o));n.push({value:o.style.paddingRight,property:"padding-right",el:o}),o.style.paddingRight=`${f(o)+e}px`;const t=(0,c.Z)(o).querySelectorAll(".mui-fixed");[].forEach.call(t,(t=>{n.push({value:t.style.paddingRight,property:"padding-right",el:t}),t.style.paddingRight=`${f(t)+e}px`}))}let e;if(o.parentNode instanceof DocumentFragment)e=(0,c.Z)(o).body;else{const t=o.parentElement,n=(0,h.Z)(o);e="HTML"===(null==t?void 0:t.nodeName)&&"scroll"===n.getComputedStyle(t).overflowY?t:o}n.push({value:e.style.overflow,property:"overflow",el:e},{value:e.style.overflowX,property:"overflow-x",el:e},{value:e.style.overflowY,property:"overflow-y",el:e}),e.style.overflow="hidden"}return()=>{n.forEach((({value:e,el:t,property:n})=>{e?t.style.setProperty(n,e):t.style.removeProperty(n)}))}}const g=new class{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(e,t){let n=this.modals.indexOf(e);if(-1!==n)return n;n=this.modals.length,this.modals.push(e),e.modalRef&&v(e.modalRef,!1);const o=function(e){const t=[];return[].forEach.call(e.children,(e=>{"true"===e.getAttribute("aria-hidden")&&t.push(e)})),t}(t);m(t,e.mount,e.modalRef,o,!0);const r=x(this.containers,(e=>e.container===t));return-1!==r?(this.containers[r].modals.push(e),n):(this.containers.push({modals:[e],container:t,restore:null,hiddenSiblings:o}),n)}mount(e,t){const n=x(this.containers,(t=>-1!==t.modals.indexOf(e))),o=this.containers[n];o.restore||(o.restore=Z(o,t))}remove(e,t=!0){const n=this.modals.indexOf(e);if(-1===n)return n;const o=x(this.containers,(t=>-1!==t.modals.indexOf(e))),r=this.containers[o];if(r.modals.splice(r.modals.indexOf(e),1),this.modals.splice(n,1),0===r.modals.length)r.restore&&r.restore(),e.modalRef&&v(e.modalRef,t),m(r.container,e.mount,e.modalRef,r.hiddenSiblings,!1),this.containers.splice(o,1);else{const e=r.modals[r.modals.length-1];e.modalRef&&v(e.modalRef,!1)}return n}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}};function b(e){const{container:t,disableEscapeKeyDown:n=!1,disableScrollLock:o=!1,manager:a=g,closeAfterTransition:s=!1,onTransitionEnter:h,onTransitionExited:f,children:m,onClose:x,open:Z,rootRef:b}=e,y=i.useRef({}),E=i.useRef(null),k=i.useRef(null),z=(0,l.Z)(k,b),[T,w]=i.useState(!Z),M=function(e){return!!e&&e.props.hasOwnProperty("in")}(m);let R=!0;"false"!==e["aria-hidden"]&&!1!==e["aria-hidden"]||(R=!1);const P=()=>(y.current.modalRef=k.current,y.current.mount=E.current,y.current),C=()=>{a.mount(P(),{disableScrollLock:o}),k.current&&(k.current.scrollTop=0)},S=(0,d.Z)((()=>{const e=function(e){return"function"===typeof e?e():e}(t)||(0,c.Z)(E.current).body;a.add(P(),e),k.current&&C()})),j=i.useCallback((()=>a.isTopModal(P())),[a]),L=(0,d.Z)((e=>{E.current=e,e&&(Z&&j()?C():k.current&&v(k.current,R))})),A=i.useCallback((()=>{a.remove(P(),R)}),[R,a]);i.useEffect((()=>()=>{A()}),[A]),i.useEffect((()=>{Z?S():M&&s||A()}),[Z,A,M,s,S]);const H=e=>t=>{var o;null==(o=e.onKeyDown)||o.call(e,t),"Escape"===t.key&&229!==t.which&&j()&&(n||(t.stopPropagation(),x&&x(t,"escapeKeyDown")))},N=e=>t=>{var n;null==(n=e.onClick)||n.call(e,t),t.target===t.currentTarget&&x&&x(t,"backdropClick")};return{getRootProps:(t={})=>{const n=(0,p._)(e);delete n.onTransitionEnter,delete n.onTransitionExited;const o=(0,r.Z)({},n,t);return(0,r.Z)({role:"presentation"},o,{onKeyDown:H(o),ref:z})},getBackdropProps:(e={})=>{const t=e;return(0,r.Z)({"aria-hidden":!0},t,{onClick:N(t),open:Z})},getTransitionProps:()=>({onEnter:(0,u.Z)((()=>{w(!1),h&&h()}),null==m?void 0:m.props.onEnter),onExited:(0,u.Z)((()=>{w(!0),f&&f(),s&&A()}),null==m?void 0:m.props.onExited)}),rootRef:z,portalRef:L,isTopModal:j,exited:T,hasTransition:M}}var y=n(94780),E=n(85893);const k=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function z(e){const t=[],n=[];return Array.from(e.querySelectorAll(k)).forEach(((e,o)=>{const r=function(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?"true"===e.contentEditable||("AUDIO"===e.nodeName||"VIDEO"===e.nodeName||"DETAILS"===e.nodeName)&&null===e.getAttribute("tabindex")?0:e.tabIndex:t}(e);-1!==r&&function(e){return!(e.disabled||"INPUT"===e.tagName&&"hidden"===e.type||function(e){if("INPUT"!==e.tagName||"radio"!==e.type)return!1;if(!e.name)return!1;const t=t=>e.ownerDocument.querySelector(`input[type="radio"]${t}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}(e))}(e)&&(0===r?t.push(e):n.push({documentOrder:o,tabIndex:r,node:e}))})),n.sort(((e,t)=>e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex)).map((e=>e.node)).concat(t)}function T(){return!0}function w(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:o=!1,disableRestoreFocus:r=!1,getTabbable:a=z,isEnabled:s=T,open:d}=e,u=i.useRef(!1),p=i.useRef(null),h=i.useRef(null),v=i.useRef(null),f=i.useRef(null),m=i.useRef(!1),x=i.useRef(null),Z=(0,l.Z)(t.ref,x),g=i.useRef(null);i.useEffect((()=>{d&&x.current&&(m.current=!n)}),[n,d]),i.useEffect((()=>{if(!d||!x.current)return;const e=(0,c.Z)(x.current);return x.current.contains(e.activeElement)||(x.current.hasAttribute("tabIndex")||x.current.setAttribute("tabIndex","-1"),m.current&&x.current.focus()),()=>{r||(v.current&&v.current.focus&&(u.current=!0,v.current.focus()),v.current=null)}}),[d]),i.useEffect((()=>{if(!d||!x.current)return;const e=(0,c.Z)(x.current),t=t=>{g.current=t,!o&&s()&&"Tab"===t.key&&e.activeElement===x.current&&t.shiftKey&&(u.current=!0,h.current&&h.current.focus())},n=()=>{const t=x.current;if(null===t)return;if(!e.hasFocus()||!s()||u.current)return void(u.current=!1);if(t.contains(e.activeElement))return;if(o&&e.activeElement!==p.current&&e.activeElement!==h.current)return;if(e.activeElement!==f.current)f.current=null;else if(null!==f.current)return;if(!m.current)return;let n=[];if(e.activeElement!==p.current&&e.activeElement!==h.current||(n=a(x.current)),n.length>0){var r,i;const e=Boolean((null==(r=g.current)?void 0:r.shiftKey)&&"Tab"===(null==(i=g.current)?void 0:i.key)),t=n[0],o=n[n.length-1];"string"!==typeof t&&"string"!==typeof o&&(e?o.focus():t.focus())}else t.focus()};e.addEventListener("focusin",n),e.addEventListener("keydown",t,!0);const r=setInterval((()=>{e.activeElement&&"BODY"===e.activeElement.tagName&&n()}),50);return()=>{clearInterval(r),e.removeEventListener("focusin",n),e.removeEventListener("keydown",t,!0)}}),[n,o,r,s,d,a]);const b=e=>{null===v.current&&(v.current=e.relatedTarget),m.current=!0};return(0,E.jsxs)(i.Fragment,{children:[(0,E.jsx)("div",{tabIndex:d?0:-1,onFocus:b,ref:p,"data-testid":"sentinelStart"}),i.cloneElement(t,{ref:Z,onFocus:e=>{null===v.current&&(v.current=e.relatedTarget),m.current=!0,f.current=e.target;const n=t.props.onFocus;n&&n(e)}}),(0,E.jsx)("div",{tabIndex:d?0:-1,onFocus:b,ref:h,"data-testid":"sentinelEnd"})]})}var M=n(73935),R=n(73546),P=n(7960);const C=i.forwardRef((function(e,t){const{children:n,container:o,disablePortal:r=!1}=e,[a,s]=i.useState(null),c=(0,l.Z)(i.isValidElement(n)?n.ref:null,t);if((0,R.Z)((()=>{r||s(function(e){return"function"===typeof e?e():e}(o)||document.body)}),[o,r]),(0,R.Z)((()=>{if(a&&!r)return(0,P.Z)(t,a),()=>{(0,P.Z)(t,null)}}),[t,a,r]),r){if(i.isValidElement(n)){const e={ref:c};return i.cloneElement(n,e)}return(0,E.jsx)(i.Fragment,{children:n})}return(0,E.jsx)(i.Fragment,{children:a?M.createPortal(n,a):a})}));var S=n(2641),j=n(54502),L=n(84527),A=n(2734),H=n(30577),N=n(51705);const V=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"],I={entering:{opacity:1},entered:{opacity:1}};var D=i.forwardRef((function(e,t){const n=(0,A.Z)(),a={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:s,appear:l=!0,children:c,easing:d,in:u,onEnter:p,onEntered:h,onEntering:v,onExit:f,onExited:m,onExiting:x,style:Z,timeout:g=a,TransitionComponent:b=L.ZP}=e,y=(0,o.Z)(e,V),k=i.useRef(null),z=(0,N.Z)(k,c.ref,t),T=e=>t=>{if(e){const n=k.current;void 0===t?e(n):e(n,t)}},w=T(v),M=T(((e,t)=>{(0,H.n)(e);const o=(0,H.C)({style:Z,timeout:g,easing:d},{mode:"enter"});e.style.webkitTransition=n.transitions.create("opacity",o),e.style.transition=n.transitions.create("opacity",o),p&&p(e,t)})),R=T(h),P=T(x),C=T((e=>{const t=(0,H.C)({style:Z,timeout:g,easing:d},{mode:"exit"});e.style.webkitTransition=n.transitions.create("opacity",t),e.style.transition=n.transitions.create("opacity",t),f&&f(e)})),S=T(m);return(0,E.jsx)(b,(0,r.Z)({appear:l,in:u,nodeRef:k,onEnter:M,onEntered:R,onEntering:w,onExit:C,onExited:S,onExiting:P,addEndListener:e=>{s&&s(k.current,e)},timeout:g},y,{children:(e,t)=>i.cloneElement(c,(0,r.Z)({style:(0,r.Z)({opacity:0,visibility:"exited"!==e||u?void 0:"hidden"},I[e],Z,c.props.style),ref:z},t))}))})),B=n(1588),F=n(34867);function O(e){return(0,F.Z)("MuiBackdrop",e)}(0,B.Z)("MuiBackdrop",["root","invisible"]);const $=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],K=(0,S.ZP)("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})((({ownerState:e})=>(0,r.Z)({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"})));var Y=i.forwardRef((function(e,t){var n,i,s;const l=(0,j.Z)({props:e,name:"MuiBackdrop"}),{children:c,className:d,component:u="div",components:p={},componentsProps:h={},invisible:v=!1,open:f,slotProps:m={},slots:x={},TransitionComponent:Z=D,transitionDuration:g}=l,b=(0,o.Z)(l,$),k=(0,r.Z)({},l,{component:u,invisible:v}),z=(e=>{const{classes:t,invisible:n}=e,o={root:["root",n&&"invisible"]};return(0,y.Z)(o,O,t)})(k),T=null!=(n=m.root)?n:h.root;return(0,E.jsx)(Z,(0,r.Z)({in:f,timeout:g},b,{children:(0,E.jsx)(K,(0,r.Z)({"aria-hidden":!0},T,{as:null!=(i=null!=(s=x.root)?s:p.Root)?i:u,className:(0,a.Z)(z.root,d,null==T?void 0:T.className),ownerState:(0,r.Z)({},k,null==T?void 0:T.ownerState),classes:z,ref:t,children:c}))}))}));function U(e){return(0,F.Z)("MuiModal",e)}(0,B.Z)("MuiModal",["root","hidden","backdrop"]);const W=["BackdropComponent","BackdropProps","classes","className","closeAfterTransition","children","container","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","onBackdropClick","onClose","onTransitionEnter","onTransitionExited","open","slotProps","slots","theme"],X=(0,S.ZP)("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})((({theme:e,ownerState:t})=>(0,r.Z)({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!t.open&&t.exited&&{visibility:"hidden"}))),_=(0,S.ZP)(Y,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,t)=>t.backdrop})({zIndex:-1});var q=i.forwardRef((function(e,t){var n,l,c,d,u,p;const h=(0,j.Z)({name:"MuiModal",props:e}),{BackdropComponent:v=_,BackdropProps:f,className:m,closeAfterTransition:x=!1,children:Z,container:g,component:k,components:z={},componentsProps:T={},disableAutoFocus:M=!1,disableEnforceFocus:R=!1,disableEscapeKeyDown:P=!1,disablePortal:S=!1,disableRestoreFocus:L=!1,disableScrollLock:A=!1,hideBackdrop:H=!1,keepMounted:N=!1,onBackdropClick:V,open:I,slotProps:D,slots:B}=h,F=(0,o.Z)(h,W),O=(0,r.Z)({},h,{closeAfterTransition:x,disableAutoFocus:M,disableEnforceFocus:R,disableEscapeKeyDown:P,disablePortal:S,disableRestoreFocus:L,disableScrollLock:A,hideBackdrop:H,keepMounted:N}),{getRootProps:$,getBackdropProps:K,getTransitionProps:Y,portalRef:q,isTopModal:G,exited:J,hasTransition:Q}=b((0,r.Z)({},O,{rootRef:t})),ee=(0,r.Z)({},O,{exited:J}),te=(e=>{const{open:t,exited:n,classes:o}=e,r={root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]};return(0,y.Z)(r,U,o)})(ee),ne={};if(void 0===Z.props.tabIndex&&(ne.tabIndex="-1"),Q){const{onEnter:e,onExited:t}=Y();ne.onEnter=e,ne.onExited=t}const oe=null!=(n=null!=(l=null==B?void 0:B.root)?l:z.Root)?n:X,re=null!=(c=null!=(d=null==B?void 0:B.backdrop)?d:z.Backdrop)?c:v,ie=null!=(u=null==D?void 0:D.root)?u:T.root,ae=null!=(p=null==D?void 0:D.backdrop)?p:T.backdrop,se=(0,s.y)({elementType:oe,externalSlotProps:ie,externalForwardedProps:F,getSlotProps:$,additionalProps:{ref:t,as:k},ownerState:ee,className:(0,a.Z)(m,null==ie?void 0:ie.className,null==te?void 0:te.root,!ee.open&&ee.exited&&(null==te?void 0:te.hidden))}),le=(0,s.y)({elementType:re,externalSlotProps:ae,additionalProps:f,getSlotProps:e=>K((0,r.Z)({},e,{onClick:t=>{V&&V(t),null!=e&&e.onClick&&e.onClick(t)}})),className:(0,a.Z)(null==ae?void 0:ae.className,null==f?void 0:f.className,null==te?void 0:te.backdrop),ownerState:ee});return N||I||Q&&!J?(0,E.jsx)(C,{ref:q,container:g,disablePortal:S,children:(0,E.jsxs)(oe,(0,r.Z)({},se,{children:[!H&&v?(0,E.jsx)(re,(0,r.Z)({},le)):null,(0,E.jsx)(w,{disableEnforceFocus:R,disableAutoFocus:M,disableRestoreFocus:L,isEnabled:G,open:I,children:i.cloneElement(Z,ne)})]}))}):null}))}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/2870-8e302171aed920f8.js b/dsql-app/.local_dist/static/chunks/2870-8e302171aed920f8.js new file mode 100644 index 0000000..a7720ba --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/2870-8e302171aed920f8.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2870],{96224:function(e,t,n){var a=n(64836);t.Z=void 0;var c=a(n(64938)),i=n(85893),r=(0,c.default)([(0,i.jsx)("path",{d:"m16 7.58-5.5-2.4L5 7.58v3.6c0 3.5 2.33 6.74 5.5 7.74.25-.08.49-.2.73-.3-.15-.51-.23-1.06-.23-1.62 0-2.97 2.16-5.43 5-5.91V7.58z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M17 13c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 1.38c.62 0 1.12.51 1.12 1.12s-.51 1.12-1.12 1.12-1.12-.51-1.12-1.12.5-1.12 1.12-1.12zm0 5.37c-.93 0-1.74-.46-2.24-1.17.05-.72 1.51-1.08 2.24-1.08s2.19.36 2.24 1.08c-.5.71-1.31 1.17-2.24 1.17z",opacity:".3"},"1"),(0,i.jsx)("circle",{cx:"17",cy:"15.5",r:"1.12"},"2"),(0,i.jsx)("path",{d:"M18 11.09V6.27L10.5 3 3 6.27v4.91c0 4.54 3.2 8.79 7.5 9.82.55-.13 1.08-.32 1.6-.55C13.18 21.99 14.97 23 17 23c3.31 0 6-2.69 6-6 0-2.97-2.16-5.43-5-5.91zM11 17c0 .56.08 1.11.23 1.62-.24.11-.48.22-.73.3-3.17-1-5.5-4.24-5.5-7.74v-3.6l5.5-2.4 5.5 2.4v3.51c-2.84.48-5 2.94-5 5.91zm6 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"},"3"),(0,i.jsx)("path",{d:"M17 17.5c-.73 0-2.19.36-2.24 1.08.5.71 1.32 1.17 2.24 1.17s1.74-.46 2.24-1.17c-.05-.72-1.51-1.08-2.24-1.08z"},"4")],"AdminPanelSettingsTwoTone");t.Z=r},42065:function(e,t,n){var a=n(64836);t.Z=void 0;var c=a(n(64938)),i=n(85893),r=(0,c.default)((0,i.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");t.Z=r},88518:function(e,t,n){var a=n(64836);t.Z=void 0;var c=a(n(64938)),i=n(85893),r=(0,c.default)([(0,i.jsx)("path",{d:"M22 15c0-1.66-1.34-3-3-3h-1.5v-.5C17.5 8.46 15.04 6 12 6c-.77 0-1.49.17-2.16.46L20.79 17.4c.73-.55 1.21-1.41 1.21-2.4zM2 14c0 2.21 1.79 4 4 4h9.73l-8-8H6c-2.21 0-4 1.79-4 4z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.33 0-2.57.36-3.65.97l1.49 1.49C10.51 6.17 11.23 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 .99-.48 1.85-1.21 2.4l1.41 1.41c1.09-.92 1.8-2.27 1.8-3.81 0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.77 2.77h-.42C2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h11.73l2 2 1.41-1.41L4.41 3.86 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"},"1")],"CloudOffTwoTone");t.Z=r},57150:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},33587:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},49525:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},72733:function(e,t,n){n.d(t,{Z:function(){return o}});var a=n(47568),c=n(97582),i=n(85893),r=n(67294),l=n(36718);n(25472);function o(e){e.user;var t=e.userImage,n=e.setUserImage,o=(e.database,e.className),s=r.useRef();return(0,i.jsxs)("div",{className:"card no-hover col"+(o?" "+o:""),children:[(0,i.jsx)("div",{className:"bg-white rounded-full overflow-hidden w-24 h-24",children:(0,i.jsx)("img",{src:t?"string"===typeof t?t:t.imageBase64Full:"/images/user_images/user-preset.png",alt:"Database Image",width:100,className:"w-full h-full object-cover",ref:s,"data-imagepreview":"image"})}),(0,i.jsxs)("div",{className:"w-full flex-col image-selector-wrapper",children:[(0,i.jsx)("div",{className:"button outlined secondary w-full whitespace-normal",onClick:function(e){e.target.closest(".image-selector-wrapper").querySelector("input").click()},children:"Upload Image"}),(0,i.jsx)("input",{type:"file",accept:".png,.jpg,.jpeg,.webp",placeholder:"Choose Database Image",className:"hidden",onChange:function(){var e=(0,a.Z)((function(e){var t;return(0,c.__generator)(this,(function(a){switch(a.label){case 0:return[4,(0,l.Z)({imageInputFile:e.target.files[0],maxWidth:400})];case 1:return t=a.sent(),n(t),[2]}}))}));return function(t){return e.apply(this,arguments)}}()})]})]})}},25472:function(e,t,n){n.d(t,{Mw:function(){return l},ZP:function(){return r},j4:function(){return o}});var a=n(85893),c=n(41352),i=n(67294);function r(e){var t=e.children,n=e.title,r=e.data,l=e.fullPage,s=e.wrapperClasses,u=e.closePopupDispatch,d=e.wrapperStyle,p=e.noContainer;return l?(0,a.jsxs)("div",{className:"popup-bg overflow-hidden "+(s||""),"data-popupid":n||null,style:d,children:[p?(0,a.jsx)(i.Fragment,{children:t}):(0,a.jsx)("div",{className:"relative w-full h-full z-50","data-data":r?JSON.stringify(r):"",children:t}),(0,a.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(e){o(),u&&u()},children:(0,a.jsx)(c.Z,{color:"white",size:20})}),(0,a.jsx)("div",{className:"popup-canceller",onClick:function(e){o(),u&&u()}})]}):(0,a.jsxs)("div",{className:"popup-bg","data-popupid":n||null,children:[p?(0,a.jsx)(i.Fragment,{children:t}):(0,a.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":r?JSON.stringify(r):"",children:[t,(0,a.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(e){o(),u&&u()},children:(0,a.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),p&&(0,a.jsx)("button",{className:"gray popup-cancel-button",onClick:function(e){o(),u&&u()},children:(0,a.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,a.jsx)("div",{className:"popup-canceller",onClick:function(e){o(),u&&u()}})]})}function l(e,t){var n=document.querySelector("[data-popupid='".concat(e,"']"));n&&(n.style.display="flex",t&&t(n))}function o(e){document.querySelectorAll("[data-popupid]").forEach((function(e){e.style.display="none"})),e&&e()}},36718:function(e,t,n){n.d(t,{Z:function(){return i}});var a=n(47568),c=n(97582);function i(e){return r.apply(this,arguments)}function r(){return(r=(0,a.Z)((function(e){var t,n,a,i,r,l,o,s,u,d,p,h,f;return(0,c.__generator)(this,(function(c){switch(c.label){case 0:return t=e.imageInputFile,n=e.maxWidth,a=document.querySelector("[data-imagepreview='image']"),i=t.name.replace(/\..*/,""),o=document.createElement("canvas"),s=t.type,u=.95,d=n||null,null,p=t,h=URL.createObjectURL(p),(f=new Image).src=h,[4,new Promise((function(e,t){f.onerror=function(){URL.revokeObjectURL(this.src),console.log("Cannot load image")},f.onload=function(){if(URL.revokeObjectURL(this.src),d){var t=d/f.naturalWidth;o.width=f.naturalWidth"']/g,J=RegExp(G.source),Y=RegExp(H.source),Q=/<%-([\s\S]+?)%>/g,X=/<%([\s\S]+?)%>/g,nn=/<%=([\s\S]+?)%>/g,tn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rn=/^\w*$/,en=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,un=/[\\^$.*+?()[\]{}|]/g,on=RegExp(un.source),fn=/^\s+/,an=/\s/,cn=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ln=/\{\n\/\* \[wrapped with (.+)\] \*/,sn=/,? & /,hn=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,pn=/[()=,{}\[\]\/\s]/,vn=/\\(\\)?/g,_n=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,gn=/\w*$/,yn=/^[-+]0x[0-9a-f]+$/i,dn=/^0b[01]+$/i,bn=/^\[object .+?Constructor\]$/,wn=/^0o[0-7]+$/i,mn=/^(?:0|[1-9]\d*)$/,xn=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,jn=/($^)/,An=/['\n\r\u2028\u2029\\]/g,kn="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",On="\\u2700-\\u27bf",In="a-z\\xdf-\\xf6\\xf8-\\xff",En="A-Z\\xc0-\\xd6\\xd8-\\xde",Rn="\\ufe0e\\ufe0f",zn="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Sn="['\u2019]",Cn="[\\ud800-\\udfff]",Wn="["+zn+"]",Ln="["+kn+"]",Un="\\d+",Bn="[\\u2700-\\u27bf]",Tn="["+In+"]",$n="[^\\ud800-\\udfff"+zn+Un+On+In+En+"]",Dn="\\ud83c[\\udffb-\\udfff]",Nn="[^\\ud800-\\udfff]",Mn="(?:\\ud83c[\\udde6-\\uddff]){2}",Fn="[\\ud800-\\udbff][\\udc00-\\udfff]",Pn="["+En+"]",qn="(?:"+Tn+"|"+$n+")",Zn="(?:"+Pn+"|"+$n+")",Kn="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",Vn="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",Gn="(?:"+Ln+"|"+Dn+")"+"?",Hn="[\\ufe0e\\ufe0f]?",Jn=Hn+Gn+("(?:\\u200d(?:"+[Nn,Mn,Fn].join("|")+")"+Hn+Gn+")*"),Yn="(?:"+[Bn,Mn,Fn].join("|")+")"+Jn,Qn="(?:"+[Nn+Ln+"?",Ln,Mn,Fn,Cn].join("|")+")",Xn=RegExp(Sn,"g"),nt=RegExp(Ln,"g"),tt=RegExp(Dn+"(?="+Dn+")|"+Qn+Jn,"g"),rt=RegExp([Pn+"?"+Tn+"+"+Kn+"(?="+[Wn,Pn,"$"].join("|")+")",Zn+"+"+Vn+"(?="+[Wn,Pn+qn,"$"].join("|")+")",Pn+"?"+qn+"+"+Kn,Pn+"+"+Vn,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Un,Yn].join("|"),"g"),et=RegExp("[\\u200d\\ud800-\\udfff"+kn+Rn+"]"),ut=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,it=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ot=-1,ft={};ft[B]=ft[T]=ft[$]=ft[D]=ft[N]=ft[M]=ft[F]=ft[P]=ft[q]=!0,ft[d]=ft[b]=ft[L]=ft[w]=ft[U]=ft[m]=ft[x]=ft[j]=ft[k]=ft[O]=ft[I]=ft[R]=ft[z]=ft[S]=ft[W]=!1;var at={};at[d]=at[b]=at[L]=at[U]=at[w]=at[m]=at[B]=at[T]=at[$]=at[D]=at[N]=at[k]=at[O]=at[I]=at[R]=at[z]=at[S]=at[C]=at[M]=at[F]=at[P]=at[q]=!0,at[x]=at[j]=at[W]=!1;var ct={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},lt=parseFloat,st=parseInt,ht="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,pt="object"==typeof self&&self&&self.Object===Object&&self,vt=ht||pt||Function("return this")(),_t=t&&!t.nodeType&&t,gt=_t&&n&&!n.nodeType&&n,yt=gt&>.exports===_t,dt=yt&&ht.process,bt=function(){try{var n=gt&>.require&>.require("util").types;return n||dt&&dt.binding&&dt.binding("util")}catch(t){}}(),wt=bt&&bt.isArrayBuffer,mt=bt&&bt.isDate,xt=bt&&bt.isMap,jt=bt&&bt.isRegExp,At=bt&&bt.isSet,kt=bt&&bt.isTypedArray;function Ot(n,t,r){switch(r.length){case 0:return n.call(t);case 1:return n.call(t,r[0]);case 2:return n.call(t,r[0],r[1]);case 3:return n.call(t,r[0],r[1],r[2])}return n.apply(t,r)}function It(n,t,r,e){for(var u=-1,i=null==n?0:n.length;++u-1}function Wt(n,t,r){for(var e=-1,u=null==n?0:n.length;++e-1;);return r}function rr(n,t){for(var r=n.length;r--&&Ft(t,n[r],0)>-1;);return r}function er(n,t){for(var r=n.length,e=0;r--;)n[r]===t&&++e;return e}var ur=Vt({"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I","\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C","\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i","\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S","\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n","\u017f":"s"}),ir=Vt({"&":"&","<":"<",">":">",'"':""","'":"'"});function or(n){return"\\"+ct[n]}function fr(n){return et.test(n)}function ar(n){var t=-1,r=Array(n.size);return n.forEach((function(n,e){r[++t]=[e,n]})),r}function cr(n,t){return function(r){return n(t(r))}}function lr(n,t){for(var r=-1,e=n.length,u=0,i=[];++r",""":'"',"'":"'"});var yr=function n(t){var r=(t=null==t?vt:yr.defaults(vt.Object(),t,yr.pick(vt,it))).Array,e=t.Date,an=t.Error,kn=t.Function,On=t.Math,In=t.Object,En=t.RegExp,Rn=t.String,zn=t.TypeError,Sn=r.prototype,Cn=kn.prototype,Wn=In.prototype,Ln=t["__core-js_shared__"],Un=Cn.toString,Bn=Wn.hasOwnProperty,Tn=0,$n=function(){var n=/[^.]+$/.exec(Ln&&Ln.keys&&Ln.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""}(),Dn=Wn.toString,Nn=Un.call(In),Mn=vt._,Fn=En("^"+Un.call(Bn).replace(un,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Pn=yt?t.Buffer:u,qn=t.Symbol,Zn=t.Uint8Array,Kn=Pn?Pn.allocUnsafe:u,Vn=cr(In.getPrototypeOf,In),Gn=In.create,Hn=Wn.propertyIsEnumerable,Jn=Sn.splice,Yn=qn?qn.isConcatSpreadable:u,Qn=qn?qn.iterator:u,tt=qn?qn.toStringTag:u,et=function(){try{var n=hi(In,"defineProperty");return n({},"",{}),n}catch(t){}}(),ct=t.clearTimeout!==vt.clearTimeout&&t.clearTimeout,ht=e&&e.now!==vt.Date.now&&e.now,pt=t.setTimeout!==vt.setTimeout&&t.setTimeout,_t=On.ceil,gt=On.floor,dt=In.getOwnPropertySymbols,bt=Pn?Pn.isBuffer:u,Dt=t.isFinite,Vt=Sn.join,dr=cr(In.keys,In),br=On.max,wr=On.min,mr=e.now,xr=t.parseInt,jr=On.random,Ar=Sn.reverse,kr=hi(t,"DataView"),Or=hi(t,"Map"),Ir=hi(t,"Promise"),Er=hi(t,"Set"),Rr=hi(t,"WeakMap"),zr=hi(In,"create"),Sr=Rr&&new Rr,Cr={},Wr=Di(kr),Lr=Di(Or),Ur=Di(Ir),Br=Di(Er),Tr=Di(Rr),$r=qn?qn.prototype:u,Dr=$r?$r.valueOf:u,Nr=$r?$r.toString:u;function Mr(n){if(ef(n)&&!Ko(n)&&!(n instanceof Zr)){if(n instanceof qr)return n;if(Bn.call(n,"__wrapped__"))return Ni(n)}return new qr(n)}var Fr=function(){function n(){}return function(t){if(!rf(t))return{};if(Gn)return Gn(t);n.prototype=t;var r=new n;return n.prototype=u,r}}();function Pr(){}function qr(n,t){this.__wrapped__=n,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=u}function Zr(n){this.__wrapped__=n,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=g,this.__views__=[]}function Kr(n){var t=-1,r=null==n?0:n.length;for(this.clear();++t=t?n:t)),n}function ce(n,t,r,e,i,o){var f,a=1&t,c=2&t,l=4&t;if(r&&(f=i?r(n,e,i,o):r(n)),f!==u)return f;if(!rf(n))return n;var s=Ko(n);if(s){if(f=function(n){var t=n.length,r=new n.constructor(t);t&&"string"==typeof n[0]&&Bn.call(n,"index")&&(r.index=n.index,r.input=n.input);return r}(n),!a)return zu(n,f)}else{var h=_i(n),p=h==j||h==A;if(Jo(n))return Au(n,a);if(h==I||h==d||p&&!i){if(f=c||p?{}:yi(n),!a)return c?function(n,t){return Su(n,vi(n),t)}(n,function(n,t){return n&&Su(t,Uf(t),n)}(f,n)):function(n,t){return Su(n,pi(n),t)}(n,ie(f,n))}else{if(!at[h])return i?n:{};f=function(n,t,r){var e=n.constructor;switch(t){case L:return ku(n);case w:case m:return new e(+n);case U:return function(n,t){var r=t?ku(n.buffer):n.buffer;return new n.constructor(r,n.byteOffset,n.byteLength)}(n,r);case B:case T:case $:case D:case N:case M:case F:case P:case q:return Ou(n,r);case k:return new e;case O:case S:return new e(n);case R:return function(n){var t=new n.constructor(n.source,gn.exec(n));return t.lastIndex=n.lastIndex,t}(n);case z:return new e;case C:return u=n,Dr?In(Dr.call(u)):{}}var u}(n,h,a)}}o||(o=new Jr);var v=o.get(n);if(v)return v;o.set(n,f),cf(n)?n.forEach((function(e){f.add(ce(e,t,r,e,n,o))})):uf(n)&&n.forEach((function(e,u){f.set(u,ce(e,t,r,u,n,o))}));var _=s?u:(l?c?ii:ui:c?Uf:Lf)(n);return Et(_||n,(function(e,u){_&&(e=n[u=e]),re(f,u,ce(e,t,r,u,n,o))})),f}function le(n,t,r){var e=r.length;if(null==n)return!e;for(n=In(n);e--;){var i=r[e],o=t[i],f=n[i];if(f===u&&!(i in n)||!o(f))return!1}return!0}function se(n,t,r){if("function"!=typeof n)throw new zn(i);return Ci((function(){n.apply(u,r)}),t)}function he(n,t,r,e){var u=-1,i=Ct,o=!0,f=n.length,a=[],c=t.length;if(!f)return a;r&&(t=Lt(t,Qt(r))),e?(i=Wt,o=!1):t.length>=200&&(i=nr,o=!1,t=new Hr(t));n:for(;++u-1},Vr.prototype.set=function(n,t){var r=this.__data__,e=ee(r,n);return e<0?(++this.size,r.push([n,t])):r[e][1]=t,this},Gr.prototype.clear=function(){this.size=0,this.__data__={hash:new Kr,map:new(Or||Vr),string:new Kr}},Gr.prototype.delete=function(n){var t=li(this,n).delete(n);return this.size-=t?1:0,t},Gr.prototype.get=function(n){return li(this,n).get(n)},Gr.prototype.has=function(n){return li(this,n).has(n)},Gr.prototype.set=function(n,t){var r=li(this,n),e=r.size;return r.set(n,t),this.size+=r.size==e?0:1,this},Hr.prototype.add=Hr.prototype.push=function(n){return this.__data__.set(n,o),this},Hr.prototype.has=function(n){return this.__data__.has(n)},Jr.prototype.clear=function(){this.__data__=new Vr,this.size=0},Jr.prototype.delete=function(n){var t=this.__data__,r=t.delete(n);return this.size=t.size,r},Jr.prototype.get=function(n){return this.__data__.get(n)},Jr.prototype.has=function(n){return this.__data__.has(n)},Jr.prototype.set=function(n,t){var r=this.__data__;if(r instanceof Vr){var e=r.__data__;if(!Or||e.length<199)return e.push([n,t]),this.size=++r.size,this;r=this.__data__=new Gr(e)}return r.set(n,t),this.size=r.size,this};var pe=Lu(me),ve=Lu(xe,!0);function _e(n,t){var r=!0;return pe(n,(function(n,e,u){return r=!!t(n,e,u)})),r}function ge(n,t,r){for(var e=-1,i=n.length;++e0&&r(f)?t>1?de(f,t-1,r,e,u):Ut(u,f):e||(u[u.length]=f)}return u}var be=Uu(),we=Uu(!0);function me(n,t){return n&&be(n,t,Lf)}function xe(n,t){return n&&we(n,t,Lf)}function je(n,t){return St(t,(function(t){return Xo(n[t])}))}function Ae(n,t){for(var r=0,e=(t=wu(t,n)).length;null!=n&&rt}function Ee(n,t){return null!=n&&Bn.call(n,t)}function Re(n,t){return null!=n&&t in In(n)}function ze(n,t,e){for(var i=e?Wt:Ct,o=n[0].length,f=n.length,a=f,c=r(f),l=1/0,s=[];a--;){var h=n[a];a&&t&&(h=Lt(h,Qt(t))),l=wr(h.length,l),c[a]=!e&&(t||o>=120&&h.length>=120)?new Hr(a&&h):u}h=n[0];var p=-1,v=c[0];n:for(;++p=f?a:a*("desc"==r[e]?-1:1)}return n.index-t.index}(n,t,r)}))}function Ke(n,t,r){for(var e=-1,u=t.length,i={};++e-1;)f!==n&&Jn.call(f,a,1),Jn.call(n,a,1);return n}function Ge(n,t){for(var r=n?t.length:0,e=r-1;r--;){var u=t[r];if(r==e||u!==i){var i=u;bi(u)?Jn.call(n,u,1):hu(n,u)}}return n}function He(n,t){return n+gt(jr()*(t-n+1))}function Je(n,t){var r="";if(!n||t<1||t>v)return r;do{t%2&&(r+=n),(t=gt(t/2))&&(n+=n)}while(t);return r}function Ye(n,t){return Wi(Ii(n,t,oa),n+"")}function Qe(n){return Qr(Pf(n))}function Xe(n,t){var r=Pf(n);return Bi(r,ae(t,0,r.length))}function nu(n,t,r,e){if(!rf(n))return n;for(var i=-1,o=(t=wu(t,n)).length,f=o-1,a=n;null!=a&&++ii?0:i+t),(e=e>i?i:e)<0&&(e+=i),i=t>e?0:e-t>>>0,t>>>=0;for(var o=r(i);++u>>1,o=n[i];null!==o&&!sf(o)&&(r?o<=t:o=200){var c=t?null:Ju(n);if(c)return sr(c);o=!1,u=nr,a=new Hr}else a=t?[]:f;n:for(;++e=e?n:uu(n,t,r)}var ju=ct||function(n){return vt.clearTimeout(n)};function Au(n,t){if(t)return n.slice();var r=n.length,e=Kn?Kn(r):new n.constructor(r);return n.copy(e),e}function ku(n){var t=new n.constructor(n.byteLength);return new Zn(t).set(new Zn(n)),t}function Ou(n,t){var r=t?ku(n.buffer):n.buffer;return new n.constructor(r,n.byteOffset,n.length)}function Iu(n,t){if(n!==t){var r=n!==u,e=null===n,i=n===n,o=sf(n),f=t!==u,a=null===t,c=t===t,l=sf(t);if(!a&&!l&&!o&&n>t||o&&f&&c&&!a&&!l||e&&f&&c||!r&&c||!i)return 1;if(!e&&!o&&!l&&n1?r[i-1]:u,f=i>2?r[2]:u;for(o=n.length>3&&"function"==typeof o?(i--,o):u,f&&wi(r[0],r[1],f)&&(o=i<3?u:o,i=1),t=In(t);++e-1?i[o?t[f]:f]:u}}function Nu(n){return ei((function(t){var r=t.length,e=r,o=qr.prototype.thru;for(n&&t.reverse();e--;){var f=t[e];if("function"!=typeof f)throw new zn(i);if(o&&!a&&"wrapper"==fi(f))var a=new qr([],!0)}for(e=a?e:r;++e1&&b.reverse(),p&&la))return!1;var l=o.get(n),s=o.get(t);if(l&&s)return l==t&&s==n;var h=-1,p=!0,v=2&r?new Hr:u;for(o.set(n,t),o.set(t,n);++h-1&&n%1==0&&n1?"& ":"")+t[e],t=t.join(r>2?", ":" "),n.replace(cn,"{\n/* [wrapped with "+t+"] */\n")}(e,function(n,t){return Et(y,(function(r){var e="_."+r[0];t&r[1]&&!Ct(n,e)&&n.push(e)})),n.sort()}(function(n){var t=n.match(ln);return t?t[1].split(sn):[]}(e),r)))}function Ui(n){var t=0,r=0;return function(){var e=mr(),i=16-(e-r);if(r=e,i>0){if(++t>=800)return arguments[0]}else t=0;return n.apply(u,arguments)}}function Bi(n,t){var r=-1,e=n.length,i=e-1;for(t=t===u?e:t;++r1?n[t-1]:u;return r="function"==typeof r?(n.pop(),r):u,oo(n,r)}));function po(n){var t=Mr(n);return t.__chain__=!0,t}function vo(n,t){return t(n)}var _o=ei((function(n){var t=n.length,r=t?n[0]:0,e=this.__wrapped__,i=function(t){return fe(t,n)};return!(t>1||this.__actions__.length)&&e instanceof Zr&&bi(r)?((e=e.slice(r,+r+(t?1:0))).__actions__.push({func:vo,args:[i],thisArg:u}),new qr(e,this.__chain__).thru((function(n){return t&&!n.length&&n.push(u),n}))):this.thru(i)}));var go=Cu((function(n,t,r){Bn.call(n,r)?++n[r]:oe(n,r,1)}));var yo=Du(qi),bo=Du(Zi);function wo(n,t){return(Ko(n)?Et:pe)(n,ci(t,3))}function mo(n,t){return(Ko(n)?Rt:ve)(n,ci(t,3))}var xo=Cu((function(n,t,r){Bn.call(n,r)?n[r].push(t):oe(n,r,[t])}));var jo=Ye((function(n,t,e){var u=-1,i="function"==typeof t,o=Go(n)?r(n.length):[];return pe(n,(function(n){o[++u]=i?Ot(t,n,e):Se(n,t,e)})),o})),Ao=Cu((function(n,t,r){oe(n,r,t)}));function ko(n,t){return(Ko(n)?Lt:Ne)(n,ci(t,3))}var Oo=Cu((function(n,t,r){n[r?0:1].push(t)}),(function(){return[[],[]]}));var Io=Ye((function(n,t){if(null==n)return[];var r=t.length;return r>1&&wi(n,t[0],t[1])?t=[]:r>2&&wi(t[0],t[1],t[2])&&(t=[t[0]]),Ze(n,de(t,1),[])})),Eo=ht||function(){return vt.Date.now()};function Ro(n,t,r){return t=r?u:t,t=n&&null==t?n.length:t,Qu(n,s,u,u,u,u,t)}function zo(n,t){var r;if("function"!=typeof t)throw new zn(i);return n=yf(n),function(){return--n>0&&(r=t.apply(this,arguments)),n<=1&&(t=u),r}}var So=Ye((function(n,t,r){var e=1;if(r.length){var u=lr(r,ai(So));e|=c}return Qu(n,e,t,r,u)})),Co=Ye((function(n,t,r){var e=3;if(r.length){var u=lr(r,ai(Co));e|=c}return Qu(t,e,n,r,u)}));function Wo(n,t,r){var e,o,f,a,c,l,s=0,h=!1,p=!1,v=!0;if("function"!=typeof n)throw new zn(i);function _(t){var r=e,i=o;return e=o=u,s=t,a=n.apply(i,r)}function g(n){return s=n,c=Ci(d,t),h?_(n):a}function y(n){var r=n-l;return l===u||r>=t||r<0||p&&n-s>=f}function d(){var n=Eo();if(y(n))return b(n);c=Ci(d,function(n){var r=t-(n-l);return p?wr(r,f-(n-s)):r}(n))}function b(n){return c=u,v&&e?_(n):(e=o=u,a)}function w(){var n=Eo(),r=y(n);if(e=arguments,o=this,l=n,r){if(c===u)return g(l);if(p)return ju(c),c=Ci(d,t),_(l)}return c===u&&(c=Ci(d,t)),a}return t=bf(t)||0,rf(r)&&(h=!!r.leading,f=(p="maxWait"in r)?br(bf(r.maxWait)||0,t):f,v="trailing"in r?!!r.trailing:v),w.cancel=function(){c!==u&&ju(c),s=0,e=l=o=c=u},w.flush=function(){return c===u?a:b(Eo())},w}var Lo=Ye((function(n,t){return se(n,1,t)})),Uo=Ye((function(n,t,r){return se(n,bf(t)||0,r)}));function Bo(n,t){if("function"!=typeof n||null!=t&&"function"!=typeof t)throw new zn(i);var r=function(){var e=arguments,u=t?t.apply(this,e):e[0],i=r.cache;if(i.has(u))return i.get(u);var o=n.apply(this,e);return r.cache=i.set(u,o)||i,o};return r.cache=new(Bo.Cache||Gr),r}function To(n){if("function"!=typeof n)throw new zn(i);return function(){var t=arguments;switch(t.length){case 0:return!n.call(this);case 1:return!n.call(this,t[0]);case 2:return!n.call(this,t[0],t[1]);case 3:return!n.call(this,t[0],t[1],t[2])}return!n.apply(this,t)}}Bo.Cache=Gr;var $o=mu((function(n,t){var r=(t=1==t.length&&Ko(t[0])?Lt(t[0],Qt(ci())):Lt(de(t,1),Qt(ci()))).length;return Ye((function(e){for(var u=-1,i=wr(e.length,r);++u=t})),Zo=Ce(function(){return arguments}())?Ce:function(n){return ef(n)&&Bn.call(n,"callee")&&!Hn.call(n,"callee")},Ko=r.isArray,Vo=wt?Qt(wt):function(n){return ef(n)&&Oe(n)==L};function Go(n){return null!=n&&tf(n.length)&&!Xo(n)}function Ho(n){return ef(n)&&Go(n)}var Jo=bt||ba,Yo=mt?Qt(mt):function(n){return ef(n)&&Oe(n)==m};function Qo(n){if(!ef(n))return!1;var t=Oe(n);return t==x||"[object DOMException]"==t||"string"==typeof n.message&&"string"==typeof n.name&&!ff(n)}function Xo(n){if(!rf(n))return!1;var t=Oe(n);return t==j||t==A||"[object AsyncFunction]"==t||"[object Proxy]"==t}function nf(n){return"number"==typeof n&&n==yf(n)}function tf(n){return"number"==typeof n&&n>-1&&n%1==0&&n<=v}function rf(n){var t=typeof n;return null!=n&&("object"==t||"function"==t)}function ef(n){return null!=n&&"object"==typeof n}var uf=xt?Qt(xt):function(n){return ef(n)&&_i(n)==k};function of(n){return"number"==typeof n||ef(n)&&Oe(n)==O}function ff(n){if(!ef(n)||Oe(n)!=I)return!1;var t=Vn(n);if(null===t)return!0;var r=Bn.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Un.call(r)==Nn}var af=jt?Qt(jt):function(n){return ef(n)&&Oe(n)==R};var cf=At?Qt(At):function(n){return ef(n)&&_i(n)==z};function lf(n){return"string"==typeof n||!Ko(n)&&ef(n)&&Oe(n)==S}function sf(n){return"symbol"==typeof n||ef(n)&&Oe(n)==C}var hf=kt?Qt(kt):function(n){return ef(n)&&tf(n.length)&&!!ft[Oe(n)]};var pf=Vu(De),vf=Vu((function(n,t){return n<=t}));function _f(n){if(!n)return[];if(Go(n))return lf(n)?vr(n):zu(n);if(Qn&&n[Qn])return function(n){for(var t,r=[];!(t=n.next()).done;)r.push(t.value);return r}(n[Qn]());var t=_i(n);return(t==k?ar:t==z?sr:Pf)(n)}function gf(n){return n?(n=bf(n))===p||n===-1/0?17976931348623157e292*(n<0?-1:1):n===n?n:0:0===n?n:0}function yf(n){var t=gf(n),r=t%1;return t===t?r?t-r:t:0}function df(n){return n?ae(yf(n),0,g):0}function bf(n){if("number"==typeof n)return n;if(sf(n))return _;if(rf(n)){var t="function"==typeof n.valueOf?n.valueOf():n;n=rf(t)?t+"":t}if("string"!=typeof n)return 0===n?n:+n;n=Yt(n);var r=dn.test(n);return r||wn.test(n)?st(n.slice(2),r?2:8):yn.test(n)?_:+n}function wf(n){return Su(n,Uf(n))}function mf(n){return null==n?"":lu(n)}var xf=Wu((function(n,t){if(Ai(t)||Go(t))Su(t,Lf(t),n);else for(var r in t)Bn.call(t,r)&&re(n,r,t[r])})),jf=Wu((function(n,t){Su(t,Uf(t),n)})),Af=Wu((function(n,t,r,e){Su(t,Uf(t),n,e)})),kf=Wu((function(n,t,r,e){Su(t,Lf(t),n,e)})),Of=ei(fe);var If=Ye((function(n,t){n=In(n);var r=-1,e=t.length,i=e>2?t[2]:u;for(i&&wi(t[0],t[1],i)&&(e=1);++r1),t})),Su(n,ii(n),r),e&&(r=ce(r,7,ti));for(var u=t.length;u--;)hu(r,t[u]);return r}));var Df=ei((function(n,t){return null==n?{}:function(n,t){return Ke(n,t,(function(t,r){return zf(n,r)}))}(n,t)}));function Nf(n,t){if(null==n)return{};var r=Lt(ii(n),(function(n){return[n]}));return t=ci(t),Ke(n,r,(function(n,r){return t(n,r[0])}))}var Mf=Yu(Lf),Ff=Yu(Uf);function Pf(n){return null==n?[]:Xt(n,Lf(n))}var qf=Tu((function(n,t,r){return t=t.toLowerCase(),n+(r?Zf(t):t)}));function Zf(n){return Xf(mf(n).toLowerCase())}function Kf(n){return(n=mf(n))&&n.replace(xn,ur).replace(nt,"")}var Vf=Tu((function(n,t,r){return n+(r?"-":"")+t.toLowerCase()})),Gf=Tu((function(n,t,r){return n+(r?" ":"")+t.toLowerCase()})),Hf=Bu("toLowerCase");var Jf=Tu((function(n,t,r){return n+(r?"_":"")+t.toLowerCase()}));var Yf=Tu((function(n,t,r){return n+(r?" ":"")+Xf(t)}));var Qf=Tu((function(n,t,r){return n+(r?" ":"")+t.toUpperCase()})),Xf=Bu("toUpperCase");function na(n,t,r){return n=mf(n),(t=r?u:t)===u?function(n){return ut.test(n)}(n)?function(n){return n.match(rt)||[]}(n):function(n){return n.match(hn)||[]}(n):n.match(t)||[]}var ta=Ye((function(n,t){try{return Ot(n,u,t)}catch(r){return Qo(r)?r:new an(r)}})),ra=ei((function(n,t){return Et(t,(function(t){t=$i(t),oe(n,t,So(n[t],n))})),n}));function ea(n){return function(){return n}}var ua=Nu(),ia=Nu(!0);function oa(n){return n}function fa(n){return Be("function"==typeof n?n:ce(n,1))}var aa=Ye((function(n,t){return function(r){return Se(r,n,t)}})),ca=Ye((function(n,t){return function(r){return Se(n,r,t)}}));function la(n,t,r){var e=Lf(t),u=je(t,e);null!=r||rf(t)&&(u.length||!e.length)||(r=t,t=n,n=this,u=je(t,Lf(t)));var i=!(rf(r)&&"chain"in r)||!!r.chain,o=Xo(n);return Et(u,(function(r){var e=t[r];n[r]=e,o&&(n.prototype[r]=function(){var t=this.__chain__;if(i||t){var r=n(this.__wrapped__),u=r.__actions__=zu(this.__actions__);return u.push({func:e,args:arguments,thisArg:n}),r.__chain__=t,r}return e.apply(n,Ut([this.value()],arguments))})})),n}function sa(){}var ha=qu(Lt),pa=qu(zt),va=qu($t);function _a(n){return mi(n)?Kt($i(n)):function(n){return function(t){return Ae(t,n)}}(n)}var ga=Ku(),ya=Ku(!0);function da(){return[]}function ba(){return!1}var wa=Pu((function(n,t){return n+t}),0),ma=Hu("ceil"),xa=Pu((function(n,t){return n/t}),1),ja=Hu("floor");var Aa=Pu((function(n,t){return n*t}),1),ka=Hu("round"),Oa=Pu((function(n,t){return n-t}),0);return Mr.after=function(n,t){if("function"!=typeof t)throw new zn(i);return n=yf(n),function(){if(--n<1)return t.apply(this,arguments)}},Mr.ary=Ro,Mr.assign=xf,Mr.assignIn=jf,Mr.assignInWith=Af,Mr.assignWith=kf,Mr.at=Of,Mr.before=zo,Mr.bind=So,Mr.bindAll=ra,Mr.bindKey=Co,Mr.castArray=function(){if(!arguments.length)return[];var n=arguments[0];return Ko(n)?n:[n]},Mr.chain=po,Mr.chunk=function(n,t,e){t=(e?wi(n,t,e):t===u)?1:br(yf(t),0);var i=null==n?0:n.length;if(!i||t<1)return[];for(var o=0,f=0,a=r(_t(i/t));oi?0:i+r),(e=e===u||e>i?i:yf(e))<0&&(e+=i),e=r>e?0:df(e);r>>0)?(n=mf(n))&&("string"==typeof t||null!=t&&!af(t))&&!(t=lu(t))&&fr(n)?xu(vr(n),0,r):n.split(t,r):[]},Mr.spread=function(n,t){if("function"!=typeof n)throw new zn(i);return t=null==t?0:br(yf(t),0),Ye((function(r){var e=r[t],u=xu(r,0,t);return e&&Ut(u,e),Ot(n,this,u)}))},Mr.tail=function(n){var t=null==n?0:n.length;return t?uu(n,1,t):[]},Mr.take=function(n,t,r){return n&&n.length?uu(n,0,(t=r||t===u?1:yf(t))<0?0:t):[]},Mr.takeRight=function(n,t,r){var e=null==n?0:n.length;return e?uu(n,(t=e-(t=r||t===u?1:yf(t)))<0?0:t,e):[]},Mr.takeRightWhile=function(n,t){return n&&n.length?vu(n,ci(t,3),!1,!0):[]},Mr.takeWhile=function(n,t){return n&&n.length?vu(n,ci(t,3)):[]},Mr.tap=function(n,t){return t(n),n},Mr.throttle=function(n,t,r){var e=!0,u=!0;if("function"!=typeof n)throw new zn(i);return rf(r)&&(e="leading"in r?!!r.leading:e,u="trailing"in r?!!r.trailing:u),Wo(n,t,{leading:e,maxWait:t,trailing:u})},Mr.thru=vo,Mr.toArray=_f,Mr.toPairs=Mf,Mr.toPairsIn=Ff,Mr.toPath=function(n){return Ko(n)?Lt(n,$i):sf(n)?[n]:zu(Ti(mf(n)))},Mr.toPlainObject=wf,Mr.transform=function(n,t,r){var e=Ko(n),u=e||Jo(n)||hf(n);if(t=ci(t,4),null==r){var i=n&&n.constructor;r=u?e?new i:[]:rf(n)&&Xo(i)?Fr(Vn(n)):{}}return(u?Et:me)(n,(function(n,e,u){return t(r,n,e,u)})),r},Mr.unary=function(n){return Ro(n,1)},Mr.union=ro,Mr.unionBy=eo,Mr.unionWith=uo,Mr.uniq=function(n){return n&&n.length?su(n):[]},Mr.uniqBy=function(n,t){return n&&n.length?su(n,ci(t,2)):[]},Mr.uniqWith=function(n,t){return t="function"==typeof t?t:u,n&&n.length?su(n,u,t):[]},Mr.unset=function(n,t){return null==n||hu(n,t)},Mr.unzip=io,Mr.unzipWith=oo,Mr.update=function(n,t,r){return null==n?n:pu(n,t,bu(r))},Mr.updateWith=function(n,t,r,e){return e="function"==typeof e?e:u,null==n?n:pu(n,t,bu(r),e)},Mr.values=Pf,Mr.valuesIn=function(n){return null==n?[]:Xt(n,Uf(n))},Mr.without=fo,Mr.words=na,Mr.wrap=function(n,t){return Do(bu(t),n)},Mr.xor=ao,Mr.xorBy=co,Mr.xorWith=lo,Mr.zip=so,Mr.zipObject=function(n,t){return yu(n||[],t||[],re)},Mr.zipObjectDeep=function(n,t){return yu(n||[],t||[],nu)},Mr.zipWith=ho,Mr.entries=Mf,Mr.entriesIn=Ff,Mr.extend=jf,Mr.extendWith=Af,la(Mr,Mr),Mr.add=wa,Mr.attempt=ta,Mr.camelCase=qf,Mr.capitalize=Zf,Mr.ceil=ma,Mr.clamp=function(n,t,r){return r===u&&(r=t,t=u),r!==u&&(r=(r=bf(r))===r?r:0),t!==u&&(t=(t=bf(t))===t?t:0),ae(bf(n),t,r)},Mr.clone=function(n){return ce(n,4)},Mr.cloneDeep=function(n){return ce(n,5)},Mr.cloneDeepWith=function(n,t){return ce(n,5,t="function"==typeof t?t:u)},Mr.cloneWith=function(n,t){return ce(n,4,t="function"==typeof t?t:u)},Mr.conformsTo=function(n,t){return null==t||le(n,t,Lf(t))},Mr.deburr=Kf,Mr.defaultTo=function(n,t){return null==n||n!==n?t:n},Mr.divide=xa,Mr.endsWith=function(n,t,r){n=mf(n),t=lu(t);var e=n.length,i=r=r===u?e:ae(yf(r),0,e);return(r-=t.length)>=0&&n.slice(r,i)==t},Mr.eq=Fo,Mr.escape=function(n){return(n=mf(n))&&Y.test(n)?n.replace(H,ir):n},Mr.escapeRegExp=function(n){return(n=mf(n))&&on.test(n)?n.replace(un,"\\$&"):n},Mr.every=function(n,t,r){var e=Ko(n)?zt:_e;return r&&wi(n,t,r)&&(t=u),e(n,ci(t,3))},Mr.find=yo,Mr.findIndex=qi,Mr.findKey=function(n,t){return Nt(n,ci(t,3),me)},Mr.findLast=bo,Mr.findLastIndex=Zi,Mr.findLastKey=function(n,t){return Nt(n,ci(t,3),xe)},Mr.floor=ja,Mr.forEach=wo,Mr.forEachRight=mo,Mr.forIn=function(n,t){return null==n?n:be(n,ci(t,3),Uf)},Mr.forInRight=function(n,t){return null==n?n:we(n,ci(t,3),Uf)},Mr.forOwn=function(n,t){return n&&me(n,ci(t,3))},Mr.forOwnRight=function(n,t){return n&&xe(n,ci(t,3))},Mr.get=Rf,Mr.gt=Po,Mr.gte=qo,Mr.has=function(n,t){return null!=n&&gi(n,t,Ee)},Mr.hasIn=zf,Mr.head=Vi,Mr.identity=oa,Mr.includes=function(n,t,r,e){n=Go(n)?n:Pf(n),r=r&&!e?yf(r):0;var u=n.length;return r<0&&(r=br(u+r,0)),lf(n)?r<=u&&n.indexOf(t,r)>-1:!!u&&Ft(n,t,r)>-1},Mr.indexOf=function(n,t,r){var e=null==n?0:n.length;if(!e)return-1;var u=null==r?0:yf(r);return u<0&&(u=br(e+u,0)),Ft(n,t,u)},Mr.inRange=function(n,t,r){return t=gf(t),r===u?(r=t,t=0):r=gf(r),function(n,t,r){return n>=wr(t,r)&&n=-9007199254740991&&n<=v},Mr.isSet=cf,Mr.isString=lf,Mr.isSymbol=sf,Mr.isTypedArray=hf,Mr.isUndefined=function(n){return n===u},Mr.isWeakMap=function(n){return ef(n)&&_i(n)==W},Mr.isWeakSet=function(n){return ef(n)&&"[object WeakSet]"==Oe(n)},Mr.join=function(n,t){return null==n?"":Vt.call(n,t)},Mr.kebabCase=Vf,Mr.last=Yi,Mr.lastIndexOf=function(n,t,r){var e=null==n?0:n.length;if(!e)return-1;var i=e;return r!==u&&(i=(i=yf(r))<0?br(e+i,0):wr(i,e-1)),t===t?function(n,t,r){for(var e=r+1;e--;)if(n[e]===t)return e;return e}(n,t,i):Mt(n,qt,i,!0)},Mr.lowerCase=Gf,Mr.lowerFirst=Hf,Mr.lt=pf,Mr.lte=vf,Mr.max=function(n){return n&&n.length?ge(n,oa,Ie):u},Mr.maxBy=function(n,t){return n&&n.length?ge(n,ci(t,2),Ie):u},Mr.mean=function(n){return Zt(n,oa)},Mr.meanBy=function(n,t){return Zt(n,ci(t,2))},Mr.min=function(n){return n&&n.length?ge(n,oa,De):u},Mr.minBy=function(n,t){return n&&n.length?ge(n,ci(t,2),De):u},Mr.stubArray=da,Mr.stubFalse=ba,Mr.stubObject=function(){return{}},Mr.stubString=function(){return""},Mr.stubTrue=function(){return!0},Mr.multiply=Aa,Mr.nth=function(n,t){return n&&n.length?qe(n,yf(t)):u},Mr.noConflict=function(){return vt._===this&&(vt._=Mn),this},Mr.noop=sa,Mr.now=Eo,Mr.pad=function(n,t,r){n=mf(n);var e=(t=yf(t))?pr(n):0;if(!t||e>=t)return n;var u=(t-e)/2;return Zu(gt(u),r)+n+Zu(_t(u),r)},Mr.padEnd=function(n,t,r){n=mf(n);var e=(t=yf(t))?pr(n):0;return t&&et){var e=n;n=t,t=e}if(r||n%1||t%1){var i=jr();return wr(n+i*(t-n+lt("1e-"+((i+"").length-1))),t)}return He(n,t)},Mr.reduce=function(n,t,r){var e=Ko(n)?Bt:Gt,u=arguments.length<3;return e(n,ci(t,4),r,u,pe)},Mr.reduceRight=function(n,t,r){var e=Ko(n)?Tt:Gt,u=arguments.length<3;return e(n,ci(t,4),r,u,ve)},Mr.repeat=function(n,t,r){return t=(r?wi(n,t,r):t===u)?1:yf(t),Je(mf(n),t)},Mr.replace=function(){var n=arguments,t=mf(n[0]);return n.length<3?t:t.replace(n[1],n[2])},Mr.result=function(n,t,r){var e=-1,i=(t=wu(t,n)).length;for(i||(i=1,n=u);++ev)return[];var r=g,e=wr(n,g);t=ci(t),n-=g;for(var u=Jt(e,t);++r=o)return n;var a=r-pr(e);if(a<1)return e;var c=f?xu(f,0,a).join(""):n.slice(0,a);if(i===u)return c+e;if(f&&(a+=c.length-a),af(i)){if(n.slice(a).search(i)){var l,s=c;for(i.global||(i=En(i.source,mf(gn.exec(i))+"g")),i.lastIndex=0;l=i.exec(s);)var h=l.index;c=c.slice(0,h===u?a:h)}}else if(n.indexOf(lu(i),a)!=a){var p=c.lastIndexOf(i);p>-1&&(c=c.slice(0,p))}return c+e},Mr.unescape=function(n){return(n=mf(n))&&J.test(n)?n.replace(G,gr):n},Mr.uniqueId=function(n){var t=++Tn;return mf(n)+t},Mr.upperCase=Qf,Mr.upperFirst=Xf,Mr.each=wo,Mr.eachRight=mo,Mr.first=Vi,la(Mr,function(){var n={};return me(Mr,(function(t,r){Bn.call(Mr.prototype,r)||(n[r]=t)})),n}(),{chain:!1}),Mr.VERSION="4.17.21",Et(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(n){Mr[n].placeholder=Mr})),Et(["drop","take"],(function(n,t){Zr.prototype[n]=function(r){r=r===u?1:br(yf(r),0);var e=this.__filtered__&&!t?new Zr(this):this.clone();return e.__filtered__?e.__takeCount__=wr(r,e.__takeCount__):e.__views__.push({size:wr(r,g),type:n+(e.__dir__<0?"Right":"")}),e},Zr.prototype[n+"Right"]=function(t){return this.reverse()[n](t).reverse()}})),Et(["filter","map","takeWhile"],(function(n,t){var r=t+1,e=1==r||3==r;Zr.prototype[n]=function(n){var t=this.clone();return t.__iteratees__.push({iteratee:ci(n,3),type:r}),t.__filtered__=t.__filtered__||e,t}})),Et(["head","last"],(function(n,t){var r="take"+(t?"Right":"");Zr.prototype[n]=function(){return this[r](1).value()[0]}})),Et(["initial","tail"],(function(n,t){var r="drop"+(t?"":"Right");Zr.prototype[n]=function(){return this.__filtered__?new Zr(this):this[r](1)}})),Zr.prototype.compact=function(){return this.filter(oa)},Zr.prototype.find=function(n){return this.filter(n).head()},Zr.prototype.findLast=function(n){return this.reverse().find(n)},Zr.prototype.invokeMap=Ye((function(n,t){return"function"==typeof n?new Zr(this):this.map((function(r){return Se(r,n,t)}))})),Zr.prototype.reject=function(n){return this.filter(To(ci(n)))},Zr.prototype.slice=function(n,t){n=yf(n);var r=this;return r.__filtered__&&(n>0||t<0)?new Zr(r):(n<0?r=r.takeRight(-n):n&&(r=r.drop(n)),t!==u&&(r=(t=yf(t))<0?r.dropRight(-t):r.take(t-n)),r)},Zr.prototype.takeRightWhile=function(n){return this.reverse().takeWhile(n).reverse()},Zr.prototype.toArray=function(){return this.take(g)},me(Zr.prototype,(function(n,t){var r=/^(?:filter|find|map|reject)|While$/.test(t),e=/^(?:head|last)$/.test(t),i=Mr[e?"take"+("last"==t?"Right":""):t],o=e||/^find/.test(t);i&&(Mr.prototype[t]=function(){var t=this.__wrapped__,f=e?[1]:arguments,a=t instanceof Zr,c=f[0],l=a||Ko(t),s=function(n){var t=i.apply(Mr,Ut([n],f));return e&&h?t[0]:t};l&&r&&"function"==typeof c&&1!=c.length&&(a=l=!1);var h=this.__chain__,p=!!this.__actions__.length,v=o&&!h,_=a&&!p;if(!o&&l){t=_?t:new Zr(this);var g=n.apply(t,f);return g.__actions__.push({func:vo,args:[s],thisArg:u}),new qr(g,h)}return v&&_?n.apply(this,f):(g=this.thru(s),v?e?g.value()[0]:g.value():g)})})),Et(["pop","push","shift","sort","splice","unshift"],(function(n){var t=Sn[n],r=/^(?:push|sort|unshift)$/.test(n)?"tap":"thru",e=/^(?:pop|shift)$/.test(n);Mr.prototype[n]=function(){var n=arguments;if(e&&!this.__chain__){var u=this.value();return t.apply(Ko(u)?u:[],n)}return this[r]((function(r){return t.apply(Ko(r)?r:[],n)}))}})),me(Zr.prototype,(function(n,t){var r=Mr[t];if(r){var e=r.name+"";Bn.call(Cr,e)||(Cr[e]=[]),Cr[e].push({name:t,func:r})}})),Cr[Mu(u,2).name]=[{name:"wrapper",func:u}],Zr.prototype.clone=function(){var n=new Zr(this.__wrapped__);return n.__actions__=zu(this.__actions__),n.__dir__=this.__dir__,n.__filtered__=this.__filtered__,n.__iteratees__=zu(this.__iteratees__),n.__takeCount__=this.__takeCount__,n.__views__=zu(this.__views__),n},Zr.prototype.reverse=function(){if(this.__filtered__){var n=new Zr(this);n.__dir__=-1,n.__filtered__=!0}else(n=this.clone()).__dir__*=-1;return n},Zr.prototype.value=function(){var n=this.__wrapped__.value(),t=this.__dir__,r=Ko(n),e=t<0,u=r?n.length:0,i=function(n,t,r){var e=-1,u=r.length;for(;++e=this.__values__.length;return{done:n,value:n?u:this.__values__[this.__index__++]}},Mr.prototype.plant=function(n){for(var t,r=this;r instanceof Pr;){var e=Ni(r);e.__index__=0,e.__values__=u,t?i.__wrapped__=e:t=e;var i=e;r=r.__wrapped__}return i.__wrapped__=n,t},Mr.prototype.reverse=function(){var n=this.__wrapped__;if(n instanceof Zr){var t=n;return this.__actions__.length&&(t=new Zr(this)),(t=t.reverse()).__actions__.push({func:vo,args:[to],thisArg:u}),new qr(t,this.__chain__)}return this.thru(to)},Mr.prototype.toJSON=Mr.prototype.valueOf=Mr.prototype.value=function(){return _u(this.__wrapped__,this.__actions__)},Mr.prototype.first=Mr.prototype.head,Qn&&(Mr.prototype[Qn]=function(){return this}),Mr}();vt._=yr,(e=function(){return yr}.call(t,r,t,n))===u||(n.exports=e)}.call(this)}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/3181-e628e642754b0f35.js b/dsql-app/.local_dist/static/chunks/3181-e628e642754b0f35.js new file mode 100644 index 0000000..3c815b5 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/3181-e628e642754b0f35.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3181],{96224:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"m16 7.58-5.5-2.4L5 7.58v3.6c0 3.5 2.33 6.74 5.5 7.74.25-.08.49-.2.73-.3-.15-.51-.23-1.06-.23-1.62 0-2.97 2.16-5.43 5-5.91V7.58z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"M17 13c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 1.38c.62 0 1.12.51 1.12 1.12s-.51 1.12-1.12 1.12-1.12-.51-1.12-1.12.5-1.12 1.12-1.12zm0 5.37c-.93 0-1.74-.46-2.24-1.17.05-.72 1.51-1.08 2.24-1.08s2.19.36 2.24 1.08c-.5.71-1.31 1.17-2.24 1.17z",opacity:".3"},"1"),(0,c.jsx)("circle",{cx:"17",cy:"15.5",r:"1.12"},"2"),(0,c.jsx)("path",{d:"M18 11.09V6.27L10.5 3 3 6.27v4.91c0 4.54 3.2 8.79 7.5 9.82.55-.13 1.08-.32 1.6-.55C13.18 21.99 14.97 23 17 23c3.31 0 6-2.69 6-6 0-2.97-2.16-5.43-5-5.91zM11 17c0 .56.08 1.11.23 1.62-.24.11-.48.22-.73.3-3.17-1-5.5-4.24-5.5-7.74v-3.6l5.5-2.4 5.5 2.4v3.51c-2.84.48-5 2.94-5 5.91zm6 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"},"3"),(0,c.jsx)("path",{d:"M17 17.5c-.73 0-2.19.36-2.24 1.08.5.71 1.32 1.17 2.24 1.17s1.74-.46 2.24-1.17c-.05-.72-1.51-1.08-2.24-1.08z"},"4")],"AdminPanelSettingsTwoTone");a.Z=l},88518:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"M22 15c0-1.66-1.34-3-3-3h-1.5v-.5C17.5 8.46 15.04 6 12 6c-.77 0-1.49.17-2.16.46L20.79 17.4c.73-.55 1.21-1.41 1.21-2.4zM2 14c0 2.21 1.79 4 4 4h9.73l-8-8H6c-2.21 0-4 1.79-4 4z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.33 0-2.57.36-3.65.97l1.49 1.49C10.51 6.17 11.23 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 .99-.48 1.85-1.21 2.4l1.41 1.41c1.09-.92 1.8-2.27 1.8-3.81 0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.77 2.77h-.42C2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h11.73l2 2 1.41-1.41L4.41 3.86 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"},"1")],"CloudOffTwoTone");a.Z=l},66022:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"M9 4h9v12H9z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"M18 2H9c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h9c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H9V4h9v12zM3 15v-2h2v2H3zm0-5.5h2v2H3v-2zM10 20h2v2h-2v-2zm-7-1.5v-2h2v2H3zM5 22c-1.1 0-2-.9-2-2h2v2zm3.5 0h-2v-2h2v2zm5 0v-2h2c0 1.1-.9 2-2 2zM5 6v2H3c0-1.1.9-2 2-2z"},"1")],"CopyAllTwoTone");a.Z=l},29277:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"M16 9H8v10h8V9zm-.47 7.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14l-2.13-2.12 1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"M14.12 10.47 12 12.59l-2.13-2.12-1.41 1.41L10.59 14l-2.12 2.12 1.41 1.41L12 15.41l2.12 2.12 1.41-1.41L13.41 14l2.12-2.12zM15.5 4l-1-1h-5l-1 1H5v2h14V4zM6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM8 9h8v10H8V9z"},"1")],"DeleteForeverTwoTone");a.Z=l},96673:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"M14.17 3H8v14h11V7.83L14.17 3zm2.33 12h-6v-2h6v2zm0-6h-2v2h-2V9h-2V7h2V5h2v2h2v2z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"M18 23H4c-1.1 0-2-.9-2-2V7h2v14h14v2zM14.5 7V5h-2v2h-2v2h2v2h2V9h2V7h-2zm2 6h-6v2h6v-2zM15 1H8c-1.1 0-1.99.9-1.99 2L6 17c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V7l-6-6zm4 16H8V3h6.17L19 7.83V17z"},"1")],"DifferenceTwoTone");a.Z=l},63749:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)([(0,c.jsx)("path",{d:"M12.06 10.02 5 17.08V18h.92l7.06-7.06z",opacity:".3"},"0"),(0,c.jsx)("path",{d:"m15 16-4 4h10v-4zm-2.94-8.81L3 16.25V20h3.75l9.06-9.06-3.75-3.75zM5.92 18H5v-.92l7.06-7.06.92.92L5.92 18zm12.79-9.96c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.2-.2-.45-.29-.71-.29-.25 0-.51.1-.7.29l-1.83 1.83 3.75 3.75 1.83-1.83z"},"1")],"DriveFileRenameOutlineTwoTone");a.Z=l},74458:function(e,a,t){var s=t(64836);a.Z=void 0;var n=s(t(64938)),c=t(85893),l=(0,n.default)((0,c.jsx)("path",{d:"M2 20h20v-4H2v4zm2-3h2v2H4v-2zM2 4v4h20V4H2zm4 3H4V5h2v2zm-4 7h20v-4H2v4zm2-3h2v2H4v-2z"}),"StorageTwoTone");a.Z=l},57150:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},64998:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},33587:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},49525:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(e,a,t){t.d(a,{Z:function(){return s}});const s=(0,t(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},92184:function(e,a,t){t.d(a,{Z:function(){return h}});var s=t(828),n=t(85893),c=t(67294),l=t(94739),i=t(25472),r=t(86729),d=t(95264),o=t(45449),u=t(64998);function h(e){var a,t=e.database,h=e.setTargetDatabase,x=e.delegated,p=(e.icons,e.user),m="/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(t.db_slug)+(x?"?delegated=true&dbUserId=".concat(t.user_id):""),v=t.active_clone,f=t.active_clone_parent_db,j=(0,s.Z)(c.useState(!1),2),b=j[0],g=j[1];return(0,n.jsxs)("a",{href:m,className:"card",onClick:function(e){e.target.closest(".db-list-item-actions-block")&&e.preventDefault(),x&&(e.preventDefault(),g(!0),(0,r.Z)("/api/getDelegatedDatabaseToken",{method:"post",body:{rootUserId:t.user_id,priviledges:t.user_priviledge,database:t.db_slug}},!0).then((function(e){e.success&&(window.location.href=m)})),setTimeout((function(){g(!1)}),1e3))},children:[b&&(0,n.jsx)(d.Z,{width:"20px"}),(0,n.jsx)("img",{src:t.db_image?t.db_image:"/images/folder.svg",alt:"Folder Image",width:20,className:t.db_image?"avatar":"avatar opacity-50"}),(0,n.jsxs)("div",{className:"flex-col items-start grow",children:[(0,n.jsx)("span",{className:"title",children:t.db_name}),f&&(0,n.jsxs)("span",{className:"text-xs bg-emerald-100 dark:bg-emerald-100/10 text-emerald-700 dark:text-emerald-200 px-2 py-0.5 rounded-full mb-1",children:["This Database is an active Clone of"," ",(0,n.jsx)("b",{children:f.replace(/datasquirel_user_\d+_/,"")})]}),(0,n.jsx)("div",{className:"-mt-2",children:(0,n.jsx)(l.Z,{slugText:t.db_slug,smaller:!0})}),!x&&(0,n.jsxs)("span",{className:"text-sm text-slate-400",children:["Created: ",null===(a=t.date_created)||void 0===a?void 0:a.substring(0,21)]}),x&&(0,n.jsxs)("div",{className:"flex items-center mt-2",children:[(0,n.jsx)("img",{src:t.image_thumbnail,alt:"",className:"w-8 h-8 rounded-full object-cover"}),(0,n.jsxs)("div",{className:"flex-col items-start gap-0",children:[(0,n.jsxs)("span",{className:"text-xs text-slate-600",children:[t.first_name," ",t.last_name]}),(0,n.jsx)("span",{className:"text-xs text-slate-400",children:t.email})]})]}),(0,n.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,n.jsx)("div",{className:"db-list-item-actions-block flex-wrap",children:(0,n.jsxs)(o.Z,{children:[!x&&(0,n.jsx)("button",{className:"outlined light-gray small-text",onClick:function(e){window.location.pathname="/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(t.db_slug,"/edit-database")},children:(0,n.jsx)("span",{children:"Edit"})}),!x&&!v&&(0,n.jsx)("button",{className:"outlined light-gray small-text",onClick:function(e){window.location.href="/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/add-database?duplicate=").concat(t.db_full_name)},children:(0,n.jsx)("span",{children:"Duplicate"})}),!x&&(0,n.jsx)("button",{className:"outlined light-gray small-text",onClick:function(e){h&&h(t),(0,i.Mw)("delete-database-confirmation")},children:(0,n.jsx)("span",{children:"Delete"})})]})}),(0,n.jsx)(u.Z,{className:"text-slate-600",size:20})]})]})]})}},68744:function(e,a,t){t.d(a,{Z:function(){return o}});var s=t(85893),n=t(67294),c=t(2109),l=t(424),i=t(97946),r=t(96891),d=t(55592);function o(e){var a,t=n.useContext(c.DatabasesContext),o=t.databases,u=t.setTargetDatabase,h=t.user;return(0,s.jsxs)(n.Fragment,{children:[(0,s.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,s.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,s.jsx)("h1",{className:"text-3xl m-0",children:"Databases"}),(0,s.jsxs)("a",{href:"/admin/".concat(null===h||void 0===h?void 0:h.id,"/databases/add-database"),className:"button flex items-center gap-2",children:[(0,s.jsx)("span",{className:"symbol",children:"+"}),(0,s.jsx)("span",{children:"Add Database"})]})]}),(0,s.jsx)(l.Z,{user:h})]}),(null===h||void 0===h||null===(a=h.verification_status)||void 0===a?void 0:a.toString().match(/1/))?(0,s.jsxs)(n.Fragment,{children:[(0,s.jsx)(r.Z,{databases:o,setTargetDatabase:u,user:h}),(0,s.jsx)(d.Z,{user:h})]}):(0,s.jsx)(i.Z,{})]})}},96891:function(e,a,t){t.d(a,{Z:function(){return u}});var s=t(85893),n=t(67294),c=t(92184),l=t(63749),i=t(96673),r=t(29277),d=t(66022),o=t(74458);function u(e){var a=e.databases,t=e.setTargetDatabase,u=e.title,h=e.more,x=e.user;return(0,s.jsx)(n.Fragment,{children:(0,s.jsxs)("section",{className:"paper",children:[(0,s.jsx)("h2",{className:"text-xl m-0",children:u||"Database List"}),x&&a&&a[0]&&t&&(0,s.jsx)("div",{className:"w-full grid grid-cols-1 sl:grid-cols-2 xl:grid-cols-3 items-stretch gap-6",children:a.map((function(e){return(0,s.jsx)(c.Z,{database:e,setTargetDatabase:t,icons:{edit:l.Z,duplicate:i.Z,delete:r.Z,copy:d.Z},user:x},e.id)}))}),h&&a&&a[0]&&(0,s.jsx)("a",{href:"/admin/".concat(null===x||void 0===x?void 0:x.id,"/databases"),className:"button w-full more-padding",children:"See All Databases"}),!a||!a[0]&&(0,s.jsxs)("a",{href:"/admin/".concat(null===x||void 0===x?void 0:x.id,"/databases/add-database"),className:"button outlined gray dashed w-full p-10 flex-col",children:[(0,s.jsx)("span",{className:"text-slate-400",children:"No Databases Created."}),(0,s.jsx)(o.Z,{color:"action",sx:{fontSize:80},className:"opacity-40"}),(0,s.jsx)("span",{className:"",children:"Add Database"})]})]})})}},55592:function(e,a,t){t.d(a,{Z:function(){return x}});var s=t(828),n=t(85893),c=t(67294),l=t(63749),i=t(96673),r=t(29277),d=t(66022),o=t(95264),u=t(86729),h=t(92184);function x(e){var a=e.user,t=c.useState(null),x=(0,s.Z)(t,2),p=x[0],m=x[1],v=(0,s.Z)(c.useState(!1),2),f=v[0],j=v[1];return c.useEffect((function(){(0,u.Z)("/api/getDelegatedDatabases").then((function(e){e.success&&(m(e.databases),j(!1))}))}),[]),(0,n.jsxs)("section",{className:"paper",children:[(0,n.jsx)("h2",{className:"text-xl m-0 text-left w-full",children:"Delegated Databases"}),f&&(0,n.jsx)(o.Z,{}),a&&p?p[0]?(0,n.jsx)(c.Fragment,{children:(0,n.jsx)("div",{className:"w-full grid grid-cols-1 sl:grid-cols-2 xl:grid-cols-3 items-stretch gap-6",children:p.map((function(e){return(0,n.jsx)(h.Z,{database:e,delegated:!0,icons:{edit:l.Z,duplicate:i.Z,delete:r.Z,copy:d.Z},user:a},e.id)}))})}):(0,n.jsx)(c.Fragment,{children:(0,n.jsx)("span",{className:"info gray w-full font-normal justify-center",children:"No Delegated Databases Yet"})}):(0,n.jsx)(c.Fragment,{children:(0,n.jsx)("div",{className:"w-full justify-center",children:(0,n.jsx)(o.Z,{position:"relative",width:"20px"})})})]})}},85012:function(e,a,t){t.d(a,{Z:function(){return d}});var s=t(828),n=t(85893),c=t(67294),l=t(86729),i=t(25472),r=t(95264);function d(e){var a=e.targetDatabase,t=(0,s.Z)(c.useState(!1),2),d=t[0],o=t[1];return(0,n.jsxs)(i.ZP,{title:"delete-database-confirmation",children:[d&&(0,n.jsx)(r.Z,{width:"20px"}),(0,n.jsxs)("h4",{className:"m-0",children:["Delete '",(null===a||void 0===a?void 0:a.db_name)?a.db_name:"This Database","' database?"]}),(0,n.jsxs)("div",{children:[(0,n.jsx)("button",{className:"outlined"+(d?" pointer-events-none opacity-40":""),onClick:function(e){a?(o(!0),window.confirm("Note that you will loose all data in this database. Continue?")?(0,l.Z)("/api/deleteUserDatabase",{method:"post",body:a},!0).then((function(e){e.success&&window.location.reload()})):o(!1)):alert("No Target Database Selected!")},children:(0,n.jsx)("span",{children:"Yes"})}),(0,n.jsx)("button",{onClick:function(e){(0,i.j4)()},children:(0,n.jsx)("span",{children:"Cancel"})})]})]})}},94739:function(e,a,t){t.d(a,{Z:function(){return c}});var s=t(85893),n=(t(67294),t(66022));function c(e){var a=e.slugText,t=e.smaller,c=e.outlined;return(0,s.jsxs)("span",{className:"button "+(c?" outlined gray":"light-gray")+(t?" small-text":""),onClick:function(e){navigator.clipboard.writeText(a).then((function(){alert('Database Slug "'.concat(a,'" Copied to Clipboard. Use this as the database name when querying data'))}))},children:[(0,s.jsx)(n.Z,{color:"action",sx:{opacity:.5,fontSize:15}}),(0,s.jsx)("span",{children:a})]})}},25472:function(e,a,t){t.d(a,{Mw:function(){return i},ZP:function(){return l},j4:function(){return r}});var s=t(85893),n=t(41352),c=t(67294);function l(e){var a=e.children,t=e.title,l=e.data,i=e.fullPage,d=e.wrapperClasses,o=e.closePopupDispatch,u=e.wrapperStyle,h=e.noContainer;return i?(0,s.jsxs)("div",{className:"popup-bg overflow-hidden "+(d||""),"data-popupid":t||null,style:u,children:[h?(0,s.jsx)(c.Fragment,{children:a}):(0,s.jsx)("div",{className:"relative w-full h-full z-50","data-data":l?JSON.stringify(l):"",children:a}),(0,s.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(e){r(),o&&o()},children:(0,s.jsx)(n.Z,{color:"white",size:20})}),(0,s.jsx)("div",{className:"popup-canceller",onClick:function(e){r(),o&&o()}})]}):(0,s.jsxs)("div",{className:"popup-bg","data-popupid":t||null,children:[h?(0,s.jsx)(c.Fragment,{children:a}):(0,s.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":l?JSON.stringify(l):"",children:[a,(0,s.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(e){r(),o&&o()},children:(0,s.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),h&&(0,s.jsx)("button",{className:"gray popup-cancel-button",onClick:function(e){r(),o&&o()},children:(0,s.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,s.jsx)("div",{className:"popup-canceller",onClick:function(e){r(),o&&o()}})]})}function i(e,a){var t=document.querySelector("[data-popupid='".concat(e,"']"));t&&(t.style.display="flex",a&&a(t))}function r(e){document.querySelectorAll("[data-popupid]").forEach((function(e){e.style.display="none"})),e&&e()}},97946:function(e,a,t){t.d(a,{Z:function(){return n}});var s=t(85893);t(67294);function n(e){return(0,s.jsxs)("a",{href:"/email-verification",className:"card w-full items-center justify-center py-4 gap-2",children:[(0,s.jsx)("img",{src:"/images/warning.png",alt:"Down Arrow",width:25,className:""}),(0,s.jsx)("span",{children:"Your Account is not verified. Please verify your account."})]})}},2109:function(e,a,t){t.r(a),t.d(a,{DatabasesContext:function(){return u},__N_SSP:function(){return o},default:function(){return h}});var s=t(828),n=t(85893),c=t(67294),l=t(54858),i=t(68744),r=t(85012),d={},o=!0,u=c.createContext(d);function h(e){var a=e.user,t=e.databases,d=(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("title",{children:"Databases | Datasquirel"}),(0,n.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),o=c.useState(0),h=(0,s.Z)(o,2),x=h[0],p=h[1];return(0,n.jsx)(l.Z,{head:d,user:a,children:(0,n.jsxs)(u.Provider,{value:{user:a,databases:t,targetDatabase:x,setTargetDatabase:p},children:[(0,n.jsx)(i.Z,{}),(0,n.jsx)(r.Z,{targetDatabase:x})]})})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/3695-7acf198d2c47bd8e.js b/dsql-app/.local_dist/static/chunks/3695-7acf198d2c47bd8e.js new file mode 100644 index 0000000..bcc448b --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/3695-7acf198d2c47bd8e.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3695],{50027:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("path",{d:"m19.21 12.04-1.53-.11-.3-1.5C16.88 7.86 14.62 6 12 6 9.94 6 8.08 7.14 7.12 8.96l-.5.95-1.07.11C3.53 10.24 2 11.95 2 14c0 2.21 1.79 4 4 4h13c1.65 0 3-1.35 3-3 0-1.55-1.22-2.86-2.79-2.96zm-5.76.96v3h-2.91v-3H8l4-4 4 4h-2.55z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95C8.08 7.14 9.94 6 12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11c1.56.1 2.78 1.41 2.78 2.96 0 1.65-1.35 3-3 3zM8 13h2.55v3h2.9v-3H16l-4-4z"},"1")],"BackupTwoTone");s.Z=n},64689:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("path",{d:"M18 19h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M12 3 6 7.58V6H4v3.11L1 11.4l1.21 1.59L4 11.62V21h16v-9.38l1.79 1.36L23 11.4 12 3zm6 16h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58V19zM10 1c0 1.66-1.34 3-3 3-.55 0-1 .45-1 1H4c0-1.66 1.34-3 3-3 .55 0 1-.45 1-1h2z"},"1")],"CottageTwoTone");s.Z=n},39269:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("path",{d:"M12 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm1 13h-2v-2h2v2zm0-4h-2V7h2v6z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm-1-5h2v2h-2zm0-8h2v6h-2z"},"1")],"ErrorTwoTone");s.Z=n},28466:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("path",{d:"M6 10v10h5.29c-.19-.63-.29-1.3-.29-2 0-3.87 3.13-7 7-7v-1H6z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M6 20V10h12v1c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.42-.6-.75-1.28-.97-2H6zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6z"},"1"),(0,l.jsx)("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5zm0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32z"},"2")],"LockPersonTwoTone");s.Z=n},38544:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("circle",{cx:"9",cy:"8",r:"2",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M9 15c-2.7 0-5.8 1.29-6 2.01V18h12v-1c-.2-.71-3.3-2-6-2z",opacity:".3"},"1"),(0,l.jsx)("path",{d:"M16.67 13.13C18.04 14.06 19 15.32 19 17v3h4v-3c0-2.18-3.57-3.47-6.33-3.87zM15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4c-.47 0-.91.1-1.33.24C14.5 5.27 15 6.58 15 8s-.5 2.73-1.33 3.76c.42.14.86.24 1.33.24zm-6 0c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0-6c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm0 7c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4zm6 5H3v-.99C3.2 16.29 6.3 15 9 15s5.8 1.29 6 2v1z"},"2")],"PeopleAltTwoTone");s.Z=n},51903:function(e,s,t){var c=t(64836);s.Z=void 0;var a=c(t(64938)),l=t(85893),n=(0,a.default)([(0,l.jsx)("path",{d:"M4 18h16V8H4v10zm8-3h6v2h-6v-2zm-5.91-4.59L7.5 9l4 4-4 4-1.41-1.41L8.67 13l-2.58-2.59z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M12 15h6v2h-6z"},"1"),(0,l.jsx)("path",{d:"M20 4H4c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm0 14H4V8h16v10z"},"2"),(0,l.jsx)("path",{d:"m7.5 17 4-4-4-4-1.41 1.41L8.67 13l-2.58 2.59z"},"3")],"TerminalTwoTone");s.Z=n},44187:function(e,s,t){t.d(s,{Z:function(){return i}});var c=t(828),a=t(85893),l=t(67294),n=t(86729),r=t(95264),o=t(61336);function i(e){var s=e.data,t=function(){(0,n.Z)("/api/admin/grabErrorLogs").then((function(e){var s;!(null===e||void 0===e?void 0:e.log)||"string"!==typeof e.log||(null===(s=e.log)||void 0===s?void 0:s.match(/./))?d(e.log.replace(/\n|\r|\n\r|\\n/gm,"
")):d("No Logs Yet")}))},i=(Object.keys(s.users[0]),(0,c.Z)(l.useState(null),2)),h=i[0],d=i[1],u=(0,c.Z)(l.useState(0),2),v=u[0],m=u[1],x=(0,c.Z)(l.useState(!1),2),j=x[0],f=x[1];return l.useEffect((function(){t(),0===v&&setInterval((function(){t()}),1e4)}),[v]),(0,a.jsx)(l.Fragment,{children:(0,a.jsxs)("div",{className:"items-stretch gap-10 w-full",children:[(0,a.jsxs)("section",{className:"paper w-full",children:[(0,a.jsx)("h2",{className:"text-xl m-0 mb-6",children:"Users"}),(0,a.jsx)("div",{className:"flex-col items-stretch gap-10",children:s.users.map((function(e,s){return(0,a.jsx)(o.Z,{userObject:e},s+1)}))})]}),(0,a.jsxs)("section",{className:"paper",children:[(0,a.jsxs)("div",{className:"w-full justify-between",children:[(0,a.jsx)("h2",{className:"text-xl m-0",children:"Error Logs"}),(0,a.jsx)("div",{children:(0,a.jsxs)("button",{onClick:function(e){window.confirm("Clear Error Logs?")&&(f(!0),(0,n.Z)("/api/admin/clearErrorLogs","post").then((function(e){m((function(e){return e+1}))})),setTimeout((function(){f(!1)}),2e3))},className:"outlined gray relative",children:[j&&(0,a.jsx)(r.Z,{width:"20px"}),"Clear Error Log"]})})]}),h&&(0,a.jsx)("p",{dangerouslySetInnerHTML:{__html:h||"No Log"}}),!h&&(0,a.jsx)(r.Z,{position:"relative",width:"25px"})]})]})})}},61336:function(e,s,t){t.d(s,{Z:function(){return n}});var c=t(828),a=t(85893),l=t(67294);function n(e){var s=e.userObject,t=e.userPage,n=Object.keys(s),r=(0,c.Z)(l.useState(!1),2),o=(r[0],r[1],(0,c.Z)(l.useState(0),2)),i=(o[0],o[1],(0,c.Z)(l.useState(!t),2)),h=i[0],d=i[1];return(0,a.jsxs)("div",{className:"card col green w-full overflow-hidden"+(h?t?" h-[100px]":" h-[85px]":" "),children:[(0,a.jsxs)("div",{className:"items-center w-full",children:[(0,a.jsx)("img",{src:s.image_thumbnail,alt:"",className:"rounded-full object-cover"+(t?" w-16 h-16":" w-12 h-12")}),!t&&(0,a.jsxs)("h3",{className:"m-0 text-xl",children:[s.first_name," ",s.last_name," "]}),(0,a.jsxs)("div",{className:"ml-auto",children:[(0,a.jsx)("button",{className:"outlined gray small-text",onClick:function(e){d(!h)},children:h?"More Details":"Collapse"}),!t&&(0,a.jsx)("a",{href:"/su/users/".concat(s.id),className:"button outlined gray small-text",children:"View User"})]})]}),(0,a.jsx)("div",{className:"card no-hover col w-full light-gray-bg",children:n.map((function(e,t){return(0,a.jsxs)(l.Fragment,{children:[(0,a.jsx)("div",{children:(0,a.jsxs)("span",{style:{wordBreak:"break-all"},children:[e,":"," ",(0,a.jsx)("b",{children:s[e]})]})}),t"))):u("No Logs Yet")}))},h=(Object.keys(s.users[0]),(0,c.Z)(l.useState(null),2)),d=h[0],u=h[1],v=(0,c.Z)(l.useState(0),2),m=v[0],x=v[1],f=(0,c.Z)(l.useState(!1),2),p=f[0],j=f[1];return console.log("undefined"===typeof d?"undefined":(0,a.Z)(d)),l.useEffect((function(){t(),0===m&&setInterval((function(){t()}),1e4)}),[m]),(0,n.jsx)(l.Fragment,{children:(0,n.jsxs)("div",{className:"items-stretch gap-10 w-full",children:[(0,n.jsxs)("section",{className:"paper w-full",children:[(0,n.jsx)("h2",{className:"text-xl m-0 mb-6",children:"Users"}),(0,n.jsx)("div",{className:"flex-col items-stretch gap-10",children:s.users.map((function(e,s){return(0,n.jsx)(i.Z,{userObject:e},s+1)}))})]}),(0,n.jsxs)("section",{className:"paper",children:[(0,n.jsxs)("div",{className:"w-full justify-between",children:[(0,n.jsx)("h2",{className:"text-xl m-0",children:"Error Logs"}),(0,n.jsx)("div",{children:(0,n.jsxs)("button",{onClick:function(e){window.confirm("Clear Error Logs?")&&(j(!0),(0,r.Z)("/api/admin/clearErrorLogs","post").then((function(e){x((function(e){return e+1}))})),setTimeout((function(){j(!1)}),2e3))},className:"outlined gray relative",children:[p&&(0,n.jsx)(o.Z,{width:"20px"}),"Clear Error Log"]})})]}),d&&(0,n.jsx)("p",{dangerouslySetInnerHTML:{__html:d||"No Log"}}),"string"!==typeof d&&(0,n.jsx)(o.Z,{position:"relative",width:"25px"})]})]})})}},61336:function(e,s,t){t.d(s,{Z:function(){return l}});var c=t(828),a=t(85893),n=t(67294);function l(e){var s=e.userObject,t=e.userPage,l=Object.keys(s),r=(0,c.Z)(n.useState(!1),2),o=(r[0],r[1],(0,c.Z)(n.useState(0),2)),i=(o[0],o[1],(0,c.Z)(n.useState(!t),2)),h=i[0],d=i[1];return(0,a.jsxs)("div",{className:"card col green w-full overflow-hidden"+(h?t?" h-[100px]":" h-[85px]":" "),children:[(0,a.jsxs)("div",{className:"items-center w-full",children:[(0,a.jsx)("img",{src:s.image_thumbnail,alt:"",className:"rounded-full object-cover"+(t?" w-16 h-16":" w-12 h-12")}),!t&&(0,a.jsxs)("h3",{className:"m-0 text-xl",children:[s.first_name," ",s.last_name," "]}),(0,a.jsxs)("div",{className:"ml-auto",children:[(0,a.jsx)("button",{className:"outlined gray small-text",onClick:function(e){d(!h)},children:h?"More Details":"Collapse"}),!t&&(0,a.jsx)("a",{href:"/su/users/".concat(s.id),className:"button outlined gray small-text",children:"View User"})]})]}),(0,a.jsx)("div",{className:"card no-hover col w-full light-gray-bg",children:l.map((function(e,t){return(0,a.jsxs)(n.Fragment,{children:[(0,a.jsx)("div",{children:(0,a.jsxs)("span",{style:{wordBreak:"break-all"},children:[e,":"," ",(0,a.jsx)("b",{children:s[e]})]})}),t{const{ownerState:o}=e;return[t.root,o.stickyHeader&&t.stickyHeader]}})((({theme:e,ownerState:t})=>(0,r.Z)({display:"table",width:"100%",borderCollapse:"collapse",borderSpacing:0,"& caption":(0,r.Z)({},e.typography.body2,{padding:e.spacing(2),color:(e.vars||e).palette.text.secondary,textAlign:"left",captionSide:"bottom"})},t.stickyHeader&&{borderCollapse:"separate"}))),f="table";var h=n.forwardRef((function(e,t){const o=(0,c.Z)({props:e,name:"MuiTable"}),{className:d,component:p=f,padding:u="normal",size:h="medium",stickyHeader:y=!1}=o,b=(0,a.Z)(o,g),x=(0,r.Z)({},o,{component:p,padding:u,size:h,stickyHeader:y}),w=(e=>{const{classes:t,stickyHeader:o}=e,a={root:["root",o&&"stickyHeader"]};return(0,s.Z)(a,v,t)})(x),k=n.useMemo((()=>({padding:u,size:h,stickyHeader:y})),[u,h,y]);return(0,m.jsx)(l.Z.Provider,{value:k,children:(0,m.jsx)(Z,(0,r.Z)({as:p,role:p===f?null:"table",ref:t,className:(0,i.Z)(w.root,d),ownerState:x},b))})}))},31618:function(e,t,o){const a=o(67294).createContext();t.Z=a},44063:function(e,t,o){const a=o(67294).createContext();t.Z=a},295:function(e,t,o){o.d(t,{Z:function(){return y}});var a=o(87462),r=o(63366),n=o(67294),i=o(90512),s=o(94780),l=o(44063),c=o(54502),d=o(2641),p=o(1588),u=o(34867);function v(e){return(0,u.Z)("MuiTableBody",e)}(0,p.Z)("MuiTableBody",["root"]);var m=o(85893);const g=["className","component"],Z=(0,d.ZP)("tbody",{name:"MuiTableBody",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"table-row-group"}),f={variant:"body"},h="tbody";var y=n.forwardRef((function(e,t){const o=(0,c.Z)({props:e,name:"MuiTableBody"}),{className:n,component:d=h}=o,p=(0,r.Z)(o,g),u=(0,a.Z)({},o,{component:d}),y=(e=>{const{classes:t}=e;return(0,s.Z)({root:["root"]},v,t)})(u);return(0,m.jsx)(l.Z.Provider,{value:f,children:(0,m.jsx)(Z,(0,a.Z)({className:(0,i.Z)(y.root,n),as:d,ref:t,role:d===h?null:"rowgroup",ownerState:u},p))})}))},98102:function(e,t,o){var a=o(63366),r=o(87462),n=o(67294),i=o(90512),s=o(94780),l=o(41796),c=o(98216),d=o(31618),p=o(44063),u=o(54502),v=o(2641),m=o(89755),g=o(85893);const Z=["align","className","component","padding","scope","size","sortDirection","variant"],f=(0,v.ZP)("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:o}=e;return[t.root,t[o.variant],t[`size${(0,c.Z)(o.size)}`],"normal"!==o.padding&&t[`padding${(0,c.Z)(o.padding)}`],"inherit"!==o.align&&t[`align${(0,c.Z)(o.align)}`],o.stickyHeader&&t.stickyHeader]}})((({theme:e,ownerState:t})=>(0,r.Z)({},e.typography.body2,{display:"table-cell",verticalAlign:"inherit",borderBottom:e.vars?`1px solid ${e.vars.palette.TableCell.border}`:`1px solid\n ${"light"===e.palette.mode?(0,l.$n)((0,l.Fq)(e.palette.divider,1),.88):(0,l._j)((0,l.Fq)(e.palette.divider,1),.68)}`,textAlign:"left",padding:16},"head"===t.variant&&{color:(e.vars||e).palette.text.primary,lineHeight:e.typography.pxToRem(24),fontWeight:e.typography.fontWeightMedium},"body"===t.variant&&{color:(e.vars||e).palette.text.primary},"footer"===t.variant&&{color:(e.vars||e).palette.text.secondary,lineHeight:e.typography.pxToRem(21),fontSize:e.typography.pxToRem(12)},"small"===t.size&&{padding:"6px 16px",[`&.${m.Z.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}},"checkbox"===t.padding&&{width:48,padding:"0 0 0 4px"},"none"===t.padding&&{padding:0},"left"===t.align&&{textAlign:"left"},"center"===t.align&&{textAlign:"center"},"right"===t.align&&{textAlign:"right",flexDirection:"row-reverse"},"justify"===t.align&&{textAlign:"justify"},t.stickyHeader&&{position:"sticky",top:0,zIndex:2,backgroundColor:(e.vars||e).palette.background.default}))),h=n.forwardRef((function(e,t){const o=(0,u.Z)({props:e,name:"MuiTableCell"}),{align:l="inherit",className:v,component:h,padding:y,scope:b,size:x,sortDirection:w,variant:k}=o,T=(0,a.Z)(o,Z),C=n.useContext(d.Z),M=n.useContext(p.Z),R=M&&"head"===M.variant;let H;H=h||(R?"th":"td");let N=b;"td"===H?N=void 0:!N&&R&&(N="col");const z=k||M&&M.variant,$=(0,r.Z)({},o,{align:l,component:H,padding:y||(C&&C.padding?C.padding:"normal"),size:x||(C&&C.size?C.size:"medium"),sortDirection:w,stickyHeader:"head"===z&&C&&C.stickyHeader,variant:z}),S=(e=>{const{classes:t,variant:o,align:a,padding:r,size:n,stickyHeader:i}=e,l={root:["root",o,i&&"stickyHeader","inherit"!==a&&`align${(0,c.Z)(a)}`,"normal"!==r&&`padding${(0,c.Z)(r)}`,`size${(0,c.Z)(n)}`]};return(0,s.Z)(l,m.U,t)})($);let j=null;return w&&(j="asc"===w?"ascending":"descending"),(0,g.jsx)(f,(0,r.Z)({as:H,ref:t,className:(0,i.Z)(S.root,v),"aria-sort":j,scope:N,ownerState:$},T))}));t.Z=h},89755:function(e,t,o){o.d(t,{U:function(){return n}});var a=o(1588),r=o(34867);function n(e){return(0,r.Z)("MuiTableCell",e)}const i=(0,a.Z)("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]);t.Z=i},72882:function(e,t,o){o.d(t,{Z:function(){return Z}});var a=o(87462),r=o(63366),n=o(67294),i=o(90512),s=o(94780),l=o(54502),c=o(2641),d=o(1588),p=o(34867);function u(e){return(0,p.Z)("MuiTableContainer",e)}(0,d.Z)("MuiTableContainer",["root"]);var v=o(85893);const m=["className","component"],g=(0,c.ZP)("div",{name:"MuiTableContainer",slot:"Root",overridesResolver:(e,t)=>t.root})({width:"100%",overflowX:"auto"});var Z=n.forwardRef((function(e,t){const o=(0,l.Z)({props:e,name:"MuiTableContainer"}),{className:n,component:c="div"}=o,d=(0,r.Z)(o,m),p=(0,a.Z)({},o,{component:c}),Z=(e=>{const{classes:t}=e;return(0,s.Z)({root:["root"]},u,t)})(p);return(0,v.jsx)(g,(0,a.Z)({ref:t,as:c,className:(0,i.Z)(Z.root,n),ownerState:p},d))}))},53184:function(e,t,o){o.d(t,{Z:function(){return y}});var a=o(87462),r=o(63366),n=o(67294),i=o(90512),s=o(94780),l=o(44063),c=o(54502),d=o(2641),p=o(1588),u=o(34867);function v(e){return(0,u.Z)("MuiTableHead",e)}(0,p.Z)("MuiTableHead",["root"]);var m=o(85893);const g=["className","component"],Z=(0,d.ZP)("thead",{name:"MuiTableHead",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"table-header-group"}),f={variant:"head"},h="thead";var y=n.forwardRef((function(e,t){const o=(0,c.Z)({props:e,name:"MuiTableHead"}),{className:n,component:d=h}=o,p=(0,r.Z)(o,g),u=(0,a.Z)({},o,{component:d}),y=(e=>{const{classes:t}=e;return(0,s.Z)({root:["root"]},v,t)})(u);return(0,m.jsx)(l.Z.Provider,{value:f,children:(0,m.jsx)(Z,(0,a.Z)({as:d,className:(0,i.Z)(y.root,n),ref:t,role:d===h?null:"rowgroup",ownerState:u},p))})}))},53816:function(e,t,o){o.d(t,{Z:function(){return b}});var a=o(87462),r=o(63366),n=o(67294),i=o(90512),s=o(94780),l=o(41796),c=o(44063),d=o(54502),p=o(2641),u=o(1588),v=o(34867);function m(e){return(0,v.Z)("MuiTableRow",e)}var g=(0,u.Z)("MuiTableRow",["root","selected","hover","head","footer"]),Z=o(85893);const f=["className","component","hover","selected"],h=(0,p.ZP)("tr",{name:"MuiTableRow",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:o}=e;return[t.root,o.head&&t.head,o.footer&&t.footer]}})((({theme:e})=>({color:"inherit",display:"table-row",verticalAlign:"middle",outline:0,[`&.${g.hover}:hover`]:{backgroundColor:(e.vars||e).palette.action.hover},[`&.${g.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:(0,l.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:(0,l.Fq)(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity)}}}))),y="tr";var b=n.forwardRef((function(e,t){const o=(0,d.Z)({props:e,name:"MuiTableRow"}),{className:l,component:p=y,hover:u=!1,selected:v=!1}=o,g=(0,r.Z)(o,f),b=n.useContext(c.Z),x=(0,a.Z)({},o,{component:p,hover:u,selected:v,head:b&&"head"===b.variant,footer:b&&"footer"===b.variant}),w=(e=>{const{classes:t,selected:o,hover:a,head:r,footer:n}=e,i={root:["root",o&&"selected",a&&"hover",r&&"head",n&&"footer"]};return(0,s.Z)(i,m,t)})(x);return(0,Z.jsx)(h,(0,a.Z)({as:p,ref:t,className:(0,i.Z)(w.root,l),role:p===y?null:"row",ownerState:x},g))}))}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/3935-eea593fa60dfd620.js b/dsql-app/.local_dist/static/chunks/3935-eea593fa60dfd620.js new file mode 100644 index 0000000..a638b97 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/3935-eea593fa60dfd620.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3935],{31356:function(e,t,a){var s=a(64836);t.Z=void 0;var i=s(a(64938)),r=a(85893),l=(0,i.default)([(0,r.jsx)("path",{d:"M5 5v14h14V5H5zm9 12H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z",opacity:".3"},"0"),(0,r.jsx)("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14zm-2-6H7v-2h10v2zm0-4H7V7h10v2zm-3 8H7v-2h7v2z"},"1")],"ArticleTwoTone");t.Z=l},47335:function(e,t,a){a.d(t,{Z:function(){return l}});var s=a(85893);a(67294);function i(e){var t=e.image,a=e.title,i=e.description,r=e.color,l=e.imageHeight,c="green"==r?"green":"gray"==r?"gray":"";return(0,s.jsxs)("div",{className:"color-card shadow-xl"+(r?" "+c:""),children:[(0,s.jsx)("h3",{className:"title m-0 text-2xl",children:a}),i&&(0,s.jsx)("span",{className:"text-slate-600 dark:text-slate-400 text-left",children:i}),(0,s.jsx)("div",{className:"image-block",style:l?{height:"".concat(l,"px")}:void 0,children:(0,s.jsx)("img",{src:t,alt:"".concat(a," Image")})})]})}function r(e){var t=e.image,a=e.title,i=e.description,r=e.color,l=e.height,c=e.h2,n=e.url,o=e.cta,d="green"==r?"green":"gray"==r?"gray":"purple"==r?"purple":"";return(0,s.jsxs)("div",{className:"contained-section shadow-xl"+(r?" "+d:""),style:l?{height:"".concat(l,"px")}:void 0,children:[(0,s.jsxs)("div",{className:"content text-left",children:[c?(0,s.jsx)("h2",{className:"m-0 text-white",children:a}):(0,s.jsx)("h3",{className:"m-0 text-white",children:a}),i&&(0,s.jsx)("span",{className:"text-slate-400",children:i}),n&&o&&(0,s.jsx)("a",{href:n,className:"button mt-4",children:o})]}),(0,s.jsx)("div",{className:"image-block",children:(0,s.jsx)("img",{src:t,alt:"".concat(a," Image")})}),(0,s.jsx)("img",{src:"/images/geometric-overlay.webp",className:"absolute z-0 left-0 top-0 w-full h-full opacity-80 mix-blend-overlay",alt:"Background Image"})]})}function l(e){return(0,s.jsx)("section",{className:"py-20",children:(0,s.jsxs)("div",{className:"main-container flex-col items-center text-center",children:[(0,s.jsx)("h2",{className:"m-0 lg:text-left",children:"All your data storage needs in one place"}),(0,s.jsx)("p",{className:"m-0 ",children:"Datasquirel solves the hassle of storing data across different platforms using a centralized, easy-to-use, SQL-based cloud database administration system. Now you can have all your data in one place and retrieve from any location or environment using HTTP REST API calls and SQL queries."}),(0,s.jsxs)("div",{className:"grid grid-cols-1 xl:grid-cols-2 w-full mt-10 gap-10",children:[(0,s.jsx)(i,{image:"/images/screenshots/databases-light.webp",title:"Data and Content",description:"Create databases, tables, dynamic datatypes including rich text, JSON and other editable code blocks",imageHeight:400}),(0,s.jsx)(i,{image:"/images/screenshots/media-list-white.webp",title:"Images, Videos, and other Media",description:"Static images automatically compressed with multiple format support, videos, pdf, excel documents, and more.",color:"green",imageHeight:400})]}),(0,s.jsx)("div",{className:"mt-10 w-full",children:(0,s.jsx)(r,{image:"/images/screenshots/tables-list-white.webp",title:"All the power of SQL without the hassle",description:"Indexes, Foreign keys, encryption, triggers, stored proceedures, etc. You get the best of both worlds: the full power of SQL, and the best UI yet to better manipulate your data.",cta:"Learn More",url:"/about",height:500})})]})})}},73987:function(e,t,a){a.d(t,{Z:function(){return r}});var s=a(85893),i=(a(67294),a(31356));function r(e){var t=e.user;return(0,s.jsxs)("section",{className:"py-24 border-0 border-t border-b border-slate-100 dark:border-slate-100/10 border-solid",children:[(0,s.jsx)("div",{className:"w-full max-w-6xl gap-10 justify-between flex-col relative z-10",children:(0,s.jsxs)("div",{className:"flex-col items-center max-w-2xl text-center ",style:{minWidth:"45%"},children:[(0,s.jsx)("h2",{className:"m-0 leading-tight",children:"Get started For Free."}),(0,s.jsx)("span",{className:"text-lg font-normal",children:"Get Started At no cost. Learn how to create and retrieve data by viewing our documentation."}),(0,s.jsxs)("div",{className:"flex items-start justify-center w-full mt-4",children:[!(null===t||void 0===t?void 0:t.logged_in_status)&&(0,s.jsx)("a",{href:"/create-account",className:"button",children:(0,s.jsx)("span",{className:"",children:"Sign Up For Free"})}),(0,s.jsxs)("a",{href:"/docs",className:"button outlined gray",children:[(0,s.jsx)(i.Z,{sx:{opacity:.8,fontSize:16}}),(0,s.jsx)("span",{children:"See The Docs"})]})]})]})}),(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-80 dark:opacity-10 z-0"})]})}},40662:function(e,t,a){a(85893),a(67294)},9922:function(e,t,a){a.d(t,{Z:function(){return i}});var s=a(86729);function i(e){var t=e.setUser,a=localStorage.getItem("user");if(a)try{return void t(JSON.parse(a))}catch(i){return void t({})}(0,s.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(e){var a=e.user?e.user:{};t(a),localStorage.setItem("user",JSON.stringify(a))})).catch((function(e){console.log(e)}))}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/4156-a7c42d729046e9bc.js b/dsql-app/.local_dist/static/chunks/4156-a7c42d729046e9bc.js new file mode 100644 index 0000000..f044bbe --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/4156-a7c42d729046e9bc.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4156],{96224:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"m16 7.58-5.5-2.4L5 7.58v3.6c0 3.5 2.33 6.74 5.5 7.74.25-.08.49-.2.73-.3-.15-.51-.23-1.06-.23-1.62 0-2.97 2.16-5.43 5-5.91V7.58z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M17 13c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 1.38c.62 0 1.12.51 1.12 1.12s-.51 1.12-1.12 1.12-1.12-.51-1.12-1.12.5-1.12 1.12-1.12zm0 5.37c-.93 0-1.74-.46-2.24-1.17.05-.72 1.51-1.08 2.24-1.08s2.19.36 2.24 1.08c-.5.71-1.31 1.17-2.24 1.17z",opacity:".3"},"1"),(0,l.jsx)("circle",{cx:"17",cy:"15.5",r:"1.12"},"2"),(0,l.jsx)("path",{d:"M18 11.09V6.27L10.5 3 3 6.27v4.91c0 4.54 3.2 8.79 7.5 9.82.55-.13 1.08-.32 1.6-.55C13.18 21.99 14.97 23 17 23c3.31 0 6-2.69 6-6 0-2.97-2.16-5.43-5-5.91zM11 17c0 .56.08 1.11.23 1.62-.24.11-.48.22-.73.3-3.17-1-5.5-4.24-5.5-7.74v-3.6l5.5-2.4 5.5 2.4v3.51c-2.84.48-5 2.94-5 5.91zm6 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"},"3"),(0,l.jsx)("path",{d:"M17 17.5c-.73 0-2.19.36-2.24 1.08.5.71 1.32 1.17 2.24 1.17s1.74-.46 2.24-1.17c-.05-.72-1.51-1.08-2.24-1.08z"},"4")],"AdminPanelSettingsTwoTone");t.Z=o},47381:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"M5 5v14h14V5H5zm9 12H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M7 15h7v2H7zm0-4h10v2H7zm0-4h10v2H7zm12-4h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-.14 0-.27.01-.4.04-.39.08-.74.28-1.01.55-.18.18-.33.4-.43.64S3 4.72 3 5v14c0 .27.06.54.16.78s.25.45.43.64c.27.27.62.47 1.01.55.13.02.26.03.4.03h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7-.25c.41 0 .75.34.75.75s-.34.75-.75.75-.75-.34-.75-.75.34-.75.75-.75zM19 19H5V5h14v14z"},"1")],"AssignmentTwoTone");t.Z=o},88518:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"M22 15c0-1.66-1.34-3-3-3h-1.5v-.5C17.5 8.46 15.04 6 12 6c-.77 0-1.49.17-2.16.46L20.79 17.4c.73-.55 1.21-1.41 1.21-2.4zM2 14c0 2.21 1.79 4 4 4h9.73l-8-8H6c-2.21 0-4 1.79-4 4z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.33 0-2.57.36-3.65.97l1.49 1.49C10.51 6.17 11.23 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 .99-.48 1.85-1.21 2.4l1.41 1.41c1.09-.92 1.8-2.27 1.8-3.81 0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.77 2.77h-.42C2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h11.73l2 2 1.41-1.41L4.41 3.86 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"},"1")],"CloudOffTwoTone");t.Z=o},52778:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)((0,l.jsx)("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM8 9h8v10H8V9zm7.5-5-1-1h-5l-1 1H5v2h14V4h-3.5z"}),"DeleteOutlineOutlined");t.Z=o},30212:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"M11.17 4H7v11h14V6h-7.83z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M21 4h-7l-2-2H7c-1.1 0-1.99.9-1.99 2L5 15c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 11H7V4h4.17l2 2H21v9z"},"1"),(0,l.jsx)("path",{d:"M3 6H1v13c0 1.1.9 2 2 2h17v-2H3V6z"},"2")],"FolderCopyTwoTone");t.Z=o},73340:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)((0,l.jsx)("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6h2c0-1.66 1.34-3 3-3s3 1.34 3 3v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 12H6V10h12v10zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2z"}),"LockOpenOutlined");t.Z=o},95808:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"M18 11c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.79-1.13-1.26-2.51-1.26-4 0-3.87 3.13-7 7-7zM8.9 6c0-1.71 1.39-3.1 3.1-3.1s3.1 1.39 3.1 3.1v2H8.9V6z"},"0"),(0,l.jsx)("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5zm0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32z"},"1")],"LockPersonRounded");t.Z=o},99152:function(e,t,a){var n=a(64836);t.Z=void 0;var i=n(a(64938)),l=a(85893),o=(0,i.default)([(0,l.jsx)("path",{d:"m13.17 6-.59-.59L11.17 4H6v12h16V6h-8.83zm4.33 4.5L21 15H7l4.5-6 3.5 4.51 2.5-3.01z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M2 6H0v5h.01L0 20c0 1.1.9 2 2 2h18v-2H2V6zm5 9h14l-3.5-4.5-2.5 3.01L11.5 9zM22 4h-8l-2-2H6c-1.1 0-1.99.9-1.99 2L4 16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 12H6V4h5.17l1.41 1.41.59.59H22v10z"},"1")],"PermMediaTwoTone");t.Z=o},57150:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},64998:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},33587:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},49525:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(e,t,a){a.d(t,{Z:function(){return n}});const n=(0,a(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},62588:function(e,t,a){a.d(t,{Z:function(){return s}});var n=a(85893),i=(a(67294),a(25472)),l=a(78107),o=a(45711);const r=(0,o.Z)("Files",[["path",{d:"M20 7h-3a2 2 0 0 1-2-2V2",key:"x099mo"}],["path",{d:"M9 18a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h7l4 4v10a2 2 0 0 1-2 2Z",key:"18t6ie"}],["path",{d:"M3 7.6v12.8A1.6 1.6 0 0 0 4.6 22h9.8",key:"1nja0z"}]]),c=(0,o.Z)("FileVideo2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v4",key:"1pf5j1"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["rect",{width:"8",height:"6",x:"2",y:"12",rx:"1",key:"1a6c1e"}],["path",{d:"m10 15.5 4 2.5v-6l-4 2.5",key:"t7cp39"}]]);function s(e){var t=e.user;return(0,n.jsx)(i.ZP,{title:"choose-media-type-popoup",noContainer:!0,wrapperClasses:"items-center",wrapperStyle:{alignItems:"center"},children:(0,n.jsxs)("div",{className:"paper items-center max-w-2xl m-auto z-50 p-4 xl:p-10",children:[(0,n.jsxs)("h4",{className:"m-0 text-center text-lg leading-tight",children:["What kind of Media do you",(0,n.jsx)("br",{}),"want to upload?"]}),(0,n.jsx)("span",{children:"Please Select the media type to upload."}),(0,n.jsxs)("div",{className:"w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch",children:[(0,n.jsxs)("div",{className:"card cursor-pointer",onClick:function(e){var a;if(null===t||void 0===t||null===(a=t.verification_status)||void 0===a?void 0:a.toString().match(/1/)){var n=document.getElementById("upload_image_input");null===n||void 0===n||n.click()}else alert("Please Verify to Add Media");setTimeout((function(){(0,i.j4)()}),500)},children:[(0,n.jsx)(l.Z,{size:50,className:"text-primary"}),(0,n.jsxs)("div",{className:"content",children:[(0,n.jsx)("span",{className:"title",children:"Images"}),(0,n.jsx)("span",{className:"text-sm",children:"General image formats like JPEG, PNG, SVG, WEBP, etc."})]})]}),(0,n.jsxs)("div",{className:"card cursor-pointer",onClick:function(e){var a,n;(null===t||void 0===t||null===(a=t.verification_status)||void 0===a?void 0:a.toString().match(/1/))?null===(n=document.getElementById("upload_file_input"))||void 0===n||n.click():alert("Please Verify to Add Media");(0,i.j4)()},children:[(0,n.jsx)(r,{size:50,className:"text-secondary"}),(0,n.jsxs)("div",{className:"content",children:[(0,n.jsx)("span",{className:"title",children:"Files"}),(0,n.jsx)("span",{className:"text-sm",children:"Other documents type. Like PDF, XLSX, CSV, etc."})]})]})]}),(0,n.jsx)("div",{className:"w-full grid grid-cols-1 lg:grid-cols-2 gap-6 items-stretch",children:(0,n.jsxs)("div",{className:"card cursor-pointer",onClick:function(e){var a,n;(null===t||void 0===t||null===(a=t.verification_status)||void 0===a?void 0:a.toString().match(/1/))?null===(n=document.getElementById("upload_video_input"))||void 0===n||n.click():alert("Please Verify to Add Media");(0,i.j4)()},children:[(0,n.jsx)(c,{size:55,className:"text-slate-600"}),(0,n.jsxs)("div",{className:"content",children:[(0,n.jsx)("span",{className:"title",children:"Videos"}),(0,n.jsxs)("span",{className:"text-sm",children:["Video Files. ",(0,n.jsx)("b",{children:"MP4"})," for now. These files can be streamed. Max 200mb"]})]})]})})]})})}},17244:function(e,t,a){a.d(t,{Z:function(){return M}});var n=a(85893),i=a(67294),l=a(828),o=a(86729),r=a(30212),c=a(52778),s=a(95264);function d(e){var t=e.folderName,a=e.folder,d=e.user,u="".concat(a?a+"/":"").concat(t),m=(0,l.Z)(i.useState(!1),2),h=m[0],f=m[1];return(0,n.jsxs)("a",{href:"/admin/".concat(null===d||void 0===d?void 0:d.id,"/media/").concat(u),className:"card col items-center justify-center",onClick:function(e){if(e.target.closest("button"))return e.preventDefault()},children:[h&&(0,n.jsx)(s.Z,{}),(0,n.jsx)(r.Z,{sx:{fontSize:100},className:"opacity-20"}),(0,n.jsx)("span",{className:"absolute top-4 left-4 text-xs bg-slate-200 dark:bg-slate-700 px-2 py-0.5 rounded-full",children:"Folder"}),(0,n.jsx)("span",{className:"",children:t}),(0,n.jsx)("button",{className:"plain-text absolute top-2 right-2",onClick:function(e){window.confirm("Delete this Folder and all its contents?")&&(f(!0),window.confirm("NOTE: this folder and all its contents will be permanently lost. Continue?")?(0,o.Z)("/api/deleteMediaFolder",{method:"post",body:{folder:u}},!0).then((function(e){e.success&&window.location.reload()})):f(!1))},children:(0,n.jsx)(c.Z,{className:"opacity-30"})})]},t)}var u=a(26042),m=a(69396),h=a(25472),f=a(45449),p=a(18826),v=a(47381);function x(e){var t,a,l=e.mediaObject,r=e.staticHost,c=l.media_thumbnail_path?(null===l||void 0===l?void 0:l.private)?l.media_thumbnail_url:"".concat(r).concat(l.media_thumbnail_path):l.media_thumbnail_url,s=l.media_path?(null===l||void 0===l?void 0:l.private)?l.media_url:"".concat(r).concat(l.media_path):l.media_url;return(0,n.jsx)(i.Fragment,{children:(null===(t=l.media_type)||void 0===t?void 0:t.match(/file/i))?(0,n.jsxs)("div",{className:"cursor-pointer hover:opacity-80",children:[(0,n.jsx)(v.Z,{sx:{fontSize:100},className:"opacity-10"}),(0,n.jsx)("span",{className:"info w-auto small gray absolute top-4 right-4",children:l.media_type.replace(/.*\//,"").toUpperCase()})]}):(null===(a=l.media_type)||void 0===a?void 0:a.match(/video/i))?(0,n.jsx)("video",{src:s,className:"w-full h-60 object-cover",controls:!0,muted:!0,autoPlay:!0,loop:!0}):(0,n.jsx)("img",{src:c,alt:l.media_name,className:"w-full h-60 object-cover bg-slate-200 rounded",onError:function(e){(null===l||void 0===l?void 0:l.private)||(0,o.Z)("/api/purgeDb",{method:"post",body:{paradigm:"user_media",payload:l}},!0).then((function(e){e.success?window.location.reload():(console.log(e),console.log(c),console.log(s))}))}})})}var g=a(34642);function y(e){var t,a=e.mediaObject,l=e.staticHost;a.media_thumbnail_path?"".concat(l,"/").concat(a.media_thumbnail_path):a.media_thumbnail_url,a.media_path?"".concat(l,"/").concat(a.media_path):a.media_url;return(null===a||void 0===a?void 0:a.private)?(0,n.jsx)(i.Fragment,{}):(0,n.jsxs)("div",{className:"dropdown-wrapper w-full xl:w-auto",children:[(0,n.jsx)("button",{className:"outlined secondary small-text w-full hidden xl:flex bg-secondary/10",children:"Copy Link"}),(0,n.jsx)("div",{className:"dropdown mobile-transform gap-2 w-full",children:(0,n.jsxs)(f.Z,{column:!0,className:"w-full mb-2 xl:mb-0",children:[(0,n.jsx)("button",{className:"gray outlined normal-weight more-padding",onClick:function(e){navigator.clipboard.writeText(a.media_url||"").then((function(){alert("Media url ".concat(a.media_url," Copied to clipboard"))}))},children:"Copy Full Link"}),!(null===a||void 0===a||null===(t=a.media_type)||void 0===t?void 0:t.match(/file|video/i))&&(0,n.jsx)("button",{className:"gray outlined normal-weight more-padding",onClick:function(e){navigator.clipboard.writeText(a.media_thumbnail_url||"").then((function(){alert("Media url ".concat(a.media_thumbnail_url," Copied to clipboard"))}))},children:"Copy Thumbnail Link"})]})})]})}var w=a(45711);const b=(0,w.Z)("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]),j=(0,w.Z)("LockOpen",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 9.9-1",key:"1mm8w8"}]]);function N(e){var t,a=e.mediaObject,r=e.setLoading,c=(0,l.Z)(i.useState(!1),2);c[0],c[1];return(null===a||void 0===a||null===(t=a.media_type)||void 0===t?void 0:t.match(/video/i))?null:(0,n.jsx)("button",{className:"light-gray p-2 w-8 h-8 rounded-full absolute top-4 left-4 bg-white"+((null===a||void 0===a?void 0:a.private)?" ":" text-slate-400 fill-slate-400"),style:{backgroundColor:"white"},onClick:function(e){var t=a.private?"This media is private: Make it public?":"Make this media Private?";window.confirm(t)&&(r(!0),(0,o.Z)("/api/media/addPrivateMedia",{method:"post",body:(0,u.Z)({},a)},!0).then((function(e){e.success?window.location.reload():window.alert("Action Failed!"),setTimeout((function(){r(!1)}),1e3)})).catch((function(e){console.log(e)})))},children:(null===a||void 0===a?void 0:a.private)?(0,n.jsx)(b,{size:20,color:"green"}):(0,n.jsx)(j,{color:"black",size:20})})}var Z=a(58436);function _(e){var t=e.mediaObject,a=e.setTargetMedia,o=(e.folder,e.staticHost),r=(0,l.Z)(i.useState(!!(null===t||void 0===t?void 0:t.private)),2),c=r[0],d=r[1],v=(0,l.Z)(i.useState(t),2),w=v[0],b=v[1];i.useEffect((function(){var e;(null===t||void 0===t?void 0:t.private)&&t.media_thumbnail_url&&!(null===(e=w.media_type)||void 0===e?void 0:e.match(/file/i))?(0,Z.Z)({url:t.media_thumbnail_url}).then((function(e){b((0,m.Z)((0,u.Z)({},t),{media_thumbnail_url:e})),d(!1)})).catch((function(e){console.log(e.message)})):c&&d(!1)}),[]);w.media_thumbnail_path?"".concat(o,"/").concat(w.media_thumbnail_path):w.media_thumbnail_url;var j=w.media_path?"".concat(o,"/").concat(w.media_path):w.media_url;return(0,n.jsxs)("div",{className:"media-card card col",onClick:function(e){var t,n;if(!e.target.closest("button")&&!e.target.closest(".button"))if(!(null===(t=w.media_type)||void 0===t?void 0:t.match(/file/i))||w.private)(null===(n=w.media_type)||void 0===n?void 0:n.match(/file/i))&&w.private||(a(w),(0,h.Mw)("target-media-popup"));else{var i=j;window.open(i,"__blank")}},onMouseEnter:function(e){e.target.closest(".media-card").style.zIndex="10"},onMouseLeave:function(e){e.target.closest(".media-card").style.zIndex="0"},style:(null===w||void 0===w?void 0:w.private)?{outline:"5px solid var(--sec-color-light)",borderColor:"var(--sec-color-lighter)"}:{},children:[c&&(0,n.jsx)(s.Z,{}),(0,n.jsx)(x,{mediaObject:w,staticHost:o}),(0,n.jsxs)("div",{className:"flex-col items-center xl:items-start flex-wrap w-full mt-auto",children:[(0,n.jsx)("span",{className:"w-full",style:{wordBreak:"break-all"},children:w.media_name}),(0,n.jsx)("div",{className:"flex-wrap w-full",children:(0,n.jsxs)(f.Z,{className:"flex-wrap w-full items-stretch",children:[(0,n.jsx)("button",{className:"secondary small-text relative w-full xl:w-auto mb-2 xl:mb-0",onClick:function(e){var t;(0,p.Z)({mediaObject:w,fileName:(null===(t=null===j||void 0===j?void 0:j.match(/[^\/]+$/))||void 0===t?void 0:t[0])||"",setLoading:d})},children:(0,n.jsx)("span",{children:"Download"})}),(0,n.jsx)(y,{mediaObject:w,staticHost:o}),(0,n.jsx)(g.Z,{mediaObject:w,setLoading:d})]})})]}),(0,n.jsx)(N,{mediaObject:w,setLoading:d})]})}var k=a(99152);function M(e){var t=e.media,a=e.setTargetMedia,l=e.folders,o=e.folder,r=e.staticHost,c=e.user;return(0,n.jsx)(i.Fragment,{children:(0,n.jsxs)("section",{className:"paper overflow-visible",children:[(0,n.jsx)("h2",{className:"text-xl m-0",children:"Media List"}),(0,n.jsxs)("div",{className:"w-full gap-4 grid grid-cols-1 md:grid-cols-2 xl:grid-cols-3 items-stretch",children:[l&&l[0]&&l.map((function(e){return(0,n.jsx)(d,{folder:o,folderName:e,user:c},e)})),t&&t[0]&&t.map((function(e){return(0,n.jsx)(_,{mediaObject:e,setTargetMedia:a,folder:o,staticHost:r},e.id)}))]}),!(null===t||void 0===t?void 0:t[0])&&(0,n.jsx)(z,{})]})})}function z(){return(0,n.jsxs)("div",{className:"button outlined gray dashed w-full p-10 flex-col",onClick:function(e){(0,h.Mw)("choose-media-type-popoup")},children:[(0,n.jsx)("span",{className:"text-slate-400",children:"No Media Added."}),(0,n.jsx)(k.Z,{color:"inherit",sx:{fontSize:80},className:"opacity-40 text-gray-500"}),(0,n.jsx)("span",{className:"",children:"Add Media"})]})}},81597:function(e,t,a){a.d(t,{Z:function(){return d}});var n,i=a(828),l=a(85893),o=a(67294),r=a(86729),c=a(25472),s=a(95264);function d(e){var t=e.folder,a=(0,i.Z)(o.useState(!1),2),d=a[0],u=a[1],m=(0,i.Z)(o.useState(!1),2),h=m[0],f=m[1];return(0,l.jsxs)(c.ZP,{title:"add-folder-popoup",children:[(0,l.jsx)("h4",{className:"m-0",children:"Add A New Folder"}),(0,l.jsxs)("div",{className:"flex-col w-full relative",children:[d&&(0,l.jsx)(s.Z,{}),(0,l.jsxs)("form",{onSubmit:function(e){e.preventDefault(),window.clearTimeout(n),u(!0);var a=e.target;(0,r.Z)("/api/addNewMediaFolder",{method:"post",body:{name:(t?"".concat(t,"/"):"")+a["new-folder-name"].value}},!0).then((function(e){e.success?window.location.reload():u(!1)}))},className:"w-full flex flex-col items-stretch gap-2",children:[h&&(0,l.jsx)("span",{className:"text-xs text-orange-700 bg-orange-100 flex items-center justify-center rounded px-2 py-1",children:"Folder Already Exists. Please Change the name."}),(0,l.jsx)("input",{type:"text",name:"new-folder-name",id:"new-folder-name",placeholder:"New Folder Name",className:"w-full"+(h?" warning":""),onChange:function(e){e.target.value=e.target.value.toLocaleLowerCase().replace(/ /g,"-"),window.clearTimeout(n),n=setTimeout((function(){(0,r.Z)("/api/checkExistingFolder?name=".concat(e.target.value).concat(t?"&folder="+t:"")).then((function(t){var a;(null===(a=e.target.value)||void 0===a?void 0:a.match(/./))&&(null===t||void 0===t?void 0:t.success)?(f(!0),alert("Folder Already Exists")):f(!1)}))}),500)}}),(0,l.jsx)("button",{children:"Add New Folder"})]})]})]})}},94891:function(e,t,a){a.d(t,{Z:function(){return x}});var n=a(828),i=a(85893),l=a(67294),o=a(86729),r=a(81069),c=a(25472),s=a(95264),d=a(29815),u=a(73340),m=a(95808);function h(e){var t=e.mediaObject,a=(0,n.Z)(l.useState(!1),2),o=a[0],r=a[1];return l.useEffect((function(){t.private=o}),[o]),(0,i.jsx)("button",{className:"light-gray p-2 w-8 h-8 rounded-full absolute top-2 left-2 bg-white"+(o?" ":" text-slate-400 fill-slate-400"),style:{backgroundColor:"white"},onClick:function(e){r((function(e){return!e}))},children:o?(0,i.jsx)(m.Z,{fontSize:"small",color:"secondary"}):(0,i.jsx)(u.Z,{fontSize:"small",className:"fill-inherit text-inherit"})})}function f(e){var t=e.imageObject,a=e.newMedia,n=e.setNewMedia,l=e.video,o=t,r=o.imageBase64Full||o.fileBase64Full,c=o.imageName||o.fileName;return(0,i.jsxs)("div",{className:"border border-slate-300 rounded max-h-44 flex-col w-full overflow-hidden h-full bg-slate-200 relative p-2",children:[l?(0,i.jsx)("video",{src:r,className:"w-full h-full object-contain",muted:!0,autoPlay:!0,controls:!0}):(0,i.jsx)("img",{src:r,alt:c,className:"w-full h-full object-contain"}),(0,i.jsx)("input",{type:"text",defaultValue:c,onInput:function(e){var a,n=null===(a=e.target.value)||void 0===a?void 0:a.replace(/ /g,"-");t.fileName&&(t.fileName=n),t.imageName&&(t.imageName=n)},className:"absolute bottom-1 text-sm left-2 px-2 py-1",style:{width:"calc(100% - 15px)"}}),(0,i.jsx)("button",{className:"outlined bg-white absolute top-2 right-2 p-1 w-8 h-8 rounded-full",style:{backgroundColor:"white",borderColor:"var(--slate-200)"},onClick:function(e){var i=a.findIndex((function(e){return e.imageBase64===t.imageBase64||e.fileBase64===t.fileBase64})),l=a;l.splice(i,1),n((0,d.Z)(l))},children:"\u2716"}),!l&&(0,i.jsx)(h,{mediaObject:t})]})}var p=a(47381);function v(e){var t=e.fileObject,a=e.newFile,n=e.setNewFile;return(0,i.jsxs)("div",{className:"border border-slate-300 rounded max-h-44 flex-col w-full overflow-hidden h-full bg-slate-200 relative p-2",children:[(0,i.jsx)(p.Z,{sx:{fontSize:100},className:"opacity-20"}),(0,i.jsx)("input",{type:"text",defaultValue:t.fileName,onInput:function(e){var a;t.fileName=null===(a=e.target.value)||void 0===a?void 0:a.replace(/ /g,"-")},className:"absolute bottom-1 text-sm left-2 px-2 py-1",style:{width:"calc(100% - 15px)"}}),(0,i.jsx)("button",{className:"outlined bg-white absolute top-2 right-2 p-1 w-8 h-8 rounded-full",style:{backgroundColor:"white",borderColor:"var(--slate-200)"},onClick:function(e){var i=a.findIndex((function(e){return e.fileBase64===t.fileBase64})),l=a;l.splice(i,1),n((0,d.Z)(l))},children:"\u2716"}),(0,i.jsx)(h,{mediaObject:t})]})}function x(e){var t=e.newMedia,a=e.setNewMedia,d=e.newFile,u=e.setNewFile,m=e.newVideo,h=e.setNewVideo,p=e.folder,x=(null===t||void 0===t?void 0:t[0])?"images":(null===d||void 0===d?void 0:d[0])?"files":"videos",g=(null===x||void 0===x?void 0:x.match(/image/i))?t:(null===x||void 0===x?void 0:x.match(/file/i))?d:m,y=(null===x||void 0===x?void 0:x.match(/image/i))?a:(null===x||void 0===x?void 0:x.match(/file/i))?u:h,w=(0,n.Z)(l.useState(!1),2),b=w[0],j=w[1];return l.useEffect((function(){g&&g[0]&&(0,c.Mw)("new-media-popup")}),[t,d,m]),(0,i.jsxs)(c.ZP,{title:"new-media-popup",closePopupDispatch:function(){a(null),u(null),h(null)},children:[b&&(0,i.jsx)(s.Z,{screen:!0}),(0,i.jsx)("h4",{className:"m-0",children:"Upload New Media"}),(0,i.jsx)("div",{className:"grid grid-cols-2 gap-4 w-full",children:g&&g[0]&&g.map((function(e,t){return(null===x||void 0===x?void 0:x.match(/image/i))?(0,i.jsx)(f,{imageObject:e,newMedia:g,setNewMedia:y},t+1):(null===x||void 0===x?void 0:x.match(/video/i))?(0,i.jsx)(f,{imageObject:e,newMedia:g,setNewMedia:y,video:!0},t+1):(0,i.jsx)(v,{fileObject:e,newFile:g,setNewFile:y},t+1)}))}),g&&g[0]&&(0,i.jsx)("button",{className:"py-3 w-full relative z-50"+(b?" pointer-events-none opacity-40":""),onClick:function(e){j(!0);var t=(null===x||void 0===x?void 0:x.match(/image/i))?{type:x,folder:p,media:g.map((function(e){return{imageBase64:e.imageBase64,imageName:e.imageName,imageSize:e.imageSize,private:e.private}}))}:{type:x,folder:p,media:g.map((function(e){return{fileBase64:e.fileBase64,fileName:e.fileName,fileSize:e.fileSize,fileType:e.fileType,private:e.private,video:Boolean(null===x||void 0===x?void 0:x.match(/video/i))}}))};(0,o.Z)("/api/addUserMedia",{method:"post",body:t},!0).then((function(e){e.success?(0,r.Z)().then((function(){window.location.reload()})):(alert("Image Upload Failed"),console.log(e),setTimeout((function(){j(!1)}),1e3))}))},children:"Upload Media"})]})}},1347:function(e,t,a){a.d(t,{Z:function(){return v}});var n=a(828),i=a(85893),l=a(67294),o=a(86729),r=a(81069),c=a(25472),s=a(95264),d=a(45449),u=a(18826),m=a(58436);const h=(0,a(45711).Z)("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);var f=a(64998),p=a(34642);function v(e){var t,a,v=e.targetMedia,x=e.staticHost,g=e.setTargetMedia,y=e.media,w=((null===v||void 0===v?void 0:v.media_thumbnail_path)?"".concat(x,"/").concat(null===v||void 0===v?void 0:v.media_thumbnail_path):null===v||void 0===v||v.media_thumbnail_url,(null===v||void 0===v?void 0:v.media_path)?"".concat(x,"/").concat(null===v||void 0===v?void 0:v.media_path):null===v||void 0===v?void 0:v.media_url),b=Boolean(null===v||void 0===v||null===(t=v.media_type)||void 0===t?void 0:t.match(/video/i)),j=v?y.findIndex((function(e){return e.id==v.id})):null,N="number"==typeof j&&j>=0,Z=function(){var e;if(!N)return null;var t=y[j+1];if(!t)return null;if(!(null===t||void 0===t||null===(e=t.media_type)||void 0===e?void 0:e.match(/image/i))){var a=y.slice(j+1).find((function(e){var t;return!!(null===(t=e.media_type)||void 0===t?void 0:t.match(/image/i))}));return a||null}return t}(),_=function(){var e;if(!N)return null;var t=y[j-1];if(!t)return null;if(!(null===t||void 0===t||null===(e=t.media_type)||void 0===e?void 0:e.match(/image/i))){var a=y.slice(0,j-1).findLast((function(e){var t;return!!(null===(t=e.media_type)||void 0===t?void 0:t.match(/image/i))}));return a||null}return t}(),k=(0,n.Z)(l.useState(!!(null===v||void 0===v?void 0:v.private)),2),M=k[0],z=k[1],C=(0,n.Z)(l.useState(!1),2),L=C[0],H=C[1],F=(0,n.Z)(l.useState(w),2),S=F[0],O=F[1],V=l.useRef();return l.useEffect((function(){(null===v||void 0===v?void 0:v.private)?(0,m.Z)({url:v.media_url||""}).then((function(e){e&&(O(e),z(!1))})).catch((function(e){console.log(e.message)})):O((null===v||void 0===v?void 0:v.media_url)||"")}),[v]),(0,i.jsxs)(c.ZP,{title:"target-media-popup",noContainer:!0,fullPage:!0,closePopupDispatch:function(){H(!1),g(null)},children:[M&&(0,i.jsx)(s.Z,{}),!L&&(0,i.jsx)(s.Z,{}),v&&(0,i.jsxs)(l.Fragment,{children:[(0,i.jsxs)("div",{className:"self-center h-screen py-4",children:[S?b?(0,i.jsx)("video",{src:S,className:"w-full h-full object-cover",controls:!0,muted:!0,autoPlay:!0,loop:!0,onCanPlay:function(){H(!0)},style:L?void 0:{display:"none"}}):(0,i.jsx)("img",{src:S,alt:v.media_name,className:"bg-slate-200 rounded w-full h-full object-contain",ref:V,onLoad:function(e){H(!0)},style:L?void 0:{display:"none"}}):(0,i.jsx)(i.Fragment,{}),_&&(0,i.jsx)("div",{className:"absolute left-5 md:left-10 z-[100] cursor-pointer p-5 bg-slate-800/40 rounded-full",onClick:function(e){g(null),g(_)},children:(0,i.jsx)(h,{color:"white"})}),Z&&(0,i.jsx)("div",{className:"absolute right-5 md:right-10 z-[100] cursor-pointer p-5 bg-slate-800/40 rounded-full",onClick:function(e){g(null),g(Z)},children:(0,i.jsx)(f.Z,{color:"white"})})]}),(0,i.jsx)("span",{className:"info gray absolute top-5 left-5 w-auto mr-5",style:{backgroundColor:"white"},children:null===(a=v.media_path)||void 0===a?void 0:a.replace(/.*\//,"")}),(0,i.jsx)("div",{className:"absolute bottom-6 left-6 p-2 bg-white dark:bg-slate-900 rounded z-20 hidden lg:flex flex-col items-stretch",children:(0,i.jsxs)(d.Z,{column:!0,children:[(0,i.jsx)(p._,{mediaObject:v,setLoading:z}),(0,i.jsx)("button",{className:"outlined secondary more-padding",onClick:function(e){var t,a;(0,u.Z)({mediaObject:v,fileName:(null===(a=null===(t=v.media_url)||void 0===t?void 0:t.match(/[^\/]+$/))||void 0===a?void 0:a[0])||"",setLoading:z})},children:"Download"}),(0,i.jsx)("button",{onClick:function(e){window.confirm("Delete this media?")&&(0,o.Z)("/api/deleteUserMedia",{method:"post",body:v},!0).then((function(e){e.success?(0,r.Z)().then((function(){window.location.reload()})):alert("Media deletion Failed! Please try again.")}))},className:"more-padding",children:"Delete"}),(0,i.jsx)("button",{className:"outlined gray w-full bg-white more-padding",onClick:function(e){navigator.clipboard.writeText(v.media_url||"").then((function(){alert("Media url ".concat(v.media_url," Copied to clipboard"))}))},children:"Copy Full Image Link"}),(0,i.jsx)("button",{className:"outlined gray w-full more-padding",onClick:function(e){navigator.clipboard.writeText(v.media_thumbnail_url||"").then((function(){alert("Media url ".concat(v.media_thumbnail_url," Copied to clipboard"))}))},style:{borderTop:"1px solid #0b8862"},children:"Copy Image Thumbnail Link"})]})})]})]})}},34642:function(e,t,a){a.d(t,{Z:function(){return r},_:function(){return c}});var n=a(85893),i=(a(67294),a(86729)),l=a(81069),o=a(45449);function r(e){var t=e.mediaObject,a=e.setLoading;return(0,n.jsxs)("div",{className:"dropdown-wrapper w-full xl:w-auto",children:[(0,n.jsx)("button",{className:"outlined gray small-text hidden xl:flex",children:"More"}),(0,n.jsx)("div",{className:"dropdown mobile-transform gap-2 w-full",children:(0,n.jsxs)(o.Z,{column:!0,className:"w-full mb-2 xl:mb-0",children:[(0,n.jsx)(c,{mediaObject:t,setLoading:a}),(0,n.jsx)("button",{className:"outlined gray normal-weight more-padding w-full xl:w-auto",onClick:function(e){window.confirm("Delete this media?")&&(0,i.Z)("/api/deleteUserMedia",{method:"post",body:t},!0).then((function(e){e.success?(0,l.Z)().then((function(){window.location.reload()})):alert("Media deletion Failed! Please try again.")}))},children:"Delete"})]})})]})}function c(e){var t=e.mediaObject,a=e.setLoading;return(0,n.jsx)("button",{onClick:function(e){var n=window.prompt("Rename media",t.media_name);n&&window.confirm('Rename "'.concat(t.media_name,'" to "').concat(n,'"'))&&(a(!0),(0,i.Z)("/api/renameMedia",{method:"post",body:{mediaObject:t,newName:n.replace(/ /g,"-"),newThumbnailName:n.replace(/ /g,"-")+"_thumbnail"}},!0).then((function(e){e.success?window.location.reload():(window.alert(e.msg),setTimeout((function(){a(!1)}),1e3))})))},className:"outlined gray normal-weight more-padding",children:"Rename"})}},25472:function(e,t,a){a.d(t,{Mw:function(){return r},ZP:function(){return o},j4:function(){return c}});var n=a(85893),i=a(41352),l=a(67294);function o(e){var t=e.children,a=e.title,o=e.data,r=e.fullPage,s=e.wrapperClasses,d=e.closePopupDispatch,u=e.wrapperStyle,m=e.noContainer;return r?(0,n.jsxs)("div",{className:"popup-bg overflow-hidden "+(s||""),"data-popupid":a||null,style:u,children:[m?(0,n.jsx)(l.Fragment,{children:t}):(0,n.jsx)("div",{className:"relative w-full h-full z-50","data-data":o?JSON.stringify(o):"",children:t}),(0,n.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(e){c(),d&&d()},children:(0,n.jsx)(i.Z,{color:"white",size:20})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){c(),d&&d()}})]}):(0,n.jsxs)("div",{className:"popup-bg","data-popupid":a||null,children:[m?(0,n.jsx)(l.Fragment,{children:t}):(0,n.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":o?JSON.stringify(o):"",children:[t,(0,n.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(e){c(),d&&d()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),m&&(0,n.jsx)("button",{className:"gray popup-cancel-button",onClick:function(e){c(),d&&d()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){c(),d&&d()}})]})}function r(e,t){var a=document.querySelector("[data-popupid='".concat(e,"']"));a&&(a.style.display="flex",t&&t(a))}function c(e){document.querySelectorAll("[data-popupid]").forEach((function(e){e.style.display="none"})),e&&e()}},98916:function(e,t,a){a.d(t,{Z:function(){return r}});var n=a(47568),i=a(97582),l=a(85893),o=(a(67294),a(53314));function r(e){var t=e.setNewFile,a=e.setLoading;return(0,l.jsx)("div",{children:(0,l.jsx)("input",{type:"file",name:"upload_file_input",id:"upload_file_input",className:"hidden",accept:".xlsx,.pdf,.csv,.json",multiple:!0,onChange:function(){var e=(0,n.Z)((function(e){var n,l,r,c,s,d,u;return(0,i.__generator)(this,(function(i){switch(i.label){case 0:if(a&&a(!0),n=[],!(null===(l=e.target.files)||void 0===l?void 0:l.length))return[3,6];r=0,i.label=1;case 1:return r",l.message),[2,{fileBase64:null,fileBase64Full:null,fileName:t.name,fileSize:null,fileType:null}];case 4:return[2]}}))}))).apply(this,arguments)}},29815:function(e,t,a){a.d(t,{Z:function(){return o}});var n=a(20943);var i=a(13375);var l=a(91566);function o(e){return function(e){if(Array.isArray(e))return(0,n.Z)(e)}(e)||(0,i.Z)(e)||(0,l.Z)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/4185-b4c9a571bd713be6.js b/dsql-app/.local_dist/static/chunks/4185-b4c9a571bd713be6.js new file mode 100644 index 0000000..aab98d5 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/4185-b4c9a571bd713be6.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4185],{30437:function(t,e,n){function o(t,e=[]){if(void 0===t)return{};const n={};return Object.keys(t).filter((n=>n.match(/^on[A-Z]/)&&"function"===typeof t[n]&&!e.includes(n))).forEach((e=>{n[e]=t[e]})),n}n.d(e,{_:function(){return o}})},78987:function(t,e,n){n.d(e,{y:function(){return c}});var o=n(87462),i=n(63366),r=n(33703);var a=n(90512),s=n(30437);function l(t){if(void 0===t)return{};const e={};return Object.keys(t).filter((e=>!(e.match(/^on[A-Z]/)&&"function"===typeof t[e]))).forEach((n=>{e[n]=t[n]})),e}const u=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function c(t){var e;const{elementType:n,externalSlotProps:c,ownerState:p,skipResolvingSlotProps:d=!1}=t,f=(0,i.Z)(t,u),v=d?{}:function(t,e,n){return"function"===typeof t?t(e,n):t}(c,p),{props:h,internalRef:m}=function(t){const{getSlotProps:e,additionalProps:n,externalSlotProps:i,externalForwardedProps:r,className:u}=t;if(!e){const t=(0,a.Z)(null==n?void 0:n.className,u,null==r?void 0:r.className,null==i?void 0:i.className),e=(0,o.Z)({},null==n?void 0:n.style,null==r?void 0:r.style,null==i?void 0:i.style),s=(0,o.Z)({},n,r,i);return t.length>0&&(s.className=t),Object.keys(e).length>0&&(s.style=e),{props:s,internalRef:void 0}}const c=(0,s._)((0,o.Z)({},r,i)),p=l(i),d=l(r),f=e(c),v=(0,a.Z)(null==f?void 0:f.className,null==n?void 0:n.className,u,null==r?void 0:r.className,null==i?void 0:i.className),h=(0,o.Z)({},null==f?void 0:f.style,null==n?void 0:n.style,null==r?void 0:r.style,null==i?void 0:i.style),m=(0,o.Z)({},f,n,d,p);return v.length>0&&(m.className=v),Object.keys(h).length>0&&(m.style=h),{props:m,internalRef:f.ref}}((0,o.Z)({},f,{externalSlotProps:v})),E=(0,r.Z)(m,null==v?void 0:v.ref,null==(e=t.additionalProps)?void 0:e.ref),x=function(t,e,n){return void 0===t||"string"===typeof t?e:(0,o.Z)({},e,{ownerState:(0,o.Z)({},e.ownerState,n)})}(n,(0,o.Z)({},h,{ref:E}),p);return x}},90629:function(t,e,n){n.d(e,{Z:function(){return x}});var o=n(63366),i=n(87462),r=n(67294),a=n(90512),s=n(94780),l=n(41796),u=n(2641);var c=t=>{let e;return e=t<1?5.11916*t**2:4.5*Math.log(t+1)+2,(e/100).toFixed(2)},p=n(54502),d=n(1588),f=n(34867);function v(t){return(0,f.Z)("MuiPaper",t)}(0,d.Z)("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);var h=n(85893);const m=["className","component","elevation","square","variant"],E=(0,u.ZP)("div",{name:"MuiPaper",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],!n.square&&e.rounded,"elevation"===n.variant&&e[`elevation${n.elevation}`]]}})((({theme:t,ownerState:e})=>{var n;return(0,i.Z)({backgroundColor:(t.vars||t).palette.background.paper,color:(t.vars||t).palette.text.primary,transition:t.transitions.create("box-shadow")},!e.square&&{borderRadius:t.shape.borderRadius},"outlined"===e.variant&&{border:`1px solid ${(t.vars||t).palette.divider}`},"elevation"===e.variant&&(0,i.Z)({boxShadow:(t.vars||t).shadows[e.elevation]},!t.vars&&"dark"===t.palette.mode&&{backgroundImage:`linear-gradient(${(0,l.Fq)("#fff",c(e.elevation))}, ${(0,l.Fq)("#fff",c(e.elevation))})`},t.vars&&{backgroundImage:null==(n=t.vars.overlays)?void 0:n[e.elevation]}))}));var x=r.forwardRef((function(t,e){const n=(0,p.Z)({props:t,name:"MuiPaper"}),{className:r,component:l="div",elevation:u=1,square:c=!1,variant:d="elevation"}=n,f=(0,o.Z)(n,m),x=(0,i.Z)({},n,{component:l,elevation:u,square:c,variant:d}),b=(t=>{const{square:e,elevation:n,variant:o,classes:i}=t,r={root:["root",o,!e&&"rounded","elevation"===o&&`elevation${n}`]};return(0,s.Z)(r,v,i)})(x);return(0,h.jsx)(E,(0,i.Z)({as:l,ownerState:x,className:(0,a.Z)(b.root,r),ref:e},f))}))},2734:function(t,e,n){n.d(e,{Z:function(){return a}});n(67294);var o=n(96682),i=n(90247),r=n(10606);function a(){const t=(0,o.Z)(i.Z);return t[r.Z]||t}},30577:function(t,e,n){n.d(e,{C:function(){return i},n:function(){return o}});const o=t=>t.scrollTop;function i(t,e){var n,o;const{timeout:i,easing:r,style:a={}}=t;return{duration:null!=(n=a.transitionDuration)?n:"number"===typeof i?i:i[e.mode]||0,easing:null!=(o=a.transitionTimingFunction)?o:"object"===typeof r?r[e.mode]:r,delay:a.transitionDelay}}},84527:function(t,e,n){n.d(e,{ZP:function(){return m}});var o=n(63366);function i(t,e){return i=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},i(t,e)}var r=n(67294),a=n(73935),s=!1,l=r.createContext(null),u="unmounted",c="exited",p="entering",d="entered",f="exiting",v=function(t){var e,n;function v(e,n){var o;o=t.call(this,e,n)||this;var i,r=n&&!n.isMounting?e.enter:e.appear;return o.appearStatus=null,e.in?r?(i=c,o.appearStatus=p):i=d:i=e.unmountOnExit||e.mountOnEnter?u:c,o.state={status:i},o.nextCallback=null,o}n=t,(e=v).prototype=Object.create(n.prototype),e.prototype.constructor=e,i(e,n),v.getDerivedStateFromProps=function(t,e){return t.in&&e.status===u?{status:c}:null};var h=v.prototype;return h.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},h.componentDidUpdate=function(t){var e=null;if(t!==this.props){var n=this.state.status;this.props.in?n!==p&&n!==d&&(e=p):n!==p&&n!==d||(e=f)}this.updateStatus(!1,e)},h.componentWillUnmount=function(){this.cancelNextCallback()},h.getTimeouts=function(){var t,e,n,o=this.props.timeout;return t=e=n=o,null!=o&&"number"!==typeof o&&(t=o.exit,e=o.enter,n=void 0!==o.appear?o.appear:e),{exit:t,enter:e,appear:n}},h.updateStatus=function(t,e){if(void 0===t&&(t=!1),null!==e)if(this.cancelNextCallback(),e===p){if(this.props.unmountOnExit||this.props.mountOnEnter){var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this);n&&function(t){t.scrollTop}(n)}this.performEnter(t)}else this.performExit();else this.props.unmountOnExit&&this.state.status===c&&this.setState({status:u})},h.performEnter=function(t){var e=this,n=this.props.enter,o=this.context?this.context.isMounting:t,i=this.props.nodeRef?[o]:[a.findDOMNode(this),o],r=i[0],l=i[1],u=this.getTimeouts(),c=o?u.appear:u.enter;!t&&!n||s?this.safeSetState({status:d},(function(){e.props.onEntered(r)})):(this.props.onEnter(r,l),this.safeSetState({status:p},(function(){e.props.onEntering(r,l),e.onTransitionEnd(c,(function(){e.safeSetState({status:d},(function(){e.props.onEntered(r,l)}))}))})))},h.performExit=function(){var t=this,e=this.props.exit,n=this.getTimeouts(),o=this.props.nodeRef?void 0:a.findDOMNode(this);e&&!s?(this.props.onExit(o),this.safeSetState({status:f},(function(){t.props.onExiting(o),t.onTransitionEnd(n.exit,(function(){t.safeSetState({status:c},(function(){t.props.onExited(o)}))}))}))):this.safeSetState({status:c},(function(){t.props.onExited(o)}))},h.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},h.safeSetState=function(t,e){e=this.setNextCallback(e),this.setState(t,e)},h.setNextCallback=function(t){var e=this,n=!0;return this.nextCallback=function(o){n&&(n=!1,e.nextCallback=null,t(o))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},h.onTransitionEnd=function(t,e){this.setNextCallback(e);var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this),o=null==t&&!this.props.addEndListener;if(n&&!o){if(this.props.addEndListener){var i=this.props.nodeRef?[this.nextCallback]:[n,this.nextCallback],r=i[0],s=i[1];this.props.addEndListener(r,s)}null!=t&&setTimeout(this.nextCallback,t)}else setTimeout(this.nextCallback,0)},h.render=function(){var t=this.state.status;if(t===u)return null;var e=this.props,n=e.children,i=(e.in,e.mountOnEnter,e.unmountOnExit,e.appear,e.enter,e.exit,e.timeout,e.addEndListener,e.onEnter,e.onEntering,e.onEntered,e.onExit,e.onExiting,e.onExited,e.nodeRef,(0,o.Z)(e,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return r.createElement(l.Provider,{value:null},"function"===typeof n?n(t,i):r.cloneElement(r.Children.only(n),i))},v}(r.Component);function h(){}v.contextType=l,v.propTypes={},v.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:h,onEntering:h,onEntered:h,onExit:h,onExiting:h,onExited:h},v.UNMOUNTED=u,v.EXITED=c,v.ENTERING=p,v.ENTERED=d,v.EXITING=f;var m=v}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/4893-e30c16360c86c67d.js b/dsql-app/.local_dist/static/chunks/4893-e30c16360c86c67d.js new file mode 100644 index 0000000..b2d0622 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/4893-e30c16360c86c67d.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4893],{34893:function(e,l,t){t.d(l,{Z:function(){return R}});var a=t(828),i=t(85893),d=t(67294),n=t(10990);function s(e){var l=e.tableFields,t=e.setTableFields,a=(e.setRefresh,e.setPageRefresh,e.refreshFieldsListRef),i=l,d=i.findIndex((function(e){return"date_created"===e.fieldName}));i.splice(d,0,{newTempField:!0}),t(i),(null===a||void 0===a?void 0:a.current)&&a.current((function(e){return e+1}))}var r=t(36169),o=t(95264),c=t(33907),u=t(29815),f=t(96486),v=t.n(f);function p(e){var l=e.tableFields,t=e.setTableFields,a=e.refreshFieldsListRef,i=e.order,d=e.field,n=e.e,s=v().cloneDeep(l),r=s.findIndex((function(e){return e.fieldName===d.fieldName}));if(!(r<0)){var o=s[r];if("up"===i&&r&&r<=1)console.log("Min Reached =>",r);else if("down"===i&&r&&r>=s.length-7)console.log("Max Reached =>",r);else{try{var c,f,p=n.target.closest(".table-field-wrapper"),m=p.previousElementSibling,x=p.nextElementSibling,h=window.DSQL.Flip,b=h.getState(p);if("up"===i)c=h.getState(m),null===(f=p.parentNode)||void 0===f||f.insertBefore(p,m);else if(null===x||void 0===x?void 0:x.nextElementSibling){var g;c=h.getState(x),null===(g=p.parentNode)||void 0===g||g.insertBefore(p,x.nextElementSibling)}h.from(b,{duration:.3,ease:"power1.inOut"}),h.from(c,{duration:.3,ease:"power1.inOut"})}catch(y){console.log("Error =>",y.message)}r?(s.splice(r,1),"up"===i?s.splice(r-1,0,o):s.splice(r+1,0,o),setTimeout((function(){t((0,u.Z)(s)),a.current&&a.current((function(e){return e+1}))}),500)):console.log("No target Field Index =>",r)}}}var m=t(99967),x=t(3699),h=t(86729);function b(e){var l,t,n,s,r,o,u,f,v,p,m,b=e.field,g=(e.setTargetField,e.fieldIndex,e.tableFields),y=e.setTableFields,w=(e.refreshFieldsListRef,e.database),j=e.currentTable,N=e.user,T=e.isDelegated,F=e.setLoading,_=(0,a.Z)(d.useState(b),2),D=_[0],C=_[1],Z=(0,a.Z)(d.useState(!1),2),k=Z[0],S=Z[1];return(0,i.jsxs)("div",{className:"flex-col w-full table-field-wrapper"+(k?" shadow-2xl shadow-slate-700/40 relative z-50":""),children:[(0,i.jsxs)("div",{className:"card no-hover items-center w-full py-4"+(k?" rounded-t":" rounded")+((null===(l=D.fieldName)||void 0===l?void 0:l.match(c.Z))?" text-slate-400 pointer-events-none border-slate-200 border":" light-gray"),children:[(0,i.jsx)("span",{className:"font-bold"+((null===(t=D.fieldName)||void 0===t?void 0:t.match(c.Z))?" dark:text-slate-500":" dark:text-white"),children:D.fieldName}),(0,i.jsx)("span",{className:"text-xs py-1 px-2 bg-slate-100 dark:bg-slate-700 dark:text-slate-200 rounded ",children:D.dataType}),(null===D||void 0===D?void 0:D.foreignKey)&&(0,i.jsxs)("div",{className:"text-xs bg-primary text-white px-2 py-0.5 rounded-full",children:[(0,i.jsx)("span",{children:"Foreign Key: "}),(0,i.jsxs)("span",{children:[D.foreignKey.destinationTableName," ("," ",(0,i.jsx)("b",{children:D.foreignKey.destinationTableColumnName})," ",")"]})]}),(null===(n=D.fieldName)||void 0===n?void 0:n.match(c.Z))&&(0,i.jsx)("span",{className:"text-slate-300 text-sm font-semibold ml-0 md:ml-auto",children:"Default Field"}),T||(null===(s=D.fieldName)||void 0===s?void 0:s.match(c.Z))||!(null===(r=D.dataType)||void 0===r?void 0:r.match(/INT/))||D.foreignKey||(null===(u=null===w||void 0===w||null===(o=w.active_clone)||void 0===o?void 0:o.toString())||void 0===u?void 0:u.match(/1/))?T||(null===(f=D.fieldName)||void 0===f?void 0:f.match(c.Z))||!(null===(v=D.dataType)||void 0===v?void 0:v.match(/INT/))||(null===(m=null===w||void 0===w||null===(p=w.active_clone)||void 0===p?void 0:p.toString())||void 0===m?void 0:m.match(/1/))?(0,i.jsx)(d.Fragment,{}):(0,i.jsx)("div",{className:"ml-0 md:ml-auto flex-wrap",children:(0,i.jsx)("div",{className:"button py-1 text-xs light-gray",onClick:function(e){var l,t;window.confirm("Delete this foreign Key?")&&(delete b.foreignKey,F(!0),(0,h.Z)("/api/updateClonedTableForeignKeys",{method:"post",body:{tableData:j,database:w.db_full_name,dbSlug:w.db_slug,delegated:!!(null===(l=window.location)||void 0===l||null===(t=l.search)||void 0===t?void 0:t.match(/delegated=true/i))}},!0).then((function(e){e.success?window.location.reload():window.alert("Update Failed, Please Try again.")})))},style:{color:"var(--slate-500)"},children:"Delete Foreign Key"})}):(0,i.jsx)("div",{className:"ml-0 md:ml-auto flex-wrap",children:(0,i.jsx)("div",{className:"button outlined py-1 text-xs gray",onClick:function(e){S(!k)},style:{color:"var(--slate-500)"},children:"Add Foreign Key"})})]}),k&&!T&&(0,i.jsx)("div",{className:"card col w-full -mt-5 pt-0 no-hover",children:(0,i.jsx)(x.Z,{targetField:b,setFieldData:C,tableFields:g,setTableFields:y,database:w,currentTable:j,user:N,setActiveEdit:S,activeClonedTable:!0})})]})}var g=t(26042),y=t(69396);var w=t(47568),j=t(97582),N=t(24209),T=t(64838);function F(e){var l=e.fieldIndex,a=e.setTableFields,n=e.database,s=e.user,r=e.isNewField,o=e.setLiteralValue,c=e.tempFieldData,u=e.setTempFieldData,f=e.dataTypeValue,v=e.setDataTypeValue,p=e.dataType,m=e.setDataType,x=e.dataTypeDesc,h=e.setDataTypeDesc,b=t(89594),g=d.useRef();d.useEffect((function(){var e;g.current&&(g.current.scrollIntoView({block:"center",behavior:"smooth"}),null===(e=g.current.querySelector("input"))||void 0===e||e.focus())}),[]);var y=Boolean(p.match(/uuid/i));return(0,i.jsxs)(d.Fragment,{children:[r&&(0,i.jsx)("span",{className:"absolute -top-4 text-sm bg-fuchsia-600 dark:bg-white text-white dark:text-fuchsia-800 px-3 py-1 rounded-full",children:"New Field"}),(0,i.jsxs)("div",{className:"gap-4 flex-wrap xl:flex-nowrap flex-col xl:flex-row items-stretch w-full xl:w-auto",children:[(0,i.jsxs)("div",{className:"flex flex-col items-start gap-0.5",children:[(0,i.jsx)("label",{htmlFor:"new_field_name",children:"Field Name"}),(0,i.jsx)("input",{type:"text",name:"new_field_name",id:"new_field_name",placeholder:"Eg. post_title",onInput:function(){var e=(0,w.Z)((function(e){var l,t;return(0,j.__generator)(this,(function(a){return l=e.target,t=l.value.toLowerCase().replace(/ /g,"_"),l.value=t,[2]}))}));return function(l){return e.apply(this,arguments)}}(),required:!0})]}),(0,i.jsxs)("div",{className:"flex flex-col items-start gap-4 xl:gap-0.5",children:[(0,i.jsxs)("div",{className:"items-start flex-wrap xl:flex-nowrap",children:[(0,i.jsx)("label",{htmlFor:"new_field_data_type",children:"Data Type"}),(0,i.jsxs)("div",{className:"dropdown-wrapper reversed text-sm w-full items-start gap-2",children:[(0,i.jsx)("span",{className:"px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex",children:"Info"}),(0,i.jsx)("div",{className:"dropdown mt-0 xl:-mt-2",children:(0,i.jsx)("span",{children:x})})]})]}),(0,i.jsxs)("div",{className:"w-full xl:w-auto",children:[(0,i.jsx)("select",{name:"new_field_data_type",id:"new_field_data_type",className:"w-full xl:w-auto",onChange:function(e){var l=e.target;m(l.value),l.childNodes.forEach((function(e){e.value===l.value&&h(e.dataset.desc),e.value===l.value&&e.dataset.literal&&o(e.dataset.literal)}))},children:b.map((function(e,l){return e.name.match(/VARCHAR/)?(0,i.jsx)("option",{value:e.name,"data-desc":e.description,children:e.title+"("+(f||200)+")"},l+1):(0,i.jsx)("option",{value:e.name,"data-desc":e.description,"data-literal":e.valueLiteral||void 0,children:e.title},l+1)}))}),p.match(/VARCHAR/)&&(0,i.jsx)("input",{type:"number",defaultValue:f,className:"px-2",style:{maxWidth:"60px"},max:255,min:5,onChange:function(e){v(e.target.value)}})]})]}),(null===p||void 0===p?void 0:p.match(/text/i))&&(0,i.jsx)(d.Fragment,{children:(0,i.jsx)(T.Z,{targetField:c})}),!y&&(0,i.jsxs)("div",{className:"flex flex-col items-start gap-0.5",style:{minWidth:"70px"},children:[(0,i.jsx)("label",{htmlFor:"new_field_required",children:"Required?"}),(0,i.jsxs)("select",{name:"new_field_required",id:"new_field_required",className:"px-2",children:[(0,i.jsx)("option",{value:"No",children:"No"}),(0,i.jsx)("option",{value:"Yes",children:"Yes"})]})]}),!y&&(0,i.jsxs)("div",{className:"flex flex-col items-start gap-0.5",children:[(0,i.jsx)("label",{htmlFor:"new_field_default_value",children:"Default Value (optional)"}),(0,i.jsx)("input",{type:"text",name:"new_field_default_value",id:"new_field_default_value",placeholder:"Default Value"})]}),!y&&(0,i.jsx)(N.Z,{database:n,setFieldData:u,targetField:c,user:s,fieldIndex:l})]}),(0,i.jsxs)("div",{className:"secondary mt-auto flex-wrap xl:flex-nowrap w-full xl:w-auto",children:[(0,i.jsx)("button",{type:"submit",className:"secondary mt-auto py-3 w-full sm:w-auto justify-center grow",children:"Add Field"}),(0,i.jsx)("div",{className:"button outlined-gray mt-auto py-2.5 w-full sm:w-auto justify-center grow",onClick:function(e){a((function(e){return e.filter((function(e,t){return t!=l}))}))},children:"Cancel"})]})]})}function _(e){var l=e.fieldIndex,n=e.tableFields,s=e.setTableFields,r=e.refreshFieldsListRef,o=e.database,c=e.currentTable,u=e.user,f=(t(89594),(0,a.Z)(d.useState("VARCHAR"),2)),v=f[0],p=f[1],m=(0,a.Z)(d.useState("200"),2),x=m[0],h=m[1],b=(0,a.Z)(d.useState("Varchar is simply letters and numbers within the range 0 - 255"),2),w=b[0],j=b[1],N=d.useState({}),T=(0,a.Z)(N,2),_=T[0],D=T[1],C=d.useRef(),Z=(0,a.Z)(d.useState(""),2),k=Z[0],S=Z[1];d.useEffect((function(){var e;C.current&&(C.current.scrollIntoView({block:"center",behavior:"smooth"}),null===(e=C.current.querySelector("input"))||void 0===e||e.focus())}),[]);var R=Boolean(v.match(/uuid/i));return(0,i.jsx)("div",{className:"w-full mt-1 flex-wrap relative z-0 hover:z-20",ref:C,children:(0,i.jsx)("form",{className:"flex flex-row items-start gap-4 w-full justify-between border border-solid p-4 pt-6 border-slate-400 rounded focus:shadow-lg shadow-slate-400/40 dark:shadow-black/30 relative flex-wrap xl:flex-nowrap shadow-xl",onSubmit:function(e){var t,a,i,d,n,o;e.preventDefault();var c=_.foreignKey;c&&!c.destinationTableName&&delete _.foreignKey;var u=e.target,f=u.new_field_name.value,v=u.new_field_data_type.value,p=null===(t=u.new_field_required)||void 0===t?void 0:t.value,m=null===(a=u.new_field_default_value)||void 0===a?void 0:a.value,h=null===(i=u.encryption_field)||void 0===i?void 0:i.value,b=null===(d=u.rich_text_option)||void 0===d?void 0:d.value,w=u.foreign_key_field,j=u.foreign_key_destination_table_name,N=u.foreign_key_destination_table_column_name,T=(null===w||void 0===w||w.value,(0,y.Z)((0,g.Z)({},_),{fieldName:f,dataType:(null===_||void 0===_?void 0:_.dataType)&&(null===_||void 0===_?void 0:_.foreignKey)?_.dataType:(null===v||void 0===v?void 0:v.match(/VARCHAR/))?"".concat(v,"(").concat(x,")"):v}));(null===p||void 0===p?void 0:p.match(/yes/i))?T.notNullValue=!0:(null===m||void 0===m?void 0:m.match(/./))||(T.nullValue=!0),(null===m||void 0===m?void 0:m.match(/./))&&(T.defaultValue=m),(null===h||void 0===h?void 0:h.match(/yes/i))&&(T.encrypted=!0),(null===N||void 0===N||null===(n=N.value)||void 0===n?void 0:n.match(/./i))&&!(null===N||void 0===N||null===(o=N.value)||void 0===o?void 0:o.match(/^--$/i))&&(T.dataType=N.dataset.dataType,T.foreignKey={foreignKeyName:N.dataset.foreignKeyName,destinationTableName:j.dataset.destinationTableName,destinationTableColumnName:N.dataset.destinationTableColumnName,cascadeDelete:!0}),(null===b||void 0===b?void 0:b.match(/yes/i))&&(T.richText=!0),R?(T.defaultValueLiteral=k,T.nullValue=!1):delete T.defaultValueLiteral,console.log("newFieldObject",T),function(e){var l=e.fieldIndex,t=e.setTableFields,a=e.refreshFieldsListRef,i=e.payload;t((function(e){var t=e;return t.splice(l,1,i),t})),(null===a||void 0===a?void 0:a.current)&&a.current((function(e){return e+1}))}({fieldIndex:l,setTableFields:s,refreshFieldsListRef:r,payload:T})},children:(0,i.jsx)(F,{database:o,fieldIndex:l,isNewField:!0,literalValue:k,refreshFieldsListRef:r,setLiteralValue:S,setTableFields:s,user:u,currentTable:c,tableFields:n,tempFieldData:_,setTempFieldData:D,dataTypeValue:x,setDataTypeValue:h,dataType:v,setDataType:p,dataTypeDesc:w,setDataTypeDesc:j})})})}var D=t(45449),C=t(8971);function Z(e){var l,t,n,s,r,o,u,f=e.field,v=(e.setTargetField,e.fieldIndex),x=e.tableFields,h=e.setTableFields,b=e.refreshFieldsListRef,g=e.database,y=e.currentTable,w=e.confirmedDelegetedUser,j=e.user,N=null===w||void 0===w?void 0:w.delegated,T=null===w||void 0===w||null===(l=w.priviledges)||void 0===l?void 0:l.match(/Edit Tables/i),F=(null===w||void 0===w||null===(t=w.priviledges)||void 0===t||t.match(/Delete Tables/i),null===w||void 0===w||null===(n=w.priviledges)||void 0===n||n.match(/Create Tables/i),g.active_clone,g.active_clone_parent_db),_=g.remote_connected,Z=(0,a.Z)(d.useState(f),2),k=Z[0],S=(Z[1],(0,a.Z)(d.useState(!1),2)),R=S[0],L=S[1];return(0,i.jsxs)("div",{className:"flex-col w-full table-field-wrapper"+(R?" shadow-2xl shadow-slate-300/40 dark:shadow-black/30 relative z-50":""),children:[(0,i.jsxs)("div",{className:"card no-hover items-center w-full py-4"+(R?" rounded-t":" rounded")+((null===(s=k.fieldName)||void 0===s?void 0:s.match(c.Z))?" text-slate-400 pointer-events-none border-slate-200 border":" light-gray"),children:[(0,i.jsx)("span",{className:"font-bold"+((null===(r=k.fieldName)||void 0===r?void 0:r.match(c.Z))?" dark:text-slate-500":" dark:text-white"),children:k.fieldName}),(0,i.jsx)("span",{className:"text-xs py-1 px-2 bg-slate-100 dark:bg-slate-700 dark:text-slate-200 rounded ",children:k.dataType}),(null===k||void 0===k?void 0:k.foreignKey)&&(0,i.jsxs)("div",{className:"text-xs bg-primary text-white px-2 py-0.5 rounded-full",children:[(0,i.jsx)("span",{children:"Foreign Key: "}),(0,i.jsxs)("span",{children:[k.foreignKey.destinationTableName," ("," ",(0,i.jsx)("b",{children:k.foreignKey.destinationTableColumnName})," ",")"]})]}),(null===(o=k.fieldName)||void 0===o?void 0:o.match(c.Z))&&(0,i.jsx)("span",{className:"text-slate-300 text-sm font-semibold ml-0 md:ml-auto",children:"Default Field"}),!(null===(u=k.fieldName)||void 0===u?void 0:u.match(c.Z))&&!F&&!_&&(0,i.jsx)("div",{className:"ml-0 md:ml-auto flex-wrap",children:(!N||N&&T)&&(0,i.jsxs)(d.Fragment,{children:[(0,i.jsxs)(D.Z,{children:[(0,i.jsx)("div",{className:"button outlined py-1 text-xs gray",onClick:function(e){L(!R)},style:{color:"var(--slate-500)"},children:"Edit"}),!F&&!_&&(0,i.jsx)("div",{className:"button outlined py-1 text-xs gray",onClick:function(e){window.confirm('Delete "'.concat(f.fieldName,'"?'))&&h((function(e){return e.filter((function(e,l){return l!=v}))}))},style:{color:"var(--slate-500)"},children:"Delete"})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:"button outlined gray p-2 w-8 h-8 rounded-full rotate-180",onClick:function(e){p({tableFields:x,setTableFields:h,refreshFieldsListRef:b,order:"up",field:f,e:e})},children:(0,i.jsx)(C.Z,{size:20})}),(0,i.jsx)("div",{className:"button outlined gray p-2 w-8 h-8 rounded-full",onClick:function(e){p({tableFields:x,setTableFields:h,refreshFieldsListRef:b,order:"down",field:f,e:e})},children:(0,i.jsx)(C.Z,{size:20})})]})]})})]}),R&&(0,i.jsx)("div",{className:"w-full",children:(0,i.jsx)(m.Z,{fieldIndex:v,tableFields:x,setTableFields:h,refreshFieldsListRef:b,targetField:f,setActiveEdit:L,database:g,currentTable:y,user:j})})]})}var k=t(95753),S=1;function R(e){var l,c,u,f,v=e.user,p=e.tableFields,m=e.setTableFields,x=e.setTargetField,h=e.refreshFieldsListRef,g=e.updateTable,y=e.updateTableAfterFieldsUpdateFunction,w=e.collapsed,j=e.database,N=e.table,T=e.confirmedDelegetedUser,F=e.query,D=((null===N||void 0===N?void 0:N.childTable)&&(null===(l=N.childTableDbFullName)||void 0===l||l.replace(new RegExp(/datasquirel_user_\d+_/),"")),null===T||void 0===T?void 0:T.delegated),C=null===T||void 0===T||null===(c=T.priviledges)||void 0===c?void 0:c.match(/Edit Tables/i),R=(null===T||void 0===T||null===(u=T.priviledges)||void 0===u||u.match(/Delete Tables/i),null===T||void 0===T||null===(f=T.priviledges)||void 0===f||f.match(/Create Tables/i),j.active_clone,j.active_clone_parent_db),L=j.remote_connected,V=(0,a.Z)(d.useState(0),2),I=(V[0],V[1]);h.current=I;var E=(0,a.Z)(d.useState(!1),2),K=E[0],A=E[1],q=(0,a.Z)(d.useState(w||!1),2),$=q[0],U=q[1];return d.useEffect((function(){var e=t(23226).B;n.ZP.registerPlugin(e);var l=window.DSQL;l&&(l.Flip=e)}),[]),D&&!C?(0,i.jsx)(i.Fragment,{}):(0,i.jsxs)("section",{className:"paper green",children:[K&&(0,i.jsx)(o.Z,{}),(null===N||void 0===N?void 0:N.childTable)?(0,i.jsxs)(d.Fragment,{children:[(0,i.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,i.jsx)("h2",{className:"text-xl m-0 text-left title",children:"Fields"}),(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:"button outlined light-gray",onClick:function(e){var l=(0,k.Z)({paradigm:"JavaScript",table:N,query:F,user:v});l&&navigator.clipboard.writeText(l).then((function(){window.alert("JavaScript Type Definition Copied")}))},children:(0,i.jsx)("span",{children:"Copy TypeDef (JS)"})}),(0,i.jsx)("div",{className:"button outlined light-gray",onClick:function(e){var l=(0,k.Z)({paradigm:"TypeScript",table:N,query:F,user:v});l&&navigator.clipboard.writeText(l).then((function(){window.alert("TypeScript Type Definition Copied")}))},children:(0,i.jsx)("span",{children:"Copy TypeDef (TS)"})})]})]}),(0,i.jsx)("div",{className:"flex-col w-full",style:$?{maxHeight:"200px"}:{},children:p&&p[0]&&p.map((function(e,l){return S++,(0,i.jsx)(b,{field:e,fieldIndex:l,setTargetField:x,setTableFields:m,refreshFieldsListRef:h,tableFields:p,database:j,setLoading:A,currentTable:N,user:v,isDelegated:D},S)}))}),w&&(0,i.jsx)(r.Z,{collapse:$||!1,setCollapse:U})]}):(0,i.jsxs)(d.Fragment,{children:[(0,i.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,i.jsx)("h2",{className:"text-xl m-0 text-left title",children:"Fields"}),(0,i.jsxs)("div",{children:[(!D||D&&C)&&!R&&!L&&(0,i.jsxs)("div",{className:"button secondary outlined",onClick:function(e){$&&U(!1),s({setTableFields:m,tableFields:p,setRefresh:I,refreshFieldsListRef:h})},children:[(0,i.jsx)("span",{className:"symbol",children:"+"}),(0,i.jsx)("span",{children:"Add New Field"})]}),(0,i.jsx)("div",{className:"button outlined light-gray",onClick:function(e){if(N){var l=(0,k.Z)({paradigm:"JavaScript",table:N,query:F,user:v});l&&navigator.clipboard.writeText(l).then((function(){window.alert("JavaScript Type Definition Copied")}))}},children:(0,i.jsx)("span",{children:"Copy TypeDef (JS)"})}),(0,i.jsx)("div",{className:"button outlined light-gray",onClick:function(e){if(N){var l=(0,k.Z)({paradigm:"TypeScript",table:N,query:F,user:v});l&&navigator.clipboard.writeText(l).then((function(){window.alert("TypeScript Type Definition Copied")}))}},children:(0,i.jsx)("span",{children:"Copy TypeDef (TS)"})})]})]}),(0,i.jsxs)("div",{className:"flex-col w-full",style:$?{maxHeight:"200px"}:{},children:[p&&p[0]&&p.map((function(e,l){return S++,e.newTempField?(0,i.jsx)(_,{fieldIndex:l,tableFields:p,setTableFields:m,refreshFieldsListRef:h,database:j,currentTable:N,user:v},S):(0,i.jsx)(Z,{field:e,fieldIndex:l,setTargetField:x,setTableFields:m,refreshFieldsListRef:h,tableFields:p,database:j,currentTable:N,confirmedDelegetedUser:T,user:v},S)})),(!D||D&&C)&&!R&&!L&&(0,i.jsxs)(d.Fragment,{children:[(0,i.jsxs)("div",{className:"button outlined gray w-full more-padding",style:{borderStyle:"dashed"},onClick:function(e){$&&U(!1),s({setTableFields:m,tableFields:p,setRefresh:I,refreshFieldsListRef:h})},children:[(0,i.jsx)("span",{className:"symbol",children:"+"}),(0,i.jsx)("span",{children:"Add New Field"})]}),g&&(0,i.jsx)("button",{className:"secondary w-full py-3",onClick:function(e){A(!0),y&&y(A)},children:"Update Table Fields"})]})]}),w&&(0,i.jsx)(r.Z,{collapse:$,setCollapse:U})]})]})}},95753:function(e,l,t){t.d(l,{Z:function(){return i}});var a=t(33907);function i(e){var l=e.paradigm,t=e.table,i=e.query,d=(e.user,"");try{var n=function(e){return(null===e||void 0===e?void 0:e.match(/int/i))?"number":(null===e||void 0===e||e.match(/text|varchar|timestamp/i),"string")},s="DSQL_".concat(i.single,"_").concat(i.single_table).toUpperCase(),r=t.fields,o=[],c=[];o.push("type ".concat(s," = {")),c.push("/**\n * @typedef {object} ".concat(s)),r.forEach((function(e){var l,t=e.nullValue||(null===(l=e.fieldName)||void 0===l?void 0:l.match(a.Z))?"?":"";o.push(" ".concat(e.fieldName).concat(t,": ").concat(n(e.dataType||""),";")),c.push(" * @property {".concat(n(e.dataType||"")).concat(t,"} ").concat(e.fieldName))})),o.push("}"),c.push(" */"),(null===l||void 0===l?void 0:l.match(/javascript/i))&&(d=c.join("\n")),(null===l||void 0===l?void 0:l.match(/typescript/i))&&(d=o.join("\n"))}catch(u){console.log(u.message),d=null}return d}},36169:function(e,l,t){t.d(l,{Z:function(){return i}});var a=t(85893);t(67294);function i(e){var l=e.collapse,t=e.setCollapse;return(0,a.jsxs)("div",{className:"collapse-block"+(l?" -mt-16 -mb-6 pt-10":" mt-0 mb-0 p-0"),onClick:function(e){t(!l)},children:[(0,a.jsx)("span",{children:l?"Expand":"Collapse"}),(0,a.jsx)("img",{src:"/images/down-arrow-dark.svg",alt:"Down Arrow",width:16,className:"dark:hidden opacity-30 "+(l?"":"rotate-180")}),(0,a.jsx)("img",{src:"/images/down-arrow-white.svg",alt:"Down Arrow",width:16,className:"opacity-30 hidden dark:flex "+(l?"":"rotate-180")})]})}},33907:function(e,l){l.Z=/^id$|^uuid$|^date_created$|^date_created_code$|^date_created_timestamp$|^date_updated$|^date_updated_code$|^date_updated_timestamp$/}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/493-ec86d71e0fece010.js b/dsql-app/.local_dist/static/chunks/493-ec86d71e0fece010.js new file mode 100644 index 0000000..c0b5bba --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/493-ec86d71e0fece010.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[493],{50027:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("path",{d:"m19.21 12.04-1.53-.11-.3-1.5C16.88 7.86 14.62 6 12 6 9.94 6 8.08 7.14 7.12 8.96l-.5.95-1.07.11C3.53 10.24 2 11.95 2 14c0 2.21 1.79 4 4 4h13c1.65 0 3-1.35 3-3 0-1.55-1.22-2.86-2.79-2.96zm-5.76.96v3h-2.91v-3H8l4-4 4 4h-2.55z",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95C8.08 7.14 9.94 6 12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11c1.56.1 2.78 1.41 2.78 2.96 0 1.65-1.35 3-3 3zM8 13h2.55v3h2.9v-3H16l-4-4z"},"1")],"BackupTwoTone");e.Z=o},64689:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("path",{d:"M18 19h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58z",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M12 3 6 7.58V6H4v3.11L1 11.4l1.21 1.59L4 11.62V21h16v-9.38l1.79 1.36L23 11.4 12 3zm6 16h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58V19zM10 1c0 1.66-1.34 3-3 3-.55 0-1 .45-1 1H4c0-1.66 1.34-3 3-3 .55 0 1-.45 1-1h2z"},"1")],"CottageTwoTone");e.Z=o},39269:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("path",{d:"M12 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm1 13h-2v-2h2v2zm0-4h-2V7h2v6z",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm-1-5h2v2h-2zm0-8h2v6h-2z"},"1")],"ErrorTwoTone");e.Z=o},28466:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("path",{d:"M6 10v10h5.29c-.19-.63-.29-1.3-.29-2 0-3.87 3.13-7 7-7v-1H6z",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M6 20V10h12v1c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.42-.6-.75-1.28-.97-2H6zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6z"},"1"),(0,s.jsx)("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5zm0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32z"},"2")],"LockPersonTwoTone");e.Z=o},38544:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("circle",{cx:"9",cy:"8",r:"2",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M9 15c-2.7 0-5.8 1.29-6 2.01V18h12v-1c-.2-.71-3.3-2-6-2z",opacity:".3"},"1"),(0,s.jsx)("path",{d:"M16.67 13.13C18.04 14.06 19 15.32 19 17v3h4v-3c0-2.18-3.57-3.47-6.33-3.87zM15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4c-.47 0-.91.1-1.33.24C14.5 5.27 15 6.58 15 8s-.5 2.73-1.33 3.76c.42.14.86.24 1.33.24zm-6 0c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0-6c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm0 7c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4zm6 5H3v-.99C3.2 16.29 6.3 15 9 15s5.8 1.29 6 2v1z"},"2")],"PeopleAltTwoTone");e.Z=o},51903:function(t,e,r){"use strict";var n=r(64836);e.Z=void 0;var i=n(r(64938)),s=r(85893),o=(0,i.default)([(0,s.jsx)("path",{d:"M4 18h16V8H4v10zm8-3h6v2h-6v-2zm-5.91-4.59L7.5 9l4 4-4 4-1.41-1.41L8.67 13l-2.58-2.59z",opacity:".3"},"0"),(0,s.jsx)("path",{d:"M12 15h6v2h-6z"},"1"),(0,s.jsx)("path",{d:"M20 4H4c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm0 14H4V8h16v10z"},"2"),(0,s.jsx)("path",{d:"m7.5 17 4-4-4-4-1.41 1.41L8.67 13l-2.58 2.59z"},"3")],"TerminalTwoTone");e.Z=o},21876:function(t){!function(){var e={675:function(t,e){"use strict";e.byteLength=function(t){var e=h(t),r=e[0],n=e[1];return 3*(r+n)/4-n},e.toByteArray=function(t){var e,r,s=h(t),o=s[0],a=s[1],c=new i(function(t,e,r){return 3*(e+r)/4-r}(0,o,a)),u=0,f=a>0?o-4:o;for(r=0;r>16&255,c[u++]=e>>8&255,c[u++]=255&e;2===a&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,c[u++]=255&e);1===a&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,c[u++]=e>>8&255,c[u++]=255&e);return c},e.fromByteArray=function(t){for(var e,n=t.length,i=n%3,s=[],o=16383,a=0,h=n-i;ah?h:a+o));1===i?(e=t[n-1],s.push(r[e>>2]+r[e<<4&63]+"==")):2===i&&(e=(t[n-2]<<8)+t[n-1],s.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"="));return s.join("")};for(var r=[],n=[],i="undefined"!==typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0,a=s.length;o0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function c(t){return r[t>>18&63]+r[t>>12&63]+r[t>>6&63]+r[63&t]}function u(t,e,r){for(var n,i=[],s=e;so)throw new RangeError('The value "'+t+'" is invalid for option "size"');var e=new Uint8Array(t);return Object.setPrototypeOf(e,h.prototype),e}function h(t,e,r){if("number"===typeof t){if("string"===typeof e)throw new TypeError('The "string" argument must be of type string. Received type number');return f(t)}return c(t,e,r)}function c(t,e,r){if("string"===typeof t)return function(t,e){"string"===typeof e&&""!==e||(e="utf8");if(!h.isEncoding(e))throw new TypeError("Unknown encoding: "+e);var r=0|y(t,e),n=a(r),i=n.write(t,e);i!==r&&(n=n.slice(0,i));return n}(t,e);if(ArrayBuffer.isView(t))return p(t);if(null==t)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(V(t,ArrayBuffer)||t&&V(t.buffer,ArrayBuffer))return l(t,e,r);if("undefined"!==typeof SharedArrayBuffer&&(V(t,SharedArrayBuffer)||t&&V(t.buffer,SharedArrayBuffer)))return l(t,e,r);if("number"===typeof t)throw new TypeError('The "value" argument must not be of type number. Received type number');var n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return h.from(n,e,r);var i=function(t){if(h.isBuffer(t)){var e=0|d(t.length),r=a(e);return 0===r.length||t.copy(r,0,0,e),r}if(void 0!==t.length)return"number"!==typeof t.length||F(t.length)?a(0):p(t);if("Buffer"===t.type&&Array.isArray(t.data))return p(t.data)}(t);if(i)return i;if("undefined"!==typeof Symbol&&null!=Symbol.toPrimitive&&"function"===typeof t[Symbol.toPrimitive])return h.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function u(t){if("number"!==typeof t)throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function f(t){return u(t),a(t<0?0:0|d(t))}function p(t){for(var e=t.length<0?0:0|d(t.length),r=a(e),n=0;n=o)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o.toString(16)+" bytes");return 0|t}function y(t,e){if(h.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||V(t,ArrayBuffer))return t.byteLength;if("string"!==typeof t)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);var r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;for(var i=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return q(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return z(t).length;default:if(i)return n?-1:q(t).length;e=(""+e).toLowerCase(),i=!0}}function g(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return S(this,e,r);case"utf8":case"utf-8":return C(this,e,r);case"ascii":return R(this,e,r);case"latin1":case"binary":return x(this,e,r);case"base64":return T(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return L(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function m(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function v(t,e,r,n,i){if(0===t.length)return-1;if("string"===typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),F(r=+r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0){if(!i)return-1;r=0}if("string"===typeof e&&(e=h.from(e,n)),h.isBuffer(e))return 0===e.length?-1:b(t,e,r,n,i);if("number"===typeof e)return e&=255,"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):b(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(t,e,r,n,i){var s,o=1,a=t.length,h=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;o=2,a/=2,h/=2,r/=2}function c(t,e){return 1===o?t[e]:t.readUInt16BE(e*o)}if(i){var u=-1;for(s=r;sa&&(r=a-h),s=r;s>=0;s--){for(var f=!0,p=0;pi&&(n=i):n=i;var s=e.length;n>s/2&&(n=s/2);for(var o=0;o>8,i=r%256,s.push(i),s.push(n);return s}(e,t.length-r),t,r,n)}function T(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function C(t,e,r){r=Math.min(t.length,r);for(var n=[],i=e;i239?4:c>223?3:c>191?2:1;if(i+f<=r)switch(f){case 1:c<128&&(u=c);break;case 2:128===(192&(s=t[i+1]))&&(h=(31&c)<<6|63&s)>127&&(u=h);break;case 3:s=t[i+1],o=t[i+2],128===(192&s)&&128===(192&o)&&(h=(15&c)<<12|(63&s)<<6|63&o)>2047&&(h<55296||h>57343)&&(u=h);break;case 4:s=t[i+1],o=t[i+2],a=t[i+3],128===(192&s)&&128===(192&o)&&128===(192&a)&&(h=(15&c)<<18|(63&s)<<12|(63&o)<<6|63&a)>65535&&h<1114112&&(u=h)}null===u?(u=65533,f=1):u>65535&&(u-=65536,n.push(u>>>10&1023|55296),u=56320|1023&u),n.push(u),i+=f}return O(n)}e.kMaxLength=o,h.TYPED_ARRAY_SUPPORT=function(){try{var t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}(),h.TYPED_ARRAY_SUPPORT||"undefined"===typeof console||"function"!==typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(h.prototype,"parent",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.buffer}}),Object.defineProperty(h.prototype,"offset",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.byteOffset}}),h.poolSize=8192,h.from=function(t,e,r){return c(t,e,r)},Object.setPrototypeOf(h.prototype,Uint8Array.prototype),Object.setPrototypeOf(h,Uint8Array),h.alloc=function(t,e,r){return function(t,e,r){return u(t),t<=0?a(t):void 0!==e?"string"===typeof r?a(t).fill(e,r):a(t).fill(e):a(t)}(t,e,r)},h.allocUnsafe=function(t){return f(t)},h.allocUnsafeSlow=function(t){return f(t)},h.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==h.prototype},h.compare=function(t,e){if(V(t,Uint8Array)&&(t=h.from(t,t.offset,t.byteLength)),V(e,Uint8Array)&&(e=h.from(e,e.offset,e.byteLength)),!h.isBuffer(t)||!h.isBuffer(e))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;for(var r=t.length,n=e.length,i=0,s=Math.min(r,n);ir&&(t+=" ... "),""},s&&(h.prototype[s]=h.prototype.inspect),h.prototype.compare=function(t,e,r,n,i){if(V(t,Uint8Array)&&(t=h.from(t,t.offset,t.byteLength)),!h.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),e<0||r>t.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&e>=r)return 0;if(n>=i)return-1;if(e>=r)return 1;if(this===t)return 0;for(var s=(i>>>=0)-(n>>>=0),o=(r>>>=0)-(e>>>=0),a=Math.min(s,o),c=this.slice(n,i),u=t.slice(e,r),f=0;f>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-e;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var s=!1;;)switch(n){case"hex":return w(this,t,e,r);case"utf8":case"utf-8":return E(this,t,e,r);case"ascii":return A(this,t,e,r);case"latin1":case"binary":return k(this,t,e,r);case"base64":return _(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B(this,t,e,r);default:if(s)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),s=!0}},h.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function O(t){var e=t.length;if(e<=4096)return String.fromCharCode.apply(String,t);for(var r="",n=0;nn)&&(r=n);for(var i="",s=e;sr)throw new RangeError("Trying to access beyond buffer length")}function U(t,e,r,n,i,s){if(!h.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||et.length)throw new RangeError("Index out of range")}function I(t,e,r,n,i,s){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function M(t,e,r,n,s){return e=+e,r>>>=0,s||I(t,0,r,4),i.write(t,e,r,n,23,4),r+4}function P(t,e,r,n,s){return e=+e,r>>>=0,s||I(t,0,r,8),i.write(t,e,r,n,52,8),r+8}h.prototype.slice=function(t,e){var r=this.length;(t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e>>=0,e>>>=0,r||N(t,e,this.length);for(var n=this[t],i=1,s=0;++s>>=0,e>>>=0,r||N(t,e,this.length);for(var n=this[t+--e],i=1;e>0&&(i*=256);)n+=this[t+--e]*i;return n},h.prototype.readUInt8=function(t,e){return t>>>=0,e||N(t,1,this.length),this[t]},h.prototype.readUInt16LE=function(t,e){return t>>>=0,e||N(t,2,this.length),this[t]|this[t+1]<<8},h.prototype.readUInt16BE=function(t,e){return t>>>=0,e||N(t,2,this.length),this[t]<<8|this[t+1]},h.prototype.readUInt32LE=function(t,e){return t>>>=0,e||N(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},h.prototype.readUInt32BE=function(t,e){return t>>>=0,e||N(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},h.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||N(t,e,this.length);for(var n=this[t],i=1,s=0;++s=(i*=128)&&(n-=Math.pow(2,8*e)),n},h.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||N(t,e,this.length);for(var n=e,i=1,s=this[t+--n];n>0&&(i*=256);)s+=this[t+--n]*i;return s>=(i*=128)&&(s-=Math.pow(2,8*e)),s},h.prototype.readInt8=function(t,e){return t>>>=0,e||N(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},h.prototype.readInt16LE=function(t,e){t>>>=0,e||N(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},h.prototype.readInt16BE=function(t,e){t>>>=0,e||N(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},h.prototype.readInt32LE=function(t,e){return t>>>=0,e||N(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},h.prototype.readInt32BE=function(t,e){return t>>>=0,e||N(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},h.prototype.readFloatLE=function(t,e){return t>>>=0,e||N(t,4,this.length),i.read(this,t,!0,23,4)},h.prototype.readFloatBE=function(t,e){return t>>>=0,e||N(t,4,this.length),i.read(this,t,!1,23,4)},h.prototype.readDoubleLE=function(t,e){return t>>>=0,e||N(t,8,this.length),i.read(this,t,!0,52,8)},h.prototype.readDoubleBE=function(t,e){return t>>>=0,e||N(t,8,this.length),i.read(this,t,!1,52,8)},h.prototype.writeUIntLE=function(t,e,r,n){(t=+t,e>>>=0,r>>>=0,n)||U(this,t,e,r,Math.pow(2,8*r)-1,0);var i=1,s=0;for(this[e]=255&t;++s>>=0,r>>>=0,n)||U(this,t,e,r,Math.pow(2,8*r)-1,0);var i=r-1,s=1;for(this[e+i]=255&t;--i>=0&&(s*=256);)this[e+i]=t/s&255;return e+r},h.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,1,255,0),this[e]=255&t,e+1},h.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},h.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},h.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},h.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},h.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var i=Math.pow(2,8*r-1);U(this,t,e,r,i-1,-i)}var s=0,o=1,a=0;for(this[e]=255&t;++s>0)-a&255;return e+r},h.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var i=Math.pow(2,8*r-1);U(this,t,e,r,i-1,-i)}var s=r-1,o=1,a=0;for(this[e+s]=255&t;--s>=0&&(o*=256);)t<0&&0===a&&0!==this[e+s+1]&&(a=1),this[e+s]=(t/o>>0)-a&255;return e+r},h.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},h.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},h.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},h.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},h.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||U(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},h.prototype.writeFloatLE=function(t,e,r){return M(this,t,e,!0,r)},h.prototype.writeFloatBE=function(t,e,r){return M(this,t,e,!1,r)},h.prototype.writeDoubleLE=function(t,e,r){return P(this,t,e,!0,r)},h.prototype.writeDoubleBE=function(t,e,r){return P(this,t,e,!1,r)},h.prototype.copy=function(t,e,r,n){if(!h.isBuffer(t))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e=0;--s)t[s+e]=this[s+r];else Uint8Array.prototype.set.call(t,this.subarray(r,n),e);return i},h.prototype.fill=function(t,e,r,n){if("string"===typeof t){if("string"===typeof e?(n=e,e=0,r=this.length):"string"===typeof r&&(n=r,r=this.length),void 0!==n&&"string"!==typeof n)throw new TypeError("encoding must be a string");if("string"===typeof n&&!h.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===t.length){var i=t.charCodeAt(0);("utf8"===n&&i<128||"latin1"===n)&&(t=i)}}else"number"===typeof t?t&=255:"boolean"===typeof t&&(t=Number(t));if(e<0||this.length>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"===typeof t)for(s=e;s55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&s.push(239,191,189);continue}if(o+1===n){(e-=3)>-1&&s.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&s.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(e-=3)>-1&&s.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;s.push(r)}else if(r<2048){if((e-=2)<0)break;s.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;s.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;s.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return s}function z(t){return n.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace(j,"")).length<2)return"";for(;t.length%4!==0;)t+="=";return t}(t))}function D(t,e,r,n){for(var i=0;i=e.length||i>=t.length);++i)e[i+r]=t[i];return i}function V(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}function F(t){return t!==t}var H=function(){for(var t="0123456789abcdef",e=new Array(256),r=0;r<16;++r)for(var n=16*r,i=0;i<16;++i)e[n+i]=t[r]+t[i];return e}()},783:function(t,e){e.read=function(t,e,r,n,i){var s,o,a=8*i-n-1,h=(1<>1,u=-7,f=r?i-1:0,p=r?-1:1,l=t[e+f];for(f+=p,s=l&(1<<-u)-1,l>>=-u,u+=a;u>0;s=256*s+t[e+f],f+=p,u-=8);for(o=s&(1<<-u)-1,s>>=-u,u+=n;u>0;o=256*o+t[e+f],f+=p,u-=8);if(0===s)s=1-c;else{if(s===h)return o?NaN:1/0*(l?-1:1);o+=Math.pow(2,n),s-=c}return(l?-1:1)*o*Math.pow(2,s-n)},e.write=function(t,e,r,n,i,s){var o,a,h,c=8*s-i-1,u=(1<>1,p=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,l=n?0:s-1,d=n?1:-1,y=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,o=u):(o=Math.floor(Math.log(e)/Math.LN2),e*(h=Math.pow(2,-o))<1&&(o--,h*=2),(e+=o+f>=1?p/h:p*Math.pow(2,1-f))*h>=2&&(o++,h/=2),o+f>=u?(a=0,o=u):o+f>=1?(a=(e*h-1)*Math.pow(2,i),o+=f):(a=e*Math.pow(2,f-1)*Math.pow(2,i),o=0));i>=8;t[r+l]=255&a,l+=d,a/=256,i-=8);for(o=o<0;t[r+l]=255&o,l+=d,o/=256,c-=8);t[r+l-d]|=128*y}}},r={};function n(t){var i=r[t];if(void 0!==i)return i.exports;var s=r[t]={exports:{}},o=!0;try{e[t](s,s.exports,n),o=!1}finally{o&&delete r[t]}return s.exports}n.ab="//";var i=n(72);t.exports=i}()},56500:function(){},12617:function(t){var e;self,e=()=>(()=>{"use strict";var t={};return(()=>{var e=t;Object.defineProperty(e,"__esModule",{value:!0}),e.FitAddon=void 0,e.FitAddon=class{activate(t){this._terminal=t}dispose(){}fit(){const t=this.proposeDimensions();if(!t||!this._terminal||isNaN(t.cols)||isNaN(t.rows))return;const e=this._terminal._core;this._terminal.rows===t.rows&&this._terminal.cols===t.cols||(e._renderService.clear(),this._terminal.resize(t.cols,t.rows))}proposeDimensions(){if(!this._terminal)return;if(!this._terminal.element||!this._terminal.element.parentElement)return;const t=this._terminal._core,e=t._renderService.dimensions;if(0===e.css.cell.width||0===e.css.cell.height)return;const r=0===this._terminal.options.scrollback?0:t.viewport.scrollBarWidth,n=window.getComputedStyle(this._terminal.element.parentElement),i=parseInt(n.getPropertyValue("height")),s=Math.max(0,parseInt(n.getPropertyValue("width"))),o=window.getComputedStyle(this._terminal.element),a=i-(parseInt(o.getPropertyValue("padding-top"))+parseInt(o.getPropertyValue("padding-bottom"))),h=s-(parseInt(o.getPropertyValue("padding-right"))+parseInt(o.getPropertyValue("padding-left")))-r;return{cols:Math.max(2,Math.floor(h/e.css.cell.width)),rows:Math.max(1,Math.floor(a/e.css.cell.height))}}}})(),t})(),t.exports=e()},48531:function(t,e,r){"use strict";function n(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.onlyFirst,r=void 0!==e&&e,n=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(n,r?void 0:"g")}r.d(e,{Z:function(){return n}})},53920:function(t,e,r){"use strict";r.d(e,{io:function(){return _t}});var n={};r.r(n),r.d(n,{Decoder:function(){return gt},Encoder:function(){return dt},PacketType:function(){return lt},protocol:function(){return pt}});const i=Object.create(null);i.open="0",i.close="1",i.ping="2",i.pong="3",i.message="4",i.upgrade="5",i.noop="6";const s=Object.create(null);Object.keys(i).forEach((t=>{s[i[t]]=t}));const o={type:"error",data:"parser error"},a="function"===typeof Blob||"undefined"!==typeof Blob&&"[object BlobConstructor]"===Object.prototype.toString.call(Blob),h="function"===typeof ArrayBuffer,c=t=>"function"===typeof ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer instanceof ArrayBuffer,u=({type:t,data:e},r,n)=>a&&e instanceof Blob?r?n(e):f(e,n):h&&(e instanceof ArrayBuffer||c(e))?r?n(e):f(new Blob([e]),n):n(i[t]+(e||"")),f=(t,e)=>{const r=new FileReader;return r.onload=function(){const t=r.result.split(",")[1];e("b"+(t||""))},r.readAsDataURL(t)};function p(t){return t instanceof Uint8Array?t:t instanceof ArrayBuffer?new Uint8Array(t):new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}let l;const d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y="undefined"===typeof Uint8Array?[]:new Uint8Array(256);for(let Tt=0;Tt{if("string"!==typeof t)return{type:"message",data:b(t,e)};const r=t.charAt(0);if("b"===r)return{type:"message",data:v(t.substring(1),e)};return s[r]?t.length>1?{type:s[r],data:t.substring(1)}:{type:s[r]}:o},v=(t,e)=>{if(g){const r=(t=>{let e,r,n,i,s,o=.75*t.length,a=t.length,h=0;"="===t[t.length-1]&&(o--,"="===t[t.length-2]&&o--);const c=new ArrayBuffer(o),u=new Uint8Array(c);for(e=0;e>4,u[h++]=(15&n)<<4|i>>2,u[h++]=(3&i)<<6|63&s;return c})(t);return b(r,e)}return{base64:!0,data:t}},b=(t,e)=>"blob"===e?t instanceof Blob?t:new Blob([t]):t instanceof ArrayBuffer?t:t.buffer,w=String.fromCharCode(30);function E(){return new TransformStream({transform(t,e){!function(t,e){a&&t.data instanceof Blob?t.data.arrayBuffer().then(p).then(e):h&&(t.data instanceof ArrayBuffer||c(t.data))?e(p(t.data)):u(t,!1,(t=>{l||(l=new TextEncoder),e(l.encode(t))}))}(t,(r=>{const n=r.length;let i;if(n<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,n);else if(n<65536){i=new Uint8Array(3);const t=new DataView(i.buffer);t.setUint8(0,126),t.setUint16(1,n)}else{i=new Uint8Array(9);const t=new DataView(i.buffer);t.setUint8(0,127),t.setBigUint64(1,BigInt(n))}t.data&&"string"!==typeof t.data&&(i[0]|=128),e.enqueue(i),e.enqueue(r)}))}})}let A;function k(t){return t.reduce(((t,e)=>t+e.length),0)}function _(t,e){if(t[0].length===e)return t.shift();const r=new Uint8Array(e);let n=0;for(let i=0;i(t.hasOwnProperty(r)&&(e[r]=t[r]),e)),{})}const O=T.setTimeout,R=T.clearTimeout;function x(t,e){e.useNativeTimers?(t.setTimeoutFn=O.bind(T),t.clearTimeoutFn=R.bind(T)):(t.setTimeoutFn=T.setTimeout.bind(T),t.clearTimeoutFn=T.clearTimeout.bind(T))}class S extends Error{constructor(t,e,r){super(t),this.description=e,this.context=r,this.type="TransportError"}}class L extends B{constructor(t){super(),this.writable=!1,x(this,t),this.opts=t,this.query=t.query,this.socket=t.socket}onError(t,e,r){return super.emitReserved("error",new S(t,e,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this}send(t){"open"===this.readyState&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const e=m(t,this.socket.binaryType);this.onPacket(e)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,e={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(e)}_hostname(){const t=this.opts.hostname;return-1===t.indexOf(":")?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(443!==this.opts.port)||!this.opts.secure&&80!==Number(this.opts.port))?":"+this.opts.port:""}_query(t){const e=function(t){let e="";for(let r in t)t.hasOwnProperty(r)&&(e.length&&(e+="&"),e+=encodeURIComponent(r)+"="+encodeURIComponent(t[r]));return e}(t);return e.length?"?"+e:""}}const N="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),U={};let I,M=0,P=0;function j(t){let e="";do{e=N[t%64]+e,t=Math.floor(t/64)}while(t>0);return e}function q(){const t=j(+new Date);return t!==I?(M=0,I=t):t+"."+j(M++)}for(;P<64;P++)U[N[P]]=P;let z=!1;try{z="undefined"!==typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(Bt){}const D=z;function V(t){const e=t.xdomain;try{if("undefined"!==typeof XMLHttpRequest&&(!e||D))return new XMLHttpRequest}catch(r){}if(!e)try{return new(T[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(r){}}function F(){}const H=null!=new V({xdomain:!1}).responseType;class Y extends B{constructor(t,e){super(),x(this,e),this.opts=e,this.method=e.method||"GET",this.uri=t,this.data=void 0!==e.data?e.data:null,this.create()}create(){var t;const e=C(this.opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");e.xdomain=!!this.opts.xd;const r=this.xhr=new V(e);try{r.open(this.method,this.uri,!0);try{if(this.opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let t in this.opts.extraHeaders)this.opts.extraHeaders.hasOwnProperty(t)&&r.setRequestHeader(t,this.opts.extraHeaders[t])}}catch(n){}if("POST"===this.method)try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(n){}try{r.setRequestHeader("Accept","*/*")}catch(n){}null===(t=this.opts.cookieJar)||void 0===t||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this.opts.withCredentials),this.opts.requestTimeout&&(r.timeout=this.opts.requestTimeout),r.onreadystatechange=()=>{var t;3===r.readyState&&(null===(t=this.opts.cookieJar)||void 0===t||t.parseCookies(r)),4===r.readyState&&(200===r.status||1223===r.status?this.onLoad():this.setTimeoutFn((()=>{this.onError("number"===typeof r.status?r.status:0)}),0))},r.send(this.data)}catch(n){return void this.setTimeoutFn((()=>{this.onError(n)}),0)}"undefined"!==typeof document&&(this.index=Y.requestsCount++,Y.requests[this.index]=this)}onError(t){this.emitReserved("error",t,this.xhr),this.cleanup(!0)}cleanup(t){if("undefined"!==typeof this.xhr&&null!==this.xhr){if(this.xhr.onreadystatechange=F,t)try{this.xhr.abort()}catch(e){}"undefined"!==typeof document&&delete Y.requests[this.index],this.xhr=null}}onLoad(){const t=this.xhr.responseText;null!==t&&(this.emitReserved("data",t),this.emitReserved("success"),this.cleanup())}abort(){this.cleanup()}}if(Y.requestsCount=0,Y.requests={},"undefined"!==typeof document)if("function"===typeof attachEvent)attachEvent("onunload",W);else if("function"===typeof addEventListener){addEventListener("onpagehide"in T?"pagehide":"unload",W,!1)}function W(){for(let t in Y.requests)Y.requests.hasOwnProperty(t)&&Y.requests[t].abort()}const Z="function"===typeof Promise&&"function"===typeof Promise.resolve?t=>Promise.resolve().then(t):(t,e)=>e(t,0),K=T.WebSocket||T.MozWebSocket;r(21876).Buffer;const J="undefined"!==typeof navigator&&"string"===typeof navigator.product&&"reactnative"===navigator.product.toLowerCase();const X={websocket:class extends L{constructor(t){super(t),this.supportsBinary=!t.forceBase64}get name(){return"websocket"}doOpen(){if(!this.check())return;const t=this.uri(),e=this.opts.protocols,r=J?{}:C(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=J?new K(t,e,r):e?new K(t,e):new K(t)}catch(Bt){return this.emitReserved("error",Bt)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let e=0;e{try{this.ws.send(t)}catch(e){}n&&Z((()=>{this.writable=!0,this.emitReserved("drain")}),this.setTimeoutFn)}))}}doClose(){"undefined"!==typeof this.ws&&(this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",e=this.query||{};return this.opts.timestampRequests&&(e[this.opts.timestampParam]=q()),this.supportsBinary||(e.b64=1),this.createUri(t,e)}check(){return!!K}},webtransport:class extends L{get name(){return"webtransport"}doOpen(){"function"===typeof WebTransport&&(this.transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name]),this.transport.closed.then((()=>{this.onClose()})).catch((t=>{this.onError("webtransport error",t)})),this.transport.ready.then((()=>{this.transport.createBidirectionalStream().then((t=>{const e=function(t,e){A||(A=new TextDecoder);const r=[];let n=0,i=-1,s=!1;return new TransformStream({transform(a,h){for(r.push(a);;){if(0===n){if(k(r)<1)break;const t=_(r,1);s=128===(128&t[0]),i=127&t[0],n=i<126?3:126===i?1:2}else if(1===n){if(k(r)<2)break;const t=_(r,2);i=new DataView(t.buffer,t.byteOffset,t.length).getUint16(0),n=3}else if(2===n){if(k(r)<8)break;const t=_(r,8),e=new DataView(t.buffer,t.byteOffset,t.length),s=e.getUint32(0);if(s>Math.pow(2,21)-1){h.enqueue(o);break}i=s*Math.pow(2,32)+e.getUint32(4),n=3}else{if(k(r)t){h.enqueue(o);break}}}})}(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(e).getReader(),n=E();n.readable.pipeTo(t.writable),this.writer=n.writable.getWriter();const i=()=>{r.read().then((({done:t,value:e})=>{t||(this.onPacket(e),i())})).catch((t=>{}))};i();const s={type:"open"};this.query.sid&&(s.data=`{"sid":"${this.query.sid}"}`),this.writer.write(s).then((()=>this.onOpen()))}))})))}write(t){this.writable=!1;for(let e=0;e{n&&Z((()=>{this.writable=!0,this.emitReserved("drain")}),this.setTimeoutFn)}))}}doClose(){var t;null===(t=this.transport)||void 0===t||t.close()}},polling:class extends L{constructor(t){if(super(t),this.polling=!1,"undefined"!==typeof location){const e="https:"===location.protocol;let r=location.port;r||(r=e?"443":"80"),this.xd="undefined"!==typeof location&&t.hostname!==location.hostname||r!==t.port}const e=t&&t.forceBase64;this.supportsBinary=H&&!e,this.opts.withCredentials&&(this.cookieJar=void 0)}get name(){return"polling"}doOpen(){this.poll()}pause(t){this.readyState="pausing";const e=()=>{this.readyState="paused",t()};if(this.polling||!this.writable){let t=0;this.polling&&(t++,this.once("pollComplete",(function(){--t||e()}))),this.writable||(t++,this.once("drain",(function(){--t||e()})))}else e()}poll(){this.polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){((t,e)=>{const r=t.split(w),n=[];for(let i=0;i{if("opening"===this.readyState&&"open"===t.type&&this.onOpen(),"close"===t.type)return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(t)})),"closed"!==this.readyState&&(this.polling=!1,this.emitReserved("pollComplete"),"open"===this.readyState&&this.poll())}doClose(){const t=()=>{this.write([{type:"close"}])};"open"===this.readyState?t():this.once("open",t)}write(t){this.writable=!1,((t,e)=>{const r=t.length,n=new Array(r);let i=0;t.forEach(((t,s)=>{u(t,!1,(t=>{n[s]=t,++i===r&&e(n.join(w))}))}))})(t,(t=>{this.doWrite(t,(()=>{this.writable=!0,this.emitReserved("drain")}))}))}uri(){const t=this.opts.secure?"https":"http",e=this.query||{};return!1!==this.opts.timestampRequests&&(e[this.opts.timestampParam]=q()),this.supportsBinary||e.sid||(e.b64=1),this.createUri(t,e)}request(t={}){return Object.assign(t,{xd:this.xd,cookieJar:this.cookieJar},this.opts),new Y(this.uri(),t)}doWrite(t,e){const r=this.request({method:"POST",data:t});r.on("success",e),r.on("error",((t,e)=>{this.onError("xhr post error",t,e)}))}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",((t,e)=>{this.onError("xhr poll error",t,e)})),this.pollXhr=t}}},$=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Q=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function G(t){if(t.length>2e3)throw"URI too long";const e=t,r=t.indexOf("["),n=t.indexOf("]");-1!=r&&-1!=n&&(t=t.substring(0,r)+t.substring(r,n).replace(/:/g,";")+t.substring(n,t.length));let i=$.exec(t||""),s={},o=14;for(;o--;)s[Q[o]]=i[o]||"";return-1!=r&&-1!=n&&(s.source=e,s.host=s.host.substring(1,s.host.length-1).replace(/;/g,":"),s.authority=s.authority.replace("[","").replace("]","").replace(/;/g,":"),s.ipv6uri=!0),s.pathNames=function(t,e){const r=/\/{2,9}/g,n=e.replace(r,"/").split("/");"/"!=e.slice(0,1)&&0!==e.length||n.splice(0,1);"/"==e.slice(-1)&&n.splice(n.length-1,1);return n}(0,s.path),s.queryKey=function(t,e){const r={};return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,(function(t,e,n){e&&(r[e]=n)})),r}(0,s.query),s}class tt extends B{constructor(t,e={}){super(),this.binaryType="arraybuffer",this.writeBuffer=[],t&&"object"===typeof t&&(e=t,t=null),t?(t=G(t),e.hostname=t.host,e.secure="https"===t.protocol||"wss"===t.protocol,e.port=t.port,t.query&&(e.query=t.query)):e.host&&(e.hostname=G(e.host).host),x(this,e),this.secure=null!=e.secure?e.secure:"undefined"!==typeof location&&"https:"===location.protocol,e.hostname&&!e.port&&(e.port=this.secure?"443":"80"),this.hostname=e.hostname||("undefined"!==typeof location?location.hostname:"localhost"),this.port=e.port||("undefined"!==typeof location&&location.port?location.port:this.secure?"443":"80"),this.transports=e.transports||["polling","websocket","webtransport"],this.writeBuffer=[],this.prevBufferLen=0,this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},e),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),"string"===typeof this.opts.query&&(this.opts.query=function(t){let e={},r=t.split("&");for(let n=0,i=r.length;n{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this.beforeunloadEventListener,!1)),"localhost"!==this.hostname&&(this.offlineEventListener=()=>{this.onClose("transport close",{description:"network connection lost"})},addEventListener("offline",this.offlineEventListener,!1))),this.open()}createTransport(t){const e=Object.assign({},this.opts.query);e.EIO=4,e.transport=t,this.id&&(e.sid=this.id);const r=Object.assign({},this.opts,{query:e,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new X[t](r)}open(){let t;if(this.opts.rememberUpgrade&&tt.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))t="websocket";else{if(0===this.transports.length)return void this.setTimeoutFn((()=>{this.emitReserved("error","No transports available")}),0);t=this.transports[0]}this.readyState="opening";try{t=this.createTransport(t)}catch(e){return this.transports.shift(),void this.open()}t.open(),this.setTransport(t)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this.onDrain.bind(this)).on("packet",this.onPacket.bind(this)).on("error",this.onError.bind(this)).on("close",(t=>this.onClose("transport close",t)))}probe(t){let e=this.createTransport(t),r=!1;tt.priorWebsocketSuccess=!1;const n=()=>{r||(e.send([{type:"ping",data:"probe"}]),e.once("packet",(t=>{if(!r)if("pong"===t.type&&"probe"===t.data){if(this.upgrading=!0,this.emitReserved("upgrading",e),!e)return;tt.priorWebsocketSuccess="websocket"===e.name,this.transport.pause((()=>{r||"closed"!==this.readyState&&(c(),this.setTransport(e),e.send([{type:"upgrade"}]),this.emitReserved("upgrade",e),e=null,this.upgrading=!1,this.flush())}))}else{const t=new Error("probe error");t.transport=e.name,this.emitReserved("upgradeError",t)}})))};function i(){r||(r=!0,c(),e.close(),e=null)}const s=t=>{const r=new Error("probe error: "+t);r.transport=e.name,i(),this.emitReserved("upgradeError",r)};function o(){s("transport closed")}function a(){s("socket closed")}function h(t){e&&t.name!==e.name&&i()}const c=()=>{e.removeListener("open",n),e.removeListener("error",s),e.removeListener("close",o),this.off("close",a),this.off("upgrading",h)};e.once("open",n),e.once("error",s),e.once("close",o),this.once("close",a),this.once("upgrading",h),-1!==this.upgrades.indexOf("webtransport")&&"webtransport"!==t?this.setTimeoutFn((()=>{r||e.open()}),200):e.open()}onOpen(){if(this.readyState="open",tt.priorWebsocketSuccess="websocket"===this.transport.name,this.emitReserved("open"),this.flush(),"open"===this.readyState&&this.opts.upgrade){let t=0;const e=this.upgrades.length;for(;t{this.onClose("ping timeout")}),this.pingInterval+this.pingTimeout),this.opts.autoUnref&&this.pingTimeoutTimer.unref()}onDrain(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emitReserved("drain"):this.flush()}flush(){if("closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this.getWritablePackets();this.transport.send(t),this.prevBufferLen=t.length,this.emitReserved("flush")}}getWritablePackets(){if(!(this.maxPayload&&"polling"===this.transport.name&&this.writeBuffer.length>1))return this.writeBuffer;let t=1;for(let r=0;r=57344?r+=3:(n++,r+=4);return r}(e):Math.ceil(1.33*(e.byteLength||e.size))),r>0&&t>this.maxPayload)return this.writeBuffer.slice(0,r);t+=2}var e;return this.writeBuffer}write(t,e,r){return this.sendPacket("message",t,e,r),this}send(t,e,r){return this.sendPacket("message",t,e,r),this}sendPacket(t,e,r,n){if("function"===typeof e&&(n=e,e=void 0),"function"===typeof r&&(n=r,r=null),"closing"===this.readyState||"closed"===this.readyState)return;(r=r||{}).compress=!1!==r.compress;const i={type:t,data:e,options:r};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),n&&this.once("flush",n),this.flush()}close(){const t=()=>{this.onClose("forced close"),this.transport.close()},e=()=>{this.off("upgrade",e),this.off("upgradeError",e),t()},r=()=>{this.once("upgrade",e),this.once("upgradeError",e)};return"opening"!==this.readyState&&"open"!==this.readyState||(this.readyState="closing",this.writeBuffer.length?this.once("drain",(()=>{this.upgrading?r():t()})):this.upgrading?r():t()),this}onError(t){tt.priorWebsocketSuccess=!1,this.emitReserved("error",t),this.onClose("transport error",t)}onClose(t,e){"opening"!==this.readyState&&"open"!==this.readyState&&"closing"!==this.readyState||(this.clearTimeoutFn(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),"function"===typeof removeEventListener&&(removeEventListener("beforeunload",this.beforeunloadEventListener,!1),removeEventListener("offline",this.offlineEventListener,!1)),this.readyState="closed",this.id=null,this.emitReserved("close",t,e),this.writeBuffer=[],this.prevBufferLen=0)}filterUpgrades(t){const e=[];let r=0;const n=t.length;for(;r"function"===typeof ArrayBuffer.isView?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer)(t))||nt&&t instanceof Blob||it&&t instanceof File}function ot(t,e){if(!t||"object"!==typeof t)return!1;if(Array.isArray(t)){for(let e=0,r=t.length;e=0&&t.num{delete this.acks[t];for(let e=0;e{this.io.clearTimeoutFn(i),e.apply(this,[null,...t])}}emitWithAck(t,...e){const r=void 0!==this.flags.timeout||void 0!==this._opts.ackTimeout;return new Promise(((n,i)=>{e.push(((t,e)=>r?t?i(t):n(e):n(t))),this.emit(t,...e)}))}_addToQueue(t){let e;"function"===typeof t[t.length-1]&&(e=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push(((t,...n)=>{if(r!==this._queue[0])return;return null!==t?r.tryCount>this._opts.retries&&(this._queue.shift(),e&&e(t)):(this._queue.shift(),e&&e(null,...n)),r.pending=!1,this._drainQueue()})),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||0===this._queue.length)return;const e=this._queue[0];e.pending&&!t||(e.pending=!0,e.tryCount++,this.flags=e.flags,this.emit.apply(this,e.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){"function"==typeof this.auth?this.auth((t=>{this._sendConnectPacket(t)})):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:lt.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,e){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,e)}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case lt.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case lt.EVENT:case lt.BINARY_EVENT:this.onevent(t);break;case lt.ACK:case lt.BINARY_ACK:this.onack(t);break;case lt.DISCONNECT:this.ondisconnect();break;case lt.CONNECT_ERROR:this.destroy();const e=new Error(t.data.message);e.data=t.data.data,this.emitReserved("connect_error",e)}}onevent(t){const e=t.data||[];null!=t.id&&e.push(this.ack(t.id)),this.connected?this.emitEvent(e):this.receiveBuffer.push(Object.freeze(e))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const e=this._anyListeners.slice();for(const r of e)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&"string"===typeof t[t.length-1]&&(this._lastOffset=t[t.length-1])}ack(t){const e=this;let r=!1;return function(...n){r||(r=!0,e.packet({type:lt.ACK,id:t,data:n}))}}onack(t){const e=this.acks[t.id];"function"===typeof e&&(e.apply(this,t.data),delete this.acks[t.id])}onconnect(t,e){this.id=t,this.recovered=e&&this._pid===e,this._pid=e,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach((t=>this.emitEvent(t))),this.receiveBuffer=[],this.sendBuffer.forEach((t=>{this.notifyOutgoingListeners(t),this.packet(t)})),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach((t=>t())),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:lt.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const e=this._anyListeners;for(let r=0;r0&&t.jitter<=1?t.jitter:0,this.attempts=0}Et.prototype.duration=function(){var t=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var e=Math.random(),r=Math.floor(e*this.jitter*t);t=0==(1&Math.floor(10*e))?t-r:t+r}return 0|Math.min(t,this.max)},Et.prototype.reset=function(){this.attempts=0},Et.prototype.setMin=function(t){this.ms=t},Et.prototype.setMax=function(t){this.max=t},Et.prototype.setJitter=function(t){this.jitter=t};class At extends B{constructor(t,e){var r;super(),this.nsps={},this.subs=[],t&&"object"===typeof t&&(e=t,t=void 0),(e=e||{}).path=e.path||"/socket.io",this.opts=e,x(this,e),this.reconnection(!1!==e.reconnection),this.reconnectionAttempts(e.reconnectionAttempts||1/0),this.reconnectionDelay(e.reconnectionDelay||1e3),this.reconnectionDelayMax(e.reconnectionDelayMax||5e3),this.randomizationFactor(null!==(r=e.randomizationFactor)&&void 0!==r?r:.5),this.backoff=new Et({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==e.timeout?2e4:e.timeout),this._readyState="closed",this.uri=t;const i=e.parser||n;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=!1!==e.autoConnect,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,this):this._reconnection}reconnectionAttempts(t){return void 0===t?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var e;return void 0===t?this._reconnectionDelay:(this._reconnectionDelay=t,null===(e=this.backoff)||void 0===e||e.setMin(t),this)}randomizationFactor(t){var e;return void 0===t?this._randomizationFactor:(this._randomizationFactor=t,null===(e=this.backoff)||void 0===e||e.setJitter(t),this)}reconnectionDelayMax(t){var e;return void 0===t?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,null===(e=this.backoff)||void 0===e||e.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new tt(this.uri,this.opts);const e=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const n=vt(e,"open",(function(){r.onopen(),t&&t()})),i=e=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",e),t?t(e):this.maybeReconnectOnOpen()},s=vt(e,"error",i);if(!1!==this._timeout){const t=this._timeout,r=this.setTimeoutFn((()=>{n(),i(new Error("timeout")),e.close()}),t);this.opts.autoUnref&&r.unref(),this.subs.push((()=>{this.clearTimeoutFn(r)}))}return this.subs.push(n),this.subs.push(s),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(vt(t,"ping",this.onping.bind(this)),vt(t,"data",this.ondata.bind(this)),vt(t,"error",this.onerror.bind(this)),vt(t,"close",this.onclose.bind(this)),vt(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(e){this.onclose("parse error",e)}}ondecoded(t){Z((()=>{this.emitReserved("packet",t)}),this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,e){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new wt(this,t,e),this.nsps[t]=r),r}_destroy(t){const e=Object.keys(this.nsps);for(const r of e){if(this.nsps[r].active)return}this._close()}_packet(t){const e=this.encoder.encode(t);for(let r=0;rt())),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close"),this.engine&&this.engine.close()}disconnect(){return this._close()}onclose(t,e){this.cleanup(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,e),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const e=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn((()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),t.skipReconnect||t.open((e=>{e?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",e)):t.onreconnect()})))}),e);this.opts.autoUnref&&r.unref(),this.subs.push((()=>{this.clearTimeoutFn(r)}))}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const kt={};function _t(t,e){"object"===typeof t&&(e=t,t=void 0);const r=function(t,e="",r){let n=t;r=r||"undefined"!==typeof location&&location,null==t&&(t=r.protocol+"//"+r.host),"string"===typeof t&&("/"===t.charAt(0)&&(t="/"===t.charAt(1)?r.protocol+t:r.host+t),/^(https?|wss?):\/\//.test(t)||(t="undefined"!==typeof r?r.protocol+"//"+t:"https://"+t),n=G(t)),n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443")),n.path=n.path||"/";const i=-1!==n.host.indexOf(":")?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+i+":"+n.port+e,n.href=n.protocol+"://"+i+(r&&r.port===n.port?"":":"+n.port),n}(t,(e=e||{}).path||"/socket.io"),n=r.source,i=r.id,s=r.path,o=kt[i]&&s in kt[i].nsps;let a;return e.forceNew||e["force new connection"]||!1===e.multiplex||o?a=new At(n,e):(kt[i]||(kt[i]=new At(n,e)),a=kt[i]),r.query&&!e.query&&(e.query=r.queryKey),a.socket(r.path,e)}Object.assign(_t,{Manager:At,Socket:wt,io:_t,connect:_t})}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/5114-a70f18877cc7f8bc.js b/dsql-app/.local_dist/static/chunks/5114-a70f18877cc7f8bc.js new file mode 100644 index 0000000..b52660e --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/5114-a70f18877cc7f8bc.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5114],{97037:function(e,a,s){s.d(a,{Z:function(){return t}});var l=s(85893);s(67294);function t(e){var a=e.message;return(0,l.jsxs)("div",{className:"p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid",children:[(0,l.jsx)("img",{src:"/images/warning.png",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,l.jsx)("span",{children:a})]})}},65114:function(e,a,s){s.d(a,{Z:function(){return p}});var l=s(828),t=s(85893),n=s(67294),r=s(86729),i=s(47568),o=s(97582);function d(){return(d=(0,i.Z)((function(e){var a,s,l,t,n,i,d;return(0,o.__generator)(this,(function(o){return a=e.e,s=e.setLoading,l=e.user,t=e.image,n=e.query,s(!0),i={first_name:a.target.first_name.value,last_name:a.target.last_name.value,email:l?null:a.target.email_address.value,username:l?null:a.target.username.value,password:l?null:a.target.password.value,image:t||null},(null===n||void 0===n?void 0:n.invite)&&(i.inviteObject=n),d=l?"/api/updateUser":"/api/registerUser",(0,r.Z)(d,{method:"post",body:i},!!l).then((function(e){console.log(e),!l&&(null===e||void 0===e?void 0:e.insertId)?(localStorage.setItem("id",e.insertId),(0,r.Z)("/api/loginUser",{method:"post",body:{email:i.email,password:i.password}}).then((function(e){console.log(e),localStorage.setItem("csrf",e.user.csrf_k),localStorage.setItem("stripe_id",e.user.stripe_id),localStorage.setItem("user",JSON.stringify(e.userPayload)),window.location.href="/admin"}))):l&&(null===e||void 0===e?void 0:e.user)?window.location.reload():(null===e||void 0===e?void 0:e.msg)&&alert(e.msg)})).catch((function(e){console.log(e)})).finally((function(){setTimeout((function(){s(!1)}),2e3)})),[2]}))}))).apply(this,arguments)}var u,c=s(97037),m=s(95264),f=s(98374);function p(e){var a=e.user,s=e.query,i=e.image,o=(null===s||void 0===s?void 0:s.email)?s.email:(null===a||void 0===a?void 0:a.email)?a.email:"",p=(0,l.Z)(n.useState(null),2),g=p[0],v=p[1],x=(0,l.Z)(n.useState(!1),2),h=x[0],w=x[1];return(0,t.jsxs)("div",{className:"relative w-full max-w-2xl flex-col items-start",children:[h&&(0,t.jsx)(m.Z,{}),!a&&(0,t.jsxs)(n.Fragment,{children:[(0,t.jsx)("hr",{className:"opacity-0"}),(0,t.jsx)(f.Z,{user:null,userType:"admin",setLoading:w}),(0,t.jsxs)("div",{className:"w-full justify-center relative",children:[(0,t.jsx)("span",{className:"bg-white dark:bg-slate-800 px-3 relative z-10",children:"OR"}),(0,t.jsx)("hr",{className:"absolute"})]})]}),(0,t.jsxs)("form",{className:"w-full flex flex-col items-start gap-4 relative",onSubmit:function(e){e.preventDefault(),function(e){d.apply(this,arguments)}({e:e,setLoading:w,user:a,image:i,query:s})},children:[g&&(0,t.jsx)(c.Z,{message:g}),(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"first_name",children:"First Name"}),(0,t.jsx)("input",{type:"text",name:"first_name",id:"first_name",placeholder:"First Name",autoComplete:"given-name",onInput:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),v(null)):a.classList.add("warning")},defaultValue:a?a.first_name:"",required:!0})]}),(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"last_name",children:"Last Name"}),(0,t.jsx)("input",{type:"text",name:"last_name",id:"last_name",placeholder:"Last Name",autoComplete:"family-name",onInput:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),v(null)):a.classList.add("warning")},defaultValue:a?a.last_name:"",required:!0})]}),(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"username",children:"Username"}),(0,t.jsx)("input",{type:"text",name:"username",id:"username",placeholder:"Username",autoComplete:"username",onInput:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),v(null)):a.classList.add("warning"),window.clearTimeout(u),u=setTimeout((function(){(0,r.Z)("/api/checkDuplicateData?type=username&value=".concat(a.value,"&tableName=users")).then((function(e){console.log(e),(null===e||void 0===e?void 0:e.result)?(v("Username Already Exists"),a.classList.add("warning")):(v(null),a.classList.remove("warning"))}))}),300)},defaultValue:a?a.username:"",required:!a,readOnly:!!a})]}),(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"email_address",children:"Email Address"}),(0,t.jsx)("input",{type:"email",name:"email_address",id:"email_address",placeholder:"Email Address",autoComplete:"email",onInput:function(e){var a=e.target;window.clearTimeout(u),u=setTimeout((function(){(0,r.Z)("/api/checkDuplicateData?type=email&value=".concat(a.value,"&tableName=users")).then((function(e){console.log(e),(null===e||void 0===e?void 0:e.result)?(v("Email Already Exists"),a.classList.add("warning")):(v(null),a.classList.remove("warning"))}))}),300)},defaultValue:o,required:!0,readOnly:!!a})]}),!a&&(0,t.jsxs)(n.Fragment,{children:[(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"password",children:"Password"}),(0,t.jsx)("input",{type:"password",name:"password",id:"password",placeholder:"Password",required:!0})]}),(0,t.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,t.jsx)("label",{htmlFor:"confirm_password",children:"Confirm Password"}),(0,t.jsx)("input",{type:"password",name:"confirm_password",id:"confirm_password",placeholder:"Confirm Password",onInput:function(e){var a,s=e.target;(null===(a=s.closest("form"))||void 0===a?void 0:a.password.value)===s.value?s.classList.remove("warning"):s.classList.add("warning")},required:!0})]}),(0,t.jsxs)("span",{className:"text-sm",children:['By clicking "Create Account" you agree to our'," ",(0,t.jsx)("a",{href:"/terms",target:"_blank",className:"font-bold",children:"Terms and Conditions"})]})]}),(0,t.jsx)("button",{type:"submit",className:"w-full",children:a?(0,t.jsx)("span",{children:"Update Account Info"}):(0,t.jsx)("span",{children:"Create Account"})}),!a&&(0,t.jsx)(n.Fragment,{children:(0,t.jsxs)("span",{className:"text-sm",children:["Already Have an Account?"," ",(0,t.jsx)("a",{href:"/login",className:"font-bold",children:"Login"})]})})]})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/5313-e7700a25826b1c4d.js b/dsql-app/.local_dist/static/chunks/5313-e7700a25826b1c4d.js new file mode 100644 index 0000000..9ca9790 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/5313-e7700a25826b1c4d.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5313],{85313:function(e,s,l){l.d(s,{Z:function(){return b}});var a=l(85893),t=l(67294),n=l(9008),r=l.n(n),i=l(828),c=l(64017),d=l(64689),x=l(38544),o=l(39269),u=l(50027),h=l(51903),m=l(28466);function p(e){var s=(0,i.Z)(t.useState(!0),2),l=s[0],n=s[1];return(0,a.jsxs)("aside",{className:"aside"+(l?" mobile-collapsed":" mobile-expanded"),style:{maxWidth:l?"250px":"300px",zIndex:800},children:[(0,a.jsx)(c.Z,{adminAside:!0,collapseAsideMobile:l,setCollapseAsideMobile:n}),(0,a.jsx)("hr",{className:"opacity-0 mt-4"}),(0,a.jsxs)("div",{className:"main-links"+(l?" hidden lg:flex":" "),children:[(0,a.jsxs)("a",{href:"/su","data-currentlink":"/su","data-strictlink":"true",children:[(0,a.jsx)(d.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Dashboard"})]}),(0,a.jsxs)("a",{href:"/su/users","data-currentlink":"/su/users",children:[(0,a.jsx)(x.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Users"})]}),(0,a.jsxs)("a",{href:"/su/error-logs","data-currentlink":"/su/error-logs",children:[(0,a.jsx)(o.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Error Logs"})]}),!1,(0,a.jsxs)("a",{href:"/su/backups","data-currentlink":"/su/backups",children:[(0,a.jsx)(u.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Backups"})]}),(0,a.jsxs)("a",{href:"/su/console","data-currentlink":"/su/console",children:[(0,a.jsx)(h.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Console"})]}),(0,a.jsxs)("a",{href:"/su/envar","data-currentlink":"/su/envar",children:[(0,a.jsx)(m.Z,{className:"text-slate-400"}),(0,a.jsx)("span",{children:"Env"})]})]})]})}var f=l(44981),j=l(8971);function g(e){var s=e.user,l=(e.extraHeaderContent,(0,i.Z)(t.useState(s||null),2)),n=(l[0],l[1]);return t.useEffect((function(){(null===s||void 0===s?void 0:s.logged_in_status)&&n(s||null)}),[s]),(0,a.jsx)("section",{className:"overflow-visible w-full px-0 md:px-8 py-0 flex justify-center bg-white dark:bg-slate-800 shadow-lg gap-4 dark:shadow-black/10 z-50 shadow-slate-900/5",style:{zIndex:700,border:"none"},children:(0,a.jsxs)("div",{className:"w-full items-center justify-between gap-4 md:gap-8",children:[(0,a.jsxs)("div",{className:"hidden xl:flex flex-col items-stretch grow fixed xl:static top-0 right-0 px-4 xl:px-0 shadow-xl xl:shadow-none h-screen xl:h-auto overflow-auto xl:overflow-visible w-screen sl:w-auto bg-white xl:bg-transparent pb-10 xl:pb-0",id:"main-nav-content-wrapper",children:[(0,a.jsxs)("div",{className:"items-center mb-2 flex xl:hidden",children:[(0,a.jsx)("a",{href:"/",className:"hidden xl:flex",children:(0,a.jsx)("img",{src:"/images/logo-icon-alt-2.png",alt:"Logo Icon",width:37})}),(0,a.jsx)("button",{className:"outlined gray ml-auto",onClick:function(e){var s=document.getElementById("main-nav-content-wrapper");null===s||void 0===s||s.classList.toggle("hidden")},style:{border:"none"},children:(0,a.jsx)("span",{className:"font-semibold text-4xl",children:"\u2715"})})]}),(0,a.jsx)("div",{className:"flex items-center w-full gap-6 grow flex-col xl:flex-row justify-start xl:justify-between",children:(0,a.jsx)("div",{className:"gap-2 flex-col-reverse xl:flex-row gap-y-6 w-full xl:w-auto py-2",children:(0,a.jsxs)("div",{className:"ml-auto dropdown-wrapper",children:[(0,a.jsx)("div",{className:"bg-white rounded-full overflow-hidden",style:{width:"36px",height:"36px"},children:(0,a.jsx)("img",{src:"/images/user_images/user-preset-thumbnail.png",alt:"User Image",width:35,className:"w-full h-full object-cover"})}),(0,a.jsx)("span",{children:(0,a.jsx)("b",{children:"Super User"})}),(0,a.jsx)(j.Z,{size:20}),(0,a.jsx)("div",{className:"dropdown",children:(0,a.jsx)("a",{href:"/su/logout",children:"Logout"})})]})})})]}),(0,a.jsx)("div",{className:"ml-2",children:(0,a.jsx)(f.Z,{})}),(0,a.jsxs)("button",{className:"bg-transparent w-16 p-4 gap-1.5 flex xl:hidden flex-col hover:bg-transparent transition-all ml-auto",onClick:function(e){var s=document.getElementById("main-nav-content-wrapper");null===s||void 0===s||s.classList.toggle("hidden")},style:{minWidth:"50px",backgroundColor:"transparent"},id:"main-header-hamburger-button","aria-label":"Mobile Hambutget Button",children:[(0,a.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"}),(0,a.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"}),(0,a.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"})]})]})})}var w=l(29678);function b(e){var s=e.children,l=e.head,n=e.user;return t.useEffect((function(){var e=document.querySelectorAll("aside .main-links a");(0,w.Z)({links:e})}),[]),(0,a.jsxs)(t.Fragment,{children:[(0,a.jsxs)(r(),{children:[(0,a.jsx)("link",{rel:"stylesheet",href:"/styles/admin.css"}),l]}),(0,a.jsxs)("div",{className:"admin w-full flex items-start gap-0",children:[(0,a.jsx)(p,{}),(0,a.jsxs)("main",{className:"relative",children:[(0,a.jsx)(g,{user:n}),(0,a.jsx)("div",{className:"flex-col items-start gap-6 px-4 sl:px-8 py-8 bg-slate-50 dark:bg-slate-900",children:s}),(0,a.jsx)("footer",{className:"flex justify-center w-full items-center p-4",children:(0,a.jsxs)("div",{className:"max-w-6xl w-full justify-center flex-wrap",children:[(0,a.jsxs)("a",{href:"/",className:"flex items-center gap-2",children:[(0,a.jsx)("img",{src:"/images/logo-icon-alt-2.png",alt:"Datasquirel Logo",width:30}),(0,a.jsx)("span",{className:"text-lg font-bold",children:"Datasquirel"})]}),(0,a.jsx)("span",{className:"opacity-25",children:"|"}),(0,a.jsxs)("span",{className:"text-sm text-slate-400 dark:text-slate-600 text-center",children:[(new Date).getFullYear()," \xa9 Datasquirel. All rights reserved."]}),(0,a.jsx)("span",{className:"opacity-25",children:"|"}),(0,a.jsx)("a",{href:"/docs",children:"Docs"}),(0,a.jsx)("span",{className:"opacity-25",children:"|"}),(0,a.jsx)("a",{href:"/terms",children:"Terms"})]})})]})]})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/5622-0b01b71a2de3acf8.js b/dsql-app/.local_dist/static/chunks/5622-0b01b71a2de3acf8.js new file mode 100644 index 0000000..9461efc --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/5622-0b01b71a2de3acf8.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5622],{77227:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M22 11V3h-7v3H9V3H2v8h7V8h2v10h4v3h7v-8h-7v3h-2V8h2v3h7zM7 9H4V5h3v4zm10 6h3v4h-3v-4zm0-10h3v4h-3V5z"},"0"),(0,n.jsx)("path",{d:"M7 5v4H4V5h3m13 0v4h-3V5h3m0 10v4h-3v-4h3",opacity:".3"},"1")],"AccountTreeTwoTone");t.Z=i},31356:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M5 5v14h14V5H5zm9 12H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14zm-2-6H7v-2h10v2zm0-4H7V7h10v2zm-3 8H7v-2h7v2z"},"1")],"ArticleTwoTone");t.Z=i},50027:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"m19.21 12.04-1.53-.11-.3-1.5C16.88 7.86 14.62 6 12 6 9.94 6 8.08 7.14 7.12 8.96l-.5.95-1.07.11C3.53 10.24 2 11.95 2 14c0 2.21 1.79 4 4 4h13c1.65 0 3-1.35 3-3 0-1.55-1.22-2.86-2.79-2.96zm-5.76.96v3h-2.91v-3H8l4-4 4 4h-2.55z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95C8.08 7.14 9.94 6 12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11c1.56.1 2.78 1.41 2.78 2.96 0 1.65-1.35 3-3 3zM8 13h2.55v3h2.9v-3H16l-4-4z"},"1")],"BackupTwoTone");t.Z=i},64689:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M18 19h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M12 3 6 7.58V6H4v3.11L1 11.4l1.21 1.59L4 11.62V21h16v-9.38l1.79 1.36L23 11.4 12 3zm6 16h-5v-4h-2v4H6v-8.9l6-4.58 6 4.58V19zM10 1c0 1.66-1.34 3-3 3-.55 0-1 .45-1 1H4c0-1.66 1.34-3 3-3 .55 0 1-.45 1-1h2z"},"1")],"CottageTwoTone");t.Z=i},39269:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M12 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm1 13h-2v-2h2v2zm0-4h-2V7h2v6z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm-1-5h2v2h-2zm0-8h2v6h-2z"},"1")],"ErrorTwoTone");t.Z=i},28466:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M6 10v10h5.29c-.19-.63-.29-1.3-.29-2 0-3.87 3.13-7 7-7v-1H6z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M6 20V10h12v1c.7 0 1.37.1 2 .29V10c0-1.1-.9-2-2-2h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h6.26c-.42-.6-.75-1.28-.97-2H6zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6z"},"1"),(0,n.jsx)("path",{d:"M18 13c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0 2c.83 0 1.5.67 1.5 1.5S18.83 18 18 18s-1.5-.67-1.5-1.5.67-1.5 1.5-1.5zm0 6c-1.03 0-1.94-.52-2.48-1.32.73-.42 1.57-.68 2.48-.68s1.75.26 2.48.68c-.54.8-1.45 1.32-2.48 1.32z"},"2")],"LockPersonTwoTone");t.Z=i},38544:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("circle",{cx:"9",cy:"8",r:"2",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M9 15c-2.7 0-5.8 1.29-6 2.01V18h12v-1c-.2-.71-3.3-2-6-2z",opacity:".3"},"1"),(0,n.jsx)("path",{d:"M16.67 13.13C18.04 14.06 19 15.32 19 17v3h4v-3c0-2.18-3.57-3.47-6.33-3.87zM15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4c-.47 0-.91.1-1.33.24C14.5 5.27 15 6.58 15 8s-.5 2.73-1.33 3.76c.42.14.86.24 1.33.24zm-6 0c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0-6c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm0 7c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4zm6 5H3v-.99C3.2 16.29 6.3 15 9 15s5.8 1.29 6 2v1z"},"2")],"PeopleAltTwoTone");t.Z=i},51903:function(e,t,c){var s=c(64836);t.Z=void 0;var a=s(c(64938)),n=c(85893),i=(0,a.default)([(0,n.jsx)("path",{d:"M4 18h16V8H4v10zm8-3h6v2h-6v-2zm-5.91-4.59L7.5 9l4 4-4 4-1.41-1.41L8.67 13l-2.58-2.59z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M12 15h6v2h-6z"},"1"),(0,n.jsx)("path",{d:"M20 4H4c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm0 14H4V8h16v10z"},"2"),(0,n.jsx)("path",{d:"m7.5 17 4-4-4-4-1.41 1.41L8.67 13l-2.58 2.59z"},"3")],"TerminalTwoTone");t.Z=i},62435:function(e,t,c){c.d(t,{Z:function(){return v}});var s=c(828),a=c(85893),n=c(67294),i=c(31356),o=c(86729),l=c(95264),d=c(77227);function h(e){var t=e.docPageObject,c=(0,s.Z)(n.useState(!1),2),h=c[0],r=c[1],v=(0,s.Z)(n.useState([]),2),u=v[0],m=v[1];return n.useEffect((function(){(0,o.Z)("/api/admin/docs/get-child-pages",{method:"post",body:{pageId:t.id}}).then((function(e){e.success&&m(e.result)}))}),[]),(0,a.jsxs)("div",{className:"card col relative cursor-pointer",onClick:function(e){var c;(null===(c=e.target)||void 0===c?void 0:c.closest(".cancel-link"))?e.preventDefault():window.location.pathname="/su/docs/pages/".concat(t.id)},children:[h&&(0,a.jsx)(l.Z,{width:"20px"}),(0,a.jsxs)("div",{className:"w-full items-start",children:[(0,a.jsx)(i.Z,{color:"inherit",className:"opacity-40 text-gray-600"}),(0,a.jsxs)("div",{className:"flex-col items-start gap-0 relative z-10",children:[(0,a.jsx)("span",{className:"title",children:t.title}),(0,a.jsx)("span",{className:"-my-3",dangerouslySetInnerHTML:{__html:t.description||""}})]}),(0,a.jsxs)("div",{className:"ml-auto cancel-link",children:[(0,a.jsx)("button",{onClick:function(){window.location.href="/su/docs/edit-page?id=".concat(t.id)},className:"outlined small-text light-gray",children:"Edit Page"}),(0,a.jsx)("button",{onClick:function(){window.confirm("Delete this page?")&&(r(!0),(0,o.Z)("/api/admin/docs/delete-page",{method:"post",body:t}).then((function(e){e.success&&window.location.reload(),setTimeout((function(){r(!1)}),1e3)})))},className:"outlined small-text light-gray",children:"Delete Page"})]})]}),u&&(0,a.jsxs)("div",{className:"-mt-[40px] pt-[40px] ml-[10px] pl-[20px] border-0 border-l border-slate-200 border-solid w-full flex-col items-start cancel-link",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)(d.Z,{className:"opacity-20",fontSize:"small"}),(0,a.jsx)("span",{className:"text-slate-300 font-semibold",children:"Children Pages"})]}),u.map((function(e,t){return(0,a.jsxs)("div",{className:"card w-full",onClick:function(){window.location.pathname="/su/docs/pages/".concat(e.id)},children:[(0,a.jsx)(i.Z,{color:"inherit",className:"opacity-40 text-gray-500"}),(0,a.jsx)("span",{children:e.title})]},t)}))]})]})}var r=c(45449);function v(e){var t=e.data,c=function(e){window.confirm(e?"Update Docs DB from JSON file?":"Update docs json file?")&&(u(!0),(0,o.Z)("/api/admin/docs/persist",{method:"post",body:{pull:e}}).then((function(t){t.success?window.alert(e?"Docs database table Updated Sucessfully!":"JSON data written Successfully!"):window.alert("Operation failed!"),setTimeout((function(){u(!1)}),1e3)})).catch((function(e){setTimeout((function(){u(!1)}),1e3)})))},i=(t.env,t.docPages),d=(0,s.Z)(n.useState(!1),2),v=d[0],u=d[1];return(0,a.jsxs)(n.Fragment,{children:[v&&(0,a.jsx)(l.Z,{}),(0,a.jsxs)("section",{className:"items-start justify-start p-6",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between w-full mb-6",children:[(0,a.jsx)("h2",{className:"text-xl m-0",children:"Documentation Pages"}),(0,a.jsxs)("div",{children:[(0,a.jsx)("a",{href:"/su/docs/create-page",className:"button",children:"Create Page"}),(0,a.jsxs)(r.Z,{children:[(0,a.jsx)("button",{className:"outlined gray",onClick:function(){c(!1)},children:"Push"}),(0,a.jsx)("button",{className:"outlined gray",onClick:function(){c(!0)},children:"Pull"})]})]})]}),(0,a.jsx)("div",{className:"paper flex-col items-stretch gap-10 w-full",children:i.map((function(e,t){return(0,a.jsx)(h,{docPageObject:e},t)}))})]})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/5667-9e7b94f8ce529764.js b/dsql-app/.local_dist/static/chunks/5667-9e7b94f8ce529764.js new file mode 100644 index 0000000..73bb340 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/5667-9e7b94f8ce529764.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5667],{10312:function(e,t,s){s.d(t,{Z:function(){return a}});const a=(0,s(45711).Z)("Sheet",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["line",{x1:"3",x2:"21",y1:"9",y2:"9",key:"1vqk6q"}],["line",{x1:"3",x2:"21",y1:"15",y2:"15",key:"o2sbyz"}],["line",{x1:"9",x2:"9",y1:"9",y2:"21",key:"1ib60c"}],["line",{x1:"15",x2:"15",y1:"9",y2:"21",key:"1n26ft"}]])},37359:function(e,t,s){s.d(t,{Z:function(){return b}});var a=s(85893),n=s(67294),r=s(41457),i=s(424),c=s(97946),d=(s(68744),s(96891));function l(e){var t=n.useContext(r.DashboardContext),s=t.databases,i=t.setTargetDatabase,c=t.user;return(0,a.jsx)(n.Fragment,{children:(0,a.jsx)(d.Z,{databases:s,setTargetDatabase:i,title:"Recently added Databases",more:!0,user:c})})}var o=s(55592),u=s(33587),x=s(10312),m=s(78107);const h=(0,s(45711).Z)("Key",[["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["path",{d:"m15.5 7.5 3 3L22 7l-3-3",key:"1rn1fs"}]]);function j(e){var t=e.icon,s=e.metric,n=e.count,r=e.url;return(0,a.jsxs)("a",{href:r,className:"card col w-full",children:[(0,a.jsx)("div",{className:"absolute top-4 right-4",children:t}),(0,a.jsxs)("div",{className:"content-block",children:[(0,a.jsx)("span",{className:"metric text-slate-800 dark:text-white",children:n}),(0,a.jsx)("span",{className:"text-sm text-slate-600 dark:text-slate-400",children:s})]})]})}function v(e){var t=n.useContext(r.DashboardContext),s=(t.databases,t.setTargetDatabase,t.metrics),i=t.user;return(0,a.jsx)("section",{className:"p-0",children:(0,a.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 xl:grid-cols-4 w-full gap-6 items-stretch",children:[(0,a.jsx)(j,{metric:"Databases Created",count:(null===s||void 0===s?void 0:s.dbCount)||0,icon:(0,a.jsx)(u.Z,{size:20,className:"text-secondary2"}),url:"/admin/".concat(null===i||void 0===i?void 0:i.id,"/databases")}),(0,a.jsx)(j,{metric:"Tables Created",count:(null===s||void 0===s?void 0:s.tablesCount)||0,icon:(0,a.jsx)(x.Z,{size:20,className:"text-primary"})}),(0,a.jsx)(j,{metric:"Media Added",count:(null===s||void 0===s?void 0:s.mediaCount)||0,icon:(0,a.jsx)(m.Z,{size:20,className:"text-slate-500"}),url:"/admin/".concat(null===i||void 0===i?void 0:i.id,"/media")}),(0,a.jsx)(j,{metric:"API Keys",count:(null===s||void 0===s?void 0:s.apiKeysCount)||0,icon:(0,a.jsx)(h,{size:20,className:"text-slate-900 dark:text-white"}),url:"/admin/".concat(null===i||void 0===i?void 0:i.id,"/api-keys")})]})})}function b(e){var t,s=n.useContext(r.DashboardContext),d=(s.databases,s.user);return(0,a.jsxs)(n.Fragment,{children:[(0,a.jsxs)("div",{className:"flex-col items-start gap-0",children:[(0,a.jsx)("h1",{className:"text-3xl m-0",children:"Dashboard"}),(0,a.jsx)(i.Z,{user:d})]}),(null===d||void 0===d||null===(t=d.verification_status)||void 0===t?void 0:t.toString().match(/1/))?(0,a.jsxs)(n.Fragment,{children:[(0,a.jsx)(v,{}),(0,a.jsx)(l,{}),(0,a.jsx)(o.Z,{user:d})]}):(0,a.jsx)(c.Z,{})]})}},41457:function(e,t,s){s.r(t),s.d(t,{DashboardContext:function(){return u},__N_SSP:function(){return o},default:function(){return x}});var a=s(828),n=s(85893),r=s(67294),i=s(54858),c=s(37359),d=s(85012),l={},o=!0,u=r.createContext(l);function x(e){var t=e.user,s=e.databases,l=e.metrics,o=(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,n.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),x=r.useState(null),m=(0,a.Z)(x,2),h=m[0],j=m[1];return(0,n.jsx)(i.Z,{head:o,user:t,children:(0,n.jsxs)(u.Provider,{value:{user:t,databases:s,targetDatabase:h,setTargetDatabase:j,metrics:l},children:[(0,n.jsx)(c.Z,{}),(0,n.jsx)(d.Z,{targetDatabase:h})]})})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/5949-b1c68b62cd5dbfee.js b/dsql-app/.local_dist/static/chunks/5949-b1c68b62cd5dbfee.js new file mode 100644 index 0000000..113d17e --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/5949-b1c68b62cd5dbfee.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5949],{96224:function(e,t,n){var a=n(64836);t.Z=void 0;var s=a(n(64938)),l=n(85893),c=(0,s.default)([(0,l.jsx)("path",{d:"m16 7.58-5.5-2.4L5 7.58v3.6c0 3.5 2.33 6.74 5.5 7.74.25-.08.49-.2.73-.3-.15-.51-.23-1.06-.23-1.62 0-2.97 2.16-5.43 5-5.91V7.58z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M17 13c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 1.38c.62 0 1.12.51 1.12 1.12s-.51 1.12-1.12 1.12-1.12-.51-1.12-1.12.5-1.12 1.12-1.12zm0 5.37c-.93 0-1.74-.46-2.24-1.17.05-.72 1.51-1.08 2.24-1.08s2.19.36 2.24 1.08c-.5.71-1.31 1.17-2.24 1.17z",opacity:".3"},"1"),(0,l.jsx)("circle",{cx:"17",cy:"15.5",r:"1.12"},"2"),(0,l.jsx)("path",{d:"M18 11.09V6.27L10.5 3 3 6.27v4.91c0 4.54 3.2 8.79 7.5 9.82.55-.13 1.08-.32 1.6-.55C13.18 21.99 14.97 23 17 23c3.31 0 6-2.69 6-6 0-2.97-2.16-5.43-5-5.91zM11 17c0 .56.08 1.11.23 1.62-.24.11-.48.22-.73.3-3.17-1-5.5-4.24-5.5-7.74v-3.6l5.5-2.4 5.5 2.4v3.51c-2.84.48-5 2.94-5 5.91zm6 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"},"3"),(0,l.jsx)("path",{d:"M17 17.5c-.73 0-2.19.36-2.24 1.08.5.71 1.32 1.17 2.24 1.17s1.74-.46 2.24-1.17c-.05-.72-1.51-1.08-2.24-1.08z"},"4")],"AdminPanelSettingsTwoTone");t.Z=c},88518:function(e,t,n){var a=n(64836);t.Z=void 0;var s=a(n(64938)),l=n(85893),c=(0,s.default)([(0,l.jsx)("path",{d:"M22 15c0-1.66-1.34-3-3-3h-1.5v-.5C17.5 8.46 15.04 6 12 6c-.77 0-1.49.17-2.16.46L20.79 17.4c.73-.55 1.21-1.41 1.21-2.4zM2 14c0 2.21 1.79 4 4 4h9.73l-8-8H6c-2.21 0-4 1.79-4 4z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.33 0-2.57.36-3.65.97l1.49 1.49C10.51 6.17 11.23 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 .99-.48 1.85-1.21 2.4l1.41 1.41c1.09-.92 1.8-2.27 1.8-3.81 0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.77 2.77h-.42C2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h11.73l2 2 1.41-1.41L4.41 3.86 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"},"1")],"CloudOffTwoTone");t.Z=c},57150:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},33587:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},49525:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(e,t,n){n.d(t,{Z:function(){return a}});const a=(0,n(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},9417:function(e,t,n){n.d(t,{Z:function(){return f}});var a=n(828),s=n(29815),l=n(85893),c=n(67294),i=n(86729),o=n(25472),r=n(95264),d=n(49486),u=n(44114);function f(e){var t,f,h=e.targetUser,m=e.user,p=e.setTargetUser,x=n(19169);if(!h)return null;var v=(0,a.Z)(c.useState(!0),2),b=v[0],y=v[1],g=c.useState([]),k=(0,a.Z)(g,2),Z=k[0],j=k[1],w=(0,a.Z)(c.useState(!1),2),_=w[0],N=w[1],M=c.useState(h?null===(t=h.user_priviledge)||void 0===t?void 0:t.split("|"):[]),C=(0,a.Z)(M,2),T=C[0],z=C[1],E=(0,a.Z)(c.useState((null===h||void 0===h?void 0:h.database_access)?h.database_access.split("|"):[]),2),H=E[0],S=E[1],A=c.useState(h?null===(f=h.database_access)||void 0===f?void 0:f.split("|")[0]:null),L=(0,a.Z)(A,2),V=L[0],q=L[1],D=c.useState([]),U=(0,a.Z)(D,2),R=U[0],B=U[1],F=c.useState([]),I=(0,a.Z)(F,2),O=I[0],P=I[1];return c.useEffect((function(){(0,i.Z)("/api/getUserDatabases").then((function(e){e.success&&j(e.databases)}))}),[]),c.useEffect((function(){var e;h&&(V?(0,i.Z)("/api/getDatabaseTables?dbSlug=".concat(V,"&dbOwnerId=").concat(m.id,"&delegatedUserId=").concat(h.invited_user_id)).then((function(e){e.success&&(B(null),setTimeout((function(){B((0,s.Z)(e.tables))}),200)),e.accessed_tables&&e.accessed_tables[0]&&!O[0]&&P(e.accessed_tables.map((function(e){return"".concat(e.database,"-").concat(e.table)})))})):q((null===(e=h.database_access)||void 0===e?void 0:e.split("|")[0])||null))}),[V]),c.useEffect((function(){var e,t;(y(!0),h)&&(z((null===(e=h.user_priviledge)||void 0===e?void 0:e.split("|"))||[]),S((null===(t=h.database_access)||void 0===t?void 0:t.split("|"))||[]));setTimeout((function(){y(!1)}),500)}),[h]),c.useEffect((function(){q((null===H||void 0===H?void 0:H[0])||null)}),[H]),(0,l.jsxs)(o.ZP,{title:"target-user-popup",closePopupDispatch:function(){p(null)},children:[b&&(0,l.jsx)(r.Z,{position:"relative"}),!b&&h&&(0,l.jsx)(c.Fragment,{children:(0,l.jsxs)("div",{className:"flex-col w-full items-start p-4",children:[(0,l.jsxs)("h4",{className:"m-0",children:["Edit ",h.first_name," ",h.last_name,"'s Access"]}),(0,l.jsx)("hr",{}),(0,l.jsxs)("form",{className:"flex flex-col items-start w-full",onSubmit:function(e){e.preventDefault(),y(!0),(0,i.Z)("/api/updateAdminUserAccess",{method:"post",body:{userObject:h,user_priviledge:T.join("|"),database_access:null===H||void 0===H?void 0:H.join("|"),db_tables:H&&H[0]?O.join("|"):"",inv_user_id:h.invited_user_id}},!0).then((function(e){window.location.reload(),setTimeout((function(){y(!1)}),500)}))},children:[(0,l.jsx)("h3",{className:"m-0 text-lg font-semibold mb-1 text-slate-600",children:"User Priviledges"}),(0,l.jsx)(d.Z,{checkBoxValues:x.map((function(e){return{title:e,name:e,default:!!T.includes(e),onChangeHandler:function(t){if(T.includes(e)){var n=T.filter((function(t){return t!=e}));z((0,s.Z)(n))}else z((function(t){return(0,s.Z)(t).concat([e])}))}}})),smallText:!0,flexRow:!0}),(0,l.jsx)("hr",{className:"my-6"}),(0,l.jsx)("h3",{className:"m-0 text-lg font-semibold mb-2 text-slate-600",children:"Databases Access"}),(0,l.jsx)("span",{className:"button outlined gray px-4 py-1 -mt-1 mb-1.5",onClick:function(e){_?(Z.forEach((function(e){setTimeout((function(){var t=document.getElementById(e.db_slug);(null===t||void 0===t?void 0:t.checked)&&t.click()}),200)})),N(!1)):(Z.forEach((function(e){setTimeout((function(){var t=document.getElementById(e.db_slug);t.checked||t.click()}),200)})),N(!0))},children:_?"Deselect All":"Select All"}),(0,l.jsx)(d.Z,{checkBoxValues:Z.map((function(e){return{title:e.db_name,name:e.db_slug,onChangeHandler:function(t){if(H.includes(e.db_slug)){var n=H.filter((function(t){return t!=e.db_slug}));S((0,s.Z)(n))}else S((function(t){return(0,s.Z)(t).concat([e.db_slug])}));H.length===Z.length?N(!0):N(!1)},default:!!H.includes(e.db_slug)}})),smallText:!0,flexRow:!0}),H&&H[0]&&(0,l.jsxs)(c.Fragment,{children:[(0,l.jsx)("hr",{className:"my-6"}),(0,l.jsx)("h3",{className:"m-0 text-lg font-semibold mb-2 text-slate-600",children:"Database Tables"}),(0,l.jsx)(u.Z,{required:!0,selectOptions:Z.filter((function(e){return H.includes(e.db_slug)})).map((function(e){return{title:e.db_name,payload:e.db_slug}})),name:"databases",onChangeHandler:function(e){q(e.target.value)}}),(0,l.jsx)("div",{className:"h-2"}),R&&R[0]&&(0,l.jsx)(d.Z,{checkBoxValues:R.map((function(e){return{title:e.table_name,name:e.table_slug,onChangeHandler:function(t){if(O.includes("".concat(V,"-").concat(e.table_slug))){var n=O.filter((function(t){return t!="".concat(V,"-").concat(e.table_slug)}));P((0,s.Z)(n))}else P((function(t){return(0,s.Z)(t).concat(["".concat(V,"-").concat(e.table_slug)])}))},default:!!O.includes("".concat(V,"-").concat(e.table_slug))}})),smallText:!0,flexRow:!0})]}),(0,l.jsx)("button",{className:"mt-4 w-full",children:"Update User Access"})]})]})})]})}},49486:function(e,t,n){n.d(t,{Z:function(){return s}});var a=n(85893);n(67294);function s(e){var t=e.name,n=e.checkBoxValues,s=e.setAlert,l=e.labelColor,c=e.flexRow,i=e.baseText,o=e.smallText,r=e.className;return(0,a.jsx)("div",{className:"flex items-start gap-x-4"+(c?" flex-row flex-wrap gap-y-2 ":" flex-col gap-y-4 ")+(r||""),children:n.map((function(e,n){var c=e.payload,r=e.title,d=e.onChangeHandler,u=e.fixed,f=e.jsx,h=e.name?"".concat(t,"-").concat(e.name):c?t+"-"+c:t;return(0,a.jsxs)("div",{className:"flex items-center"+(e.default&&u?" pointer-events-none":"")+(o?" gap-1 ":" gap-2 ")+((null===e||void 0===e?void 0:e.className)?e.className:""),children:[(0,a.jsx)("input",{className:"m-0"+(o?" w-4 h-4":" w-5 h-5"),type:"checkbox",defaultChecked:!!e.default,name:h,id:h,onChange:function(t){s&&s(null),d&&d(t,e)},value:c,style:{minWidth:"20px"}}),f||(0,a.jsx)("label",{htmlFor:h,className:"m-0 "+(l||"text-slate-800 dark:text-white/80")+(i||o?" text-base":" text-lg"),children:r})]},n+1)}))})}},44114:function(e,t,n){n.d(t,{Z:function(){return l}});var a=n(85893),s=n(8971);n(67294);function l(e){var t=e.selectOptions,n=e.name,l=e.onChangeHandler,c=e.required,i=e.setAlert,o=e.title,r=e.defaultValue,d=e.info,u=e.id;try{var f=function(e){if(!(e.type.match(/enter/i)&&window.innerWidth<1200)){var t=e.target.closest(".info-wrapper"),n=t.querySelector(".info-dropdown");!e.type.match(/leave/i)||n.classList.contains("hidden")?e.type.match(/leave/i)&&n.classList.contains("hidden")||(t&&n.classList.contains("hidden")?n.classList.remove("hidden"):n.classList.add("hidden")):n.classList.add("hidden")}};return(0,a.jsxs)("div",{className:"form-select-block flex items-start flex-col gap-0.5 w-full relative"+(d?" pr-8":""),children:[o&&(0,a.jsxs)("label",{htmlFor:n,children:[o,c?"":" (optional)"]}),(0,a.jsxs)("div",{className:"flex items-center w-full relative",children:[(0,a.jsx)("select",{name:n,id:u||n,className:"w-full bg-white",required:c,onChange:function(e){i&&i(null),e.target.classList.remove("warning"),l&&l(e)},defaultValue:r||void 0,children:t.map((function(e,t){var n=e.payload,s=e.title;return(0,a.jsx)("option",{value:n,selected:!!e.default,children:s},t+1)}))}),(0,a.jsx)(s.Z,{className:"absolute right-2 text-base text-slate-500 pointer-events-none",size:20}),d&&(0,a.jsxs)("div",{className:"info-wrapper absolute -right-10 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10",style:{top:"50%",transform:"translate(0,-50%)"},onMouseEnter:f,onMouseLeave:f,onClick:f,children:[(0,a.jsx)("img",{src:"/images/info-outlined-black.png",alt:"",className:"w-6 h-6 object-contain opacity-60 pointer-events-none"}),(0,a.jsx)("div",{className:"info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid",children:(0,a.jsx)("span",{children:d})}),(0,a.jsx)("div",{className:"absolute -top-2 w-12",style:{height:"45px"}})]})]})]})}catch(h){return console.log("ERROR in FormSelect =>",h),(0,a.jsx)("div",{children:"Form Select Error"})}}},29815:function(e,t,n){n.d(t,{Z:function(){return c}});var a=n(20943);var s=n(13375);var l=n(91566);function c(e){return function(e){if(Array.isArray(e))return(0,a.Z)(e)}(e)||(0,s.Z)(e)||(0,l.Z)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},19169:function(e){e.exports=JSON.parse('["Edit Tables","Update Entries","Create Table","Delete Entries","Delete Tables"]')}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/7200-4c384098300f07db.js b/dsql-app/.local_dist/static/chunks/7200-4c384098300f07db.js new file mode 100644 index 0000000..b235f85 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/7200-4c384098300f07db.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7200],{5467:function(e,t,n){var i=n(64836);t.Z=void 0;var a=i(n(64938)),l=n(85893),s=(0,a.default)([(0,l.jsx)("path",{d:"M7 3h10v1H7zm0 17h10v1H7z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"m22 12-4-4v3h-5v2h5v3l4-4zm-5 6H7V6h10v1h2V3c0-1.1-.9-2-2-2L7 1.01C5.9 1.01 5 1.9 5 3v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2v-4h-2v1zM7 3h10v1H7V3zm10 18H7v-1h10v1z"},"1")],"SendToMobileTwoTone");t.Z=s},57632:function(e,t,n){var i=n(64836);t.Z=void 0;var a=i(n(64938)),l=n(85893),s=(0,a.default)([(0,l.jsx)("path",{d:"M14 5H5v14h14v-9h-5V5zM8 17c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z",opacity:".3"},"0"),(0,l.jsx)("circle",{cx:"8",cy:"8",r:"1"},"1"),(0,l.jsx)("path",{d:"M15 3H5c-1.1 0-1.99.9-1.99 2L3 19c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V9l-6-6zm4 16H5V5h9v5h5v9z"},"2"),(0,l.jsx)("circle",{cx:"8",cy:"12",r:"1"},"3"),(0,l.jsx)("circle",{cx:"8",cy:"16",r:"1"},"4")],"SummarizeTwoTone");t.Z=s},85541:function(e,t,n){var i=n(64836);t.Z=void 0;var a=i(n(64938)),l=n(85893),s=(0,a.default)([(0,l.jsx)("path",{d:"M14.5 9.5C14.5 6.47 12.03 4 9 4S3.5 6.47 3.5 9.5c0 2.47 1.49 3.89 2.35 4.5h6.3c.86-.61 2.35-2.03 2.35-4.5z",opacity:".3"},"0"),(0,l.jsx)("path",{d:"M7 20h4c0 1.1-.9 2-2 2s-2-.9-2-2zm-2-1h8v-2H5v2zm11.5-9.5c0 3.82-2.66 5.86-3.77 6.5H5.27c-1.11-.64-3.77-2.68-3.77-6.5C1.5 5.36 4.86 2 9 2s7.5 3.36 7.5 7.5zm-2 0C14.5 6.47 12.03 4 9 4S3.5 6.47 3.5 9.5c0 2.47 1.49 3.89 2.35 4.5h6.3c.86-.61 2.35-2.03 2.35-4.5zm6.87-2.13L20 8l1.37.63L22 10l.63-1.37L24 8l-1.37-.63L22 6l-.63 1.37zM19 6l.94-2.06L22 3l-2.06-.94L19 0l-.94 2.06L16 3l2.06.94L19 6z"},"1")],"TipsAndUpdatesTwoTone");t.Z=s},76915:function(e,t,n){n.d(t,{Z:function(){return i}});const i=(0,n(45711).Z)("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},58261:function(e,t,n){n.d(t,{Z:function(){return i}});const i=(0,n(45711).Z)("SquareTerminal",[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]])},44114:function(e,t,n){n.d(t,{Z:function(){return l}});var i=n(85893),a=n(8971);n(67294);function l(e){var t=e.selectOptions,n=e.name,l=e.onChangeHandler,s=e.required,c=e.setAlert,o=e.title,r=e.defaultValue,d=e.info,h=e.id;try{var u=function(e){if(!(e.type.match(/enter/i)&&window.innerWidth<1200)){var t=e.target.closest(".info-wrapper"),n=t.querySelector(".info-dropdown");!e.type.match(/leave/i)||n.classList.contains("hidden")?e.type.match(/leave/i)&&n.classList.contains("hidden")||(t&&n.classList.contains("hidden")?n.classList.remove("hidden"):n.classList.add("hidden")):n.classList.add("hidden")}};return(0,i.jsxs)("div",{className:"form-select-block flex items-start flex-col gap-0.5 w-full relative"+(d?" pr-8":""),children:[o&&(0,i.jsxs)("label",{htmlFor:n,children:[o,s?"":" (optional)"]}),(0,i.jsxs)("div",{className:"flex items-center w-full relative",children:[(0,i.jsx)("select",{name:n,id:h||n,className:"w-full bg-white",required:s,onChange:function(e){c&&c(null),e.target.classList.remove("warning"),l&&l(e)},defaultValue:r||void 0,children:t.map((function(e,t){var n=e.payload,a=e.title;return(0,i.jsx)("option",{value:n,selected:!!e.default,children:a},t+1)}))}),(0,i.jsx)(a.Z,{className:"absolute right-2 text-base text-slate-500 pointer-events-none",size:20}),d&&(0,i.jsxs)("div",{className:"info-wrapper absolute -right-10 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10",style:{top:"50%",transform:"translate(0,-50%)"},onMouseEnter:u,onMouseLeave:u,onClick:u,children:[(0,i.jsx)("img",{src:"/images/info-outlined-black.png",alt:"",className:"w-6 h-6 object-contain opacity-60 pointer-events-none"}),(0,i.jsx)("div",{className:"info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid",children:(0,i.jsx)("span",{children:d})}),(0,i.jsx)("div",{className:"absolute -top-2 w-12",style:{height:"45px"}})]})]})]})}catch(p){return console.log("ERROR in FormSelect =>",p),(0,i.jsx)("div",{children:"Form Select Error"})}}},7947:function(e,t,n){n(85893),n(67294)},22434:function(e,t,n){n.d(t,{Z:function(){return o}});var i=n(828),a=n(85893),l=n(67294),s=n(41899),c=n(35922);function o(e){var t=e.content,n=e.language,o=e.style,r=(0,i.Z)(l.useState(!1),2),d=r[0],h=r[1],u=function(e,t){"clickaway"!==t&&h(!1)},p=(0,a.jsx)(l.Fragment,{children:(0,a.jsx)("button",{className:"outlined gray",style:{border:"none",padding:"2px",width:"20px",height:"20px",color:"white"},onClick:u,children:"\u2716"})});return(0,a.jsxs)("pre",{className:"language-".concat(n||"javascript"," w-full overflow-hidden code-block relative max-w-4xl"),style:o||{},children:[(0,a.jsx)("code",{className:"w-full",style:{wordBreak:"break-all"},children:t}),(0,a.jsx)("button",{className:"outlined absolute top-2 right-2 z-20 copy-code hover:opacity-50",style:{padding:"2px",border:"none"},onClick:function(e){navigator.clipboard.writeText(t).then((function(){h(!0)}))},children:(0,a.jsx)(s.Z,{fontSize:"small",color:"action"})}),(0,a.jsx)(c.Z,{open:d,autoHideDuration:2e3,onClose:u,children:(0,a.jsxs)("div",{className:"h-full text-white px-4 py-2 justify-between rounded",style:{maxWidth:"250px",width:"250px",backgroundColor:"#0b8862"},children:[(0,a.jsx)("span",{children:"Code Copied!"}),p]})})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/7901-841b99c96481dd31.js b/dsql-app/.local_dist/static/chunks/7901-841b99c96481dd31.js new file mode 100644 index 0000000..b6e7dff --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/7901-841b99c96481dd31.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7901],{27901:function(e,t,n){n.d(t,{Z:function(){return c}});var r,a,o=n(26042),i=n(85893),l=n(67294);function s(e){var t,n=e.value,r=e.format;if(!n)return 0;try{if("string"===r)t=n.toString().replace(/\D/g,"").replace(/\B(?=(\d{3})+(?!\d))/g,",");else t=parseInt(n.toString().replace(/\D/g,""))}catch(a){t=0,console.log(a)}return t}function u(e){var t,n,r=e.value,a=e.format,o=e.decimals,i=(null===(t=null===r||void 0===r?void 0:r.toString())||void 0===t?void 0:t.match(/^\-/))?"-":"";try{if("string"===a){var l=r.toString().split(".");n=i+l[0].toString().replace(/[^0-9\.]/g,"").replace(/\B(?=(\d{3})+(?!\d))/g,",")+(l[1]?".".concat(o?l[1].substring(0,o):l[1].substring(0,2)):"")}else n=parseFloat(i+r.toString().replace(/[^0-9\.]/g,""))}catch(s){n=0,console.log(s)}return n}function c(e){try{var t=function(e){e.target.value.match(/./)?(e.target.classList.remove("warning"),b&&b(null)):e.target.required&&e.target.classList.add("warning"),T&&(e.target.value=e.target.value.toString().match(/^0+$/)?"0":e.target.value.toString().replace(k?/[^0-9\.]/g:/\D/g,"").replace(/^0*/,"").replace(/\B(?=(\d{3})+(?!\d))/g,",")),h&&h(e),L&&L(e)},n=function(e){if(!(e.type.match(/enter/i)&&window.innerWidth<1200)){var t=e.target.closest(".info-wrapper"),n=t.querySelector(".info-dropdown");!e.type.match(/leave/i)||n.classList.contains("hidden")?e.type.match(/leave/i)&&n.classList.contains("hidden")||(t&&n.classList.contains("hidden")?n.classList.remove("hidden"):n.classList.add("hidden")):n.classList.add("hidden")}},c=function(e){var t,n=k?parseFloat(u({value:(null===(t=_.current)||void 0===t?void 0:t.value)||0}).toString())-(M?parseFloat(M.toString()):20):parseInt(s({value:_.current.value}).toString())-(M||20),r=k?u({value:n,format:"raw"}):s({value:n,format:"raw"});y&&"number"==typeof r&&rj||(_.current.value=n.toString(),V&&V(_.current.value))},p=e.title,f=e.name,v=e.defaultValue,m=e.placeholder,g=e.autoComplete,h=e.onInputHandler,w=e.required,x=e.inputType,b=e.setAlert,S=e.prefix,y=e.minValue,j=e.maxValue,I=e.encrypted,T=e.numberText,N=e.appendCurrency,F=e.elementRef,L=e.onChangeHandler,D=e.value,M=e.step,k=e.decimal,C=e.pattern,E=e.info,W=e.fontSize,R=e.maxWidth,V=e.setValue,q=e.id,_=F||l.useRef();return(0,i.jsxs)("div",{className:"form-input-wrapper flex flex-col items-start gap-0.5 w-full relative",style:(0,o.Z)({},R?{maxWidth:R}:{}),children:[p&&(0,i.jsx)("label",{htmlFor:f,children:p}),(0,i.jsxs)("div",{className:"flex items-center w-full relative",children:[S&&(0,i.jsx)("div",{className:"absolute left-4 bottom-2 text-lg",children:S}),(0,i.jsx)("input",{type:x||"text",name:f,id:q||f,ref:_,placeholder:m||(p||""),autoComplete:g,onInput:function(e){t(e)},onChange:function(e){t(e)},value:D||void 0,defaultValue:D?void 0:v||void 0,pattern:C?C.toString():void 0,required:w||!1,style:(0,o.Z)({},W?{fontSize:W}:{},S?{paddingLeft:"35px"}:{}),min:y,max:j,"data-encrypted":I||null,"data-appendcurrency":N||null,className:"bg-white"+(E?" pr-16":"")}),T&&(0,i.jsxs)("div",{className:"absolute gap-1"+(E?" right-12":" right-4"),style:{top:"50%",transform:"translate(0,-50%)"},children:[(0,i.jsx)("span",{className:"number-text-button w-10 md:w-8 h-10 md:h-8 rounded-full bg-slate-100 dark:bg-slate-800 flex items-center justify-center cursor-pointer hover:bg-slate-200 text-2xl font-semibold touch-none",onMouseDown:function(e){e.preventDefault(),window.innerWidth<1200||(c(),r=setTimeout((function(){a=setInterval((function(){c()}),50)}),200))},onTouchStart:function(e){e.preventDefault(),window.innerWidth>=1200||(c(),r=setTimeout((function(){a=setInterval((function(){c()}),50)}),200))},onMouseUp:function(e){window.clearTimeout(r),window.clearInterval(a)},onTouchEnd:function(e){window.clearTimeout(r),window.clearInterval(a)},onMouseLeave:function(e){window.clearTimeout(r),window.clearInterval(a)},onTouchMove:function(e){e.preventDefault()},children:(0,i.jsx)("span",{className:"pointer-events-none",children:"-"})}),(0,i.jsx)("span",{className:"number-text-button w-10 md:w-8 h-10 md:h-8 rounded-full bg-slate-100 dark:bg-slate-800 flex items-center justify-center cursor-pointer hover:bg-slate-200 text-2xl font-semibold touch-none",onMouseDown:function(e){e.preventDefault(),window.innerWidth<1200||(d(),r=setTimeout((function(){a=setInterval((function(){d()}),50)}),200))},onTouchStart:function(e){e.preventDefault(),window.innerWidth>=1200||(d(),r=setTimeout((function(){a=setInterval((function(){d()}),50)}),200))},onMouseUp:function(e){window.clearTimeout(r),window.clearInterval(a)},onTouchEnd:function(e){window.clearTimeout(r),window.clearInterval(a)},onMouseLeave:function(e){window.clearTimeout(r),window.clearInterval(a)},children:(0,i.jsx)("span",{className:"pointer-events-none",children:"+"})})]}),E&&(0,i.jsxs)("div",{className:"info-wrapper absolute right-2 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10",style:{top:"50%",transform:"translate(0,-50%)"},onMouseEnter:n,onMouseLeave:n,onClick:n,children:[(0,i.jsx)("img",{src:"/images/info-outlined-black.png",alt:"",className:"w-6 h-6 object-contain opacity-60 pointer-events-none"}),(0,i.jsx)("div",{className:"info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid",children:(0,i.jsx)("span",{children:E})}),(0,i.jsx)("div",{className:"absolute -top-2 w-12",style:{height:"45px"}})]})]})]})}catch(z){return console.log("ERROR in FormInput =>",z),(0,i.jsx)("div",{children:"Form Input Error"})}}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/8264-5901ddfeb3cb03ce.js b/dsql-app/.local_dist/static/chunks/8264-5901ddfeb3cb03ce.js new file mode 100644 index 0000000..6e0b6e3 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/8264-5901ddfeb3cb03ce.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8264],{58264:function(e,a,l){l.d(a,{Z:function(){return c},w:function(){return o}});var n=l(85893),t=l(67294),s=l(46734),i=l(94986);function c(e){var a,l,c,r=e.database,d=e.tables,u=e.setTargetTable,f=e.confirmedDelegetedUser,m=e.query,p=e.user;null===f||void 0===f||f.delegated,null===f||void 0===f||null===(a=f.priviledges)||void 0===a||a.match(/Edit Tables/i),null===f||void 0===f||null===(l=f.priviledges)||void 0===l||l.match(/Delete Tables/i),null===f||void 0===f||null===(c=f.priviledges)||void 0===c||c.match(/Create Tables/i);return(0,n.jsxs)(t.Fragment,{children:[r.active_clone&&p?(0,n.jsx)(i.Z,{database:r,user:p}):(0,n.jsx)(n.Fragment,{}),r.remote_connected?(0,n.jsx)(o,{database:r}):(0,n.jsx)(n.Fragment,{}),(0,n.jsxs)("section",{className:"paper gray",children:[d&&d[0]?(0,n.jsxs)("div",{className:"flex-wrap gap-4 justify-between w-full",children:[(0,n.jsx)("h2",{className:"text-xl m-0",children:"Tables"}),(0,n.jsx)("a",{href:"/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(r.db_slug,"/tables"),className:"button outlined gray small-text",children:"See All Tables"})]}):(0,n.jsx)("h2",{className:"text-xl m-0",children:"This Database is empty"}),(0,n.jsx)("hr",{}),p?(0,n.jsx)(s.Z,{database:r,tables:d,setTargetTable:u,confirmedDelegetedUser:f,query:m,user:p}):null]})]})}function o(e){var a,l=e.database;return(0,n.jsx)("div",{className:"info green",children:(0,n.jsxs)("span",{className:"text font-normal",children:["This database is an active clone of"," ",(0,n.jsx)("b",{children:null===(a=l.remote_db_full_name)||void 0===a?void 0:a.replace(/datasquirel_user_\d+_/,"")})," ","on"," ",(0,n.jsx)("a",{className:"font-bold text-inherit",href:l.remote_connection_host,target:"_blank",children:l.remote_connection_host})," ","Host"]})})}},46734:function(e,a,l){l.d(a,{Z:function(){return w}});var n=l(85893),t=l(67294),s=l(79230),i=l(25472),c=l(45449),o=l(80173),r=l(64998);function d(e){var a,l,d,u,f=e.table,m=e.setTargetTable,p=e.database,h=e.confirmedDelegetedUser,v=(e.query,e.icons,e.user),b=null===h||void 0===h?void 0:h.delegated,x=null===h||void 0===h||null===(a=h.priviledges)||void 0===a?void 0:a.match(/Edit Tables/i),g=null===h||void 0===h||null===(l=h.priviledges)||void 0===l?void 0:l.match(/Delete Tables/i),j=(null===h||void 0===h||null===(d=h.priviledges)||void 0===d||d.match(/Create Table/i),p.active_clone,p.active_clone_parent_db),N=p.remote_connected;return(0,n.jsxs)("a",{href:"/admin/".concat(null===v||void 0===v?void 0:v.id,"/databases/").concat(p.db_slug,"/tables/").concat(f.table_slug),className:"card w-full items-center justify-between py-4"+((null===f||void 0===f?void 0:f.child_table)?" green":""),onClick:function(e){e.target.closest(".db-list-item-actions-block")&&e.preventDefault()},children:[(0,n.jsxs)("div",{className:"flex-wrap items-center flex",children:[(0,n.jsx)(o.Z,{fontSize:"small",className:"opacity-50",color:"action"}),(0,n.jsx)("span",{className:"title",style:{fontSize:"16px"},children:f.table_name}),(0,n.jsxs)("span",{className:"text-sm text-slate-400",children:["Created: ",null===(u=f.date_created)||void 0===u?void 0:u.substring(0,21)]})]}),(0,n.jsxs)("div",{className:"flex-wrap",children:[(0,n.jsx)("div",{className:"db-list-item-actions-block flex-wrap",children:(0,n.jsxs)(c.Z,{children:[(0,n.jsx)(s.Z,{slugText:f.table_slug||"",outlined:!0}),(!b||b&&x)&&!j&&!N&&(0,n.jsx)(t.Fragment,{children:(0,n.jsx)("div",{className:"button outlined light-gray small-text",onClick:function(e){window.location.pathname="/admin/".concat(null===v||void 0===v?void 0:v.id,"/databases/").concat(p.db_slug,"/tables/").concat(f.table_slug,"/edit-table")},children:(0,n.jsx)("span",{children:"Edit"})})}),!j&&!f.child_table&&(0,n.jsx)("div",{className:"button outlined light-gray small-text",onClick:function(e){window.location.href="/admin/".concat(null===v||void 0===v?void 0:v.id,"/databases/").concat(p.db_slug,"/tables/add-table?clone=true&clone_db=").concat(p.db_slug,"&clone_table=").concat(f.table_slug)},children:(0,n.jsx)("span",{children:"Clone"})}),(!b||b&&g)&&!j&&!N&&(0,n.jsx)("div",{className:"button outlined light-gray small-text",onClick:function(e){m(f),(0,i.Mw)("delete-table-confirmation")},children:(0,n.jsx)("span",{children:"Delete"})})]})}),(0,n.jsx)(r.Z,{className:"text-slate-600",size:20})]})]})}var u=l(63749),f=l(96673),m=l(29277),p=l(66022),h=l(17621),v=l(828),b=l(74458),x=l(86729),g=l(53314),j=l(95264);function N(e){var a=e.database,l=t.useRef(),s=(0,v.Z)(t.useState(!1),2),i=s[0],c=s[1];return(0,n.jsxs)(t.Fragment,{children:[(0,n.jsx)("input",{type:"file",name:"sql-file-input",id:"sql-file-input",accept:".sql",className:"hidden",ref:l}),(0,n.jsxs)("button",{className:"flex-col normal-weight outlined gray dashed w-full p-8 relative",onClick:function(e){var n,t;null===(n=l.current)||void 0===n||n.addEventListener("change",(function(e){var l,n=e.target;(null===(l=n.files)||void 0===l?void 0:l[0])?(0,g.Z)({inputFile:n.files[0]}).then((function(e){window.confirm("Use this file '".concat(e.fileName,"' as your import file?"))&&(c(!0),(0,x.Z)("/api/importDatabase",{method:"post",body:{database:a,fileBase64:e.fileBase64}},!0).then((function(e){e.success?window.location.reload():window.alert("Import Failed!"),setTimeout((function(){c(!1)}),1e3)})))})):window.alert("No FIles selected")})),null===(t=l.current)||void 0===t||t.click()},children:[i&&(0,n.jsx)(j.Z,{}),(0,n.jsx)("span",{className:"text-slate-400",children:"Do you have an SQL file already?"}),(0,n.jsx)(b.Z,{sx:{fontSize:80},className:"opacity-20"}),(0,n.jsx)("span",{className:"",children:"Import Database"})]})]})}var _=l(57632);function y(e){var a=e.database,l=t.useRef(),s=(0,v.Z)(t.useState(!1),2),i=s[0],c=s[1];return(0,n.jsxs)(t.Fragment,{children:[(0,n.jsx)("input",{type:"file",name:"json_file_input",id:"json_file_input",accept:".json",className:"hidden",ref:l}),(0,n.jsxs)("button",{className:"flex-col normal-weight outlined gray dashed w-full p-8 relative",onClick:function(e){var n,t;null===(n=l.current)||void 0===n||n.addEventListener("change",(function(e){var l,n=e.target;(null===(l=n.files)||void 0===l?void 0:l[0])?(0,g.Z)({inputFile:n.files[0]}).then((function(e){window.confirm("Use this file '".concat(e.fileName,"' as your import file?"))&&(c(!0),(0,x.Z)("/api/importDatabaseSchema",{method:"post",body:{database:a,fileBase64:e.fileBase64}},!0).then((function(e){e.success?window.location.reload():window.alert("Import Failed!"),setTimeout((function(){c(!1)}),1e3)})))})):window.alert("No FIles selected")})),null===(t=l.current)||void 0===t||t.click()},children:[i&&(0,n.jsx)(j.Z,{}),(0,n.jsx)("span",{className:"text-slate-400",children:"Do you have a JSON schema?"}),(0,n.jsx)(_.Z,{sx:{fontSize:80},className:"opacity-20"}),(0,n.jsx)("span",{className:"",children:"Import JSON schema"})]})]})}function w(e){var a,l,s,i=e.database,c=e.tables,o=e.setTargetTable,r=e.confirmedDelegetedUser,v=e.query,b=e.user,x=null===r||void 0===r?void 0:r.delegated,g=(null===r||void 0===r||null===(a=r.priviledges)||void 0===a||a.match(/Edit Tables/i),null===r||void 0===r||null===(l=r.priviledges)||void 0===l||l.match(/Delete Tables/i),null===r||void 0===r||null===(s=r.priviledges)||void 0===s?void 0:s.match(/Create Table/i)),j=!(c&&c[0]||x)||!(c&&c[0]||!x||!g),_=(i.active_clone,i.active_clone_parent_db),w=i.remote_connected;return(0,n.jsx)(t.Fragment,{children:(0,n.jsxs)("div",{className:"w-full flex-col",children:[c&&c[0]&&c.map((function(e){return(0,n.jsx)(d,{table:e,setTargetTable:o,database:i,confirmedDelegetedUser:r,query:v,icons:{edit:u.Z,duplicate:f.Z,delete:m.Z,copy:p.Z},user:b},e.id)})),j&&!_&&!w&&(0,n.jsx)(t.Fragment,{children:(0,n.jsxs)("div",{className:"w-full grid grid-cols-1 xl:grid-cols-2 items-stretch gap-6",children:[(0,n.jsxs)("a",{href:"/admin/".concat(null===b||void 0===b?void 0:b.id,"/databases/").concat(i.db_slug,"/tables/add-table"),className:"button flex-col normal-weight outlined gray dashed border-dotted w-full p-8",children:[(0,n.jsx)("span",{className:"text-slate-400",children:"No Tables Created."}),(0,n.jsx)(h.Z,{sx:{fontSize:100},className:"opacity-20"}),(0,n.jsx)("span",{className:"",children:"Add Table"})]}),(0,n.jsx)(N,{database:i}),(0,n.jsx)(y,{database:i})]})}),(!c||!c[0])&&x&&(0,n.jsx)("span",{className:"text-sm bg-slate-100 px-3 py-2 rounded w-full flex items-center justify-center text-slate-400",children:"Tables will show here once the owner of the database adds one"})]})})}},94986:function(e,a,l){l.d(a,{Z:function(){return t}});var n=l(85893);l(67294);function t(e){var a,l=e.database,t=e.user,s=null===(a=l.active_clone_parent_db)||void 0===a?void 0:a.replace(/datasquirel_user_\d+_/,""),i="/admin/".concat(null===t||void 0===t?void 0:t.id,"/databases/").concat(s);return(0,n.jsx)("div",{className:"info green",children:(0,n.jsxs)("span",{className:"text font-normal",children:["This database is an active clone of"," ",(0,n.jsx)("b",{children:(0,n.jsx)("a",{href:i,target:"_blank",className:"query-url",children:s})})]})})}},25472:function(e,a,l){l.d(a,{Mw:function(){return c},ZP:function(){return i},j4:function(){return o}});var n=l(85893),t=l(41352),s=l(67294);function i(e){var a=e.children,l=e.title,i=e.data,c=e.fullPage,r=e.wrapperClasses,d=e.closePopupDispatch,u=e.wrapperStyle,f=e.noContainer;return c?(0,n.jsxs)("div",{className:"popup-bg overflow-hidden "+(r||""),"data-popupid":l||null,style:u,children:[f?(0,n.jsx)(s.Fragment,{children:a}):(0,n.jsx)("div",{className:"relative w-full h-full z-50","data-data":i?JSON.stringify(i):"",children:a}),(0,n.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(e){o(),d&&d()},children:(0,n.jsx)(t.Z,{color:"white",size:20})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){o(),d&&d()}})]}):(0,n.jsxs)("div",{className:"popup-bg","data-popupid":l||null,children:[f?(0,n.jsx)(s.Fragment,{children:a}):(0,n.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":i?JSON.stringify(i):"",children:[a,(0,n.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(e){o(),d&&d()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),f&&(0,n.jsx)("button",{className:"gray popup-cancel-button",onClick:function(e){o(),d&&d()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){o(),d&&d()}})]})}function c(e,a){var l=document.querySelector("[data-popupid='".concat(e,"']"));l&&(l.style.display="flex",a&&a(l))}function o(e){document.querySelectorAll("[data-popupid]").forEach((function(e){e.style.display="none"})),e&&e()}},53314:function(e,a,l){l.d(a,{Z:function(){return s}});var n=l(47568),t=l(97582);function s(e){return i.apply(this,arguments)}function i(){return(i=(0,n.Z)((function(e){var a,l,n,s;return(0,t.__generator)(this,(function(t){switch(t.label){case 0:a=e.inputFile,t.label=1;case 1:return t.trys.push([1,3,,4]),l=a.name.replace(/\..*/,""),[4,new Promise((function(e,l){var n=new FileReader;n.readAsDataURL(a),n.onload=function(){e(n.result)},n.onerror=function(e){console.log("Error: ",e.message)}}))];case 2:return[2,{fileBase64:(n=t.sent()).replace(/.*?base64,/,""),fileBase64Full:n,fileName:l,fileSize:a.size,fileType:a.type}];case 3:return s=t.sent(),console.log("Image Processing Error! =>",s.message),[2,{fileBase64:null,fileBase64Full:null,fileName:a.name,fileSize:null,fileType:null}];case 4:return[2]}}))}))).apply(this,arguments)}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/8374-f28680e628b18bd5.js b/dsql-app/.local_dist/static/chunks/8374-f28680e628b18bd5.js new file mode 100644 index 0000000..99a0345 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/8374-f28680e628b18bd5.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8374],{98374:function(e,n,r){r.d(n,{Z:function(){return t}});r(828),r(85893),r(67294),r(47568),r(97582),r(86729);r(29137);function t(e){e.user,e.userType,e.setLoading;return null}},29137:function(e,n,r){r.d(n,{Z:function(){return u}});var t=r(47568),s=r(97582);function u(){return c.apply(this,arguments)}function c(){return(c=(0,t.Z)((function(){var e,n;return(0,s.__generator)(this,(function(r){switch(r.label){case 0:return r.trys.push([0,4,,5]),[4,caches.keys()];case 1:return(e=r.sent())[0]?[4,Promise.all(e.map((function(e){return caches.delete(e)})))]:[3,3];case 2:r.sent(),r.label=3;case 3:return[3,5];case 4:return n=r.sent(),console.log("Error in clearing cache =>",n.message),[3,5];case 5:return[2]}}))}))).apply(this,arguments)}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/8446-a36a685092b53a06.js b/dsql-app/.local_dist/static/chunks/8446-a36a685092b53a06.js new file mode 100644 index 0000000..c11f7fe --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/8446-a36a685092b53a06.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8446],{30073:function(e,t,o){var n=o(64836);t.Z=void 0;var r=n(o(64938)),i=o(85893),a=(0,r.default)([(0,i.jsx)("path",{d:"M8 16h12V4H8v12zm2-7h3V6h2v3h3v2h-3v3h-2v-3h-3V9z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M4 22h14v-2H4V6H2v14c0 1.1.9 2 2 2zM8 2c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2H8zm12 14H8V4h12v12zm-7-2h2v-3h3V9h-3V6h-2v3h-3v2h3z"},"1")],"LibraryAddTwoTone");t.Z=a},9404:function(e,t,o){o.d(t,{Z:function(){return n}});const n=(0,o(45711).Z)("Ellipsis",[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]])},62841:function(e,t,o){var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,o=1,n=arguments.length;ol?l-e:r,n=(n=nd?d-e:n,n=Number.isNaN(n)?0:n,r=Number.isNaN(r)?0:r,i){case"right":return{borderTop:"".concat(a,"px solid transparent"),borderBottom:"".concat(a,"px solid transparent"),borderRight:"".concat(a,"px solid ").concat(c),left:0,top:n};case"left":return{borderTop:"".concat(a,"px solid transparent"),borderBottom:"".concat(a,"px solid transparent"),borderLeft:"".concat(a,"px solid ").concat(c),right:0,top:n};case"bottom":return{borderLeft:"".concat(a,"px solid transparent"),borderRight:"".concat(a,"px solid transparent"),borderBottom:"".concat(a,"px solid ").concat(c),top:0,left:r};case"top":return{borderLeft:"".concat(a,"px solid transparent"),borderRight:"".concat(a,"px solid transparent"),borderTop:"".concat(a,"px solid ").concat(c),bottom:0,left:r};default:return{display:"hidden"}}}())}),[c,a,t.height,t.left,t.top,t.width,o.height,o.left,o.top,o.width,i])}}},83423:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.useElementRef=void 0;var n=o(67294),r=o(62319);t.useElementRef=function(e){var t=e.containerClassName,o=e.containerStyle,i=(0,n.useRef)(),a=(0,n.useState)((function(){return(0,r.createContainer)({containerStyle:o,containerClassName:t})}))[0];return(0,n.useLayoutEffect)((function(){a.className=t}),[t,a]),(0,n.useLayoutEffect)((function(){Object.assign(a.style,o)}),[o,a]),i.current=a,i}},9270:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.useHandlePrevValues=void 0;var n=o(67294);t.useHandlePrevValues=function(e){var t=(0,n.useRef)(e.positions),o=(0,n.useRef)(e.reposition),r=(0,n.useRef)(e.transformMode),i=(0,n.useRef)(e.transform),a=(0,n.useRef)(e.boundaryElement),c=(0,n.useRef)(e.boundaryInset),u=(0,n.useCallback)((function(){t.current=e.positions,o.current=e.reposition,r.current=e.transformMode,i.current=e.transform,a.current=e.boundaryElement,c.current=e.boundaryInset}),[e.boundaryElement,e.boundaryInset,e.positions,e.reposition,e.transform,e.transformMode]);return{prev:{positions:t.current,reposition:o.current,transformMode:r.current,transform:i.current,boundaryElement:a.current,boundaryInset:c.current},updatePrevValues:u}}},16444:function(e,t,o){Object.defineProperty(t,"__esModule",{value:!0}),t.useMemoizedArray=void 0;var n=o(67294);t.useMemoizedArray=function(e){var t=(0,n.useRef)(e);return(0,n.useMemo)((function(){if(t.current===e)return t.current;if(t.current.length!==e.length)return t.current=e,e;for(var o=0;o0&&"react-tiny-popover-container"!==l?"react-tiny-popover-container ".concat(l):"react-tiny-popover-container",containerStyle:a}),w=(0,n.useCallback)((function(e){var n,i,a=void 0===e?{}:e,c=a.positionIndex,l=void 0===c?0:c,P=a.parentRect,C=void 0===P?d.getBoundingClientRect():P,E=a.childRect,M=void 0===E?null===(n=null===o||void 0===o?void 0:o.current)||void 0===n?void 0:n.getBoundingClientRect():E,x=a.scoutRect,_=void 0===x?null===(i=null===y||void 0===y?void 0:y.current)||void 0===i?void 0:i.getBoundingClientRect():x,j=a.popoverRect,O=void 0===j?R.current.getBoundingClientRect():j,N=a.boundaryRect,T=void 0===N?m===d?C:m.getBoundingClientRect():N;if(M&&C&&t){if(s&&"absolute"===p){var A="function"===typeof s?s({childRect:M,popoverRect:O,parentRect:C,boundaryRect:T,padding:v,align:f,nudgedTop:0,nudgedLeft:0,boundaryInset:g,violations:r.EMPTY_RECT,hasViolations:!1}):s,k=A.top,L=A.left,V=Math.round(C.left+L-_.left),I=Math.round(C.top+k-_.top);return R.current.style.transform="translate(".concat(V,"px, ").concat(I,"px)"),void b({childRect:M,popoverRect:(0,r.createRect)({left:V,top:I,width:O.width,height:O.height}),parentRect:C,boundaryRect:T,padding:v,align:f,transform:{top:k,left:L},nudgedTop:0,nudgedLeft:0,boundaryInset:g,violations:r.EMPTY_RECT,hasViolations:!1})}var S=l===u.length,z=S?u[0]:u[l],B=(0,r.getNewPopoverRect)({childRect:M,popoverRect:O,boundaryRect:T,position:z,align:f,padding:v,reposition:h},g),Y=B.rect;if(B.boundaryViolation&&h&&!S)w({positionIndex:l+1,childRect:M,popoverRect:O,parentRect:C,boundaryRect:T});else{var H=Y.top,F=Y.left,q=Y.width,Z=Y.height,D=h&&!S,G=(0,r.getNudgedPopoverRect)(Y,T,g),J=G.left,K=G.top,Q=H,U=F;D&&(Q=K,U=J),Q=Math.round(Q-_.top),U=Math.round(U-_.left),R.current.style.transform="translate(".concat(U,"px, ").concat(Q,"px)");var W={top:T.top+g-Q,left:T.left+g-U,right:U+q-T.right+g,bottom:Q+Z-T.bottom+g},X={childRect:M,popoverRect:(0,r.createRect)({left:U,top:Q,width:q,height:Z}),parentRect:C,boundaryRect:T,position:z,align:f,padding:v,nudgedTop:K-H,nudgedLeft:J-F,boundaryInset:g,violations:{top:W.top<=0?0:W.top,left:W.left<=0?0:W.left,right:W.right<=0?0:W.right,bottom:W.bottom<=0?0:W.bottom},hasViolations:W.top>0||W.left>0||W.right>0||W.bottom>0};if(s){b(X);var $="function"===typeof s?s(X):s,ee=$.top,te=$.left;R.current.style.transform="translate(".concat(Math.round(U+(null!==te&&void 0!==te?te:0)),"px, ").concat(Math.round(Q+(null!==ee&&void 0!==ee?ee:0)),"px)"),X.nudgedLeft+=null!==te&&void 0!==te?te:0,X.nudgedTop+=null!==ee&&void 0!==ee?ee:0,X.transform={top:ee,left:te}}b(X)}}}),[d,o,y,R,m,t,s,p,u,f,v,h,g,b]);return{positionPopover:w,popoverRef:R,scoutRef:y}}},62319:function(e,t){var o=this&&this.__assign||function(){return o=Object.assign||function(e){for(var t,o=1,n=arguments.length;oc.right-o||"bottom"===n&&d.bottom>c.bottom-o)}};t.getNudgedPopoverRect=function(e,n,r){var i=n.top+r,a=n.left+r,c=n.right-r,u=n.bottom-r,l=e.topu?u-e.height:l;var d=e.leftc?c-e.width:d,(0,t.createRect)(o(o({},e),{top:l,left:d}))}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/8473-1a1faf3d4d34beef.js b/dsql-app/.local_dist/static/chunks/8473-1a1faf3d4d34beef.js new file mode 100644 index 0000000..141b1bd --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/8473-1a1faf3d4d34beef.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8473],{42065:function(e,n,t){var r=t(64836);n.Z=void 0;var o=r(t(64938)),i=t(85893),a=(0,o.default)((0,i.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");n.Z=a},41899:function(e,n,t){var r=t(64836);n.Z=void 0;var o=r(t(64938)),i=t(85893),a=(0,o.default)((0,i.jsx)("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"}),"ContentCopy");n.Z=a},35922:function(e,n,t){t.d(n,{Z:function(){return $}});var r=t(63366),o=t(87462),i=t(67294),a=t(94780),s=t(78987),c=t(33703),u=t(59948),l=t(82690),d=t(85893);function f(e){return e.substring(2).toLowerCase()}function m(e){const{children:n,disableReactTree:t=!1,mouseEvent:r="onClick",onClickAway:o,touchEvent:a="onTouchEnd"}=e,s=i.useRef(!1),m=i.useRef(null),g=i.useRef(!1),p=i.useRef(!1);i.useEffect((()=>(setTimeout((()=>{g.current=!0}),0),()=>{g.current=!1})),[]);const h=(0,c.Z)(n.ref,m),v=(0,u.Z)((e=>{const n=p.current;p.current=!1;const r=(0,l.Z)(m.current);if(!g.current||!m.current||"clientX"in e&&function(e,n){return n.documentElement.clientWidth-1:!r.documentElement.contains(e.target)||m.current.contains(e.target),i||!t&&n||o(e)})),E=e=>t=>{p.current=!0;const r=n.props[e];r&&r(t)},Z={ref:h};return!1!==a&&(Z[a]=E(a)),i.useEffect((()=>{if(!1!==a){const e=f(a),n=(0,l.Z)(m.current),t=()=>{s.current=!0};return n.addEventListener(e,v),n.addEventListener("touchmove",t),()=>{n.removeEventListener(e,v),n.removeEventListener("touchmove",t)}}}),[v,a]),!1!==r&&(Z[r]=E(r)),i.useEffect((()=>{if(!1!==r){const e=f(r),n=(0,l.Z)(m.current);return n.addEventListener(e,v),()=>{n.removeEventListener(e,v)}}}),[v,r]),(0,d.jsx)(i.Fragment,{children:i.cloneElement(n,Z)})}var g=t(30437);var p=t(2641),h=t(2734),v=t(54502),E=t(98216),Z=t(84527),y=t(30577),x=t(51705);const w=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function C(e){return`scale(${e}, ${e**2})`}const b={entering:{opacity:1,transform:C(1)},entered:{opacity:1,transform:"none"}},k="undefined"!==typeof navigator&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),L=i.forwardRef((function(e,n){const{addEndListener:t,appear:a=!0,children:s,easing:c,in:u,onEnter:l,onEntered:f,onEntering:m,onExit:g,onExited:p,onExiting:v,style:E,timeout:L="auto",TransitionComponent:R=Z.ZP}=e,S=(0,r.Z)(e,w),O=i.useRef(),T=i.useRef(),P=(0,h.Z)(),M=i.useRef(null),j=(0,x.Z)(M,s.ref,n),z=e=>n=>{if(e){const t=M.current;void 0===n?e(t):e(t,n)}},H=z(m),A=z(((e,n)=>{(0,y.n)(e);const{duration:t,delay:r,easing:o}=(0,y.C)({style:E,timeout:L,easing:c},{mode:"enter"});let i;"auto"===L?(i=P.transitions.getAutoHeightDuration(e.clientHeight),T.current=i):i=t,e.style.transition=[P.transitions.create("opacity",{duration:i,delay:r}),P.transitions.create("transform",{duration:k?i:.666*i,delay:r,easing:o})].join(","),l&&l(e,n)})),D=z(f),B=z(v),N=z((e=>{const{duration:n,delay:t,easing:r}=(0,y.C)({style:E,timeout:L,easing:c},{mode:"exit"});let o;"auto"===L?(o=P.transitions.getAutoHeightDuration(e.clientHeight),T.current=o):o=n,e.style.transition=[P.transitions.create("opacity",{duration:o,delay:t}),P.transitions.create("transform",{duration:k?o:.666*o,delay:k?t:t||.333*o,easing:r})].join(","),e.style.opacity=0,e.style.transform=C(.75),g&&g(e)})),_=z(p);return i.useEffect((()=>()=>{clearTimeout(O.current)}),[]),(0,d.jsx)(R,(0,o.Z)({appear:a,in:u,nodeRef:M,onEnter:A,onEntered:D,onEntering:H,onExit:N,onExited:_,onExiting:B,addEndListener:e=>{"auto"===L&&(O.current=setTimeout(e,T.current||0)),t&&t(M.current,e)},timeout:"auto"===L?null:L},S,{children:(e,n)=>i.cloneElement(s,(0,o.Z)({style:(0,o.Z)({opacity:0,transform:C(.75),visibility:"exited"!==e||u?void 0:"hidden"},b[e],E,s.props.style),ref:j},n))}))}));L.muiSupportAuto=!0;var R=L,S=t(90512),O=t(41796),T=t(90629),P=t(1588),M=t(34867);function j(e){return(0,M.Z)("MuiSnackbarContent",e)}(0,P.Z)("MuiSnackbarContent",["root","message","action"]);const z=["action","className","message","role"],H=(0,p.ZP)(T.Z,{name:"MuiSnackbarContent",slot:"Root",overridesResolver:(e,n)=>n.root})((({theme:e})=>{const n="light"===e.palette.mode?.8:.98,t=(0,O._4)(e.palette.background.default,n);return(0,o.Z)({},e.typography.body2,{color:e.vars?e.vars.palette.SnackbarContent.color:e.palette.getContrastText(t),backgroundColor:e.vars?e.vars.palette.SnackbarContent.bg:t,display:"flex",alignItems:"center",flexWrap:"wrap",padding:"6px 16px",borderRadius:(e.vars||e).shape.borderRadius,flexGrow:1,[e.breakpoints.up("sm")]:{flexGrow:"initial",minWidth:288}})})),A=(0,p.ZP)("div",{name:"MuiSnackbarContent",slot:"Message",overridesResolver:(e,n)=>n.message})({padding:"8px 0"}),D=(0,p.ZP)("div",{name:"MuiSnackbarContent",slot:"Action",overridesResolver:(e,n)=>n.action})({display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:16,marginRight:-8});var B=i.forwardRef((function(e,n){const t=(0,v.Z)({props:e,name:"MuiSnackbarContent"}),{action:i,className:s,message:c,role:u="alert"}=t,l=(0,r.Z)(t,z),f=t,m=(e=>{const{classes:n}=e;return(0,a.Z)({root:["root"],action:["action"],message:["message"]},j,n)})(f);return(0,d.jsxs)(H,(0,o.Z)({role:u,square:!0,elevation:6,className:(0,S.Z)(m.root,s),ownerState:f,ref:n},l,{children:[(0,d.jsx)(A,{className:m.message,ownerState:f,children:c}),i?(0,d.jsx)(D,{className:m.action,ownerState:f,children:i}):null]}))}));function N(e){return(0,M.Z)("MuiSnackbar",e)}(0,P.Z)("MuiSnackbar",["root","anchorOriginTopCenter","anchorOriginBottomCenter","anchorOriginTopRight","anchorOriginBottomRight","anchorOriginTopLeft","anchorOriginBottomLeft"]);const _=["onEnter","onExited"],W=["action","anchorOrigin","autoHideDuration","children","className","ClickAwayListenerProps","ContentProps","disableWindowBlurListener","message","onBlur","onClose","onFocus","onMouseEnter","onMouseLeave","open","resumeHideDuration","TransitionComponent","transitionDuration","TransitionProps"],I=(0,p.ZP)("div",{name:"MuiSnackbar",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,n[`anchorOrigin${(0,E.Z)(t.anchorOrigin.vertical)}${(0,E.Z)(t.anchorOrigin.horizontal)}`]]}})((({theme:e,ownerState:n})=>(0,o.Z)({zIndex:(e.vars||e).zIndex.snackbar,position:"fixed",display:"flex",left:8,right:8,justifyContent:"center",alignItems:"center"},"top"===n.anchorOrigin.vertical?{top:8}:{bottom:8},"left"===n.anchorOrigin.horizontal&&{justifyContent:"flex-start"},"right"===n.anchorOrigin.horizontal&&{justifyContent:"flex-end"},{[e.breakpoints.up("sm")]:(0,o.Z)({},"top"===n.anchorOrigin.vertical?{top:24}:{bottom:24},"center"===n.anchorOrigin.horizontal&&{left:"50%",right:"auto",transform:"translateX(-50%)"},"left"===n.anchorOrigin.horizontal&&{left:24,right:"auto"},"right"===n.anchorOrigin.horizontal&&{right:24,left:"auto"})})));var $=i.forwardRef((function(e,n){const t=(0,v.Z)({props:e,name:"MuiSnackbar"}),c=(0,h.Z)(),l={enter:c.transitions.duration.enteringScreen,exit:c.transitions.duration.leavingScreen},{action:f,anchorOrigin:{vertical:p,horizontal:Z}={vertical:"bottom",horizontal:"left"},autoHideDuration:y=null,children:x,className:w,ClickAwayListenerProps:C,ContentProps:b,disableWindowBlurListener:k=!1,message:L,open:S,TransitionComponent:O=R,transitionDuration:T=l,TransitionProps:{onEnter:P,onExited:M}={}}=t,j=(0,r.Z)(t.TransitionProps,_),z=(0,r.Z)(t,W),H=(0,o.Z)({},t,{anchorOrigin:{vertical:p,horizontal:Z},autoHideDuration:y,disableWindowBlurListener:k,TransitionComponent:O,transitionDuration:T}),A=(e=>{const{classes:n,anchorOrigin:t}=e,r={root:["root",`anchorOrigin${(0,E.Z)(t.vertical)}${(0,E.Z)(t.horizontal)}`]};return(0,a.Z)(r,N,n)})(H),{getRootProps:D,onClickAway:$}=function(e={}){const{autoHideDuration:n=null,disableWindowBlurListener:t=!1,onClose:r,open:a,resumeHideDuration:s}=e,c=i.useRef();i.useEffect((()=>{if(a)return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)};function e(e){e.defaultPrevented||"Escape"!==e.key&&"Esc"!==e.key||null==r||r(e,"escapeKeyDown")}}),[a,r]);const l=(0,u.Z)(((e,n)=>{null==r||r(e,n)})),d=(0,u.Z)((e=>{r&&null!=e&&(clearTimeout(c.current),c.current=setTimeout((()=>{l(null,"timeout")}),e))}));i.useEffect((()=>(a&&d(n),()=>{clearTimeout(c.current)})),[a,n,d]);const f=()=>{clearTimeout(c.current)},m=i.useCallback((()=>{null!=n&&d(null!=s?s:.5*n)}),[n,s,d]),p=e=>n=>{const t=e.onFocus;null==t||t(n),f()},h=e=>n=>{const t=e.onMouseEnter;null==t||t(n),f()},v=e=>n=>{const t=e.onMouseLeave;null==t||t(n),m()};return i.useEffect((()=>{if(!t&&a)return window.addEventListener("focus",m),window.addEventListener("blur",f),()=>{window.removeEventListener("focus",m),window.removeEventListener("blur",f)}}),[t,m,a]),{getRootProps:(n={})=>{const t=(0,o.Z)({},(0,g._)(e),(0,g._)(n));return(0,o.Z)({role:"presentation"},n,t,{onBlur:(r=t,e=>{const n=r.onBlur;null==n||n(e),m()}),onFocus:p(t),onMouseEnter:h(t),onMouseLeave:v(t)});var r},onClickAway:e=>{null==r||r(e,"clickaway")}}}((0,o.Z)({},H)),[F,V]=i.useState(!0),X=(0,s.y)({elementType:I,getSlotProps:D,externalForwardedProps:z,ownerState:H,additionalProps:{ref:n},className:[A.root,w]});return!S&&F?null:(0,d.jsx)(m,(0,o.Z)({onClickAway:$},C,{children:(0,d.jsx)(I,(0,o.Z)({},X,{children:(0,d.jsx)(O,(0,o.Z)({appear:!0,in:S,timeout:T,direction:"top"===p?"down":"up",onEnter:(e,n)=>{V(!1),P&&P(e,n)},onExited:e=>{V(!0),M&&M(e)}},j,{children:x||(0,d.jsx)(B,(0,o.Z)({message:L,action:f},b))}))}))}))}))}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/8887-5917115e54cd417b.js b/dsql-app/.local_dist/static/chunks/8887-5917115e54cd417b.js new file mode 100644 index 0000000..1d2b6b4 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/8887-5917115e54cd417b.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8887],{96224:function(e,a,t){var n=t(64836);a.Z=void 0;var s=n(t(64938)),i=t(85893),l=(0,s.default)([(0,i.jsx)("path",{d:"m16 7.58-5.5-2.4L5 7.58v3.6c0 3.5 2.33 6.74 5.5 7.74.25-.08.49-.2.73-.3-.15-.51-.23-1.06-.23-1.62 0-2.97 2.16-5.43 5-5.91V7.58z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M17 13c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 1.38c.62 0 1.12.51 1.12 1.12s-.51 1.12-1.12 1.12-1.12-.51-1.12-1.12.5-1.12 1.12-1.12zm0 5.37c-.93 0-1.74-.46-2.24-1.17.05-.72 1.51-1.08 2.24-1.08s2.19.36 2.24 1.08c-.5.71-1.31 1.17-2.24 1.17z",opacity:".3"},"1"),(0,i.jsx)("circle",{cx:"17",cy:"15.5",r:"1.12"},"2"),(0,i.jsx)("path",{d:"M18 11.09V6.27L10.5 3 3 6.27v4.91c0 4.54 3.2 8.79 7.5 9.82.55-.13 1.08-.32 1.6-.55C13.18 21.99 14.97 23 17 23c3.31 0 6-2.69 6-6 0-2.97-2.16-5.43-5-5.91zM11 17c0 .56.08 1.11.23 1.62-.24.11-.48.22-.73.3-3.17-1-5.5-4.24-5.5-7.74v-3.6l5.5-2.4 5.5 2.4v3.51c-2.84.48-5 2.94-5 5.91zm6 4c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"},"3"),(0,i.jsx)("path",{d:"M17 17.5c-.73 0-2.19.36-2.24 1.08.5.71 1.32 1.17 2.24 1.17s1.74-.46 2.24-1.17c-.05-.72-1.51-1.08-2.24-1.08z"},"4")],"AdminPanelSettingsTwoTone");a.Z=l},88518:function(e,a,t){var n=t(64836);a.Z=void 0;var s=n(t(64938)),i=t(85893),l=(0,s.default)([(0,i.jsx)("path",{d:"M22 15c0-1.66-1.34-3-3-3h-1.5v-.5C17.5 8.46 15.04 6 12 6c-.77 0-1.49.17-2.16.46L20.79 17.4c.73-.55 1.21-1.41 1.21-2.4zM2 14c0 2.21 1.79 4 4 4h9.73l-8-8H6c-2.21 0-4 1.79-4 4z",opacity:".3"},"0"),(0,i.jsx)("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.33 0-2.57.36-3.65.97l1.49 1.49C10.51 6.17 11.23 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 .99-.48 1.85-1.21 2.4l1.41 1.41c1.09-.92 1.8-2.27 1.8-3.81 0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.77 2.77h-.42C2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h11.73l2 2 1.41-1.41L4.41 3.86 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"},"1")],"CloudOffTwoTone");a.Z=l},57150:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},33587:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},49525:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(e,a,t){t.d(a,{Z:function(){return n}});const n=(0,t(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},43726:function(e,a,t){t.d(a,{Z:function(){return u}});var n=t(828),s=t(85893),i=t(67294),l=t(95264),r=t(96706),c=(t(94105),t(25472),t(73121)),d=t(21933);function u(e){var a=i.useContext(r.AddDatabaseContext),t=a.user,u=a.dbImage,o=a.setDbImage,m=a.query;if(!t)return(0,s.jsx)(i.Fragment,{});var p=(0,n.Z)(i.useState(null),2),h=(p[0],p[1],(0,n.Z)(i.useState(!1),2)),f=h[0],g=h[1];return(0,s.jsx)("section",{className:"card",children:(0,s.jsxs)("div",{className:"w-full grid grid-cols-1 xl:grid-cols-2 gap-6 items-stretch",children:[f&&(0,s.jsx)(l.Z,{}),(0,s.jsxs)("div",{className:"flex-col items-start",children:[(0,s.jsx)("h2",{className:"text-xl m-0 text-left w-full",children:"New Database Information"}),t&&u&&o&&(0,s.jsx)(c.Z,{user:t,dbImage:u,setDbImage:o,setLoading:g,query:m})]}),t&&u&&o&&(0,s.jsx)(d.Z,{user:t,dbImage:u,setDbImage:o})]})})}},73121:function(e,a,t){t.d(a,{Z:function(){return g}});var n=t(47568),s=t(828),i=t(97582),l=t(85893),r=t(67294),c=t(94105),d=t(97037),u=(t(73935),t(86729)),o=t(81069);function m(){return(m=(0,n.Z)((function(e){var a,t,n,s,l,r,c,d,m,p,h,f,g,b;return(0,i.__generator)(this,(function(i){switch(i.label){case 0:return a=e.e,t=e.setLoading,n=e.dbImage,s=e.database,l=e.user,t(!0),f={db_description:(null===(r=a.target.database_description)||void 0===r||null===(c=r.value)||void 0===c?void 0:c.match(/./))?a.target.database_description.value:null,db_name:(null===(d=a.target.database_name)||void 0===d||null===(m=d.value)||void 0===m?void 0:m.match(/./))?a.target.database_name.value:null,db_slug:(null===(p=a.target.database_slug)||void 0===p||null===(h=p.value)||void 0===h?void 0:h.match(/./))?a.target.database_slug.value:null,db_full_name:s.db_full_name,id:s.id,active_clone:s.active_clone,active_clone_parent_db:s.active_clone_parent_db},n?"string"!==typeof n?[3,1]:(f.db_image=n,[3,3]):[3,4];case 1:return"object"!==typeof n?[3,3]:[4,(0,u.Z)("/api/addUserMedia",{method:"post",body:{media:[n],folder:f.db_slug.replace(/_/g,"-"),type:"image"}},!0)];case 2:b=i.sent(),f.db_image=(null===(g=null===b||void 0===b?void 0:b.mediaData[0])||void 0===g?void 0:g.media_thumbnail_url)?b.mediaData[0].media_thumbnail_url:"/images/database-placeholder.png",i.label=3;case 3:return[3,5];case 4:f.db_image="/images/database-placeholder.png",i.label=5;case 5:return(0,u.Z)("/api/updateUserDatabase",{method:"post",body:f},!0).then((function(e){e.success?(0,o.Z)().then((function(){window.location.pathname="/admin/".concat(null===l||void 0===l?void 0:l.id,"/databases"),setTimeout((function(){t(!1)}),1e3)})):(alert("Error! Please Try Again"),setTimeout((function(){t(!1)}),1e3))})),[2]}}))}))).apply(this,arguments)}function p(){return(p=(0,n.Z)((function(e){var a,t,n,s,l,r,c,d,m,p,h,f;return(0,i.__generator)(this,(function(i){switch(i.label){case 0:return a=e.e,t=e.setLoading,n=e.dbImage,s=e.keepUpdated,l=e.keepDataUpdated,r=e.query,c=e.user,t(!0),p={db_name:a.target.database_name.value,db_slug:a.target.database_slug.value,db_description:(null===(d=a.target.database_description)||void 0===d||null===(m=d.value)||void 0===m?void 0:m.match(/./))?a.target.database_description.value:null},n?"string"!==typeof n?[3,1]:(p.db_image=n,[3,3]):[3,3];case 1:return"object"!==typeof n?[3,3]:[4,(0,u.Z)("/api/addUserMedia",{method:"post",body:{media:[n],folder:p.db_slug.replace(/_/g,"-"),type:"image"}},!0)];case 2:f=i.sent(),p.db_image=(null===(h=null===f||void 0===f?void 0:f.mediaData[0])||void 0===h?void 0:h.media_thumbnail_url)?f.mediaData[0].media_thumbnail_url:"/images/database-placeholder.png",i.label=3;case 3:return(null===r||void 0===r?void 0:r.duplicate)&&(p.duplicate=r.duplicate,p.keepUpdated=s||!1,p.keepDataUpdated=l||!1),(0,u.Z)("/api/createUserDatabase",{method:"post",body:p},!0).then((function(e){e.success?(0,o.Z)().then((function(){window.location.pathname="/admin/".concat(null===c||void 0===c?void 0:c.id,"/databases/").concat(p.db_slug)})):setTimeout((function(){t(!1)}),1e3)})),[2]}}))}))).apply(this,arguments)}var h,f=t(49486);function g(e){var a=e.user,t=e.dbImage,u=(e.setDbImage,e.database),o=e.setLoading,g=e.query;function b(e){return v.apply(this,arguments)}function v(){return(v=(0,n.Z)((function(e){return(0,i.__generator)(this,(function(t){switch(t.label){case 0:return(null===u||void 0===u?void 0:u.db_slug)===e?[2,null]:[4,(0,c.Z)({tableName:"user_databases",columnName:"db_slug",value:e,userId:a.id})];case 1:return[2,t.sent()]}}))}))).apply(this,arguments)}var x=r.useState(null),y=(0,s.Z)(x,2),_=y[0],w=y[1],j=(0,s.Z)(r.useState(!1),2),Z=j[0],k=j[1],N=(0,s.Z)(r.useState(!1),2),D=N[0];N[1];return(0,l.jsxs)("form",{className:"w-full max-w-none xl:max-w-lg flex flex-col items-start gap-4 relative",onSubmit:function(e){e.preventDefault(),u?function(e){m.apply(this,arguments)}({e:e,setLoading:o,dbImage:t,database:u,user:a}):function(e){p.apply(this,arguments)}({e:e,setLoading:o,dbImage:t,keepUpdated:Z,keepDataUpdated:D,query:g,user:a})},children:[_&&(0,l.jsx)(d.Z,{message:_}),(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,l.jsx)("label",{htmlFor:"database_name",children:"Name"}),(0,l.jsx)("input",{type:"text",name:"database_name",id:"database_name",placeholder:"Database Name",onInput:function(){var e=(0,n.Z)((function(e){var a,t,n;return(0,i.__generator)(this,(function(s){return a=e.target,t=a.closest("form"),a.value.match(/./)?(a.classList.remove("warning"),w(null)):a.classList.add("warning"),t&&(t.database_slug.value=a.value.toLowerCase().replace(/ /g,"_").replace(/[^a-zA-Z0-9-_]/g,""),n=t.database_slug.value,window.clearTimeout(h),h=setTimeout((function(){b(n).then((function(e){(null===e||void 0===e?void 0:e.result)?(t.database_slug.classList.add("warning"),w("Duplicate Database Name")):(t.database_slug.classList.remove("warning"),w(null))}))}),300)),[2]}))}));return function(a){return e.apply(this,arguments)}}(),defaultValue:u?u.db_name:"",required:!0})]}),(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,l.jsx)("label",{htmlFor:"database_slug",children:"Slug"}),(0,l.jsx)("input",{type:"text",name:"database_slug",id:"database_slug",placeholder:"Database Slug",onInput:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),w(null)):a.classList.add("warning");var t=a.value;window.clearTimeout(h),h=setTimeout((function(){b(t).then((function(e){(null===e||void 0===e?void 0:e.result)?(a.classList.add("warning"),w("Duplicate Database Name")):(a.classList.remove("warning"),w(null))}))}),300)},defaultValue:u?u.db_slug:"",required:!0})]}),(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,l.jsx)("label",{htmlFor:"database_description",children:"Description (optional)"}),(0,l.jsx)("textarea",{name:"database_description",id:"database_description",placeholder:"Short Description of database",defaultValue:u?u.db_description:""})]}),(null===g||void 0===g?void 0:g.duplicate)&&(0,l.jsx)(r.Fragment,{children:(0,l.jsxs)("div",{className:"card col items-start",children:[(0,l.jsx)(f.Z,{checkBoxValues:[{payload:"Keep New Database Updated?",title:"Keep New Database Updated?",name:"clone_database",onChangeHandler:function(e){e.target.checked?k(!0):k(!1)}}]}),(0,l.jsx)("span",{className:"text-sm italic text-slate-600 dark:text-slate-300",children:"By checking this box the new Database stays up to date with changes to the structure of the parent Database"})]})}),(0,l.jsxs)("button",{type:"submit",className:"w-full",children:[u?"Update":"Create"," Database"]})]})}},21933:function(e,a,t){t.d(a,{Z:function(){return u}});var n=t(47568),s=t(97582),i=t(85893),l=t(67294),r=t(36718),c=t(25472),d=t(45449);function u(e){e.user;var a=e.dbImage,t=e.setDbImage,u=(e.database,l.useRef());return(0,i.jsxs)("div",{className:"card no-hover col items-center justify-center",children:[(0,i.jsx)("h4",{className:"m-0",children:"Database Image"}),(0,i.jsx)("div",{className:"bg-white rounded-full overflow-hidden w-24 h-24",children:(0,i.jsx)("img",{src:a?"string"===typeof a?a:a.imageBase64Full:"/images/database-placeholder.png",alt:"Database Image",width:100,className:"w-full h-full object-cover",ref:u,"data-imagepreview":"image"})}),(0,i.jsxs)("div",{className:"w-full flex-col",id:"edit-database-image-option-wrapper",children:[(0,i.jsxs)(d.Z,{column:!0,className:"w-full",children:[(0,i.jsx)("button",{className:"outlined w-full whitespace-normal",onClick:function(e){(0,c.Mw)("user-media-popup")},children:"Choose Image from uploads"}),(0,i.jsx)("button",{className:"outlined secondary w-full whitespace-normal",onClick:function(e){var a,t,n=e.target;null===(t=null===(a=null===n||void 0===n?void 0:n.closest("#edit-database-image-option-wrapper"))||void 0===a?void 0:a.querySelector("input"))||void 0===t||t.click()},children:"Choose Image from Computer"})]}),(0,i.jsx)("input",{type:"file",accept:".png,.jpg,.jpeg,.webp",placeholder:"Choose Database Image",className:"hidden",onChange:function(){var e=(0,n.Z)((function(e){var a,n;return(0,s.__generator)(this,(function(s){switch(s.label){case 0:return a=e.target.files[0],[4,(0,r.Z)({imageInputFile:a,maxWidth:400})];case 1:return n=s.sent(),t(n),[2]}}))}));return function(a){return e.apply(this,arguments)}}()})]})]})}},79310:function(e,a,t){t.d(a,{Z:function(){return d}});var n=t(828),s=t(85893),i=t(67294),l=t(86729),r=t(25472),c=t(95264);t(99967);function d(e){var a=e.setDbImage,t=(0,n.Z)(i.useState(!0),2),d=t[0],u=t[1],o=i.useState(null),m=(0,n.Z)(o,2),p=m[0],h=m[1];return i.useEffect((function(){(0,l.Z)("/api/getUserMedia").then((function(e){u(!1),h(e.media)}))}),[]),(0,s.jsxs)(r.ZP,{title:"user-media-popup",children:[d&&(0,s.jsx)(c.Z,{width:"20px"}),(0,s.jsx)("h4",{className:"m-0 text-lg",children:"Your Uploaded Images"}),(0,s.jsx)("div",{className:"grid grid-cols-2",children:p&&p[0]&&p.filter((function(e){return"image"==e.media_type})).map((function(e,t){return(0,s.jsx)("div",{className:"w-full h-44 cursor-pointer hover:opacity-70",onClick:function(t){a(e.media_thumbnail_url||null),(0,r.j4)()},children:(0,s.jsx)("img",{src:e.media_thumbnail_url,alt:"User Media",className:"w-full h-full object-contain"})},t+1)}))})]})}},49486:function(e,a,t){t.d(a,{Z:function(){return s}});var n=t(85893);t(67294);function s(e){var a=e.name,t=e.checkBoxValues,s=e.setAlert,i=e.labelColor,l=e.flexRow,r=e.baseText,c=e.smallText,d=e.className;return(0,n.jsx)("div",{className:"flex items-start gap-x-4"+(l?" flex-row flex-wrap gap-y-2 ":" flex-col gap-y-4 ")+(d||""),children:t.map((function(e,t){var l=e.payload,d=e.title,u=e.onChangeHandler,o=e.fixed,m=e.jsx,p=e.name?"".concat(a,"-").concat(e.name):l?a+"-"+l:a;return(0,n.jsxs)("div",{className:"flex items-center"+(e.default&&o?" pointer-events-none":"")+(c?" gap-1 ":" gap-2 ")+((null===e||void 0===e?void 0:e.className)?e.className:""),children:[(0,n.jsx)("input",{className:"m-0"+(c?" w-4 h-4":" w-5 h-5"),type:"checkbox",defaultChecked:!!e.default,name:p,id:p,onChange:function(a){s&&s(null),u&&u(a,e)},value:l,style:{minWidth:"20px"}}),m||(0,n.jsx)("label",{htmlFor:p,className:"m-0 "+(i||"text-slate-800 dark:text-white/80")+(r||c?" text-base":" text-lg"),children:d})]},t+1)}))})}},97037:function(e,a,t){t.d(a,{Z:function(){return s}});var n=t(85893);t(67294);function s(e){var a=e.message;return(0,n.jsxs)("div",{className:"p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid",children:[(0,n.jsx)("img",{src:"/images/warning.png",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,n.jsx)("span",{children:a})]})}},94105:function(e,a,t){t.d(a,{Z:function(){return l}});var n=t(47568),s=t(97582),i=(t(73935),t(86729));function l(e){return r.apply(this,arguments)}function r(){return(r=(0,n.Z)((function(e){var a,t,n,l,r,c;return(0,s.__generator)(this,(function(s){switch(s.label){case 0:return a=e.tableName,t=e.columnName,n=e.value,l=e.dbFullName,e.dispatch,r=e.userId,c=e.dbId,[4,(0,i.Z)("/api/checkDuplicateData?tableName=".concat(a,"&type=").concat(t,"&value=").concat(n).concat(l?"&dbFullName="+l:"").concat(r?"&userId="+r:"").concat(c?"&dbId="+c:""))];case 1:return[2,s.sent()]}}))}))).apply(this,arguments)}},36718:function(e,a,t){t.d(a,{Z:function(){return i}});var n=t(47568),s=t(97582);function i(e){return l.apply(this,arguments)}function l(){return(l=(0,n.Z)((function(e){var a,t,n,i,l,r,c,d,u,o,m,p,h;return(0,s.__generator)(this,(function(s){switch(s.label){case 0:return a=e.imageInputFile,t=e.maxWidth,n=document.querySelector("[data-imagepreview='image']"),i=a.name.replace(/\..*/,""),c=document.createElement("canvas"),d=a.type,u=.95,o=t||null,null,m=a,p=URL.createObjectURL(m),(h=new Image).src=p,[4,new Promise((function(e,a){h.onerror=function(){URL.revokeObjectURL(this.src),console.log("Cannot load image")},h.onload=function(){if(URL.revokeObjectURL(this.src),o){var a=o/h.naturalWidth;c.width=h.naturalWidth0?(0,l.jsxs)("b",{children:[D," "]}):(0,l.jsx)(l.Fragment,{children:"No "}):"... ","Search result",D&&1!==D?"s":""," for"," ",(0,l.jsxs)("b",{children:['"',T.current,'"']})]})})]})}var v=a(30073),h=a(82943),p=a(13684);a(40436);function b(e){var t,a,n,r,d,o=e.user,c=e.entries,u=e.database,b=e.table,x=(e.setTargetEntry,e.dbSchemaData),g=e.richTextEditors,j=e.jsonTextEditors,y=e.dataTypes,N=e.title,w=e.confirmedDelegetedUser,T=e.query,E=e.search,S=e.entriesCount;null===w||void 0===w||w.delegated,null===w||void 0===w||null===(t=w.priviledges)||void 0===t||t.match(/Edit Tables/i),null===w||void 0===w||null===(a=w.priviledges)||void 0===a||a.match(/Delete Tables/i),null===w||void 0===w||null===(n=w.priviledges)||void 0===n||n.match(/Create Tables/i),null===w||void 0===w||null===(r=w.priviledges)||void 0===r||r.match(/Edit Entries/i),null===w||void 0===w||null===(d=w.priviledges)||void 0===d||d.match(/Delete Entries/i),u.active_clone,u.active_clone_parent_db,u.remote_connected;return(0,l.jsx)(i.Fragment,{children:(0,l.jsxs)("section",{className:"paper gray gray-bg",children:[N&&(0,l.jsxs)("div",{className:"justify-between w-full flex-wrap px-4 sm:px-0 pt-4 sm:pt-0",children:[(0,l.jsx)("h2",{className:"text-xl m-0",children:N}),(0,l.jsxs)("div",{children:[(0,l.jsxs)("a",{className:"button flex gap-2 items-center",href:"/admin/".concat(null===o||void 0===o?void 0:o.id,"/databases/").concat(u.db_slug,"/tables/").concat(b.tableName,"/entries/add-entry"),children:[(0,l.jsx)("span",{className:"symbol",children:"+"}),(0,l.jsx)("span",{children:"Add New Entry"})]}),(0,l.jsx)(h.Z,{database:u,table:b}),(0,l.jsx)(p.Z,{database:u,table:b,dbSchemaData:x,query:T})]})]}),E&&(0,l.jsx)(f,{}),(0,l.jsxs)("div",{className:"w-full flex-col gap-6",children:[(null===c||void 0===c?void 0:c[0])&&c.map((function(e){return(0,l.jsx)(i.Fragment,{children:(0,l.jsx)(s.Z,{user:o,database:u,table:b,dbSchemaData:x,richTextEditors:g,dataTypes:y,entry:e,query:T,confirmedDelegetedUser:w,jsonTextEditors:j})},e.id)})),!c&&(0,l.jsx)("div",{className:"w-full h-[300px]",children:(0,l.jsx)(m.Z,{position:"relative"})}),c&&!(null===c||void 0===c?void 0:c[0])&&(0,l.jsxs)("a",{href:"/admin/".concat(null===o||void 0===o?void 0:o.id,"/databases/").concat(u.db_slug,"/tables/").concat(b.tableName,"/entries/add-entry"),className:"border-dotted border-slate-200 border-2 p-4 w-full flex-col rounded flex items-center hover:border-primary/50 gap-2",children:[(0,l.jsx)("span",{className:"text-slate-400 text-center",children:"No Entries Added Yet."}),(0,l.jsx)(v.Z,{className:"opacity-20 my-4",sx:{fontSize:80}}),(0,l.jsx)("span",{className:"text-center",children:"Add an Entry to this Table"})]}),S&&S>10?(0,l.jsx)("a",{href:"/admin/".concat(null===o||void 0===o?void 0:o.id,"/databases/").concat(u.db_slug,"/tables/").concat(b.tableName,"/entries"),className:"button outlined gray w-full -mb-4",children:(0,l.jsx)("span",{children:"See All Entries"})}):null,(null===c||void 0===c?void 0:c[0])&&N&&(0,l.jsxs)("a",{className:"button flex gap-2 items-center w-full justify-center mt-2 more-padding",href:"/admin/".concat(null===o||void 0===o?void 0:o.id,"/databases/").concat(u.db_slug,"/tables/").concat(b.tableName,"/entries/add-entry"),style:{borderStyle:"dotted",borderWidth:"2px"},children:[(0,l.jsx)("span",{className:"symbol",children:"+"}),(0,l.jsx)("span",{children:"Add New Entry"})]})]})]})})}},51985:function(e,t,a){a.d(t,{Z:function(){return x}});var n=a(828),l=a(85893),i=a(67294),s=a(33907),r=a(86729),d=a(81069),o=a(36169),c=a(95264),u=a(54559),m=a(96486),f=a.n(m),v=a(95753),h=a(9404),p=a(82106);function b(e){var t=e.user,a=e.table,s=e.entry,r=e.url,d=e.query,o=(0,n.Z)(i.useState(!1),2),c=o[0],u=o[1],m=i.useRef(null);return(0,l.jsx)("div",{className:"relative z-[1000]",children:(0,l.jsx)(p.Popover,{isOpen:c,onClickOutside:function(){return u(!1)},containerClassName:"z-[1000]",positions:["bottom"],align:"end",content:(0,l.jsx)("div",{className:"bg-white dark:bg-slate-900 rounded shadow-md cancel-link",children:(0,l.jsxs)("div",{className:"flex-col min-w-[200px] items-stretch gap-0",children:[(0,l.jsx)("button",{className:"plain-text justify-start py-3",onClick:function(){navigator.clipboard.writeText(JSON.stringify(s)).then((function(){window.alert("Post Copied"),u(!1)}))},children:"Copy Object"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("button",{className:"plain-text justify-start py-3",onClick:function(){var e=(0,v.Z)({paradigm:"JavaScript",table:a,query:d,user:t});navigator.clipboard.writeText(e||"").then((function(){window.alert("JavaScript Type Definition Copied"),u(!1)}))},children:"Copy JS Type Definition"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("button",{className:"plain-text justify-start py-3",onClick:function(){var e=(0,v.Z)({paradigm:"TypeScript",table:a,query:d,user:t});navigator.clipboard.writeText(e||"").then((function(){window.alert("TypeScript Type Definition Copied"),u(!1)}))},children:"Copy TS Type Definition"}),(0,l.jsx)("hr",{className:"m-0"}),(0,l.jsx)("a",{href:r,className:"button plain-text justify-start py-3",children:(0,l.jsx)("span",{children:"View Entry"})})]})}),children:(0,l.jsx)("button",{onClick:function(){u(!c)},ref:m,className:"ghost p-2",children:(0,l.jsx)(h.Z,{})})})})}function x(e){var t,a,m,v,h,p=e.user,x=e.database,g=e.table,j=(e.dbSchemaData,e.richTextEditors),y=e.jsonTextEditors,N=e.dataTypes,w=e.entry,T=e.entryPage,E=e.confirmedDelegetedUser,S=e.query,Z=g.fields.filter((function(e){return e.fieldName&&!e.fieldName.match(s.Z)})),_=g.fields.find((function(e){return"uuid"===e.fieldName})),C=null===E||void 0===E?void 0:E.delegated,D=(null===E||void 0===E||null===(t=E.priviledges)||void 0===t||t.match(/Edit Tables/i),null===E||void 0===E||null===(a=E.priviledges)||void 0===a||a.match(/Delete Tables/i),null===E||void 0===E||null===(m=E.priviledges)||void 0===m||m.match(/Create Tables/i),null===E||void 0===E||null===(v=E.priviledges)||void 0===v||v.match(/Edit Entries/i),null===E||void 0===E||null===(h=E.priviledges)||void 0===h?void 0:h.match(/Delete Entries/i));_&&Z.unshift({dataType:"UUID",fieldName:"uuid",defaultField:!0}),Z.unshift({dataType:"BIGINT",fieldName:"id",defaultField:!0}),Z.push({dataType:"VARCHAR(250)",fieldName:"date_created",defaultField:!0}),Z.push({dataType:"BIGINT",fieldName:"date_created_code",defaultField:!0}),Z.push({dataType:"TIMESTAMP",fieldName:"date_created_timestamp",defaultField:!0}),Z.push({dataType:"VARCHAR(250)",fieldName:"date_updated",defaultField:!0}),Z.push({dataType:"BIGINT",fieldName:"date_updated_code",defaultField:!0}),Z.push({dataType:"TIMESTAMP",fieldName:"date_updated_timestamp",defaultField:!0});var F=(0,n.Z)(i.useState(!1),2),k=F[0],q=F[1],R=(0,n.Z)(i.useState(!0),2),I=R[0],O=R[1],P=(0,n.Z)(i.useState(w),2),U=P[0],A=P[1],L=(0,n.Z)(i.useState(!1),2),H=(L[0],L[1],i.useRef(null),i.useRef([])),B=(0,n.Z)(i.useState("/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(x.db_slug,"/tables/").concat(g.tableName,"/entries/").concat(U.id)),2),z=B[0],M=B[1];i.useEffect((function(){(null===E||void 0===E?void 0:E.dbUserId)&&Number(p.id)!==Number(E.dbUserId)&&M("/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(x.db_slug,"/tables/").concat(g.tableName,"/entries/").concat(U.id)+window.location.search)}),[]);var V="".concat(x.db_slug,"-").concat(g.tableName,"-").concat(U.id,"-submit-button");return(0,l.jsxs)("div",{className:"card col w-full overflow-hidden",children:[(0,l.jsx)("a",{href:z,onClick:function(e){var t=e.target;(t.closest(".cancel-link")||t.closest(".MuiPopover-root"))&&e.preventDefault()},className:"w-full",children:(0,l.jsxs)("div",{className:"w-full bg-slate-700 text-white py-2 px-4 rounded justify-between flex-wrap hover:bg-slate-800 cursor-pointer relative z-[1000] ",onClick:function(e){var t=e.target;t.closest(".cancel-link")||t.closest(".MuiPopover-root")||(e.ctrlKey?window.open(z,"__blank"):window.location.href=z)},children:[(0,l.jsxs)("span",{children:["Entry #",U.id]}),(0,l.jsxs)("div",{className:"flex-wrap cancel-link",children:[(!C||C&&D)&&(0,l.jsx)("span",{className:"text-slate-300 hover:text-fuchsia-200 cursor-pointer"+(k?" pointer-events-none opacity-40":""),onClick:function(e){window.confirm("Delete Entry #".concat(U.id,"?"))&&(q(!0),(0,r.Z)("/api/deleteTableEntry"+window.location.search,{method:"post",body:{dbFullName:x.db_full_name,tableName:g.tableName,entryId:U.id,dbSlug:x.db_slug,dbId:x.id,delegated:null===S||void 0===S?void 0:S.delegated,confirmedDelegetedUser:E}},!0).then((function(e){e.success?(0,d.Z)().then((function(){window.location.reload()})):(window.alert(e.msg),setTimeout((function(){q(!1)}),500))})))},children:"Delete Entry"}),!T&&(0,l.jsxs)(i.Fragment,{children:[(0,l.jsx)("span",{className:"opacity-20",children:"|"}),(0,l.jsx)("span",{className:"text-slate-300 hover:text-fuchsia-200 cursor-pointer",onClick:function(e){O(!I)},children:I?(0,l.jsx)("span",{children:"Expand"}):(0,l.jsx)("span",{children:"Collapse"})})]}),(0,l.jsx)("span",{className:"opacity-20",children:"|"}),(0,l.jsx)("div",{className:"button ghost px-0",onClick:function(e){var t=f().cloneDeep(w);delete t.date_created,delete t.date_created_code,delete t.date_created_timestamp,delete t.date_updated,delete t.date_updated_code,delete t.date_updated_timestamp,delete t.id,delete t.uuid,localStorage.setItem("duplicate_entry",JSON.stringify(t)),window.location.href="/admin/".concat(null===p||void 0===p?void 0:p.id,"/databases/").concat(x.db_slug,"/tables/").concat(g.tableName,"/entries/add-entry?duplicate=true&id=").concat(w.id)},children:(0,l.jsx)("span",{className:"text-slate-300",children:"Duplicate"})}),(0,l.jsx)("span",{className:"opacity-20",children:"|"}),(0,l.jsx)(b,{table:g,user:p,entry:w,query:S,url:z})]})]})}),(0,l.jsxs)("form",{className:"w-full flex flex-col items-stretch gap-8 minimal-scrollbars relative",style:T?{}:{maxHeight:I?"300px":"none",paddingTop:"10px",paddingBottom:"10px",overflow:"hidden"},onSubmit:function(e){e.preventDefault(),q(!0);var t={},a=e.target;Z.forEach((function(e){var n;if(e.fieldName&&a[e.fieldName]){var l="string"!==typeof a[e.fieldName].value,i="number"!==typeof a[e.fieldName].value;(l||i||a[e.fieldName].value)&&((null===(n=a[e.fieldName])||void 0===n?void 0:n.dataset.default)||(t[e.fieldName]=a[e.fieldName].value))}})),H.current[0]&&H.current.forEach((function(e){var a;(null===e||void 0===e?void 0:e.fieldName)&&(null===e||void 0===e||null===(a=e.ref)||void 0===a?void 0:a.current)&&(t[e.fieldName]=e.ref.current.getContent())})),y.current[0]&&y.current.forEach((function(e){var a;(null===e||void 0===e?void 0:e.fieldName)&&(null===e||void 0===e||null===(a=e.ref)||void 0===a?void 0:a.current)&&(t[e.fieldName]=e.ref.current.getValue())})),(0,r.Z)("/api/updateTableEntry",{method:"post",body:{dbFullName:x.db_full_name,dbSlug:x.db_slug,dbId:x.id,tableName:g.tableName,entryId:U.id,payload:t,tableSchema:g,delegated:null===S||void 0===S?void 0:S.delegated,confirmedDelegetedUser:E}},!0).then((function(e){e.success?(0,r.Z)("/api/refreshEntry?table=".concat(g.tableName,"&db=").concat(x.db_full_name,"&id=").concat(U.id,"&schema=").concat(JSON.stringify(g))).then((function(e){e.success&&(A(e.entry),setTimeout((function(){q(!1)}),500))})):(window.alert(e.msg+"\n"+(e.err||"")),setTimeout((function(){q(!1)}),500))}))},onKeyUp:function(e){if(e.ctrlKey&&"Enter"==e.key){var t;if(!window.confirm("Update this Form?"))return;null===(t=document.getElementById(V))||void 0===t||t.click()}},children:[k&&(0,l.jsx)(c.Z,{}),(I&&!T?Z.slice(0,3):Z).map((function(e,t){var a=N.filter((function(t){var a;return t.name===(null===(a=e.dataType)||void 0===a?void 0:a.replace(/\d|\(|\)/g,""))}));return(0,l.jsx)(u.Z,{fieldObject:e,dataTypeSchema:a[0],richTextEditors:j,currentRichTextEditorForms:H,entry:U,query:S,entryPage:T,confirmedDelegetedUser:E,jsonTextEditors:y,formButtonId:V},t+1)})),(0,l.jsx)("button",{type:"submit",className:k?" pointer-events-none opacity-40":"",id:V,children:"Update Entry"})]}),!T&&(0,l.jsx)(o.Z,{collapse:I,setCollapse:O})]})}},22348:function(e,t,a){a.d(t,{Z:function(){return l}});var n=a(85893);a(67294);function l(e){var t=e.radioValues,a=e.name,l=e.onChangeHandler,i=e.setAlert,s=e.flexRow,r=e.labelColor,d=e.baseText,o=e.smallText,c=e.className;try{return(0,n.jsx)("div",{className:"flex items-start gap-4 flex-wrap "+(s?"":" flex-col ")+(c||""),children:t.map((function(e,t){var s=e.payload,c=e.title,u=e.jsx,m=!1===s?s:s||(c||null);return(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)("input",{className:"m-0"+(d?" w-5 h-5":o?" w-4 h-4":" w-6 h-6"),type:"radio",defaultChecked:!!e.default,name:a,id:a+"_"+m,onChange:function(t){i&&i(null),e.onChangeHandler?e.onChangeHandler(t):l&&l(t)},value:"string"==typeof m?m:void 0}),u||(0,n.jsx)("label",{htmlFor:a+"_"+m,className:"text-lg m-0 "+(r||"text-slate-800")+(d?" text-base":o?" text-sm":" text-lg"),children:c})]},t+1)}))})}catch(u){return console.log("ERROR in FormRadio =>",u),(0,n.jsx)("div",{children:"Form Radio Error"})}}},44114:function(e,t,a){a.d(t,{Z:function(){return i}});var n=a(85893),l=a(8971);a(67294);function i(e){var t=e.selectOptions,a=e.name,i=e.onChangeHandler,s=e.required,r=e.setAlert,d=e.title,o=e.defaultValue,c=e.info,u=e.id;try{var m=function(e){if(!(e.type.match(/enter/i)&&window.innerWidth<1200)){var t=e.target.closest(".info-wrapper"),a=t.querySelector(".info-dropdown");!e.type.match(/leave/i)||a.classList.contains("hidden")?e.type.match(/leave/i)&&a.classList.contains("hidden")||(t&&a.classList.contains("hidden")?a.classList.remove("hidden"):a.classList.add("hidden")):a.classList.add("hidden")}};return(0,n.jsxs)("div",{className:"form-select-block flex items-start flex-col gap-0.5 w-full relative"+(c?" pr-8":""),children:[d&&(0,n.jsxs)("label",{htmlFor:a,children:[d,s?"":" (optional)"]}),(0,n.jsxs)("div",{className:"flex items-center w-full relative",children:[(0,n.jsx)("select",{name:a,id:u||a,className:"w-full bg-white",required:s,onChange:function(e){r&&r(null),e.target.classList.remove("warning"),i&&i(e)},defaultValue:o||void 0,children:t.map((function(e,t){var a=e.payload,l=e.title;return(0,n.jsx)("option",{value:a,selected:!!e.default,children:l},t+1)}))}),(0,n.jsx)(l.Z,{className:"absolute right-2 text-base text-slate-500 pointer-events-none",size:20}),c&&(0,n.jsxs)("div",{className:"info-wrapper absolute -right-10 w-8 h-8 rounded-full bg-white flex items-center justify-center z-10",style:{top:"50%",transform:"translate(0,-50%)"},onMouseEnter:m,onMouseLeave:m,onClick:m,children:[(0,n.jsx)("img",{src:"/images/info-outlined-black.png",alt:"",className:"w-6 h-6 object-contain opacity-60 pointer-events-none"}),(0,n.jsx)("div",{className:"info-dropdown absolute top-9 right-0 bg-white w-52 md:w-96 p-2 sm:p-6 shadow-xl rounded hidden text-center border border-slate-300 border-solid",children:(0,n.jsx)("span",{children:c})}),(0,n.jsx)("div",{className:"absolute -top-2 w-12",style:{height:"45px"}})]})]})]})}catch(f){return console.log("ERROR in FormSelect =>",f),(0,n.jsx)("div",{children:"Form Select Error"})}}},37722:function(e,t,a){a.r(t),a.d(t,{TableEntriesContext:function(){return S},__N_SSP:function(){return E},default:function(){return Z}});var n,l=a(828),i=a(85893),s=a(67294),r=a(54858),d=a(29815),o=a(61781),c=a(424),u=a(79230),m=a(6122),f=a(94986),v=a(88515),h=a(58264),p=a(95264),b=a(86729),x=(a(96486),a(82943)),g=a(13684);function j(e){var t,n,l,r=s.useContext(S),d=r.user,p=r.database,b=r.table,j=r.dbSchemaData,N=r.setTargetEntry,w=r.richTextEditors,T=r.jsonTextEditors,E=r.query,Z=r.confirmedDelegetedUser,_=r.activeEntries,C=r.entriesCount,D=r.setActiveEntries,F=a(89594);null===Z||void 0===Z||Z.delegated,null===Z||void 0===Z||null===(t=Z.priviledges)||void 0===t||t.match(/Edit Tables/i),null===Z||void 0===Z||null===(n=Z.priviledges)||void 0===n||n.match(/Delete Tables/i),null===Z||void 0===Z||null===(l=Z.priviledges)||void 0===l||l.match(/Create Tables/i);return(0,i.jsxs)(s.Fragment,{children:[(0,i.jsxs)("div",{className:"flex-col items-start gap-0 w-full relative z-50",children:[(0,i.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,i.jsxs)("div",{className:"flex-wrap",children:[(0,i.jsx)(o.Z,{}),(0,i.jsx)("h1",{className:"text-3xl m-0",children:(0,i.jsxs)("span",{className:"flex items-center flex-wrap gap-2",children:["All Entries In"," ",(0,i.jsxs)("span",{className:"bg-slate-100 dark:bg-slate-800 px-2 py-1 border border-solid border-slate-400 dark:border-slate-600 rounded relative",children:[b.tableFullName,(0,i.jsx)("div",{className:"absolute -top-5 -right-4",children:(0,i.jsx)(u.Z,{slugText:b.tableName,justIcon:!0})})]})," ","Table"]})})]}),(0,i.jsxs)("div",{className:"w-full sm:w-auto",children:[(0,i.jsxs)("a",{href:"/admin/".concat(null===d||void 0===d?void 0:d.id,"/databases/").concat(p.db_slug,"/tables/").concat(b.tableName,"/entries/add-entry"),className:"button flex items-center gap-2 w-full sm:w-auto justify-center",children:[(0,i.jsx)("span",{className:"symbol",children:"+"}),(0,i.jsx)("span",{children:"Add New Entry"})]}),(0,i.jsx)(x.Z,{database:p,table:b}),(0,i.jsx)(g.Z,{database:p,table:b,dbSchemaData:j,query:E})]})]}),(0,i.jsx)(c.Z,{confirmedDelegetedUser:null===E||void 0===E?void 0:E.delegated,user:d})]}),p.active_clone?(0,i.jsx)(f.Z,{database:p,user:d}):(0,i.jsx)(i.Fragment,{}),p.remote_connected?(0,i.jsx)(h.w,{database:p}):(0,i.jsx)(i.Fragment,{}),(0,i.jsx)(v.Z,{table:b,database:p,user:d}),(0,i.jsx)(m.Z,{user:d,entries:_,database:p,table:b,setTargetEntry:N,dbSchemaData:j,richTextEditors:w,dataTypes:F,query:E,confirmedDelegetedUser:Z,jsonTextEditors:T,search:!0}),C>20&&(0,i.jsx)(y,{activeEntries:_,setActiveEntries:D,database:p,table:b,entriesCount:C})]})}function y(e){e.activeEntries;var t=e.setActiveEntries,a=e.database,l=e.table,r=e.entriesCount,o=s.useContext(S),c=s.useRef(),u=s.useRef(1),m=20*Number(u.current),f=Boolean(m>=r);return s.useEffect((function(){var e=function(e,i){var s;if(null===e||void 0===e||null===(s=e[0])||void 0===s?void 0:s.isIntersecting){var r=document.getElementById("entries-search-input"),c=document.getElementById("entries-search-field-select"),m={tableName:l.tableName,dbName:a.db_slug,page:u.current,tableSchema:l,search:r?r.value:void 0,searchField:c?c.value:void 0,delegated:Boolean(o.query.delegated)};(0,b.Z)("/api/infiniteScroll",{method:"POST",body:m},!0).then((function(e){e.success&&(e.page&&(u.current=e.page),window.clearTimeout(n),n=setTimeout((function(){var a,n;(null===(a=e.data)||void 0===a?void 0:a[0])&&(null===(n=e.data)||void 0===n?void 0:n[0])&&t((function(t){return t?(0,d.Z)(t).concat((0,d.Z)(e.data)):null}))}),500))})).catch((function(e){console.log("Infinite Scroll Error =>",e)})).finally((function(){console.log("Infinite Scroll Done. Page",u.current)}))}},i={rootMargin:"0px 0px 0px 0px"};setTimeout((function(){requestAnimationFrame((function(){var t=new IntersectionObserver(e,i);c.current&&t.observe(c.current)}))}),1e3)}),[]),f?(0,i.jsx)(s.Fragment,{}):(0,i.jsx)("div",{className:"w-full flex items-center justify-center",ref:c,children:(0,i.jsx)(p.Z,{position:"relative",style:{backgroundColor:"transparent"},width:"20px"})})}var N=a(4423),w=a(4514),T={},E=!0,S=s.createContext(T);function Z(e){var t=e.user,a=e.database,n=e.table,d=e.dbSchemaData,o=e.entries,c=e.query,u=e.confirmedDelegetedUser,m=e.entriesCount,f="".concat(n.tableFullName," Table Entries | Datasquirel"),v=(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("title",{children:f}),(0,i.jsx)("meta",{name:"description",content:"All Entries in table"})]}),h=(0,l.Z)(s.useState(null),2),p=h[0],b=h[1],x=(0,l.Z)(s.useState(o),2),g=x[0],y=x[1],T=s.useRef("title"),E=s.useRef(null),Z=s.useRef([]),_=s.useRef([]);return(0,i.jsx)(r.Z,{head:v,user:t,extraHeaderContent:(0,i.jsx)(N.Z,{database:a,query:c,confirmedDelegetedUser:u,user:t}),children:(0,i.jsxs)(S.Provider,{value:{user:t,database:a,table:n,dbSchemaData:d,entries:o,targetEntry:p,setTargetEntry:b,richTextEditors:Z,jsonTextEditors:_,query:c,confirmedDelegetedUser:u,activeEntries:g,setActiveEntries:y,targetField:T,searchTerm:E,entriesCount:m},children:[(0,i.jsx)(j,{}),(0,i.jsx)(w.Z,{snug:!0})]})})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/9365-101d5c9d637cef9a.js b/dsql-app/.local_dist/static/chunks/9365-101d5c9d637cef9a.js new file mode 100644 index 0000000..221e659 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/9365-101d5c9d637cef9a.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9365],{424:function(e,s,a){a.d(s,{Z:function(){return i}});var t=a(828),n=a(85893),l=a(67294);function i(e){var s,a,i,r=e.confirmedDelegetedUser,c=e.linksArray,d=e.user,o=(null===r||void 0===r||r.delegated,null===r||void 0===r||null===(s=r.priviledges)||void 0===s||s.match(/Edit Tables/i),null===r||void 0===r||null===(a=r.priviledges)||void 0===a||a.match(/Delete Tables/i),null===r||void 0===r||null===(i=r.priviledges)||void 0===i||i.match(/Create Tables/i),l.useState(c||null)),u=(0,t.Z)(o,2),x=u[0],h=u[1];return l.useEffect((function(){var e;if(!c){var s=window.location.pathname,a=s.split("/"),t=[];t.push({title:"Home",path:s.match(/admin/)?"/admin":"/"});null===(e=window.location.search)||void 0===e||e.match(/delegated=true/);a.forEach((function(e,s,a){(null===e||void 0===e?void 0:e.match(/./))&&1!=s&&(e.match(/^\d+$/)&&d||t.push({title:e,path:function(){for(var e="",t=0;ts||!n.match(/./)||(e+="/".concat(n))}return e}()}))})),h(t)}}),[]),x&&x[1]?(0,n.jsx)("div",{className:"text-sm mt-2 flex-wrap",children:x.map((function(e,s,a){return s===x.length-1?(0,n.jsx)("a",{href:e.path,className:"text-slate-400 dark:text-slate-500 pointer-events-none",children:e.title},s):(0,n.jsxs)(l.Fragment,{children:[(0,n.jsx)("a",{href:e.path,className:"query-url",children:e.title}),(0,n.jsx)("span",{className:"opacity-20",children:"|"})]},s)}))}):(0,n.jsx)(l.Fragment,{})}},96355:function(e,s,a){a.d(s,{Z:function(){return x}});var t=a(828),n=a(85893),l=a(67294),i=a(86729),r=a(81069),c=a(95264),d=a(88518),o=a(68599),u=a(62888);function x(e){var s=(0,t.Z)(l.useState(!0),2),a=s[0],x=s[1],h=(0,t.Z)(l.useState(0),2),m=h[0],f=h[1],p=(0,t.Z)(l.useState(0),2),j=(p[0],p[1]);return l.useEffect((function(){m||(0,i.Z)("/api/getDiskUsage").then((function(e){(null===e||void 0===e?void 0:e.total)&&(f(e.total),localStorage.setItem("disk_usage",e.total)),x(!1)}))}),[]),a?(0,n.jsx)("div",{className:"button ghost small-text",style:{height:"30px"},children:(0,n.jsx)(c.Z,{width:"15px",position:"relative"})}):(0,n.jsx)(l.Fragment,{children:m?(0,n.jsxs)("div",{className:"button ghost small-text normal-weight p-0",style:{height:"30px",padding:0},onClick:function(e){x(!0),(0,r.Z)().then((function(){j((function(e){return e+1})),x(!1)}))},children:[a&&(0,n.jsx)(c.Z,{width:"15px"}),(0,n.jsx)(o.Z,{size:20,className:"text-slate-400 mr-[3px]"}),(0,n.jsx)("span",{className:"font-bold text-slate-700 dark:text-white",children:m&&m.toFixed(2)}),(0,n.jsx)("span",{className:"text-slate-500",children:"mb"}),(0,n.jsx)(u.Z,{size:17,className:"text-slate-400",strokeWidth:2})]}):(0,n.jsxs)("span",{className:"text-sm info gray font-normal w-auto",children:[(0,n.jsx)(d.Z,{color:"inherit",className:"opacity-50 text-slate-500",fontSize:"small"}),(0,n.jsx)("span",{children:"No Disk Usage Data Available Yet"})]})})}},81069:function(e,s,a){a.d(s,{Z:function(){return i}});var t=a(47568),n=a(97582),l=a(86729);function i(){return r.apply(this,arguments)}function r(){return(r=(0,t.Z)((function(){var e;return(0,n.__generator)(this,(function(s){switch(s.label){case 0:return[4,(0,l.Z)("/api/getDiskUsage")];case 1:return e=s.sent(),localStorage.setItem("disk_usage",e.total),[2]}}))}))).apply(this,arguments)}},54858:function(e,s,a){a.d(s,{Z:function(){return N}});var t=a(85893),n=a(67294),l=a(9008),i=a.n(l),r=(a(15281),a(828)),c=a(64017),d=a(96224),o=a(73486),u=a(33587),x=a(78107),h=a(49525),m=a(57150),f=a(3848),p=a(4844);function j(e){var s=e.user,a=(0,r.Z)(n.useState(!0),2),l=a[0],i=a[1];return(0,t.jsxs)("aside",{className:"aside"+(l?" mobile-collapsed":" mobile-expanded"),children:[(0,t.jsx)(c.Z,{adminAside:!0,collapseAsideMobile:l,setCollapseAsideMobile:i}),(0,t.jsx)("hr",{className:"opacity-0 mt-4"}),(0,t.jsxs)("div",{className:"main-links"+(l?" hidden lg:flex":" "),children:[(0,t.jsxs)("a",{href:"/admin","data-currentlink":"/admin","data-strictlink":"true",children:[(0,t.jsx)(o.Z,{size:20}),(0,t.jsx)("span",{children:"Dashboard"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/databases"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/databases"),children:[(0,t.jsx)(u.Z,{size:20}),(0,t.jsx)("span",{children:"Databases"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/media"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/media"),children:[(0,t.jsx)(x.Z,{size:20}),(0,t.jsx)("span",{children:"Media"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/users"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/users"),children:[(0,t.jsx)(h.Z,{size:20}),(0,t.jsx)("span",{children:"Users"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/schema"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/schema"),children:[(0,t.jsx)(m.Z,{size:20}),(0,t.jsx)("span",{children:"Schema"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/api-keys"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/api-keys"),children:[(0,t.jsx)(f.Z,{size:20}),(0,t.jsx)("span",{children:"API Keys"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/connect"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/connect"),children:[(0,t.jsx)(p.Z,{size:20}),(0,t.jsx)("span",{children:"Connect"})]}),1==s.id&&(0,t.jsx)(n.Fragment,{children:(0,t.jsxs)("a",{href:"/su","data-currentlink":"/su",children:[(0,t.jsx)(d.Z,{className:"text-slate-400"}),(0,t.jsx)("span",{children:"Super Admin User"})]})}),(0,t.jsx)("hr",{className:"opacity-80"}),(0,t.jsxs)("div",{className:"flex-col gap-0 items-start w-full",children:[(0,t.jsx)("a",{href:"/admin/".concat(null===s||void 0===s?void 0:s.id,"/settings"),"data-currentlink":"/admin/".concat(null===s||void 0===s?void 0:s.id,"/settings"),children:(0,t.jsx)("span",{children:"Settings"})}),(0,t.jsx)("a",{href:"/docs","data-currentlink":"/docs",target:"_blank",children:(0,t.jsx)("span",{children:"Documentation"})}),(0,t.jsx)("a",{href:"/logout","data-currentlink":"/logout",children:(0,t.jsx)("span",{children:"Logout"})})]})]})]})}a(87108);var v=a(65484);function g(e){var s=e.user,a=e.extraHeaderContent,l=(0,r.Z)(n.useState(s||null),2),i=l[0],c=l[1];return n.useEffect((function(){(null===s||void 0===s?void 0:s.logged_in_status)&&c(s||null)}),[s]),(0,t.jsx)("section",{className:"overflow-visible w-full px-0 md:px-8 py-0 flex justify-center bg-white dark:bg-slate-800 shadow-lg gap-4 dark:shadow-black/10 z-50 shadow-slate-900/5",style:{zIndex:700,border:"none"},children:(0,t.jsxs)("div",{className:"w-full items-center justify-between gap-4 md:gap-8",children:[(0,t.jsxs)("div",{className:"hidden xl:flex flex-col items-stretch grow fixed xl:static top-0 right-0 px-4 xl:px-0 shadow-xl xl:shadow-none h-screen xl:h-auto overflow-auto xl:overflow-visible w-screen sl:w-auto bg-white xl:bg-transparent pb-10 xl:pb-0",id:"main-nav-content-wrapper",children:[(0,t.jsxs)("div",{className:"items-center mb-2 flex xl:hidden",children:[(0,t.jsx)("a",{href:"/",className:"hidden xl:flex",children:(0,t.jsx)("img",{src:"/images/logo-icon-alt-2.png",alt:"Logo Icon",width:37})}),(0,t.jsx)("button",{className:"outlined gray ml-auto",onClick:function(e){var s=document.getElementById("main-nav-content-wrapper");null===s||void 0===s||s.classList.toggle("hidden")},style:{border:"none"},children:(0,t.jsx)("span",{className:"font-semibold text-4xl",children:"\u2715"})})]}),(0,t.jsxs)("div",{className:"flex items-center w-full gap-6 grow flex-col xl:flex-row justify-start xl:justify-between",children:[(0,t.jsx)("div",{className:"gap-6",children:a}),(0,t.jsx)(v.Z,{activeUser:i})]})]}),(0,t.jsxs)("button",{className:"bg-transparent w-16 p-4 gap-1.5 flex xl:hidden flex-col hover:bg-transparent transition-all ml-auto",onClick:function(e){var s=document.getElementById("main-nav-content-wrapper");null===s||void 0===s||s.classList.toggle("hidden")},style:{minWidth:"50px",backgroundColor:"transparent"},id:"main-header-hamburger-button","aria-label":"Mobile Hambutget Button",children:[(0,t.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"}),(0,t.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"}),(0,t.jsx)("div",{className:"w-full h-1 bg-slate-600 dark:bg-slate-400 rounded-full"})]})]})})}var b=a(29678),w=a(96355),k=a(86729);function N(e){var s=e.children,a=e.head,l=e.user,r=(e.productionEnvironment,e.extraHeaderContent);e.aceEditor;return r||(r=(0,t.jsx)(w.Z,{})),n.useEffect((function(){var e=document.querySelectorAll("aside .main-links a");(0,b.Z)({links:e}),document.cookie.match(/user_refresh=1/)&&(0,k.Z)("/api/reAuthenticateUser",{method:"post",body:{}},!0).then((function(e){e.status&&e.user&&(document.cookie="user_refresh=0;max-age=0",localStorage.setItem("csrf",e.user.csrf_k),localStorage.setItem("user",JSON.stringify(e.user)),window.location.reload())}))}),[]),(0,t.jsxs)(n.Fragment,{children:[(0,t.jsxs)(i(),{children:[a,(0,t.jsxs)(n.Fragment,{children:[(0,t.jsx)("script",{src:"https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ace.min.js",integrity:"sha512-q6CTB0jS+VuJnSct82rVcWlI06LGzNjaG3CWenHWVUncRvc4UQMFkA3a5Ip880xr+lBx38FcHDclOxPdSg+sBw==",crossOrigin:"anonymous",referrerPolicy:"no-referrer"}),(0,t.jsx)("script",{src:"https://cdnjs.cloudflare.com/ajax/libs/ace/1.22.0/ext-language_tools.min.js",integrity:"sha512-6g6cvocV7eT/J8L44lL8gJKqq9onqQeYGgJO0DmrsYFcCfRl6wYkYA/KHS768r4QVTB4JxsCcMQ9gIezxpTCZw==",crossOrigin:"anonymous",referrerPolicy:"no-referrer"})]})]}),(0,t.jsxs)("div",{className:"admin w-full flex items-start gap-0",children:[(0,t.jsx)(j,{user:l}),(0,t.jsxs)("main",{className:"relative",children:[(0,t.jsx)(g,{user:l,extraHeaderContent:r}),(0,t.jsx)("div",{className:"admin-content",children:s}),(0,t.jsx)("footer",{className:"flex justify-center w-full items-center p-4",children:(0,t.jsxs)("div",{className:"max-w-6xl w-full justify-center flex-wrap",children:[(0,t.jsx)("div",{className:"flex items-center gap-2 scale-75",children:(0,t.jsx)(c.Z,{})}),(0,t.jsx)("span",{className:"opacity-25",children:"|"}),(0,t.jsxs)("span",{className:"text-sm text-slate-400 dark:text-slate-600 text-center",children:[(new Date).getFullYear()," \xa9 Datasquirel. All rights reserved."]}),(0,t.jsx)("span",{className:"opacity-25",children:"|"}),(0,t.jsx)("a",{href:"/docs",children:"Docs"}),(0,t.jsx)("span",{className:"opacity-25",children:"|"}),(0,t.jsx)("a",{href:"/terms",children:"Terms"})]})})]})]})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/94726e6d-f5320de901b4c44f.js b/dsql-app/.local_dist/static/chunks/94726e6d-f5320de901b4c44f.js new file mode 100644 index 0000000..ba9f796 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/94726e6d-f5320de901b4c44f.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8802],{25317:function(t,e,r){function i(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function n(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}r.d(e,{$i:function(){return rt},DY:function(){return ut},Fc:function(){return m},Fo:function(){return hr},GN:function(){return Te},JV:function(){return ur},Ks:function(){return ir},Ok:function(){return ht},Pr:function(){return _t},S5:function(){return tr},SI:function(){return I},UI:function(){return oe},Wy:function(){return Ht},bQ:function(){return N},cy:function(){return ct},d4:function(){return U},fS:function(){return ft},if:function(){return Ve},kr:function(){return be},l1:function(){return Le},lC:function(){return W},m2:function(){return R},p8:function(){return br},r9:function(){return M},xr:function(){return ke}});var s,a,o,u,h,f,_,l,c,d,p,m={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},v={duration:.5,overwrite:!1,delay:0},g=1e8,y=1e-8,T=2*Math.PI,w=T/4,b=0,k=Math.sqrt,x=Math.cos,D=Math.sin,M=function(t){return"string"===typeof t},A=function(t){return"function"===typeof t},C=function(t){return"number"===typeof t},R=function(t){return"undefined"===typeof t},E=function(t){return"object"===typeof t},S=function(t){return!1!==t},O=function(){return"undefined"!==typeof window},z=function(t){return A(t)||M(t)},P="function"===typeof ArrayBuffer&&ArrayBuffer.isView||function(){},F=Array.isArray,L=/(?:-?\.?\d|\.)+/gi,I=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,U=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,B=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,N=/[+-]=-?[.\d]+/,q=/[^,'"\[\]\s]+/gi,Q=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,V={},j={},G=function(t){return(j=Tt(t,V))&&br},W=function(t,e){return console.warn("Invalid property",t,"set to",e,"Missing plugin? gsap.registerPlugin()")},Y=function(t,e){return!e&&console.warn(t)},$=function(t,e){return t&&(V[t]=e)&&j&&(j[t]=e)||V},H=function(){return 0},J={suppressEvents:!0,isStart:!0,kill:!1},K={suppressEvents:!0,kill:!1},X={suppressEvents:!0},Z={},tt=[],et={},rt={},it={},nt=30,st=[],at="",ot=function(t){var e,r,i=t[0];if(E(i)||A(i)||(t=[t]),!(e=(i._gsap||{}).harness)){for(r=st.length;r--&&!st[r].targetTest(i););e=st[r]}for(r=t.length;r--;)t[r]&&(t[r]._gsap||(t[r]._gsap=new Le(t[r],e)))||t.splice(r,1);return t},ut=function(t){return t._gsap||ot(Zt(t))[0]._gsap},ht=function(t,e,r){return(r=t[e])&&A(r)?t[e]():R(r)&&t.getAttribute&&t.getAttribute(e)||r},ft=function(t,e){return(t=t.split(",")).forEach(e)||t},_t=function(t){return Math.round(1e5*t)/1e5||0},lt=function(t){return Math.round(1e7*t)/1e7||0},ct=function(t,e){var r=e.charAt(0),i=parseFloat(e.substr(2));return t=parseFloat(t),"+"===r?t+i:"-"===r?t-i:"*"===r?t*i:t/i},dt=function(t,e){for(var r=e.length,i=0;t.indexOf(e[i])<0&&++is;)a=a._prev;return a?(e._next=a._next,a._next=e):(e._next=t[r],t[r]=e),e._next?e._next._prev=e:t[i]=e,e._prev=a,e.parent=e._dp=t,e},Dt=function(t,e,r,i){void 0===r&&(r="_first"),void 0===i&&(i="_last");var n=e._prev,s=e._next;n?n._next=s:t[r]===e&&(t[r]=s),s?s._prev=n:t[i]===e&&(t[i]=n),e._next=e._prev=e.parent=null},Mt=function(t,e){t.parent&&(!e||t.parent.autoRemoveChildren)&&t.parent.remove&&t.parent.remove(t),t._act=0},At=function(t,e){if(t&&(!e||e._end>t._dur||e._start<0))for(var r=t;r;)r._dirty=1,r=r.parent;return t},Ct=function(t){for(var e=t.parent;e&&e.parent;)e._dirty=1,e.totalDuration(),e=e.parent;return t},Rt=function(t,e,r,i){return t._startAt&&(a?t._startAt.revert(K):t.vars.immediateRender&&!t.vars.autoRevert||t._startAt.render(e,!0,i))},Et=function t(e){return!e||e._ts&&t(e.parent)},St=function(t){return t._repeat?Ot(t._tTime,t=t.duration()+t._rDelay)*t:0},Ot=function(t,e){var r=Math.floor(t/=e);return t&&r===t?r-1:r},zt=function(t,e){return(t-e._start)*e._ts+(e._ts>=0?0:e._dirty?e.totalDuration():e._tDur)},Pt=function(t){return t._end=lt(t._start+(t._tDur/Math.abs(t._ts||t._rts||y)||0))},Ft=function(t,e){var r=t._dp;return r&&r.smoothChildTiming&&t._ts&&(t._start=lt(r._time-(t._ts>0?e/t._ts:((t._dirty?t.totalDuration():t._tDur)-e)/-t._ts)),Pt(t),r._dirty||At(r,t)),t},Lt=function(t,e){var r;if((e._time||!e._dur&&e._initted||e._starty)&&e.render(r,!0)),At(t,e)._dp&&t._initted&&t._time>=t._dur&&t._ts){if(t._dur=0&&r.totalTime(r._tTime),r=r._dp;t._zTime=-1e-8}},It=function(t,e,r,i){return e.parent&&Mt(e),e._start=lt((C(r)?r:r||t!==u?Gt(t,r,e):t._time)+e._delay),e._end=lt(e._start+(e.totalDuration()/Math.abs(e.timeScale())||0)),xt(t,e,"_first","_last",t._sort?"_start":0),qt(e)||(t._recent=e),i||Lt(t,e),t._ts<0&&Ft(t,t._tTime),t},Ut=function(t,e){return(V.ScrollTrigger||W("scrollTrigger",e))&&V.ScrollTrigger.create(e,t)},Bt=function(t,e,r,i,n){return je(t,e,n),t._initted?!r&&t._pt&&!a&&(t._dur&&!1!==t.vars.lazy||!t._dur&&t.vars.lazy)&&c!==ke.frame?(tt.push(t),t._lazy=[n,i],1):void 0:1},Nt=function t(e){var r=e.parent;return r&&r._ts&&r._initted&&!r._lock&&(r.rawTime()<0||t(r))},qt=function(t){var e=t.data;return"isFromStart"===e||"isStart"===e},Qt=function(t,e,r,i){var n=t._repeat,s=lt(e)||0,a=t._tTime/t._tDur;return a&&!i&&(t._time*=s/t._dur),t._dur=s,t._tDur=n?n<0?1e10:lt(s*(n+1)+t._rDelay*n):s,a>0&&!i&&Ft(t,t._tTime=t._tDur*a),t.parent&&Pt(t),r||At(t.parent,t),t},Vt=function(t){return t instanceof Ue?At(t):Qt(t,t._dur)},jt={_start:0,endTime:H,totalDuration:H},Gt=function t(e,r,i){var n,s,a,o=e.labels,u=e._recent||jt,h=e.duration()>=g?u.endTime(!1):e._dur;return M(r)&&(isNaN(r)||r in o)?(s=r.charAt(0),a="%"===r.substr(-1),n=r.indexOf("="),"<"===s||">"===s?(n>=0&&(r=r.replace(/=/,"")),("<"===s?u._start:u.endTime(u._repeat>=0))+(parseFloat(r.substr(1))||0)*(a?(n<0?u:i).totalDuration()/100:1)):n<0?(r in o||(o[r]=h),o[r]):(s=parseFloat(r.charAt(n-1)+r.substr(n+1)),a&&i&&(s=s/100*(F(i)?i[0]:i).totalDuration()),n>1?t(e,r.substr(0,n-1),i)+s:h+s)):null==r?h:+r},Wt=function(t,e,r){var i,n,s=C(e[1]),a=(s?2:1)+(t<2?0:1),o=e[a];if(s&&(o.duration=e[1]),o.parent=r,t){for(i=o,n=r;n&&!("immediateRender"in i);)i=n.vars.defaults||{},n=S(n.vars.inherit)&&n.parent;o.immediateRender=S(i.immediateRender),t<2?o.runBackwards=1:o.startAt=e[a-1]}return new He(e[0],o,e[a+1])},Yt=function(t,e){return t||0===t?e(t):e},$t=function(t,e,r){return re?e:r},Ht=function(t,e){return M(t)&&(e=Q.exec(t))?e[1]:""},Jt=[].slice,Kt=function(t,e){return t&&E(t)&&"length"in t&&(!e&&!t.length||t.length-1 in t&&E(t[0]))&&!t.nodeType&&t!==h},Xt=function(t,e,r){return void 0===r&&(r=[]),t.forEach((function(t){var i;return M(t)&&!e||Kt(t,1)?(i=r).push.apply(i,Zt(t)):r.push(t)}))||r},Zt=function(t,e,r){return o&&!e&&o.selector?o.selector(t):!M(t)||r||!f&&xe()?F(t)?Xt(t,r):Kt(t)?Jt.call(t,0):t?[t]:[]:Jt.call((e||_).querySelectorAll(t),0)},te=function(t){return t=Zt(t)[0]||Y("Invalid scope")||{},function(e){var r=t.current||t.nativeElement||t;return Zt(e,r.querySelectorAll?r:r===t?Y("Invalid scope")||_.createElement("div"):t)}},ee=function(t){return t.sort((function(){return.5-Math.random()}))},re=function(t){if(A(t))return t;var e=E(t)?t:{each:t},r=Se(e.ease),i=e.from||0,n=parseFloat(e.base)||0,s={},a=i>0&&i<1,o=isNaN(i)||a,u=e.axis,h=i,f=i;return M(i)?h=f={center:.5,edges:.5,end:1}[i]||0:!a&&o&&(h=i[0],f=i[1]),function(t,a,_){var l,c,d,p,m,v,y,T,w,b=(_||e).length,x=s[b];if(!x){if(!(w="auto"===e.grid?0:(e.grid||[1,g])[1])){for(y=-g;y<(y=_[w++].getBoundingClientRect().left)&&wy&&(y=m),mb?b-1:u?"y"===u?b/w:w:Math.max(w,b/w))||0)*("edges"===i?-1:1),x.b=b<0?n-b:n,x.u=Ht(e.amount||e.each)||0,r=r&&b<0?Re(r):r}return b=(x[t]-x.min)/x.max||0,lt(x.b+(r?r(b):b)*x.v)+x.u}},ie=function(t){var e=Math.pow(10,((t+"").split(".")[1]||"").length);return function(r){var i=lt(Math.round(parseFloat(r)/t)*t*e);return(i-i%1)/e+(C(r)?0:Ht(r))}},ne=function(t,e){var r,i,n=F(t);return!n&&E(t)&&(r=n=t.radius||g,t.values?(t=Zt(t.values),(i=!C(t[0]))&&(r*=r)):t=ie(t.increment)),Yt(e,n?A(t)?function(e){return i=t(e),Math.abs(i-e)<=r?i:e}:function(e){for(var n,s,a=parseFloat(i?e.x:e),o=parseFloat(i?e.y:0),u=g,h=0,f=t.length;f--;)(n=i?(n=t[f].x-a)*n+(s=t[f].y-o)*s:Math.abs(t[f]-a))(n=Math.abs(n))&&(s=i,o=n);return s},fe=function(t,e,r){var i,n,s,a=t.vars,u=a[e],h=o,f=t._ctx;if(u)return i=a[e+"Params"],n=a.callbackScope||t,r&&tt.length&&pt(),f&&(o=f),s=i?u.apply(n,i):u.call(n),o=h,s},_e=function(t){return Mt(t),t.scrollTrigger&&t.scrollTrigger.kill(!!a),t.progress()<1&&fe(t,"onInterrupt"),t},le=[],ce=function(t){if(O()&&t){var e=(t=!t.name&&t.default||t).name,r=A(t),i=e&&!r&&t.init?function(){this._props=[]}:t,n={init:H,render:nr,add:Qe,kill:ar,modifier:sr,rawVars:0},s={targetTest:0,get:0,getSetter:tr,aliases:{},register:0};if(xe(),t!==i){if(rt[e])return;yt(i,yt(bt(t,n),s)),Tt(i.prototype,Tt(n,bt(t,s))),rt[i.prop=e]=i,t.targetTest&&(st.push(i),Z[e]=1),e=("css"===e?"CSS":e.charAt(0).toUpperCase()+e.substr(1))+"Plugin"}$(e,i),t.register&&t.register(br,i,hr)}else t&&le.push(t)},de=255,pe={aqua:[0,de,de],lime:[0,de,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,de],navy:[0,0,128],white:[de,de,de],olive:[128,128,0],yellow:[de,de,0],orange:[de,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[de,0,0],pink:[de,192,203],cyan:[0,de,de],transparent:[de,de,de,0]},me=function(t,e,r){return(6*(t+=t<0?1:t>1?-1:0)<1?e+(r-e)*t*6:t<.5?r:3*t<2?e+(r-e)*(2/3-t)*6:e)*de+.5|0},ve=function(t,e,r){var i,n,s,a,o,u,h,f,_,l,c=t?C(t)?[t>>16,t>>8&de,t&de]:0:pe.black;if(!c){if(","===t.substr(-1)&&(t=t.substr(0,t.length-1)),pe[t])c=pe[t];else if("#"===t.charAt(0)){if(t.length<6&&(i=t.charAt(1),n=t.charAt(2),s=t.charAt(3),t="#"+i+i+n+n+s+s+(5===t.length?t.charAt(4)+t.charAt(4):"")),9===t.length)return[(c=parseInt(t.substr(1,6),16))>>16,c>>8&de,c&de,parseInt(t.substr(7),16)/255];c=[(t=parseInt(t.substr(1),16))>>16,t>>8&de,t&de]}else if("hsl"===t.substr(0,3))if(c=l=t.match(L),e){if(~t.indexOf("="))return c=t.match(I),r&&c.length<4&&(c[3]=1),c}else a=+c[0]%360/360,o=+c[1]/100,i=2*(u=+c[2]/100)-(n=u<=.5?u*(o+1):u+o-u*o),c.length>3&&(c[3]*=1),c[0]=me(a+1/3,i,n),c[1]=me(a,i,n),c[2]=me(a-1/3,i,n);else c=t.match(L)||pe.transparent;c=c.map(Number)}return e&&!l&&(i=c[0]/de,n=c[1]/de,s=c[2]/de,u=((h=Math.max(i,n,s))+(f=Math.min(i,n,s)))/2,h===f?a=o=0:(_=h-f,o=u>.5?_/(2-h-f):_/(h+f),a=h===i?(n-s)/_+(no&&(c+=y-u),((f=(l=(d+=y)-c)-v)>0||T)&&(p=++i.frame,n=l-1e3*i.time,i.time=l/=1e3,v+=f+(f>=m?4:m-f),_=1),T||(t=e(r)),_)for(s=0;s=e&&s--},_listeners:g}}(),xe=function(){return!p&&ke.wake()},De={},Me=/^[\d.\-M][\d.\-,\s]/,Ae=/["']/g,Ce=function(t){for(var e,r,i,n={},s=t.substr(1,t.length-3).split(":"),a=s[0],o=1,u=s.length;o1&&r.config?r.config.apply(null,~t.indexOf("{")?[Ce(e[1])]:function(t){var e=t.indexOf("(")+1,r=t.indexOf(")"),i=t.indexOf("(",e);return t.substring(e,~i&&i=1?r:1,s=(i||(e?.3:.45))/(r<1?r:1),a=s/T*(Math.asin(1/n)||0),o=function(t){return 1===t?1:n*Math.pow(2,-10*t)*D((t-a)*s)+1},u="out"===e?o:"in"===e?function(t){return 1-o(1-t)}:ze(o);return s=T/s,u.config=function(r,i){return t(e,r,i)},u},Fe=function t(e,r){void 0===r&&(r=1.70158);var i=function(t){return t?--t*t*((r+1)*t+r)+1:0},n="out"===e?i:"in"===e?function(t){return 1-i(1-t)}:ze(i);return n.config=function(r){return t(e,r)},n};ft("Linear,Quad,Cubic,Quart,Quint,Strong",(function(t,e){var r=e<5?e+1:e;Oe(t+",Power"+(r-1),e?function(t){return Math.pow(t,r)}:function(t){return t},(function(t){return 1-Math.pow(1-t,r)}),(function(t){return t<.5?Math.pow(2*t,r)/2:1-Math.pow(2*(1-t),r)/2}))})),De.Linear.easeNone=De.none=De.Linear.easeIn,Oe("Elastic",Pe("in"),Pe("out"),Pe()),function(t,e){var r=1/e,i=function(i){return i0?t+(t+this._rDelay)*this._repeat:t):this.totalDuration()&&this._dur},e.totalDuration=function(t){return arguments.length?(this._dirty=0,Qt(this,this._repeat<0?t:(t-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},e.totalTime=function(t,e){if(xe(),!arguments.length)return this._tTime;var r=this._dp;if(r&&r.smoothChildTiming&&this._ts){for(Ft(this,t),!r._dp||r.parent||Lt(r,this);r&&r.parent;)r.parent._time!==r._start+(r._ts>=0?r._tTime/r._ts:(r.totalDuration()-r._tTime)/-r._ts)&&r.totalTime(r._tTime,!0),r=r.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&t0||!this._tDur&&!t)&&It(this._dp,this,this._start-this._delay)}return(this._tTime!==t||!this._dur&&!e||this._initted&&Math.abs(this._zTime)===y||!t&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=t),mt(this,t,e)),this},e.time=function(t,e){return arguments.length?this.totalTime(Math.min(this.totalDuration(),t+St(this))%(this._dur+this._rDelay)||(t?this._dur:0),e):this._time},e.totalProgress=function(t,e){return arguments.length?this.totalTime(this.totalDuration()*t,e):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>0?1:0},e.progress=function(t,e){return arguments.length?this.totalTime(this.duration()*(!this._yoyo||1&this.iteration()?t:1-t)+St(this),e):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},e.iteration=function(t,e){var r=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(t-1)*r,e):this._repeat?Ot(this._tTime,r)+1:1},e.timeScale=function(t,e){if(!arguments.length)return-1e-8===this._rts?0:this._rts;if(this._rts===t)return this;var r=this.parent&&this._ts?zt(this.parent._time,this):this._tTime;return this._rts=+t||0,this._ts=this._ps||-1e-8===t?0:this._rts,this.totalTime($t(-Math.abs(this._delay),this._tDur,r),!1!==e),Pt(this),Ct(this)},e.paused=function(t){return arguments.length?(this._ps!==t&&(this._ps=t,t?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(xe(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,1===this.progress()&&Math.abs(this._zTime)!==y&&(this._tTime-=y)))),this):this._ps},e.startTime=function(t){if(arguments.length){this._start=t;var e=this.parent||this._dp;return e&&(e._sort||!this.parent)&&It(e,this,t-this._delay),this}return this._start},e.endTime=function(t){return this._start+(S(t)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},e.rawTime=function(t){var e=this.parent||this._dp;return e?t&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?zt(e.rawTime(t),this):this._tTime:this._tTime},e.revert=function(t){void 0===t&&(t=X);var e=a;return a=t,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(t),this.totalTime(-.01,t.suppressEvents)),"nested"!==this.data&&!1!==t.kill&&this.kill(),a=e,this},e.globalTime=function(t){for(var e=this,r=arguments.length?t:e.rawTime();e;)r=e._start+r/(Math.abs(e._ts)||1),e=e._dp;return!this.parent&&this._sat?this._sat.globalTime(t):r},e.repeat=function(t){return arguments.length?(this._repeat=t===1/0?-2:t,Vt(this)):-2===this._repeat?1/0:this._repeat},e.repeatDelay=function(t){if(arguments.length){var e=this._time;return this._rDelay=t,Vt(this),e?this.time(e):this}return this._rDelay},e.yoyo=function(t){return arguments.length?(this._yoyo=t,this):this._yoyo},e.seek=function(t,e){return this.totalTime(Gt(this,t),S(e))},e.restart=function(t,e){return this.play().totalTime(t?-this._delay:0,S(e))},e.play=function(t,e){return null!=t&&this.seek(t,e),this.reversed(!1).paused(!1)},e.reverse=function(t,e){return null!=t&&this.seek(t||this.totalDuration(),e),this.reversed(!0).paused(!1)},e.pause=function(t,e){return null!=t&&this.seek(t,e),this.paused(!0)},e.resume=function(){return this.paused(!1)},e.reversed=function(t){return arguments.length?(!!t!==this.reversed()&&this.timeScale(-this._rts||(t?-1e-8:0)),this):this._rts<0},e.invalidate=function(){return this._initted=this._act=0,this._zTime=-1e-8,this},e.isActive=function(){var t,e=this.parent||this._dp,r=this._start;return!(e&&!(this._ts&&this._initted&&e.isActive()&&(t=e.rawTime(!0))>=r&&t1?(e?(i[t]=e,r&&(i[t+"Params"]=r),"onUpdate"===t&&(this._onUpdate=e)):delete i[t],this):i[t]},e.then=function(t){var e=this;return new Promise((function(r){var i=A(t)?t:gt,n=function(){var t=e.then;e.then=null,A(i)&&(i=i(e))&&(i.then||i===e)&&(e.then=t),r(i),e.then=t};e._initted&&1===e.totalProgress()&&e._ts>=0||!e._tTime&&e._ts<0?n():e._prom=n}))},e.kill=function(){_e(this)},t}();yt(Ie.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-1e-8,_prom:0,_ps:!1,_rts:1});var Ue=function(t){function e(e,r){var n;return void 0===e&&(e={}),(n=t.call(this,e)||this).labels={},n.smoothChildTiming=!!e.smoothChildTiming,n.autoRemoveChildren=!!e.autoRemoveChildren,n._sort=S(e.sortChildren),u&&It(e.parent||u,i(n),r),e.reversed&&n.reverse(),e.paused&&n.paused(!0),e.scrollTrigger&&Ut(i(n),e.scrollTrigger),n}n(e,t);var r=e.prototype;return r.to=function(t,e,r){return Wt(0,arguments,this),this},r.from=function(t,e,r){return Wt(1,arguments,this),this},r.fromTo=function(t,e,r,i){return Wt(2,arguments,this),this},r.set=function(t,e,r){return e.duration=0,e.parent=this,kt(e).repeatDelay||(e.repeat=0),e.immediateRender=!!e.immediateRender,new He(t,e,Gt(this,r),1),this},r.call=function(t,e,r){return It(this,He.delayedCall(0,t,e),r)},r.staggerTo=function(t,e,r,i,n,s,a){return r.duration=e,r.stagger=r.stagger||i,r.onComplete=s,r.onCompleteParams=a,r.parent=this,new He(t,r,Gt(this,n)),this},r.staggerFrom=function(t,e,r,i,n,s,a){return r.runBackwards=1,kt(r).immediateRender=S(r.immediateRender),this.staggerTo(t,e,r,i,n,s,a)},r.staggerFromTo=function(t,e,r,i,n,s,a,o){return i.startAt=r,kt(i).immediateRender=S(i.immediateRender),this.staggerTo(t,e,i,n,s,a,o)},r.render=function(t,e,r){var i,n,s,o,h,f,_,l,c,d,p,m,v=this._time,g=this._dirty?this.totalDuration():this._tDur,T=this._dur,w=t<=0?0:lt(t),b=this._zTime<0!==t<0&&(this._initted||!T);if(this!==u&&w>g&&t>=0&&(w=g),w!==this._tTime||r||b){if(v!==this._time&&T&&(w+=this._time-v,t+=this._time-v),i=w,c=this._start,f=!(l=this._ts),b&&(T||(v=this._zTime),(t||!e)&&(this._zTime=t)),this._repeat){if(p=this._yoyo,h=T+this._rDelay,this._repeat<-1&&t<0)return this.totalTime(100*h+t,e,r);if(i=lt(w%h),w===g?(o=this._repeat,i=T):((o=~~(w/h))&&o===w/h&&(i=T,o--),i>T&&(i=T)),d=Ot(this._tTime,h),!v&&this._tTime&&d!==o&&this._tTime-d*h-this._dur<=0&&(d=o),p&&1&o&&(i=T-i,m=1),o!==d&&!this._lock){var k=p&&1&d,x=k===(p&&1&o);if(oe)for(i=t._first;i&&i._start<=r;){if("isPause"===i.data&&i._start>e)return i;i=i._next}else for(i=t._last;i&&i._start>=r;){if("isPause"===i.data&&i._start=v&&t>=0)for(n=this._first;n;){if(s=n._next,(n._act||i>=n._start)&&n._ts&&_!==n){if(n.parent!==this)return this.render(t,e,r);if(n.render(n._ts>0?(i-n._start)*n._ts:(n._dirty?n.totalDuration():n._tDur)+(i-n._start)*n._ts,e,r),i!==this._time||!this._ts&&!f){_=0,s&&(w+=this._zTime=-1e-8);break}}n=s}else{n=this._last;for(var D=t<0?t:i;n;){if(s=n._prev,(n._act||D<=n._end)&&n._ts&&_!==n){if(n.parent!==this)return this.render(t,e,r);if(n.render(n._ts>0?(D-n._start)*n._ts:(n._dirty?n.totalDuration():n._tDur)+(D-n._start)*n._ts,e,r||a&&(n._initted||n._startAt)),i!==this._time||!this._ts&&!f){_=0,s&&(w+=this._zTime=D?-1e-8:y);break}}n=s}}if(_&&!e&&(this.pause(),_.render(i>=v?0:-1e-8)._zTime=i>=v?1:-1,this._ts))return this._start=c,Pt(this),this.render(t,e,r);this._onUpdate&&!e&&fe(this,"onUpdate",!0),(w===g&&this._tTime>=this.totalDuration()||!w&&v)&&(c!==this._start&&Math.abs(l)===Math.abs(this._ts)||this._lock||((t||!T)&&(w===g&&this._ts>0||!w&&this._ts<0)&&Mt(this,1),e||t<0&&!v||!w&&!v&&g||(fe(this,w===g&&t>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(w0)&&this._prom())))}return this},r.add=function(t,e){var r=this;if(C(e)||(e=Gt(this,e,t)),!(t instanceof Ie)){if(F(t))return t.forEach((function(t){return r.add(t,e)})),this;if(M(t))return this.addLabel(t,e);if(!A(t))return this;t=He.delayedCall(0,t)}return this!==t?It(this,t,e):this},r.getChildren=function(t,e,r,i){void 0===t&&(t=!0),void 0===e&&(e=!0),void 0===r&&(r=!0),void 0===i&&(i=-g);for(var n=[],s=this._first;s;)s._start>=i&&(s instanceof He?e&&n.push(s):(r&&n.push(s),t&&n.push.apply(n,s.getChildren(!0,e,r)))),s=s._next;return n},r.getById=function(t){for(var e=this.getChildren(1,1,1),r=e.length;r--;)if(e[r].vars.id===t)return e[r]},r.remove=function(t){return M(t)?this.removeLabel(t):A(t)?this.killTweensOf(t):(Dt(this,t),t===this._recent&&(this._recent=this._last),At(this))},r.totalTime=function(e,r){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=lt(ke.time-(this._ts>0?e/this._ts:(this.totalDuration()-e)/-this._ts))),t.prototype.totalTime.call(this,e,r),this._forcing=0,this):this._tTime},r.addLabel=function(t,e){return this.labels[t]=Gt(this,e),this},r.removeLabel=function(t){return delete this.labels[t],this},r.addPause=function(t,e,r){var i=He.delayedCall(0,e||H,r);return i.data="isPause",this._hasPause=1,It(this,i,Gt(this,t))},r.removePause=function(t){var e=this._first;for(t=Gt(this,t);e;)e._start===t&&"isPause"===e.data&&Mt(e),e=e._next},r.killTweensOf=function(t,e,r){for(var i=this.getTweensOf(t,r),n=i.length;n--;)Be!==i[n]&&i[n].kill(t,e);return this},r.getTweensOf=function(t,e){for(var r,i=[],n=Zt(t),s=this._first,a=C(e);s;)s instanceof He?dt(s._targets,n)&&(a?(!Be||s._initted&&s._ts)&&s.globalTime(0)<=e&&s.globalTime(s.totalDuration())>e:!e||s.isActive())&&i.push(s):(r=s.getTweensOf(n,e)).length&&i.push.apply(i,r),s=s._next;return i},r.tweenTo=function(t,e){e=e||{};var r,i=this,n=Gt(i,t),s=e,a=s.startAt,o=s.onStart,u=s.onStartParams,h=s.immediateRender,f=He.to(i,yt({ease:e.ease||"none",lazy:!1,immediateRender:!1,time:n,overwrite:"auto",duration:e.duration||Math.abs((n-(a&&"time"in a?a.time:i._time))/i.timeScale())||y,onStart:function(){if(i.pause(),!r){var t=e.duration||Math.abs((n-(a&&"time"in a?a.time:i._time))/i.timeScale());f._dur!==t&&Qt(f,t,0,1).render(f._time,!0,!0),r=1}o&&o.apply(f,u||[])}},e));return h?f.render(0):f},r.tweenFromTo=function(t,e,r){return this.tweenTo(e,yt({startAt:{time:Gt(this,t)}},r))},r.recent=function(){return this._recent},r.nextLabel=function(t){return void 0===t&&(t=this._time),he(this,Gt(this,t))},r.previousLabel=function(t){return void 0===t&&(t=this._time),he(this,Gt(this,t),1)},r.currentLabel=function(t){return arguments.length?this.seek(t,!0):this.previousLabel(this._time+y)},r.shiftChildren=function(t,e,r){void 0===r&&(r=0);for(var i,n=this._first,s=this.labels;n;)n._start>=r&&(n._start+=t,n._end+=t),n=n._next;if(e)for(i in s)s[i]>=r&&(s[i]+=t);return At(this)},r.invalidate=function(e){var r=this._first;for(this._lock=0;r;)r.invalidate(e),r=r._next;return t.prototype.invalidate.call(this,e)},r.clear=function(t){void 0===t&&(t=!0);for(var e,r=this._first;r;)e=r._next,this.remove(r),r=e;return this._dp&&(this._time=this._tTime=this._pTime=0),t&&(this.labels={}),At(this)},r.totalDuration=function(t){var e,r,i,n=0,s=this,a=s._last,o=g;if(arguments.length)return s.timeScale((s._repeat<0?s.duration():s.totalDuration())/(s.reversed()?-t:t));if(s._dirty){for(i=s.parent;a;)e=a._prev,a._dirty&&a.totalDuration(),(r=a._start)>o&&s._sort&&a._ts&&!s._lock?(s._lock=1,It(s,a,r-a._delay,1)._lock=0):o=r,r<0&&a._ts&&(n-=r,(!i&&!s._dp||i&&i.smoothChildTiming)&&(s._start+=r/s._ts,s._time-=r,s._tTime-=r),s.shiftChildren(-r,!1,-Infinity),o=0),a._end>n&&a._ts&&(n=a._end),a=e;Qt(s,s===u&&s._time>n?s._time:n,1,1),s._dirty=0}return s._tDur},e.updateRoot=function(t){if(u._ts&&(mt(u,zt(t,u)),c=ke.frame),ke.frame>=nt){nt+=m.autoSleep||120;var e=u._first;if((!e||!e._ts)&&m.autoSleep&&ke._listeners.length<2){for(;e&&!e._ts;)e=e._next;e||ke.sleep()}}},e}(Ie);yt(Ue.prototype,{_lock:0,_hasPause:0,_forcing:0});var Be,Ne,qe=function(t,e,r,i,n,s,a){var o,u,h,f,_,l,c,d,p=new hr(this._pt,t,e,0,1,ir,null,n),m=0,v=0;for(p.b=r,p.e=i,r+="",(c=~(i+="").indexOf("random("))&&(i=oe(i)),s&&(s(d=[r,i],t,e),r=d[0],i=d[1]),u=r.match(B)||[];o=B.exec(i);)f=o[0],_=i.substring(m,o.index),h?h=(h+1)%5:"rgba("===_.substr(-5)&&(h=1),f!==u[v++]&&(l=parseFloat(u[v-1])||0,p._pt={_next:p._pt,p:_||1===v?_:",",s:l,c:"="===f.charAt(1)?ct(l,f)-l:parseFloat(f)-l,m:h&&h<4?Math.round:0},m=B.lastIndex);return p.c=m")})),h.duration();else{for(c in _={},x)"ease"===c||"easeEach"===c||Ge(c,x[c],_,x.easeEach);for(c in _)for(L=_[c].sort((function(t,e){return t.t-e.t})),B=0,f=0;fd-y&&!m?d:tp&&(i=p)),(h=this._yoyo&&1&s)&&(l=this._yEase,i=p-i),u=Ot(this._tTime,o),i===c&&!r&&this._initted&&s===u)return this._tTime=v,this;s!==u&&(_&&this._yEase&&Ee(_,h),this.vars.repeatRefresh&&!h&&!this._lock&&this._time!==p&&this._initted&&(this._lock=r=1,this.render(lt(o*s),!0).invalidate()._lock=0))}if(!this._initted){if(Bt(this,m?t:i,r,e,v))return this._tTime=0,this;if(c!==this._time&&(!r||!this.vars.repeatRefresh||s===u))return this;if(p!==this._dur)return this.render(t,e,r)}if(this._tTime=v,this._time=i,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=f=(l||this._ease)(i/p),this._from&&(this.ratio=f=1-f),i&&!c&&!e&&!s&&(fe(this,"onStart"),this._tTime!==v))return this;for(n=this._pt;n;)n.r(f,n.d),n=n._next;_&&_.render(t<0?t:!i&&h?-1e-8:_._dur*_._ease(i/this._dur),e,r)||this._startAt&&(this._zTime=t),this._onUpdate&&!e&&(m&&Rt(this,t,0,r),fe(this,"onUpdate")),this._repeat&&s!==u&&this.vars.onRepeat&&!e&&this.parent&&fe(this,"onRepeat"),v!==this._tDur&&v||this._tTime!==v||(m&&!this._onUpdate&&Rt(this,t,0,!0),(t||!p)&&(v===this._tDur&&this._ts>0||!v&&this._ts<0)&&Mt(this,1),e||m&&!c||!(v||c||h)||(fe(this,v===d?"onComplete":"onReverseComplete",!0),this._prom&&!(v0)&&this._prom()))}}else!function(t,e,r,i){var n,s,o,u=t.ratio,h=e<0||!e&&(!t._start&&Nt(t)&&(t._initted||!qt(t))||(t._ts<0||t._dp._ts<0)&&!qt(t))?0:1,f=t._rDelay,_=0;if(f&&t._repeat&&(_=$t(0,t._tDur,e),s=Ot(_,f),t._yoyo&&1&s&&(h=1-h),s!==Ot(t._tTime,f)&&(u=1-h,t.vars.repeatRefresh&&t._initted&&t.invalidate())),h!==u||a||i||t._zTime===y||!e&&t._zTime){if(!t._initted&&Bt(t,e,i,r,_))return;for(o=t._zTime,t._zTime=e||(r?y:0),r||(r=e&&!o),t.ratio=h,t._from&&(h=1-h),t._time=0,t._tTime=_,n=t._pt;n;)n.r(h,n.d),n=n._next;e<0&&Rt(t,e,0,!0),t._onUpdate&&!r&&fe(t,"onUpdate"),_&&t._repeat&&!r&&t.parent&&fe(t,"onRepeat"),(e>=t._tDur||e<0)&&t.ratio===h&&(h&&Mt(t,1),r||a||(fe(t,h?"onComplete":"onReverseComplete",!0),t._prom&&t._prom()))}else t._zTime||(t._zTime=e)}(this,t,e,r);return this},r.targets=function(){return this._targets},r.invalidate=function(e){return(!e||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(e),t.prototype.invalidate.call(this,e)},r.resetTo=function(t,e,r,i,n){p||ke.wake(),this._ts||this.play();var s=Math.min(this._dur,(this._dp._time-this._start)*this._ts);return this._initted||je(this,s),function(t,e,r,i,n,s,a,o){var u,h,f,_,l=(t._pt&&t._ptCache||(t._ptCache={}))[e];if(!l)for(l=t._ptCache[e]=[],f=t._ptLookup,_=t._targets.length;_--;){if((u=f[_][e])&&u.d&&u.d._pt)for(u=u.d._pt;u&&u.p!==e&&u.fp!==e;)u=u._next;if(!u)return Ne=1,t.vars[e]="+=0",je(t,a),Ne=0,o?Y(e+" not eligible for reset"):1;l.push(u)}for(_=l.length;_--;)(u=(h=l[_])._pt||h).s=!i&&0!==i||n?u.s+(i||0)+s*u.c:i,u.c=r-u.s,h.e&&(h.e=_t(r)+Ht(h.e)),h.b&&(h.b=u.s+Ht(h.b))}(this,t,e,r,i,this._ease(s/this._dur),s,n)?this.resetTo(t,e,r,i,1):(Ft(this,0),this.parent||xt(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},r.kill=function(t,e){if(void 0===e&&(e="all"),!t&&(!e||"all"===e))return this._lazy=this._pt=0,this.parent?_e(this):this;if(this.timeline){var r=this.timeline.totalDuration();return this.timeline.killTweensOf(t,e,Be&&!0!==Be.vars.overwrite)._first||_e(this),this.parent&&r!==this.timeline.totalDuration()&&Qt(this,this._dur*this.timeline._tDur/r,0,1),this}var i,n,s,a,o,u,h,f=this._targets,_=t?Zt(t):f,l=this._ptLookup,c=this._pt;if((!e||"all"===e)&&function(t,e){for(var r=t.length,i=r===e.length;i&&r--&&t[r]===e[r];);return r<0}(f,_))return"all"===e&&(this._pt=0),_e(this);for(i=this._op=this._op||[],"all"!==e&&(M(e)&&(o={},ft(e,(function(t){return o[t]=1})),e=o),e=function(t,e){var r,i,n,s,a=t[0]?ut(t[0]).harness:0,o=a&&a.aliases;if(!o)return e;for(i in r=Tt({},e),o)if(i in r)for(n=(s=o[i].split(",")).length;n--;)r[s[n]]=r[i];return r}(f,e)),h=f.length;h--;)if(~_.indexOf(f[h]))for(o in n=l[h],"all"===e?(i[h]=e,a=n,s={}):(s=i[h]=i[h]||{},a=e),a)(u=n&&n[o])&&("kill"in u.d&&!0!==u.d.kill(o)||Dt(this,u,"_pt"),delete n[o]),"all"!==s&&(s[o]=1);return this._initted&&!this._pt&&c&&_e(this),this},e.to=function(t,r){return new e(t,r,arguments[2])},e.from=function(t,e){return Wt(1,arguments)},e.delayedCall=function(t,r,i,n){return new e(r,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:t,onComplete:r,onReverseComplete:r,onCompleteParams:i,onReverseCompleteParams:i,callbackScope:n})},e.fromTo=function(t,e,r){return Wt(2,arguments)},e.set=function(t,r){return r.duration=0,r.repeatDelay||(r.repeat=0),new e(t,r)},e.killTweensOf=function(t,e,r){return u.killTweensOf(t,e,r)},e}(Ie);yt(He.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0}),ft("staggerTo,staggerFrom,staggerFromTo",(function(t){He[t]=function(){var e=new Ue,r=Jt.call(arguments,0);return r.splice("staggerFromTo"===t?5:4,0,0),e[t].apply(e,r)}}));var Je=function(t,e,r){return t[e]=r},Ke=function(t,e,r){return t[e](r)},Xe=function(t,e,r,i){return t[e](i.fp,r)},Ze=function(t,e,r){return t.setAttribute(e,r)},tr=function(t,e){return A(t[e])?Ke:R(t[e])&&t.setAttribute?Ze:Je},er=function(t,e){return e.set(e.t,e.p,Math.round(1e6*(e.s+e.c*t))/1e6,e)},rr=function(t,e){return e.set(e.t,e.p,!!(e.s+e.c*t),e)},ir=function(t,e){var r=e._pt,i="";if(!t&&e.b)i=e.b;else if(1===t&&e.e)i=e.e;else{for(;r;)i=r.p+(r.m?r.m(r.s+r.c*t):Math.round(1e4*(r.s+r.c*t))/1e4)+i,r=r._next;i+=e.c}e.set(e.t,e.p,i,e)},nr=function(t,e){for(var r=e._pt;r;)r.r(t,r.d),r=r._next},sr=function(t,e,r,i){for(var n,s=this._pt;s;)n=s._next,s.p===i&&s.modifier(t,e,r),s=n},ar=function(t){for(var e,r,i=this._pt;i;)r=i._next,i.p===t&&!i.op||i.op===t?Dt(this,i,"_pt"):i.dep||(e=1),i=r;return!e},or=function(t,e,r,i){i.mSet(t,e,i.m.call(i.tween,r,i.mt),i)},ur=function(t){for(var e,r,i,n,s=t._pt;s;){for(e=s._next,r=i;r&&r.pr>s.pr;)r=r._next;(s._prev=r?r._prev:n)?s._prev._next=s:i=s,(s._next=r)?r._prev=s:n=s,s=e}t._pt=i},hr=function(){function t(t,e,r,i,n,s,a,o,u){this.t=e,this.s=i,this.c=n,this.p=r,this.r=s||er,this.d=a||this,this.set=o||Je,this.pr=u||0,this._next=t,t&&(t._prev=this)}return t.prototype.modifier=function(t,e,r){this.mSet=this.mSet||this.set,this.set=or,this.m=t,this.mt=r,this.tween=e},t}();ft(at+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",(function(t){return Z[t]=1})),V.TweenMax=V.TweenLite=He,V.TimelineLite=V.TimelineMax=Ue,u=new Ue({sortChildren:!1,defaults:v,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0}),m.stringFilter=be;var fr=[],_r={},lr=[],cr=0,dr=0,pr=function(t){return(_r[t]||lr).map((function(t){return t()}))},mr=function(){var t=Date.now(),e=[];t-cr>2&&(pr("matchMediaInit"),fr.forEach((function(t){var r,i,n,s,a=t.queries,o=t.conditions;for(i in a)(r=h.matchMedia(a[i]).matches)&&(n=1),r!==o[i]&&(o[i]=r,s=1);s&&(t.revert(),n&&e.push(t))})),pr("matchMediaRevert"),e.forEach((function(t){return t.onMatch(t,(function(e){return t.add(null,e)}))})),cr=t,pr("matchMedia"))},vr=function(){function t(t,e){this.selector=e&&te(e),this.data=[],this._r=[],this.isReverted=!1,this.id=dr++,t&&this.add(t)}var e=t.prototype;return e.add=function(t,e,r){A(t)&&(r=e,e=t,t=A);var i=this,n=function(){var t,n=o,s=i.selector;return n&&n!==i&&n.data.push(i),r&&(i.selector=te(r)),o=i,t=e.apply(i,arguments),A(t)&&i._r.push(t),o=n,i.selector=s,i.isReverted=!1,t};return i.last=n,t===A?n(i,(function(t){return i.add(null,t)})):t?i[t]=n:n},e.ignore=function(t){var e=o;o=null,t(this),o=e},e.getTweens=function(){var e=[];return this.data.forEach((function(r){return r instanceof t?e.push.apply(e,r.getTweens()):r instanceof He&&!(r.parent&&"nested"===r.parent.data)&&e.push(r)})),e},e.clear=function(){this._r.length=this.data.length=0},e.kill=function(t,e){var r=this;if(t?function(){for(var e,i=r.getTweens(),n=r.data.length;n--;)"isFlip"===(e=r.data[n]).data&&(e.revert(),e.getChildren(!0,!0,!1).forEach((function(t){return i.splice(i.indexOf(t),1)})));for(i.map((function(t){return{g:t._dur||t._delay||t._sat&&!t._sat.vars.immediateRender?t.globalTime(0):-1/0,t:t}})).sort((function(t,e){return e.g-t.g||-1/0})).forEach((function(e){return e.t.revert(t)})),n=r.data.length;n--;)(e=r.data[n])instanceof Ue?"nested"!==e.data&&(e.scrollTrigger&&e.scrollTrigger.revert(),e.kill()):!(e instanceof He)&&e.revert&&e.revert(t);r._r.forEach((function(e){return e(t,r)})),r.isReverted=!0}():this.data.forEach((function(t){return t.kill&&t.kill()})),this.clear(),e)for(var i=fr.length;i--;)fr[i].id===this.id&&fr.splice(i,1)},e.revert=function(t){this.kill(t||{})},t}(),gr=function(){function t(t){this.contexts=[],this.scope=t}var e=t.prototype;return e.add=function(t,e,r){E(t)||(t={matches:t});var i,n,s,a=new vr(0,r||this.scope),u=a.conditions={};for(n in o&&!a.selector&&(a.selector=o.selector),this.contexts.push(a),e=a.add("onMatch",e),a.queries=t,t)"all"===n?s=1:(i=h.matchMedia(t[n]))&&(fr.indexOf(a)<0&&fr.push(a),(u[n]=i.matches)&&(s=1),i.addListener?i.addListener(mr):i.addEventListener("change",mr));return s&&e(a,(function(t){return a.add(null,t)})),this},e.revert=function(t){this.kill(t||{})},e.kill=function(t){this.contexts.forEach((function(e){return e.kill(t,!0)}))},t}(),yr={registerPlugin:function(){for(var t=arguments.length,e=new Array(t),r=0;r1){var i=t.map((function(t){return br.quickSetter(t,e,r)})),n=i.length;return function(t){for(var e=n;e--;)i[e](t)}}t=t[0]||{};var s=rt[e],a=ut(t),o=a.harness&&(a.harness.aliases||{})[e]||e,u=s?function(e){var i=new s;d._pt=0,i.init(t,r?e+r:e,d,0,[t]),i.render(1,i),d._pt&&nr(1,d)}:a.set(t,o);return s?u:function(e){return u(t,o,r?e+r:e,a,1)}},quickTo:function(t,e,r){var i,n=br.to(t,Tt(((i={})[e]="+=0.1",i.paused=!0,i),r||{})),s=function(t,r,i){return n.resetTo(e,t,r,i)};return s.tween=n,s},isTweening:function(t){return u.getTweensOf(t,!0).length>0},defaults:function(t){return t&&t.ease&&(t.ease=Se(t.ease,v.ease)),wt(v,t||{})},config:function(t){return wt(m,t||{})},registerEffect:function(t){var e=t.name,r=t.effect,i=t.plugins,n=t.defaults,s=t.extendTimeline;(i||"").split(",").forEach((function(t){return t&&!rt[t]&&!V[t]&&Y(e+" effect requires "+t+" plugin.")})),it[e]=function(t,e,i){return r(Zt(t),yt(e||{},n),i)},s&&(Ue.prototype[e]=function(t,r,i){return this.add(it[e](t,E(r)?r:(i=r)&&{},this),i)})},registerEase:function(t,e){De[t]=Se(e)},parseEase:function(t,e){return arguments.length?Se(t,e):De},getById:function(t){return u.getById(t)},exportRoot:function(t,e){void 0===t&&(t={});var r,i,n=new Ue(t);for(n.smoothChildTiming=S(t.smoothChildTiming),u.remove(n),n._dp=0,n._time=n._tTime=u._time,r=u._first;r;)i=r._next,!e&&!r._dur&&r instanceof He&&r.vars.onComplete===r._targets[0]||It(n,r,r._start-r._delay),r=i;return It(u,n,0),n},context:function(t,e){return t?new vr(t,e):o},matchMedia:function(t){return new gr(t)},matchMediaRefresh:function(){return fr.forEach((function(t){var e,r,i=t.conditions;for(r in i)i[r]&&(i[r]=!1,e=1);e&&t.revert()}))||mr()},addEventListener:function(t,e){var r=_r[t]||(_r[t]=[]);~r.indexOf(e)||r.push(e)},removeEventListener:function(t,e){var r=_r[t],i=r&&r.indexOf(e);i>=0&&r.splice(i,1)},utils:{wrap:function t(e,r,i){var n=r-e;return F(e)?ae(e,t(0,e.length),r):Yt(i,(function(t){return(n+(t-e)%n)%n+e}))},wrapYoyo:function t(e,r,i){var n=r-e,s=2*n;return F(e)?ae(e,t(0,e.length-1),r):Yt(i,(function(t){return e+((t=(s+(t-e)%s)%s||0)>n?s-t:t)}))},distribute:re,random:se,snap:ne,normalize:function(t,e,r){return ue(t,e,0,1,r)},getUnit:Ht,clamp:function(t,e,r){return Yt(r,(function(r){return $t(t,e,r)}))},splitColor:ve,toArray:Zt,selector:te,mapRange:ue,pipe:function(){for(var t=arguments.length,e=new Array(t),r=0;r1?function(t){for(var e=new C,n=0;n4&&(a=s.offsetLeft,u=s.offsetTop,s=0);if("absolute"!==(d=r.getComputedStyle(t)).position&&"fixed"!==d.position)for(i=t.offsetParent;M&&M!==i;)a+=M.scrollLeft||0,u+=M.scrollTop||0,M=M.parentNode;(s=n.style).top=t.offsetTop-u+"px",s.left=t.offsetLeft-a+"px",s[p]=d[p],s[f]=d[f],s.position="fixed"===d.position?"fixed":"absolute",t.parentNode.appendChild(n)}return n},O=function(t,e,n,i,r,s,a){return t.a=e,t.b=n,t.c=i,t.d=r,t.e=s,t.f=a,t},C=function(){function t(t,e,n,i,r,s){void 0===t&&(t=1),void 0===e&&(e=0),void 0===n&&(n=0),void 0===i&&(i=1),void 0===r&&(r=0),void 0===s&&(s=0),O(this,t,e,n,i,r,s)}var e=t.prototype;return e.inverse=function(){var t=this.a,e=this.b,n=this.c,i=this.d,r=this.e,s=this.f,a=t*i-e*n||1e-10;return O(this,i/a,-e/a,-n/a,t/a,(n*s-i*r)/a,-(t*s-e*r)/a)},e.multiply=function(t){var e=this.a,n=this.b,i=this.c,r=this.d,s=this.e,a=this.f,o=t.a,l=t.c,c=t.b,u=t.d,h=t.e,p=t.f;return O(this,o*e+c*i,o*n+c*r,l*e+u*i,l*n+u*r,s+h*e+p*i,a+h*n+p*r)},e.clone=function(){return new t(this.a,this.b,this.c,this.d,this.e,this.f)},e.equals=function(t){var e=this.a,n=this.b,i=this.c,r=this.d,s=this.e,a=this.f;return e===t.a&&n===t.b&&i===t.c&&r===t.d&&s===t.e&&a===t.f},e.apply=function(t,e){void 0===e&&(e={});var n=t.x,i=t.y,r=this.a,s=this.b,a=this.c,o=this.d,l=this.e,c=this.f;return e.x=n*r+i*a+l||0,e.y=n*s+i*o+c||0,e},t}();function S(t,e,n,r){if(!t||!t.parentNode||(i||d(t)).documentElement===t)return new C;var s=function(t){for(var e,n;t&&t!==a;)(n=t._gsap)&&n.uncache&&n.get(t,"x"),n&&!n.scaleX&&!n.scaleY&&n.renderTransform&&(n.scaleX=n.scaleY=1e-4,n.renderTransform(1,n),e?e.push(n):e=[n]),t=t.parentNode;return e}(t),o=x(t)?g:m,l=M(t,n),c=o[0].getBoundingClientRect(),u=o[1].getBoundingClientRect(),h=o[2].getBoundingClientRect(),p=l.parentNode,f=!r&&b(t),w=new C((u.left-c.left)/100,(u.top-c.top)/100,(h.left-c.left)/100,(h.top-c.top)/100,c.left+(f?0:v()),c.top+(f?0:y()));if(p.removeChild(l),s)for(c=s.length;c--;)(u=s[c]).scaleX=u.scaleY=0,u.renderTransform(1,u);return e?w.inverse():w}var _,P,z,V,T,E,B,L,A=1,F=function(t,e){return t.actions.forEach((function(t){return t.vars[e]&&t.vars[e](t)}))},X={},Y=180/Math.PI,Z=Math.PI/180,I={},N={},H={},j=function(t){return"string"===typeof t?t.split(" ").join("").split(","):t},W=j("onStart,onUpdate,onComplete,onReverseComplete,onInterrupt"),D=j("transform,transformOrigin,width,height,position,top,left,opacity,zIndex,maxWidth,maxHeight,minWidth,minHeight"),R=function(t){return _(t)[0]||console.warn("Element not found:",t)},q=function(t){return Math.round(1e4*t)/1e4||0},G=function(t,e,n){return t.forEach((function(t){return t.classList[n](e)}))},U={zIndex:1,kill:1,simple:1,spin:1,clearProps:1,targets:1,toggleClass:1,onComplete:1,onUpdate:1,onInterrupt:1,onStart:1,delay:1,repeat:1,repeatDelay:1,yoyo:1,scale:1,fade:1,absolute:1,props:1,onEnter:1,onLeave:1,custom:1,paused:1,nested:1,prune:1,absoluteOnLeave:1},$={zIndex:1,simple:1,clearProps:1,scale:1,absolute:1,fitChild:1,getVars:1,props:1},J=function(t){return t.replace(/([A-Z])/g,"-$1").toLowerCase()},K=function(t,e){var n,i={};for(n in t)e[n]||(i[n]=t[n]);return i},Q={},tt=function(t){var e=Q[t]=j(t);return H[t]=e.concat(D),e},et=function t(e,n,i){void 0===i&&(i=0);for(var r=e.parentNode,s=1e3*Math.pow(10,i)*(n?-1:1),a=n?900*-s:0;e;)a+=s,e=e.previousSibling;return r?a+t(r,n,i+1):a},nt=function(t,e,n){return t.forEach((function(t){return t.d=et(n?t.element:t.t,e)})),t.sort((function(t,e){return t.d-e.d})),t},it=function(t,e){for(var n,i,r=t.element.style,s=t.css=t.css||[],a=e.length;a--;)i=r[n=e[a]]||r.getPropertyValue(n),s.push(i?n:N[n]||(N[n]=J(n)),i);return r},rt=function(t){var e=t.css,n=t.element.style,i=0;for(t.cache.uncache=1;i0&&Y&&(l.style.opacity=pt?m.opacity-y.opacity:"0"),gt(m,y,X,j)):y.isVisible!==m.isVisible&&(y.isVisible?m.isVisible||(y.css=m.css,rt.push(y),at.splice(o--,1),M&&A&>(m,y,X,j)):(m.isVisible&&et.push(m),at.splice(o--,1))),X||(l.style.maxWidth=Math.max(m.width,y.width)+"px",l.style.maxHeight=Math.max(m.height,y.height)+"px",l.style.minWidth=Math.min(m.width,y.width)+"px",l.style.minHeight=Math.min(m.height,y.height)+"px"),A&&L&&l.classList.add(L)):at.splice(o--,1),p.push(m);var e;if(L&&(e=p.map((function(t){return t.element})),A&&e.forEach((function(t){return t.classList.remove(L)}))),bt(!1),X?(R.scaleX=function(t){return at[t].a.scaleX},R.scaleY=function(t){return at[t].a.scaleY}):(R.width=function(t){return at[t].a.width+"px"},R.height=function(t){return at[t].a.height+"px"},R.autoRound=n.autoRound||!1),R.x=function(t){return at[t].a.x+"px"},R.y=function(t){return at[t].a.y+"px"},R.rotation=function(t){return at[t].a.rotation+(I?360*ht(t,h[t],h):0)},R.skewX=function(t){return at[t].a.skewX},h=at.map((function(t){return t.t})),(F||0===F)&&(R.modifiers={zIndex:function(){return F}},R.zIndex=F,R.immediateRender=!1!==n.immediateRender),Y&&(R.opacity=function(t){return at[t].sd<0?0:at[t].sd>0?at[t].a.opacity:"+=0"}),ot.length){Z=P.utils.distribute(Z);var i=h.slice(ot.length);R.stagger=function(t,e){return Z(~ot.indexOf(e)?h.indexOf(at[t].swap.t):t,e,i)}}if(W.forEach((function(t){return n[t]&&q.eventCallback(t,n[t],n[t+"Params"])})),C&&h.length)for(s in J=K(R,U),"scale"in C&&(C.scaleX=C.scaleY=C.scale,delete C.scale),C)(r=K(C[s],$))[s]=R[s],!("duration"in r)&&"duration"in R&&(r.duration=R.duration),r.stagger=R.stagger,ft.call(q,h,r,0),delete J[s];(h.length||rt.length||et.length)&&(L&&q.add((function(){return G(e,L,q._zTime<0?"remove":"add")}),0)&&!V&&G(e,L,"add"),h.length&&ft.call(q,h,J,0)),dt(w,et,q),dt(k,rt,q);var f=z&&z.timeline;f&&(f.add(q,0),z._final.push((function(){return st(at,!b)}))),a=q.duration(),q.call((function(){var t=q.time()>=a;t&&!f&&st(at,!b),L&&G(e,L,t?"remove":"add")}))},O&&(M=at.filter((function(t){return!t.sd&&!t.a.isVisible&&t.b.isVisible})).map((function(t){return t.a.element}))),z)?(M&&(v=z._abs).push.apply(v,lt(at,M)),z._run.push(g)):(M&&ct(lt(at,M)),g());var mt=z?z.timeline:q;return mt.revert=function(){return Mt(mt,1,1)},mt},kt=function t(e){e.vars.onInterrupt&&e.vars.onInterrupt.apply(e,e.vars.onInterruptParams||[]),e.getChildren(!0,!1,!0).forEach(t)},Mt=function(t,e,n){if(t&&t.progress()<1&&(!t.paused()||n))return e&&(kt(t),e<2&&t.progress(1),t.kill()),!0},Ot=function(t){for(var e,n=t.idLookup={},i=t.alt={},r=t.elementStates,s=r.length;s--;)n[(e=r[s]).id]?i[e.id]=e:n[e.id]=e},Ct=function(){function t(t,e,n){if(this.props=e&&e.props,this.simple=!(!e||!e.simple),n)this.targets=ft(t),this.elementStates=t,Ot(this);else{this.targets=_(t);var i=e&&(!1===e.kill||e.batch&&!e.kill);z&&!i&&z._kill.push(this),this.update(i||!!z)}}var e=t.prototype;return e.update=function(t){var e=this;return this.elementStates=this.targets.map((function(t){return new St(t,e.props,e.simple)})),Ot(this),this.interrupt(t),this.recordInlineStyles(),this},e.clear=function(){return this.targets.length=this.elementStates.length=0,Ot(this),this},e.fit=function(t,e,n){for(var i,r,s=nt(this.elementStates.slice(0),!1,!0),a=(t||this).idLookup,o=0;o=0&&this.actions.splice(e,1),this},e.getState=function(t){var e=this,n=z,i=V;return z=this,this.state.clear(),this._kill.length=0,this.actions.forEach((function(n){n.vars.getState&&(n.states.length=0,V=n,n.state=n.vars.getState(n)),t&&n.states.forEach((function(t){return e.state.add(t)}))})),V=i,z=n,this.killConflicts(),this},e.animate=function(){var t,e,n=this,i=z,r=this.timeline,s=this.actions.length;for(z=this,r.clear(),this._abs.length=this._final.length=this._run.length=0,this.actions.forEach((function(t){t.vars.animate&&t.vars.animate(t);var e,n,i=t.vars.onEnter,r=t.vars.onLeave,s=t.targets;s&&s.length&&(i||r)&&(e=new Ct,t.states.forEach((function(t){return e.add(t)})),(n=e.compare(zt.getState(s))).enter.length&&i&&i(n.enter),n.leave.length&&r&&r(n.leave))})),ct(this._abs),this._run.forEach((function(t){return t()})),e=r.duration(),t=this._final.slice(0),r.add((function(){e<=r.time()&&(t.forEach((function(t){return t()})),F(n,"onComplete"))})),z=i;s--;)this.actions[s].vars.once&&this.actions[s].kill();return F(this,"onStart"),r.restart(),this},e.loadState=function(t){t||(t=function(){return 0});var e=[];return this.actions.forEach((function(n){if(n.vars.loadState){var i,r=function r(s){s&&(n.targets=s),~(i=e.indexOf(r))&&(e.splice(i,1),e.length||t())};e.push(r),n.vars.loadState(r)}})),e.length||t(),this},e.setState=function(){return this.actions.forEach((function(t){return t.targets=t.vars.setState&&t.vars.setState(t)})),this},e.killConflicts=function(t){return this.state.interrupt(t),this._kill.forEach((function(e){return e.interrupt(t)})),this},e.run=function(t,e){var n=this;return this!==z&&(t||this.getState(e),this.loadState((function(){n._killed||(n.setState(),n.animate())}))),this},e.clear=function(t){this.state.clear(),t||(this.actions.length=0)},e.getStateById=function(t){for(var e,n=this.actions.length;n--;)if(e=this.actions[n].getStateById(t))return e;return this.state.idLookup[t]&&this.state},e.kill=function(){this._killed=1,this.clear(),delete X[this.id]},t}(),zt=function(){function t(){}return t.getState=function(e,n){var i=mt(e,n);return V&&V.states.push(i),n&&n.batch&&t.batch(n.batch).state.add(i),i},t.from=function(t,e){return"clearProps"in(e=e||{})||(e.clearProps=!0),wt(t,mt(e.targets||t.targets,{props:e.props||t.props,simple:e.simple,kill:!!e.kill}),e,-1)},t.to=function(t,e){return wt(t,mt(e.targets||t.targets,{props:e.props||t.props,simple:e.simple,kill:!!e.kill}),e,1)},t.fromTo=function(t,e,n){return wt(t,e,n)},t.fit=function(t,e,n){var i=n?K(n,$):{},r=n||i,s=r.absolute,a=r.scale,o=r.getVars,l=r.props,c=r.runBackwards,u=r.onComplete,h=r.simple,p=n&&n.fitChild&&R(n.fitChild),f=ht(e,l,h,t),d=ht(t,0,h,f),g=l?H[l]:D,m=P.context();return l&&pt(i,f.props),it(d,g),c&&("immediateRender"in i||(i.immediateRender=!0),i.onComplete=function(){rt(d),u&&u.apply(this,arguments)}),s&&ot(d,f),i=gt(d,f,a||p,l,p,i.duration||o?i:0),m&&!o&&m.add((function(){return function(){return rt(d)}})),o?i:i.duration?P.to(d.element,i):null},t.makeAbsolute=function(t,e){return(t instanceof Ct?t:new Ct(t,e)).makeAbsolute()},t.batch=function(t){return t||(t="default"),X[t]||(X[t]=new Pt(t))},t.killFlipsOf=function(t,e){(t instanceof Ct?t.targets:_(t)).forEach((function(t){return t&&Mt(t._flip,!1!==e?1:2)}))},t.isFlipping=function(e){var n=t.getByTarget(e);return!!n&&n.isActive()},t.getByTarget=function(t){return(R(t)||I)._flip},t.getElementState=function(t,e){return new St(R(t),e)},t.convertCoordinates=function(t,e,n){var i=S(e,!0,!0).multiply(S(t));return n?i.apply(n):i},t.register=function(t){if(T="undefined"!==typeof document&&document.body){P=t,d(T),_=P.utils.toArray,B=P.core.getStyleSaver;var e=P.utils.snap(.1);E=function(t,n){return e(parseFloat(t)+n)}}},t}();zt.version="3.12.4","undefined"!==typeof window&&window.gsap&&window.gsap.registerPlugin(zt)},10990:function(t,e,n){n.d(e,{ZP:function(){return Mt}});var i,r,s,a,o,l,c,u,h=n(25317),p={},f=180/Math.PI,d=Math.PI/180,g=Math.atan2,m=/([A-Z])/g,y=/(left|right|width|margin|padding|x)/i,v=/[\s,\(]\S/,x={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},b=function(t,e){return e.set(e.t,e.p,Math.round(1e4*(e.s+e.c*t))/1e4+e.u,e)},w=function(t,e){return e.set(e.t,e.p,1===t?e.e:Math.round(1e4*(e.s+e.c*t))/1e4+e.u,e)},k=function(t,e){return e.set(e.t,e.p,t?Math.round(1e4*(e.s+e.c*t))/1e4+e.u:e.b,e)},M=function(t,e){var n=e.s+e.c*t;e.set(e.t,e.p,~~(n+(n<0?-.5:.5))+e.u,e)},O=function(t,e){return e.set(e.t,e.p,t?e.e:e.b,e)},C=function(t,e){return e.set(e.t,e.p,1!==t?e.b:e.e,e)},S=function(t,e,n){return t.style[e]=n},_=function(t,e,n){return t.style.setProperty(e,n)},P=function(t,e,n){return t._gsap[e]=n},z=function(t,e,n){return t._gsap.scaleX=t._gsap.scaleY=n},V=function(t,e,n,i,r){var s=t._gsap;s.scaleX=s.scaleY=n,s.renderTransform(r,s)},T=function(t,e,n,i,r){var s=t._gsap;s[e]=n,s.renderTransform(r,s)},E="transform",B=E+"Origin",L=function t(e,n){var i=this,r=this.target,s=r.style,a=r._gsap;if(e in p&&s){if(this.tfm=this.tfm||{},"transform"===e)return x.transform.split(",").forEach((function(e){return t.call(i,e,n)}));if(~(e=x[e]||e).indexOf(",")?e.split(",").forEach((function(t){return i.tfm[t]=K(r,t)})):this.tfm[e]=a.x?a[e]:K(r,e),e===B&&(this.tfm.zOrigin=a.zOrigin),this.props.indexOf(E)>=0)return;a.svg&&(this.svgo=r.getAttribute("data-svg-origin"),this.props.push(B,n,"")),e=E}(s||n)&&this.props.push(e,n,s[e])},A=function(t){t.translate&&(t.removeProperty("translate"),t.removeProperty("scale"),t.removeProperty("rotate"))},F=function(){var t,e,n=this.props,i=this.target,r=i.style,s=i._gsap;for(t=0;t=0?I[r]:"")+t},H=function(){"undefined"!==typeof window&&window.document&&(i=window,r=i.document,s=r.documentElement,o=Y("div")||{style:{}},Y("div"),E=N(E),B=E+"Origin",o.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",u=!!N("perspective"),c=h.p8.core.reverting,a=1)},j=function t(e){var n,i=Y("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),r=this.parentNode,a=this.nextSibling,o=this.style.cssText;if(s.appendChild(i),i.appendChild(this),this.style.display="block",e)try{n=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=t}catch(l){}else this._gsapBBox&&(n=this._gsapBBox());return r&&(a?r.insertBefore(this,a):r.appendChild(this)),s.removeChild(i),this.style.cssText=o,n},W=function(t,e){for(var n=e.length;n--;)if(t.hasAttribute(e[n]))return t.getAttribute(e[n])},D=function(t){var e;try{e=t.getBBox()}catch(n){e=j.call(t,!0)}return e&&(e.width||e.height)||t.getBBox===j||(e=j.call(t,!0)),!e||e.width||e.x||e.y?e:{x:+W(t,["x","cx","x1"])||0,y:+W(t,["y","cy","y1"])||0,width:0,height:0}},R=function(t){return!(!t.getCTM||t.parentNode&&!t.ownerSVGElement||!D(t))},q=function(t,e){if(e){var n,i=t.style;e in p&&e!==B&&(e=E),i.removeProperty?("ms"!==(n=e.substr(0,2))&&"webkit"!==e.substr(0,6)||(e="-"+e),i.removeProperty("--"===n?e:e.replace(m,"-$1").toLowerCase())):i.removeAttribute(e)}},G=function(t,e,n,i,r,s){var a=new h.Fo(t._pt,e,n,0,1,s?C:O);return t._pt=a,a.b=i,a.e=r,t._props.push(n),a},U={deg:1,rad:1,turn:1},$={grid:1,flex:1},J=function t(e,n,i,s){var a,l,c,u,f=parseFloat(i)||0,d=(i+"").trim().substr((f+"").length)||"px",g=o.style,m=y.test(n),v="svg"===e.tagName.toLowerCase(),x=(v?"client":"offset")+(m?"Width":"Height"),b=100,w="px"===s,k="%"===s;if(s===d||!f||U[s]||U[d])return f;if("px"!==d&&!w&&(f=t(e,n,i,"px")),u=e.getCTM&&R(e),(k||"%"===d)&&(p[n]||~n.indexOf("adius")))return a=u?e.getBBox()[m?"width":"height"]:e[x],(0,h.Pr)(k?f/a*b:f/100*a);if(g[m?"width":"height"]=b+(w?d:s),l=~n.indexOf("adius")||"em"===s&&e.appendChild&&!v?e:e.parentNode,u&&(l=(e.ownerSVGElement||{}).parentNode),l&&l!==r&&l.appendChild||(l=r.body),(c=l._gsap)&&k&&c.width&&m&&c.time===h.xr.time&&!c.uncache)return(0,h.Pr)(f/c.width*b);if(!k||"height"!==n&&"width"!==n)(k||"%"===d)&&!$[Z(l,"display")]&&(g.position=Z(e,"position")),l===e&&(g.position="static"),l.appendChild(o),a=o[x],l.removeChild(o),g.position="absolute";else{var M=e.style[n];e.style[n]=b+s,a=e[x],M?e.style[n]=M:q(e,n)}return m&&k&&((c=(0,h.DY)(l)).time=h.xr.time,c.width=l[x]),(0,h.Pr)(w?a*f/b:a&&f?b/a*f:0)},K=function(t,e,n,i){var r;return a||H(),e in x&&"transform"!==e&&~(e=x[e]).indexOf(",")&&(e=e.split(",")[0]),p[e]&&"transform"!==e?(r=ut(t,i),r="transformOrigin"!==e?r[e]:r.svg?r.origin:ht(Z(t,B))+" "+r.zOrigin+"px"):(!(r=t.style[e])||"auto"===r||i||~(r+"").indexOf("calc("))&&(r=it[e]&&it[e](t,e,n)||Z(t,e)||(0,h.Ok)(t,e)||("opacity"===e?1:0)),n&&!~(r+"").trim().indexOf(" ")?J(t,e,r,n)+n:r},Q=function(t,e,n,i){if(!n||"none"===n){var r=N(e,t,1),s=r&&Z(t,r,1);s&&s!==n?(e=r,n=s):"borderColor"===e&&(n=Z(t,"borderTopColor"))}var a,o,l,c,u,p,f,d,g,m,y,v=new h.Fo(this._pt,t.style,e,0,1,h.Ks),x=0,b=0;if(v.b=n,v.e=i,n+="","auto"===(i+="")&&(p=t.style[e],t.style[e]=i,i=Z(t,e)||i,p?t.style[e]=p:q(t,e)),a=[n,i],(0,h.kr)(a),i=a[1],l=(n=a[0]).match(h.d4)||[],(i.match(h.d4)||[]).length){for(;o=h.d4.exec(i);)f=o[0],g=i.substring(x,o.index),u?u=(u+1)%5:"rgba("!==g.substr(-5)&&"hsla("!==g.substr(-5)||(u=1),f!==(p=l[b++]||"")&&(c=parseFloat(p)||0,y=p.substr((c+"").length),"="===f.charAt(1)&&(f=(0,h.cy)(c,f)+y),d=parseFloat(f),m=f.substr((d+"").length),x=h.d4.lastIndex-m.length,m||(m=m||h.Fc.units[e]||y,x===i.length&&(i+=m,v.e+=m)),y!==m&&(c=J(t,e,p,m)||0),v._pt={_next:v._pt,p:g||1===b?g:",",s:c,c:d-c,m:u&&u<4||"zIndex"===e?Math.round:0});v.c=x-1;)n=o[r],p[n]&&(i=1,n="transformOrigin"===n?B:E),q(s,n);i&&(q(s,E),l&&(l.svg&&s.removeAttribute("transform"),ut(s,1),l.uncache=1,A(a)))}},it={clearProps:function(t,e,n,i,r){if("isFromStart"!==r.data){var s=t._pt=new h.Fo(t._pt,e,n,0,0,nt);return s.u=i,s.pr=-10,s.tween=r,t._props.push(n),1}}},rt=[1,0,0,1,0,0],st={},at=function(t){return"matrix(1, 0, 0, 1, 0, 0)"===t||"none"===t||!t},ot=function(t){var e=Z(t,E);return at(e)?rt:e.substr(7).match(h.SI).map(h.Pr)},lt=function(t,e){var n,i,r,a,o=t._gsap||(0,h.DY)(t),l=t.style,c=ot(t);return o.svg&&t.getAttribute("transform")?"1,0,0,1,0,0"===(c=[(r=t.transform.baseVal.consolidate().matrix).a,r.b,r.c,r.d,r.e,r.f]).join(",")?rt:c:(c!==rt||t.offsetParent||t===s||o.svg||(r=l.display,l.display="block",(n=t.parentNode)&&t.offsetParent||(a=1,i=t.nextElementSibling,s.appendChild(t)),c=ot(t),r?l.display=r:q(t,"display"),a&&(i?n.insertBefore(t,i):n?n.appendChild(t):s.removeChild(t))),e&&c.length>6?[c[0],c[1],c[4],c[5],c[12],c[13]]:c)},ct=function(t,e,n,i,r,s){var a,o,l,c=t._gsap,u=r||lt(t,!0),h=c.xOrigin||0,p=c.yOrigin||0,f=c.xOffset||0,d=c.yOffset||0,g=u[0],m=u[1],y=u[2],v=u[3],x=u[4],b=u[5],w=e.split(" "),k=parseFloat(w[0])||0,M=parseFloat(w[1])||0;n?u!==rt&&(o=g*v-m*y)&&(l=k*(-m/o)+M*(g/o)-(g*b-m*x)/o,k=k*(v/o)+M*(-y/o)+(y*b-v*x)/o,M=l):(k=(a=D(t)).x+(~w[0].indexOf("%")?k/100*a.width:k),M=a.y+(~(w[1]||w[0]).indexOf("%")?M/100*a.height:M)),i||!1!==i&&c.smooth?(x=k-h,b=M-p,c.xOffset=f+(x*g+b*y)-x,c.yOffset=d+(x*m+b*v)-b):c.xOffset=c.yOffset=0,c.xOrigin=k,c.yOrigin=M,c.smooth=!!i,c.origin=e,c.originIsAbsolute=!!n,t.style[B]="0px 0px",s&&(G(s,c,"xOrigin",h,k),G(s,c,"yOrigin",p,M),G(s,c,"xOffset",f,c.xOffset),G(s,c,"yOffset",d,c.yOffset)),t.setAttribute("data-svg-origin",k+" "+M)},ut=function(t,e){var n=t._gsap||new h.l1(t);if("x"in n&&!e&&!n.uncache)return n;var i,r,s,a,o,l,c,p,m,y,v,x,b,w,k,M,O,C,S,_,P,z,V,T,L,A,F,X,Y,I,N,H,j=t.style,W=n.scaleX<0,D="px",q="deg",G=getComputedStyle(t),U=Z(t,B)||"0";return i=r=s=l=c=p=m=y=v=0,a=o=1,n.svg=!(!t.getCTM||!R(t)),G.translate&&("none"===G.translate&&"none"===G.scale&&"none"===G.rotate||(j[E]=("none"!==G.translate?"translate3d("+(G.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+("none"!==G.rotate?"rotate("+G.rotate+") ":"")+("none"!==G.scale?"scale("+G.scale.split(" ").join(",")+") ":"")+("none"!==G[E]?G[E]:"")),j.scale=j.rotate=j.translate="none"),w=lt(t,n.svg),n.svg&&(n.uncache?(L=t.getBBox(),U=n.xOrigin-L.x+"px "+(n.yOrigin-L.y)+"px",T=""):T=!e&&t.getAttribute("data-svg-origin"),ct(t,T||U,!!T||n.originIsAbsolute,!1!==n.smooth,w)),x=n.xOrigin||0,b=n.yOrigin||0,w!==rt&&(C=w[0],S=w[1],_=w[2],P=w[3],i=z=w[4],r=V=w[5],6===w.length?(a=Math.sqrt(C*C+S*S),o=Math.sqrt(P*P+_*_),l=C||S?g(S,C)*f:0,(m=_||P?g(_,P)*f+l:0)&&(o*=Math.abs(Math.cos(m*d))),n.svg&&(i-=x-(x*C+b*_),r-=b-(x*S+b*P))):(H=w[6],I=w[7],F=w[8],X=w[9],Y=w[10],N=w[11],i=w[12],r=w[13],s=w[14],c=(k=g(H,Y))*f,k&&(T=z*(M=Math.cos(-k))+F*(O=Math.sin(-k)),L=V*M+X*O,A=H*M+Y*O,F=z*-O+F*M,X=V*-O+X*M,Y=H*-O+Y*M,N=I*-O+N*M,z=T,V=L,H=A),p=(k=g(-_,Y))*f,k&&(M=Math.cos(-k),N=P*(O=Math.sin(-k))+N*M,C=T=C*M-F*O,S=L=S*M-X*O,_=A=_*M-Y*O),l=(k=g(S,C))*f,k&&(T=C*(M=Math.cos(k))+S*(O=Math.sin(k)),L=z*M+V*O,S=S*M-C*O,V=V*M-z*O,C=T,z=L),c&&Math.abs(c)+Math.abs(l)>359.9&&(c=l=0,p=180-p),a=(0,h.Pr)(Math.sqrt(C*C+S*S+_*_)),o=(0,h.Pr)(Math.sqrt(V*V+H*H)),k=g(z,V),m=Math.abs(k)>2e-4?k*f:0,v=N?1/(N<0?-N:N):0),n.svg&&(T=t.getAttribute("transform"),n.forceCSS=t.setAttribute("transform","")||!at(Z(t,E)),T&&t.setAttribute("transform",T))),Math.abs(m)>90&&Math.abs(m)<270&&(W?(a*=-1,m+=l<=0?180:-180,l+=l<=0?180:-180):(o*=-1,m+=m<=0?180:-180)),e=e||n.uncache,n.x=i-((n.xPercent=i&&(!e&&n.xPercent||(Math.round(t.offsetWidth/2)===Math.round(-i)?-50:0)))?t.offsetWidth*n.xPercent/100:0)+D,n.y=r-((n.yPercent=r&&(!e&&n.yPercent||(Math.round(t.offsetHeight/2)===Math.round(-r)?-50:0)))?t.offsetHeight*n.yPercent/100:0)+D,n.z=s+D,n.scaleX=(0,h.Pr)(a),n.scaleY=(0,h.Pr)(o),n.rotation=(0,h.Pr)(l)+q,n.rotationX=(0,h.Pr)(c)+q,n.rotationY=(0,h.Pr)(p)+q,n.skewX=m+q,n.skewY=y+q,n.transformPerspective=v+D,(n.zOrigin=parseFloat(U.split(" ")[2])||!e&&n.zOrigin||0)&&(j[B]=ht(U)),n.xOffset=n.yOffset=0,n.force3D=h.Fc.force3D,n.renderTransform=n.svg?vt:u?yt:ft,n.uncache=0,n},ht=function(t){return(t=t.split(" "))[0]+" "+t[1]},pt=function(t,e,n){var i=(0,h.Wy)(e);return(0,h.Pr)(parseFloat(e)+parseFloat(J(t,"x",n+"px",i)))+i},ft=function(t,e){e.z="0px",e.rotationY=e.rotationX="0deg",e.force3D=0,yt(t,e)},dt="0deg",gt="0px",mt=") ",yt=function(t,e){var n=e||this,i=n.xPercent,r=n.yPercent,s=n.x,a=n.y,o=n.z,l=n.rotation,c=n.rotationY,u=n.rotationX,h=n.skewX,p=n.skewY,f=n.scaleX,g=n.scaleY,m=n.transformPerspective,y=n.force3D,v=n.target,x=n.zOrigin,b="",w="auto"===y&&t&&1!==t||!0===y;if(x&&(u!==dt||c!==dt)){var k,M=parseFloat(c)*d,O=Math.sin(M),C=Math.cos(M);M=parseFloat(u)*d,k=Math.cos(M),s=pt(v,s,O*k*-x),a=pt(v,a,-Math.sin(M)*-x),o=pt(v,o,C*k*-x+x)}m!==gt&&(b+="perspective("+m+mt),(i||r)&&(b+="translate("+i+"%, "+r+"%) "),(w||s!==gt||a!==gt||o!==gt)&&(b+=o!==gt||w?"translate3d("+s+", "+a+", "+o+") ":"translate("+s+", "+a+mt),l!==dt&&(b+="rotate("+l+mt),c!==dt&&(b+="rotateY("+c+mt),u!==dt&&(b+="rotateX("+u+mt),h===dt&&p===dt||(b+="skew("+h+", "+p+mt),1===f&&1===g||(b+="scale("+f+", "+g+mt),v.style[E]=b||"translate(0, 0)"},vt=function(t,e){var n,i,r,s,a,o=e||this,l=o.xPercent,c=o.yPercent,u=o.x,p=o.y,f=o.rotation,g=o.skewX,m=o.skewY,y=o.scaleX,v=o.scaleY,x=o.target,b=o.xOrigin,w=o.yOrigin,k=o.xOffset,M=o.yOffset,O=o.forceCSS,C=parseFloat(u),S=parseFloat(p);f=parseFloat(f),g=parseFloat(g),(m=parseFloat(m))&&(g+=m=parseFloat(m),f+=m),f||g?(f*=d,g*=d,n=Math.cos(f)*y,i=Math.sin(f)*y,r=Math.sin(f-g)*-v,s=Math.cos(f-g)*v,g&&(m*=d,a=Math.tan(g-m),r*=a=Math.sqrt(1+a*a),s*=a,m&&(a=Math.tan(m),n*=a=Math.sqrt(1+a*a),i*=a)),n=(0,h.Pr)(n),i=(0,h.Pr)(i),r=(0,h.Pr)(r),s=(0,h.Pr)(s)):(n=y,s=v,i=r=0),(C&&!~(u+"").indexOf("px")||S&&!~(p+"").indexOf("px"))&&(C=J(x,"x",u,"px"),S=J(x,"y",p,"px")),(b||w||k||M)&&(C=(0,h.Pr)(C+b-(b*n+w*r)+k),S=(0,h.Pr)(S+w-(b*i+w*s)+M)),(l||c)&&(a=x.getBBox(),C=(0,h.Pr)(C+l/100*a.width),S=(0,h.Pr)(S+c/100*a.height)),a="matrix("+n+","+i+","+r+","+s+","+C+","+S+")",x.setAttribute("transform",a),O&&(x.style[E]=a)},xt=function(t,e,n,i,r){var s,a,o=360,l=(0,h.r9)(r),c=parseFloat(r)*(l&&~r.indexOf("rad")?f:1)-i,u=i+c+"deg";return l&&("short"===(s=r.split("_")[1])&&(c%=o)!==c%180&&(c+=c<0?o:-360),"cw"===s&&c<0?c=(c+36e9)%o-~~(c/o)*o:"ccw"===s&&c>0&&(c=(c-36e9)%o-~~(c/o)*o)),t._pt=a=new h.Fo(t._pt,e,n,i,c,w),a.e=u,a.u="deg",t._props.push(n),a},bt=function(t,e){for(var n in e)t[n]=e[n];return t},wt=function(t,e,n){var i,r,s,a,o,l,c,u=bt({},n._gsap),f=n.style;for(r in u.svg?(s=n.getAttribute("transform"),n.setAttribute("transform",""),f[E]=e,i=ut(n,1),q(n,E),n.setAttribute("transform",s)):(s=getComputedStyle(n)[E],f[E]=e,i=ut(n,1),f[E]=s),p)(s=u[r])!==(a=i[r])&&"perspective,force3D,transformOrigin,svgOrigin".indexOf(r)<0&&(o=(0,h.Wy)(s)!==(c=(0,h.Wy)(a))?J(n,r,s,c):parseFloat(s),l=parseFloat(a),t._pt=new h.Fo(t._pt,i,r,o,l-o,b),t._pt.u=c||0,t._props.push(r));bt(i,u)};(0,h.fS)("padding,margin,Width,Radius",(function(t,e){var n="Top",i="Right",r="Bottom",s="Left",a=(e<3?[n,i,r,s]:[n+s,n+i,r+i,r+s]).map((function(n){return e<2?t+n:"border"+n+t}));it[e>1?"border"+t:t]=function(t,e,n,i,r){var s,o;if(arguments.length<4)return s=a.map((function(e){return K(t,e,n)})),5===(o=s.join(" ")).split(s[0]).length?s[0]:o;s=(i+"").split(" "),o={},a.forEach((function(t,e){return o[t]=s[e]=s[e]||s[(e-1)/2|0]})),t.init(e,o,r)}}));var kt={name:"css",register:H,targetTest:function(t){return t.style&&t.nodeType},init:function(t,e,n,i,r){var s,o,l,c,u,f,d,g,m,y,w,O,C,S,_,P,z=this._props,V=t.style,T=n.vars.startAt;for(d in a||H(),this.styles=this.styles||X(t),P=this.styles.props,this.tween=n,e)if("autoRound"!==d&&(o=e[d],!h.$i[d]||!(0,h.if)(d,e,n,i,t,r)))if(u=typeof o,f=it[d],"function"===u&&(u=typeof(o=o.call(n,i,t,r))),"string"===u&&~o.indexOf("random(")&&(o=(0,h.UI)(o)),f)f(this,t,d,o,n)&&(_=1);else if("--"===d.substr(0,2))s=(getComputedStyle(t).getPropertyValue(d)+"").trim(),o+="",h.GN.lastIndex=0,h.GN.test(s)||(g=(0,h.Wy)(s),m=(0,h.Wy)(o)),m?g!==m&&(s=J(t,d,s,m)+m):g&&(o+=g),this.add(V,"setProperty",s,o,i,r,0,0,d),z.push(d),P.push(d,0,V[d]);else if("undefined"!==u){if(T&&d in T?(s="function"===typeof T[d]?T[d].call(n,i,t,r):T[d],(0,h.r9)(s)&&~s.indexOf("random(")&&(s=(0,h.UI)(s)),(0,h.Wy)(s+"")||"auto"===s||(s+=h.Fc.units[d]||(0,h.Wy)(K(t,d))||""),"="===(s+"").charAt(1)&&(s=K(t,d))):s=K(t,d),c=parseFloat(s),(y="string"===u&&"="===o.charAt(1)&&o.substr(0,2))&&(o=o.substr(2)),l=parseFloat(o),d in x&&("autoAlpha"===d&&(1===c&&"hidden"===K(t,"visibility")&&l&&(c=0),P.push("visibility",0,V.visibility),G(this,V,"visibility",c?"inherit":"hidden",l?"inherit":"hidden",!l)),"scale"!==d&&"transform"!==d&&~(d=x[d]).indexOf(",")&&(d=d.split(",")[0])),w=d in p)if(this.styles.save(d),O||((C=t._gsap).renderTransform&&!e.parseTransform||ut(t,e.parseTransform),S=!1!==e.smoothOrigin&&C.smooth,(O=this._pt=new h.Fo(this._pt,V,E,0,1,C.renderTransform,C,0,-1)).dep=1),"scale"===d)this._pt=new h.Fo(this._pt,C,"scaleY",C.scaleY,(y?(0,h.cy)(C.scaleY,y+l):l)-C.scaleY||0,b),this._pt.u=0,z.push("scaleY",d),d+="X";else{if("transformOrigin"===d){P.push(B,0,V[B]),o=et(o),C.svg?ct(t,o,0,S,0,this):((m=parseFloat(o.split(" ")[2])||0)!==C.zOrigin&&G(this,C,"zOrigin",C.zOrigin,m),G(this,V,d,ht(s),ht(o)));continue}if("svgOrigin"===d){ct(t,o,1,S,0,this);continue}if(d in st){xt(this,C,d,c,y?(0,h.cy)(c,y+o):o);continue}if("smoothOrigin"===d){G(this,C,"smooth",C.smooth,o);continue}if("force3D"===d){C[d]=o;continue}if("transform"===d){wt(this,o,t);continue}}else d in V||(d=N(d)||d);if(w||(l||0===l)&&(c||0===c)&&!v.test(o)&&d in V)l||(l=0),(g=(s+"").substr((c+"").length))!==(m=(0,h.Wy)(o)||(d in h.Fc.units?h.Fc.units[d]:g))&&(c=J(t,d,s,m)),this._pt=new h.Fo(this._pt,w?C:V,d,c,(y?(0,h.cy)(c,y+l):l)-c,w||"px"!==m&&"zIndex"!==d||!1===e.autoRound?b:M),this._pt.u=m||0,g!==m&&"%"!==m&&(this._pt.b=s,this._pt.r=k);else if(d in V)Q.call(this,t,d,s,y?y+o:o);else if(d in t)this.add(t,d,s||t[d],y?y+o:o,i,r);else if("parseTransform"!==d){(0,h.lC)(d,o);continue}w||(d in V?P.push(d,0,V[d]):P.push(d,1,s||t[d])),z.push(d)}_&&(0,h.JV)(this)},render:function(t,e){if(e.tween._time||!c())for(var n=e._pt;n;)n.r(t,n.d),n=n._next;else e.styles.revert()},get:K,aliases:x,getSetter:function(t,e,n){var i=x[e];return i&&i.indexOf(",")<0&&(e=i),e in p&&e!==B&&(t._gsap.x||K(t,"x"))?n&&l===n?"scale"===e?z:P:(l=n||{})&&("scale"===e?V:T):t.style&&!(0,h.m2)(t.style[e])?S:~e.indexOf("-")?_:(0,h.S5)(t,e)},core:{_removeProperty:q,_getMatrix:lt}};h.p8.utils.checkPrefix=N,h.p8.core.getStyleSaver=X,function(t,e,n,i){var r=(0,h.fS)(t+","+e+",transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective",(function(t){p[t]=1}));(0,h.fS)(e,(function(t){h.Fc.units[t]="deg",st[t]=1})),x[r[13]]=t+","+e,(0,h.fS)("0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY",(function(t){var e=t.split(":");x[e[1]]=r[e[0]]}))}("x,y,z,scale,scaleX,scaleY,xPercent,yPercent","rotation,rotationX,rotationY,skewX,skewY"),(0,h.fS)("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",(function(t){h.Fc.units[t]="px"})),h.p8.registerPlugin(kt);var Mt=h.p8.registerPlugin(kt)||h.p8;Mt.core.Tween},57150:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("BookText",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H20v20H6.5a2.5 2.5 0 0 1 0-5H20",key:"t4utmx"}],["path",{d:"M8 7h6",key:"1f0q6e"}],["path",{d:"M8 11h8",key:"vwpz6n"}]])},76915:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},33587:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]])},3848:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},4844:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]])},68599:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},78107:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("Images",[["path",{d:"M18 22H4a2 2 0 0 1-2-2V6",key:"pblm9e"}],["path",{d:"m22 13-1.296-1.296a2.41 2.41 0 0 0-3.408 0L11 18",key:"nf6bnh"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["rect",{width:"16",height:"16",x:"6",y:"2",rx:"2",key:"12espp"}]])},62888:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("RotateCw",[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]])},58261:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("SquareTerminal",[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]])},49525:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},41352:function(t,e,n){n.d(e,{Z:function(){return i}});const i=(0,n(45711).Z)("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},29815:function(t,e,n){n.d(e,{Z:function(){return a}});var i=n(20943);var r=n(13375);var s=n(91566);function a(t){return function(t){if(Array.isArray(t))return(0,i.Z)(t)}(t)||(0,r.Z)(t)||(0,s.Z)(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/9719-14cc8b76a1deed3c.js b/dsql-app/.local_dist/static/chunks/9719-14cc8b76a1deed3c.js new file mode 100644 index 0000000..a169a16 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/9719-14cc8b76a1deed3c.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9719],{5467:function(e,a,s){var t=s(64836);a.Z=void 0;var l=t(s(64938)),n=s(85893),r=(0,l.default)([(0,n.jsx)("path",{d:"M7 3h10v1H7zm0 17h10v1H7z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"m22 12-4-4v3h-5v2h5v3l4-4zm-5 6H7V6h10v1h2V3c0-1.1-.9-2-2-2L7 1.01C5.9 1.01 5 1.9 5 3v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2v-4h-2v1zM7 3h10v1H7V3zm10 18H7v-1h10v1z"},"1")],"SendToMobileTwoTone");a.Z=r},57632:function(e,a,s){var t=s(64836);a.Z=void 0;var l=t(s(64938)),n=s(85893),r=(0,l.default)([(0,n.jsx)("path",{d:"M14 5H5v14h14v-9h-5V5zM8 17c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z",opacity:".3"},"0"),(0,n.jsx)("circle",{cx:"8",cy:"8",r:"1"},"1"),(0,n.jsx)("path",{d:"M15 3H5c-1.1 0-1.99.9-1.99 2L3 19c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V9l-6-6zm4 16H5V5h9v5h5v9z"},"2"),(0,n.jsx)("circle",{cx:"8",cy:"12",r:"1"},"3"),(0,n.jsx)("circle",{cx:"8",cy:"16",r:"1"},"4")],"SummarizeTwoTone");a.Z=r},85541:function(e,a,s){var t=s(64836);a.Z=void 0;var l=t(s(64938)),n=s(85893),r=(0,l.default)([(0,n.jsx)("path",{d:"M14.5 9.5C14.5 6.47 12.03 4 9 4S3.5 6.47 3.5 9.5c0 2.47 1.49 3.89 2.35 4.5h6.3c.86-.61 2.35-2.03 2.35-4.5z",opacity:".3"},"0"),(0,n.jsx)("path",{d:"M7 20h4c0 1.1-.9 2-2 2s-2-.9-2-2zm-2-1h8v-2H5v2zm11.5-9.5c0 3.82-2.66 5.86-3.77 6.5H5.27c-1.11-.64-3.77-2.68-3.77-6.5C1.5 5.36 4.86 2 9 2s7.5 3.36 7.5 7.5zm-2 0C14.5 6.47 12.03 4 9 4S3.5 6.47 3.5 9.5c0 2.47 1.49 3.89 2.35 4.5h6.3c.86-.61 2.35-2.03 2.35-4.5zm6.87-2.13L20 8l1.37.63L22 10l.63-1.37L24 8l-1.37-.63L22 6l-.63 1.37zM19 6l.94-2.06L22 3l-2.06-.94L19 0l-.94 2.06L16 3l2.06.94L19 6z"},"1")],"TipsAndUpdatesTwoTone");a.Z=r},76915:function(e,a,s){s.d(a,{Z:function(){return t}});const t=(0,s(45711).Z)("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},58261:function(e,a,s){s.d(a,{Z:function(){return t}});const t=(0,s(45711).Z)("SquareTerminal",[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]])},81926:function(e,a,s){s.d(a,{Z:function(){return u}});var t,l=s(828),n=s(85893),r=s(67294),i=s(86729),c=s(97037),o=s(95264),m=s(27901),d=s(72733);function u(e){var a=e.targetDb,s=(e.database,e.user,e.userImage),u=e.setUserImage,p=(0,l.Z)(r.useState(null),2),h=p[0],x=p[1],v=(0,l.Z)(r.useState(!1),2),f=v[0];v[1];return(0,n.jsxs)(r.Fragment,{children:[f&&(0,n.jsx)(o.Z,{}),h&&(0,n.jsx)(c.Z,{message:h}),(0,n.jsx)("h3",{className:"m-0 text-lg font-semibold mb-1 text-slate-600 mt-4",children:"User information"}),(0,n.jsx)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:(0,n.jsx)(m.Z,{title:"First Name",inputType:"text",name:"first_name",autoComplete:"given-name",onInputHandler:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),x(null)):a.classList.add("warning")},required:!0})}),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,n.jsx)("label",{htmlFor:"last_name",children:"Last Name"}),(0,n.jsx)("input",{type:"text",name:"last_name",id:"last_name",placeholder:"Last Name",autoComplete:"family-name",onInput:function(e){var a=e.target;a.value.match(/./)?(a.classList.remove("warning"),x(null)):a.classList.add("warning")},required:!0})]}),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,n.jsx)("label",{htmlFor:"username",children:"Username"}),(0,n.jsx)("input",{type:"text",name:"username",id:"username",placeholder:"Username",autoComplete:"username",onInput:function(e){var s=e.target;s.value.match(/./)?(s.classList.remove("warning"),x(null)):s.classList.add("warning"),window.clearTimeout(t),t=setTimeout((function(){(0,i.Z)("/api/checkDuplicateData?type=username&value=".concat(s.value,"&tableName=users&dbFullName=").concat(a)).then((function(e){(null===e||void 0===e?void 0:e.result)?(x("Username Already Exists"),s.classList.add("warning")):(x(null),s.classList.remove("warning"))}))}),300)}})]}),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,n.jsx)("label",{htmlFor:"email_address",children:"Email Address"}),(0,n.jsx)("input",{type:"email",name:"email_address",id:"email_address",placeholder:"Email Address",autoComplete:"email",onInput:function(e){window.clearTimeout(t);var s=e.target;t=setTimeout((function(){(0,i.Z)("/api/checkDuplicateData?type=email&value=".concat(s.value,"&tableName=users&dbFullName=").concat(a)).then((function(e){(null===e||void 0===e?void 0:e.result)?(x("Email Already Exists"),s.classList.add("warning")):(x(null),s.classList.remove("warning"))}))}),300)},required:!0})]}),(0,n.jsx)(m.Z,{title:"Phone Number",inputType:"text",name:"phone",autoComplete:"tel"}),(0,n.jsx)(m.Z,{title:"Address",name:"address",autoComplete:"address"}),(0,n.jsxs)("div",{className:"flex-wrap xl:flex-nowrap",children:[(0,n.jsx)(m.Z,{title:"City",name:"city",autoComplete:"city"}),(0,n.jsx)(m.Z,{title:"State",name:"state",autoComplete:"state"}),(0,n.jsx)(m.Z,{title:"Country",name:"country",autoComplete:"country"}),(0,n.jsx)(m.Z,{title:"Zip Code",name:"zip_code",autoComplete:"zip_code"})]}),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,n.jsx)("label",{htmlFor:"password",children:"Password"}),(0,n.jsx)("input",{type:"password",name:"password",id:"password",placeholder:"Password",required:!0})]}),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",children:[(0,n.jsx)("label",{htmlFor:"confirm_password",children:"Confirm Password"}),(0,n.jsx)("input",{type:"password",name:"confirm_password",id:"confirm_password",placeholder:"Confirm Password",onInput:function(e){var a,s=e.target;(null===(a=s.closest("form"))||void 0===a?void 0:a.password.value)===s.value?s.classList.remove("warning"):s.classList.add("warning")},required:!0})]}),(0,n.jsxs)("div",{className:"paper",children:[(0,n.jsx)("h3",{className:"m-0 text-lg font-semibold mb-1 text-slate-600",children:"User Image"}),(0,n.jsx)(d.Z,{userImage:s,setUserImage:u,className:"w-full"})]})]})}},97037:function(e,a,s){s.d(a,{Z:function(){return l}});var t=s(85893);s(67294);function l(e){var a=e.message;return(0,t.jsxs)("div",{className:"p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid",children:[(0,t.jsx)("img",{src:"/images/warning.png",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,t.jsx)("span",{children:a})]})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/9788-84477f8e20625988.js b/dsql-app/.local_dist/static/chunks/9788-84477f8e20625988.js new file mode 100644 index 0000000..e5967d7 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/9788-84477f8e20625988.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9788],{54559:function(e,t,a){a.d(t,{Z:function(){return w}});var l=a(85893),i=a(67294);var d=a(828),r=a(95264),n=a(63845),o=a(90918),s=a(20745);function c(e){var t=e.editor,a=e.rootElement;return(0,l.jsx)("div",{className:"embed-popup-form-content-wrapper text-sm mt-2 flex-wrap bg-white p-10 rounded max-w-2xl w-full",children:(0,l.jsxs)("form",{onSubmit:function(e){e.preventDefault();var l=e.target["embed-text-area"].value;if(!(null===l||void 0===l?void 0:l.match(/./)))return alert("Please Enter HTML Text to continue.");t.insertContent(l),document.body.removeChild(a)},className:"w-full flex flex-col items-stretch gap-2",children:[(0,l.jsx)("h3",{className:"m-0 text-center text-lg",children:"Enter HTML code"}),(0,l.jsx)("textarea",{name:"embed-text-area",id:"embed-text-area",cols:30,rows:10,placeholder:"Paste Code here ..."}),(0,l.jsx)("button",{type:"submit",children:"Embed"})]})})}function u(e){var t=e.editor;navigator.clipboard.writeText((null===t||void 0===t?void 0:t.getContent())||"").then((function(){alert("Html Copied to Clipboard!")}))}var m=a(41352),f=a(52652),p=a.n(f);function x(e){var t=e.editor,a=e.rootElement,r=t.getContent(),n=i.useRef(),o=i.useRef(),s=(0,d.Z)(i.useState(null),2),c=s[0],u=s[1];return i.useEffect((function(){try{if(!(null===ace||void 0===ace?void 0:ace.edit)||!n.current)return void console.log("Ace Editor not found!");var e=ace.edit(n.current);e.setOptions({mode:"ace/mode/html",value:p()(r)}),u(e);try{ace.require("ace/ext/beautify").beautify(e.session)}catch(t){}}catch(a){console.log("JSON Editor ERROR =>",a.message)}}),[]),(0,l.jsxs)("div",{onKeyUp:function(e){var t;e.ctrlKey&&"Enter"==e.key&&(null===(t=o.current)||void 0===t||t.click())},children:[(0,l.jsx)("div",{className:"embed-popup-form-content-wrapper relative flex flex-col items-center justify-center",children:(0,l.jsxs)("div",{className:"max-w-[1200px] rounded-md overflow-hidden bg-white w-[90vw] items-start justify-start relative",children:[(0,l.jsx)("div",{ref:n,className:"w-full h-[80vh] text-[18px]"}),(0,l.jsx)("button",{className:"absolute bottom-4 right-4",onClick:function(e){if(c){var l=c.getValue();t.setContent(l),setTimeout((function(){document.body.removeChild(a)}),200)}},ref:o,children:"Save"})]})}),(0,l.jsx)("button",{className:"absolute top-4 right-8 rounded-full white",onClick:function(){try{document.body.removeChild(a)}catch(e){}},style:{width:"40px",height:"40px",padding:"0",zIndex:"12039800000"},children:(0,l.jsx)(m.Z,{})})]})}function h(e){var t=e.editor,a=document.createElement("div");(a.style.position="fixed",a.style.width="100vw",a.style.height="100vh",a.style.zIndex="123000000000000000",a.style.backgroundColor="rgba(0,0,0,0.8)",a.style.display="flex",a.style.alignItems="center",a.style.justifyContent="center",a.style.top="0",a.style.left="0",document.body.append(a),a.onclick=function(e){e.target.closest(".embed-popup-form-content-wrapper")||document.body.removeChild(a)},t)&&s.createRoot(a).render((0,l.jsx)(x,{editor:t,rootElement:a}))}function v(e){var t=e.editor,a=document.createElement("div");(a.style.position="fixed",a.style.width="100vw",a.style.height="100vh",a.style.zIndex="123000000000000000",a.style.backgroundColor="rgba(0,0,0,0.8)",a.style.display="flex",a.style.alignItems="center",a.style.justifyContent="center",a.style.top="0",a.style.left="0",document.body.append(a),a.onclick=function(e){e.target.closest(".embed-popup-form-content-wrapper")?console.log("Still In Form"):document.body.removeChild(a)},t)&&s.createRoot(a).render((0,l.jsx)(c,{editor:t,rootElement:a}))}function y(e){var t=e.fieldObject,a=(e.dataTypeSchema,e.richTextEditors),s=e.entry,c=e.currentRichTextEditorForms,m=e.entryPage,f=e.formButtonId,p=(0,d.Z)(i.useState(!1),2),x=p[0],y=p[1],b=i.useRef(),g=i.useRef();return i.useEffect((function(){y(!0)}),[]),i.useEffect((function(){x&&(a.current.push({fieldName:t.fieldName||"",ref:g}),c.current.push({fieldName:t.fieldName||"",ref:g}))}),[x]),(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0 w-full rich-text-editor-wrapper",children:[(0,l.jsxs)("label",{className:"font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2",htmlFor:t.fieldName,children:[t.encrypted&&(0,l.jsx)(n.Z,{fontSize:"small",className:"opacity-50"}),(0,l.jsx)("span",{children:t.fieldName})]}),(0,l.jsxs)("div",{ref:b,id:t.fieldName,className:"w-full p-0 sm:p-4 flex-col items-stretch bg-slate-100 relative dark:bg-slate-700 border border-solid border-slate-300 dark:border-slate-300/20",style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},children:[!x&&(0,l.jsx)(r.Z,{}),x&&(0,l.jsx)(i.Fragment,{children:(0,l.jsx)(o.M,{tinymceScriptSrc:"/tinymce/tinymce.min.js",onInit:function(e,t){g.current=t},initialValue:t.defaultValue||(s&&t.fieldName&&s[t.fieldName]?s[t.fieldName]:""),init:{height:m?400:300,width:"100%",convert_urls:!1,menubar:!1,plugins:["advlist","lists","link","image","charmap","anchor","searchreplace","visualblocks","code","fullscreen","insertdatetime","media","table","preview","help","wordcount"],toolbar:"undo redo | blocks | bold italic forecolor | link image | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | removeformat help | editCode embedCode copyCode",placeholder:"Type something ...",document_base_url:"/",content_css:t.cssFiles||void 0,setup:function(e){!function(e){var t=e.editor,a=e.formButtonId;t.addShortcut("meta+13","Save Entry.",(function(){var e;window.confirm("Update this Form?")&&a&&(null===(e=document.getElementById(a))||void 0===e||e.click())})),t.addShortcut("meta+shift+e","Edit Code.",(function(){h({editor:t})})),t.addShortcut("meta+shift+d","Embed Code.",(function(){v({editor:t})})),t.addShortcut("meta+shift+c","Copy Code.",(function(){u({editor:t})})),t.ui.registry.addButton("editCode",{icon:"edit-block",onAction:function(e){return h({editor:t})},tooltip:"Edit HTML Code"}),t.ui.registry.addButton("embedCode",{icon:"sourcecode",onAction:function(e){return v({editor:t})},tooltip:"Embed Code"}),t.ui.registry.addButton("copyCode",{icon:"copy",onAction:function(e){return u({editor:t})},tooltip:"Copy HTML"})}({editor:e,formButtonId:f})}}})})]})]})}var b=a(86729);a(63764);var g=a(31571),j=a(31325);function N(e){var t=e.fieldObject,a=e.typeFinal,i=e.isExpanded,d=e.setHeight,r=e.COLLAPSED_HEIGHT,o=e.EXPANDED_HEIGHT;return(0,l.jsxs)("div",{className:"gap-2 w-full",children:[(0,l.jsxs)("label",{className:"font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2",htmlFor:t.fieldName,children:[t.encrypted&&(0,l.jsx)(n.Z,{fontSize:"small",className:"opacity-50"}),(0,l.jsx)("span",{children:t.fieldName})]}),(0,l.jsx)("div",{className:"px-4 py-1 bg-secondary text-white rounded-full text-sm font-bold -mt-2",children:(0,l.jsx)("span",{children:a})}),(0,l.jsxs)("div",{className:"ml-auto cursor-pointer gap-1 text-slate-400 hover:text-slate-800 -mt-2 items-center flex",onClick:function(e){d(i?r:o)},children:[(0,l.jsx)("span",{className:"font-semibold text-sm",children:i?"Collapse":"Expand"}),i?(0,l.jsx)(g.Z,{size:18,className:"mt-[-1px]"}):(0,l.jsx)(j.Z,{size:18,className:"mt-[-1px]"})]})]})}function E(e){var t=e.fieldObject,a=(e.dataTypeSchema,e.entry),r=(e.entryPage,e.jsonTextEditors),n=e.type||"json";try{var o=(0,d.Z)(i.useState(0),2),s=o[0],c=o[1],u=(0,d.Z)(i.useState(300),2),m=u[0],f=u[1],p=300!==m,x=i.useRef(),h=i.useRef();return i.useEffect((function(){!function(e){var t=e.jsonEditorRef,a=e.fieldObject,l=e.setRefresh,i=e.typeFinal,d=e.entry,r=e.jsonTextEditors,n=e.editorRef;try{if(!(null===ace||void 0===ace?void 0:ace.edit)||!t.current||!a.fieldName)return console.log("Ace Editor not found!"),void setTimeout((function(){l((function(e){return e+1}))}),1e3);var o=ace.edit(t.current);o.setOptions({mode:"ace/mode/"+i,value:a.defaultValue?a.defaultValue:(null===d||void 0===d?void 0:d[a.fieldName])?function(){if("json"!==i)return d[a.fieldName];try{return JSON.stringify(JSON.parse(d[a.fieldName]),null,4)}catch(e){return d[a.fieldName]}}():"",placeholder:"json"==i?"{} ...":"",enableBasicAutocompletion:!0,enableLiveAutocompletion:!0}),r.current.push({fieldName:a.fieldName,ref:n}),n.current=o;try{ace.require("ace/ext/beautify").beautify(o.session)}catch(s){}}catch(c){console.log("JSON Editor ERROR =>",c.message)}}({editorRef:h,entry:a,fieldObject:t,jsonEditorRef:x,jsonTextEditors:r,setRefresh:c,typeFinal:n})}),[s]),(0,l.jsx)(i.Fragment,{children:(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0 w-full rich-text-editor-wrapper",children:[(0,l.jsx)(N,{fieldObject:t,isExpanded:p,setHeight:f,typeFinal:n,COLLAPSED_HEIGHT:300,EXPANDED_HEIGHT:600}),(0,l.jsx)(T,{height:m,jsonEditorRef:x})]})})}catch(v){return i.useEffect((function(){(0,b.Z)("/api/admin/clientError",{method:"post",body:{component:"DatabaseShellContent/catch-error-return",message:v.message}})}),[]),(0,l.jsx)(i.Fragment,{children:(0,l.jsx)("span",{children:"Editor Load Error"})})}}function T(e){var t=e.height,a=e.jsonEditorRef;return(0,l.jsx)("div",{className:"w-full p-0 sm:p-4 flex-col relative dark:bg-slate-700 border border-solid border-slate-300 dark:border-slate-300/20 overflow-hidden",style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px",height:"".concat(t,"px")},children:(0,l.jsx)("div",{ref:a,className:"w-full text-[18px] h-full"})})}function w(e){var t,a,d,r,o,s,c,u,m,f=e.fieldObject,p=e.dataTypeSchema,x=e.richTextEditors,h=e.jsonTextEditors,v=e.entry,b=e.currentRichTextEditorForms,g=e.confirmedDelegetedUser,j=(e.query,e.entryPage),N=e.formButtonId,T=(null===g||void 0===g||g.delegated,null===g||void 0===g||null===(t=g.priviledges)||void 0===t||t.match(/Edit Tables/i),null===g||void 0===g||null===(a=g.priviledges)||void 0===a||a.match(/Delete Tables/i),null===g||void 0===g||null===(d=g.priviledges)||void 0===d||d.match(/Create Tables/i),null===g||void 0===g||null===(r=g.priviledges)||void 0===r||r.match(/Edit Entries/i),null===g||void 0===g||null===(o=g.priviledges)||void 0===o||o.match(/Delete Entries/i),i.useRef()),w=function(e){var t,a,i,d,r,n,o,s,c,u=e.fieldObject,m=e.dataTypeSchema,f=e.elementRef,p=e.entry;return u.defaultField?r=(0,l.jsx)("input",{ref:f,type:"text",name:"def_field_"+u.fieldName,id:"def_field_"+u.fieldName,placeholder:u.fieldName,defaultValue:p&&p[u.fieldName||""]?p[u.fieldName||""]:u.defaultValue?u.defaultValue:"",style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},readOnly:!0,"data-default":"true"}):((null===(t=u.dataType)||void 0===t?void 0:t.match(/varchar/i))&&(r=(0,l.jsx)("textarea",{ref:f,name:u.fieldName,id:u.fieldName,placeholder:u.fieldName,required:!!u.notNullValue,maxLength:(null===(o=null===(n=u.dataType)||void 0===n?void 0:n.match(/\d+/))||void 0===o?void 0:o[0])?parseInt((null===(c=null===(s=u.dataType)||void 0===s?void 0:s.match(/\d+/))||void 0===c?void 0:c[0])||""):void 0,defaultValue:p&&p[u.fieldName||""]?p[u.fieldName||""]:u.defaultValue?u.defaultValue:"",style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},onChange:function(e){var t;(null===(t=u.fieldName)||void 0===t?void 0:t.match(/^title$/))&&function(e){var t=e.target.closest("form");if(t){var a=null===t||void 0===t?void 0:t.querySelector("#slug");a&&(a.value=e.target.value.toLowerCase().replace(/ /g,"-").replace(/[^a-z\-0-9]/g,""))}}(e)}})),(null===(a=u.dataType)||void 0===a?void 0:a.match(/int$/i))&&(r=(0,l.jsx)("input",{ref:f,type:"number",name:u.fieldName,id:u.fieldName,placeholder:u.fieldName,required:!!u.notNullValue,max:m.maxValue,style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},defaultValue:p&&p[u.fieldName||""]?p[u.fieldName||""]:u.defaultValue?u.defaultValue:"",onChange:function(e){}})),(null===(i=u.dataType)||void 0===i?void 0:i.match(/text$/i))&&(r=(0,l.jsx)("textarea",{ref:f,name:u.fieldName,id:u.fieldName,placeholder:u.fieldName,required:!!u.notNullValue,defaultValue:p&&p[u.fieldName||""]?p[u.fieldName||""]:u.defaultValue?u.defaultValue:"",style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},rows:10,onChange:function(e){}})),(null===(d=u.fieldName)||void 0===d?void 0:d.match(/password|^pass$|^key$/i))&&(r=(0,l.jsxs)("div",{className:"w-full relative",children:[(0,l.jsx)("input",{ref:f,type:"password",name:u.fieldName,id:u.fieldName,placeholder:u.fieldName,required:!!u.notNullValue,max:m.maxValue,style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},defaultValue:p&&p[u.fieldName]?p[u.fieldName]:u.defaultValue?u.defaultValue:"",onChange:function(e){}}),(0,l.jsx)("span",{className:"absolute right-4 cursor-pointer",onClick:function(e){var t=e.target.closest("div").querySelector("input");"password"===t.type?(t.type="text",e.target.innerText="Hide"):(t.type="password",e.target.innerText="Reveal")},children:"Reveal"})]})),r||(r=(0,l.jsx)("input",{ref:f,type:"text",name:u.fieldName,id:u.fieldName,style:{borderRadius:"0 5px 5px 5px",marginTop:"-1px"},defaultValue:p&&p[u.fieldName||""]?p[u.fieldName||""]:u.defaultValue?u.defaultValue:"",onChange:function(e){}})),r)}({fieldObject:f,dataTypeSchema:p,elementRef:T,entry:v});if((null===(s=f.dataType)||void 0===s?void 0:s.match(/text$/i))&&f.richText&&!f.plainText&&!(null===(c=f.fieldName)||void 0===c?void 0:c.match(/^pass|^key$/i))&&!f.encrypted||f.encrypted&&f.richText)return(0,l.jsx)(i.Fragment,{children:(0,l.jsx)(y,{fieldObject:f,dataTypeSchema:p,richTextEditors:x,currentRichTextEditorForms:b,entry:v,entryPage:j,formButtonId:N})});var C=f.json||f.yaml||f.html||f.css||f.javascript||f.shell;return(null===(u=f.dataType)||void 0===u?void 0:u.match(/text$/i))&&C&&!f.plainText&&!(null===(m=f.fieldName)||void 0===m?void 0:m.match(/^pass|^key$/i))&&!f.encrypted||f.encrypted&&C?(0,l.jsx)(E,{fieldObject:f,dataTypeSchema:p,entry:v,entryPage:j,jsonTextEditors:h,type:f.json?"json":f.yaml?"yaml":f.html?"html":f.css?"css":f.javascript?"javascript":f.shell?"shell":"json"}):(0,l.jsxs)("div",{className:"flex flex-col items-start gap-0 w-full"+(f.defaultField?" opacity-50":""),children:[(0,l.jsxs)("label",{className:"font-bold text-slate-700 dark:text-slate-300 text-base px-3 py-1 bg-slate-100 dark:bg-slate-700 rounded-t-md border border-solid border-slate-300 dark:border-slate-300/20 flex items-center gap-2",htmlFor:f.fieldName,children:[f.encrypted&&(0,l.jsx)(i.Fragment,{children:(0,l.jsx)(n.Z,{fontSize:"small",className:"opacity-50"})}),(0,l.jsx)("span",{children:f.fieldName}),f.defaultField&&(0,l.jsx)("span",{className:"bg-white dark:bg-slate-900 text-primary dark:text-slate-300 font-semibold text-xs px-2 py-0.5 rounded-xs",children:"Default Field"})]}),w]})}},88515:function(e,t,a){a.d(t,{Z:function(){return d}});var l=a(85893),i=a(67294);function d(e){var t=e.table,a=e.database,d=e.user,r=(e.activeDbClone,(null===t||void 0===t?void 0:t.childTableDbFullName)?t.childTableDbFullName.replace(new RegExp(/datasquirel_user_\d+_/),""):null),n=t.childTableDbFullName===a.db_full_name;return r?(0,l.jsxs)("span",{className:"info small green gap-1"+((null===a||void 0===a?void 0:a.active_clone)?" -mt-6":""),style:{fontWeight:"500"},children:["This Table is an active clone of"," ",(0,l.jsx)("a",{href:"/admin/".concat(null===d||void 0===d?void 0:d.id,"/databases/").concat(r,"/tables/").concat(t.childTableName),target:"_blank",className:"button gray outlined small-text",style:{display:"inline-block",fontSize:"12px",padding:"3px 7px"},children:(0,l.jsx)("b",{children:t.childTableName})})," ","in"," ",n?(0,l.jsxs)("span",{children:["this current database(",(0,l.jsx)("b",{children:a.db_name}),")."]}):(0,l.jsxs)(i.Fragment,{children:[(0,l.jsx)("a",{href:"/admin/".concat(null===d||void 0===d?void 0:d.id,"/databases/").concat(r),target:"_blank",className:"button gray outlined small-text",style:{display:"inline-block",fontSize:"12px",padding:"3px 7px"},children:(0,l.jsx)("b",{children:r})}),(0,l.jsx)("span",{children:"database."})]})," ",(null===a||void 0===a?void 0:a.active_clone)?"":"Only Foreign keys and Entries can be updated."]}):(0,l.jsx)(i.Fragment,{})}}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/9967-c027b915261dae19.js b/dsql-app/.local_dist/static/chunks/9967-c027b915261dae19.js new file mode 100644 index 0000000..5003074 --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/9967-c027b915261dae19.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9967],{99967:function(e,t,l){l.d(t,{Z:function(){return m}});var a=l(47568),n=l(828),i=l(97582),s=l(85893),r=l(67294),d=l(24209),o=l(64838),u=l(96486),c=l.n(u);function m(e){var t,u,m,f=e.targetField,v=e.fieldIndex,x=e.tableFields,h=e.setTableFields,p=e.refreshFieldsListRef,g=e.setActiveEdit,N=e.database,j=e.currentTable,y=e.user,b=(null===f||void 0===f?void 0:f.dataType)?f.dataType.replace(/\d|\(|\)/g,""):null,T=(null===f||void 0===f?void 0:f.dataType)?f.dataType.replace(/[^\d]/g,""):"200",w=l(89594),_=r.useRef(c().cloneDeep(f)),F=r.useRef(),C=(0,n.Z)(r.useState(f),2),I=C[0],V=C[1],E=(0,n.Z)(r.useState(null===f||void 0===f?void 0:f.fieldName),2),S=E[0],D=(E[1],(0,n.Z)(r.useState(b),2)),k=D[0],Z=D[1],K=(0,n.Z)(r.useState(T),2),R=K[0],A=K[1],L=(0,n.Z)(r.useState("Varchar is simply letters and numbers within the range 0 - 255"),2),U=L[0],M=L[1],Y=(0,n.Z)(r.useState((null===f||void 0===f?void 0:f.richText)&&!(null===f||void 0===f?void 0:f.encrypted)?"Yes":"No"),2),q=(Y[0],Y[1],Boolean(null===k||void 0===k?void 0:k.match(/uuid/i)));return(0,s.jsx)("div",{className:"w-full -mt-3 bg-white dark:bg-slate-800 flex-wrap",ref:F,children:(0,s.jsxs)("form",{className:"flex flex-col xl:flex-row items-start gap-4 w-full justify-between border border-solid p-4 border-slate-200 dark:border-slate-600 rounded rounded-t-none focus:shadow-lg shadow-slate-700 dark:shadow-black relative flex-wrap",onSubmit:function(e){var t,l;e.preventDefault(),h((function(e){var t=e;return t[v]=I,t})),p.current((function(e){return e+1})),null===(l=null===(t=e.target.closest(".table-field-wrapper"))||void 0===t?void 0:t.querySelector(".edit-table-field-section"))||void 0===l||l.classList.toggle("hidden")},children:[(0,s.jsxs)("div",{className:"gap-4 flex-wrap w-full md:w-auto flex-col xl:flex-row items-stretch",children:[(0,s.jsxs)("div",{className:"flex flex-col items-start gap-0.5",children:[(0,s.jsx)("label",{htmlFor:"new_field_name",children:"Field Name"}),(0,s.jsx)("input",{type:"text",name:"new_field_name",id:"new_field_name",placeholder:"Eg. post_title",onInput:function(){var e=(0,a.Z)((function(e){var t;return(0,i.__generator)(this,(function(l){return(t=e.target).value=t.value.toLowerCase().replace(/ /g,"_"),V((function(e){var l=e;return l.fieldName=t.value,l.updatedField=!0,l.originName||(l.originName=S),l})),[2]}))}));return function(t){return e.apply(this,arguments)}}(),required:!0,defaultValue:S})]}),(0,s.jsxs)("div",{className:"flex flex-col items-start gap-4 xl:gap-0.5",children:[(0,s.jsxs)("div",{className:"flex-wrap xl:flex-nowrap w-full md:w-auto",children:[(0,s.jsx)("label",{htmlFor:"new_field_data_type",children:"Data Type"}),(0,s.jsxs)("div",{className:"dropdown-wrapper reversed text-sm items-start",children:[(0,s.jsx)("span",{className:"px-2 bg-slate-200 dark:bg-slate-700 rounded-full hover:bg-slate-100 dark:hover:bg-slate-600 hidden xl:flex",children:"Info"}),(0,s.jsx)("div",{className:"dropdown mt-0 xl:-mt-2",children:(0,s.jsx)("span",{children:U})})]})]}),(0,s.jsxs)("div",{className:"w-auto",children:[(0,s.jsx)("select",{name:"new_field_data_type",id:"new_field_data_type",className:"w-full xl-w-auto",onChange:function(e){var t=e.target;Z(t.value),t.childNodes.forEach((function(e){e.value===t.value&&e.dataset.desc&&M(e.dataset.desc),e.value===t.value&&e.dataset.literal?(I.defaultValueLiteral=e.dataset.literal,I.nullValue=!1):delete I.defaultValueLiteral})),f.dataType=t.value+(t.value.match(/VARCHAR/)?"(".concat(R||200,")"):"")},defaultValue:k||void 0,children:w.map((function(e,t){return e.name.match(/VARCHAR/)?(0,s.jsx)("option",{value:e.name,"data-desc":e.description,children:e.title+"("+(R||200)+")"},t+1):(0,s.jsx)("option",{value:e.name,"data-desc":e.description,"data-literal":e.valueLiteral||void 0,children:e.title},t+1)}))}),(null===k||void 0===k?void 0:k.match(/VARCHAR/))&&(0,s.jsx)("input",{type:"number",defaultValue:R||200,className:"px-2",style:{maxWidth:"60px"},max:255,min:5,onChange:function(e){A(e.target.value),f.dataType=k+"(".concat(e.target.value,")")}})]})]}),(null===k||void 0===k?void 0:k.match(/text/i))&&(0,s.jsx)(r.Fragment,{children:(0,s.jsx)(o.Z,{targetField:f})}),!(null===(t=f.dataType)||void 0===t?void 0:t.match(/text/i))&&!q&&(0,s.jsxs)("div",{className:"flex flex-col items-start gap-0.5",style:{minWidth:"70px"},children:[(0,s.jsx)("label",{htmlFor:"new_field_required",children:"Required?"}),(0,s.jsxs)("select",{name:"new_field_required",id:"new_field_required",className:"px-2",defaultValue:(null===f||void 0===f?void 0:f.notNullValue)?"Yes":"No",onChange:function(e){console.log(f),"Yes"===e.target.value?f.notNullValue=!0:(f.notNullValue=!1,delete f.notNullValue)},children:[(0,s.jsx)("option",{value:"No",children:"No"}),(0,s.jsx)("option",{value:"Yes",children:"Yes"})]})]}),!q&&(0,s.jsxs)("div",{className:"flex flex-col items-start gap-0.5",children:[(0,s.jsx)("label",{htmlFor:"new_field_default_value",children:(null===I||void 0===I||null===(u=I.dataType)||void 0===u?void 0:u.match(/text$/i))?"Can't Set Default for text values":"Default Value (optional)"}),(0,s.jsx)("input",{type:"text",name:"new_field_default_value",id:"new_field_default_value",className:(null===I||void 0===I||null===(m=I.dataType)||void 0===m?void 0:m.match(/text$/i))?"pointer-events-none opacity-50":"",placeholder:"Default Value",defaultValue:(null===I||void 0===I?void 0:I.defaultValue)?I.defaultValue:(null===I||void 0===I?void 0:I.nullValue)?"NULL":"",onInput:function(e){var t,l=e.target;(null===(t=I.dataType)||void 0===t?void 0:t.match(/text$/i))||V((function(e){var t=e;return l.value.match(/./)?delete t.notNullValue:(delete t.defaultValue,delete t.nullValue),l.value.match(/^null$/i)?(delete t.defaultValue,t.nullValue=!0):l.value.match(/./)&&(delete t.nullValue,t.defaultValue=l.value),t}))}})]}),!q&&(0,s.jsx)(d.Z,{database:N,setFieldData:V,setTableFields:h,tableFields:x,targetField:f,user:y,currentTable:j,fieldIndex:v})]}),(0,s.jsxs)("div",{className:"secondary mt-auto flex-wrap w-full xl:w-auto",children:[(0,s.jsx)("button",{type:"submit",className:"secondary mt-auto py-3 w-full md:w-auto grow",children:"Save Updates"}),(0,s.jsx)("div",{className:"button outlined gray mt-auto py-2.5 w-full md:w-auto justify-center grow",onClick:function(e){_.current&&(f=c().cloneDeep(_.current)),h((function(e){var t=c().cloneDeep(e);return v&&_.current&&(t[v]=c().cloneDeep(_.current)),t})),g&&g(!1)},children:"Cancel"})]})]})})}},24209:function(e,t,l){l.d(t,{Z:function(){return g}});var a=l(828),n=l(85893),i=l(67294),s=l(29815),r=l(27901),d=l(41352);function o(e){var t=e.targetField;if(!(null===t||void 0===t?void 0:t.richText))return null;var l=(0,a.Z)(i.useState(t.cssFiles||[]),2),o=l[0],u=l[1],c=i.useRef(null);return i.useEffect((function(){t.cssFiles=o}),[o]),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-2 w-full my-4",style:{minWidth:"70px"},children:[(0,n.jsx)("span",{className:"label text-xs text-slate-500",children:"Add CSS"}),o.map((function(e,t){return(0,n.jsxs)("div",{className:"relative border border-solid border-slate-300 text-xs px-2 py-1 rounded-full",children:[(0,n.jsx)("span",{children:e}),(0,n.jsx)(d.Z,{size:20,onClick:function(){u((function(t){return t.filter((function(t){return t!==e}))}))},className:"cursor-pointer hover:opacity-60 "})]},t+1)})),(0,n.jsxs)("div",{className:"row w-full",children:[(0,n.jsx)(r.Z,{name:"css-file",placeholder:"CSS file URL",elementRef:c}),(0,n.jsx)("button",{className:"secondary outlined",onClick:function(){var e,t=null===(e=c.current)||void 0===e?void 0:e.value;(null===t||void 0===t?void 0:t.match(/./))&&u((function(e){return(0,s.Z)(new Set((0,s.Z)(e).concat([t])))}))},children:"Add"})]}),(0,n.jsx)("span",{className:"text-sm text-slate-600",children:"Add CSS files to your Rich Text field"})]})}function u(e){var t=e.targetField,l=e.setFieldData;return(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",style:{minWidth:"70px"},children:[(0,n.jsx)("label",{htmlFor:"encryption_field",children:"Encrypt?"}),(0,n.jsxs)("select",{name:"encryption_field",id:"encryption_field",className:"px-2",defaultValue:(null===t||void 0===t?void 0:t.encrypted)?"Yes":"No",onChange:function(e){l&&l((function(t){var l=t;return e.target.value.match(/yes/i)?l.encrypted=!0:(l.encrypted=!1,delete l.encrypted),l}))},children:[(0,n.jsx)("option",{value:"No",children:"No"}),(0,n.jsx)("option",{value:"Yes",children:"Yes"})]})]})}var c=l(3699);function m(e){e.targetField,e.setFieldData;return null}function f(e){var t=e.targetField;return(0,n.jsxs)("div",{className:"flex flex-col items-start gap-2 w-full",style:{minWidth:"70px"},children:[(0,n.jsx)("label",{htmlFor:"encryption_field",children:"Pattern"}),(0,n.jsx)("span",{className:"text-sm text-slate-500",children:'This describes a pattern that must be matched for this field to be valid. If you add a pattern and make a db entry that doesn\'t match, the entry will be "NULL" or an empty string or the default value.'}),(0,n.jsx)("input",{type:"text",placeholder:"Regex Pattern. Eg: '\\\\.[a-z]+'",onInput:function(e){var l,a=e.target;(null===a||void 0===a||null===(l=a.value)||void 0===l?void 0:l.length)>0?t.pattern=a.value:delete t.pattern},defaultValue:null===t||void 0===t?void 0:t.pattern}),(0,n.jsx)("input",{type:"text",placeholder:"Regex Pattern Flags. Eg: igm",onInput:function(e){var l,a=e.target;(null===a||void 0===a||null===(l=a.value)||void 0===l?void 0:l.length)>0?t.patternFlags=a.value:delete t.patternFlags},defaultValue:null===t||void 0===t?void 0:t.patternFlags})]})}var v=l(96486),x=l.n(v),h=l(59471);function p(e){var t=e.targetField,l=e.setFieldData;return(0,n.jsxs)("div",{className:"flex flex-col items-start gap-0.5 w-full",style:{minWidth:"70px"},children:[(0,n.jsx)("label",{htmlFor:"unique_field",children:"Unique Field?"}),(0,n.jsxs)("select",{name:"unique_field",id:"unique_field",className:"px-2",defaultValue:(null===t||void 0===t?void 0:t.unique)?"Yes":"No",onChange:function(e){l&&l((function(t){var l=t;return e.target.value.match(/yes/i)?l.unique=!0:(l.unique=!1,delete l.unique),l}))},children:[(0,n.jsx)("option",{value:"No",children:"No"}),(0,n.jsx)("option",{value:"Yes",children:"Yes"})]})]})}function g(e){var t=e.targetField,l=e.currentTable,s=e.database,r=e.tableFields,d=e.setTableFields,v=e.setFieldData,g=e.user,N=(e.fieldIndex,(0,a.Z)(i.useState(!1),2)),j=N[0],y=N[1],b=i.useRef(x().cloneDeep(t));return i.useEffect((function(){}),[]),(0,n.jsxs)(i.Fragment,{children:[(0,n.jsx)("span",{className:"button outlined gray mt-5 w-full xl:w-auto",onClick:function(){y(!0)},children:"More"}),(0,n.jsx)(h.Z,{open:j,onClose:function(){if(b.current){var e=x().cloneDeep(b.current);t=e}y(!1)},maxWidth:"600px",children:(0,n.jsxs)("div",{className:"m-auto flex flex-col max-w-xl w-full max-h-[90vh] overflow-y-auto",children:[(0,n.jsx)("div",{className:"w-full justify-between",children:(0,n.jsx)("span",{className:"text-xl",children:"More Options"})}),(0,n.jsx)(o,{targetField:t}),(0,n.jsx)(p,{targetField:t,setFieldData:v}),(0,n.jsx)(u,{targetField:t,setFieldData:v}),l&&(0,n.jsx)(c.Z,{targetField:t,setFieldData:v,database:s,tableFields:r,setTableFields:d,currentTable:l,user:g}),(0,n.jsx)(m,{targetField:t,setFieldData:v}),(0,n.jsx)(f,{targetField:t}),(0,n.jsx)("button",{className:"w-full outlined more-padding",onClick:function(){y(!1)},children:"Done"})]})})]})}},3699:function(e,t,l){l.d(t,{Z:function(){return d}});var a=l(828),n=l(85893),i=l(67294),s=l(86729),r=l(95264);function d(e){var t,l,d=e.targetField,o=e.setFieldData,u=(e.tableFields,e.setTableFields,e.database),c=e.currentTable,m=e.user,f=e.setActiveEdit,v=e.activeClonedTable,x=(0,a.Z)(i.useState(!!(null===d||void 0===d?void 0:d.foreignKey)),2),h=x[0],p=x[1],g=i.useState(null),N=(0,a.Z)(g,2),j=N[0],y=N[1],b=i.useState(null),T=(0,a.Z)(b,2),w=T[0],_=T[1],F=i.useState(null),C=(0,a.Z)(F,2),I=C[0],V=C[1],E=i.useState(null),S=(0,a.Z)(E,2),D=S[0],k=S[1],Z=(0,a.Z)(i.useState(!1),2),K=Z[0],R=Z[1];return i.useEffect((function(){(h||(null===d||void 0===d?void 0:d.foreignKey))&&(0,s.Z)("/api/getUserSchemaData").then((function(e){if(e.success)try{var t=e.schemaData.filter((function(e){return e.dbFullName===u.db_full_name})),l=c?t[0].tables.filter((function(e){return e.tableName!==c.tableName})):t[0].tables;if(y(l),null===d||void 0===d?void 0:d.foreignKey){var a,n=l.filter((function(e){var t;return e.tableName===(null===d||void 0===d||null===(t=d.foreignKey)||void 0===t?void 0:t.destinationTableName)}));_(n[0]),(null===(a=n[0])||void 0===a?void 0:a.fields)&&V(n[0].fields)}}catch(i){(0,s.Z)("/api/admin/clientError",{method:"post",body:{component:"ForeignKey/fetch-error-getUserSchemaData/lines-65-77",message:i.message,user:m}})}}))}),[h]),(0,n.jsxs)("div",{className:"flex flex-col items-start gap-2 w-full mt-2 relative",style:{minWidth:"70px"},children:[K&&(0,n.jsx)(r.Z,{}),(0,n.jsxs)("label",{htmlFor:"foreign_key_field",className:"flex flex-wrap items-center gap-2 mt-2",children:[(0,n.jsx)("span",{children:"Foreign Key?"}),(0,n.jsxs)("div",{className:"dropdown-wrapper reversed text-sm items-start",children:[(0,n.jsx)("span",{className:"px-2 bg-slate-200 rounded-full hover:bg-slate-100 hidden xl:flex text-slate-600",children:"Info"}),(0,n.jsx)("div",{className:"dropdown mt-0 xl:-mt-2",children:(0,n.jsx)("span",{children:"Foriegn key links the current table to another table"})})]})]}),(0,n.jsxs)("select",{name:"foreign_key_field",id:"foreign_key_field",className:"px-2",defaultValue:(null===d||void 0===d?void 0:d.foreignKey)?"Yes":"No",onChange:function(e){e.target.value.match(/yes/i)?(p(!0),o&&o((function(e){var t=e;return t.foreignKey={foreignKeyName:void 0,destinationTableName:void 0,destinationTableColumnName:void 0,cascadeDelete:!0},t}))):(p(!1),o&&o((function(e){var t=e;return delete t.foreignKey,t})))},children:[(0,n.jsx)("option",{value:"No",children:"No"}),(0,n.jsx)("option",{value:"Yes",children:"Yes"})]}),h&&j&&(0,n.jsx)(i.Fragment,{children:(0,n.jsxs)("select",{name:"foreign_key_destination_table_name",id:"foreign_key_destination_table_name",className:"px-2",defaultValue:(null===d||void 0===d||null===(t=d.foreignKey)||void 0===t?void 0:t.destinationTableName)?d.foreignKey.destinationTableName:void 0,onChange:function(e){var t,l=e.target;if(null===(t=e.target.value)||void 0===t?void 0:t.match(/--/))o?o((function(e){var t=e,l=t.foreignKey;return l&&(l.destinationTableName=void 0),t})):l.dataset.destinationTableName=void 0;else{var a=j.filter((function(t){return t.tableName===e.target.value}))[0];_(a),(null===a||void 0===a?void 0:a.fields)&&V(a.fields),o?o((function(t){var l=t,a=l.foreignKey;return a&&(a.destinationTableName=e.target.value),l})):e.target.dataset.destinationTableName=e.target.value}},children:[(0,n.jsx)("option",{value:"--",children:"--Select Table--"}),j.map((function(e,t){return(0,n.jsx)("option",{value:e.tableName,children:e.tableFullName},t+1)}))]})}),w&&I&&(0,n.jsxs)(i.Fragment,{children:[(0,n.jsxs)("select",{name:"foreign_key_destination_table_column_name",id:"foreign_key_destination_table_column_name",className:"px-2",defaultValue:(null===d||void 0===d||null===(l=d.foreignKey)||void 0===l?void 0:l.destinationTableColumnName)?d.foreignKey.destinationTableColumnName:void 0,onChange:function(e){try{var t,l=I.filter((function(t){return t.fieldName===e.target.value}))[0];if(k(l),null===(t=e.target.value)||void 0===t?void 0:t.match(/--/))return void(o&&o((function(e){var t=e,l=t.foreignKey;return l&&(l.destinationTableColumnName=void 0),t})));var a="dsql_".concat(u.user_id,"_").concat(u.db_slug,"_").concat(Date.now());o?o((function(e){var t=e;t.dataType=l.dataType;var n=t.foreignKey;return n&&(n.destinationTableColumnName=l.fieldName,n.destinationTableColumnType=l.dataType,n.foreignKeyName=a),t})):(e.target.dataset.dataType=l.dataType,e.target.dataset.destinationTableColumnName=l.fieldName,e.target.dataset.foreignKeyName=a)}catch(n){(0,s.Z)("/api/admin/clientError",{method:"post",body:{component:"ForeignKey/lines-232-264",message:n.message,user:m}})}},children:[(0,n.jsx)("option",{value:"--",children:"--Select Column--"}),I.map((function(e,t){return(0,n.jsx)("option",{value:e.fieldName,children:e.fieldName},t+1)}))]}),v&&D&&(0,n.jsx)("button",{className:"secondary w-full",onClick:function(e){var t,l;R(!0),(0,s.Z)("/api/updateClonedTableForeignKeys",{method:"post",body:{tableData:c,database:u.db_full_name,dbSlug:u.db_slug,delegated:!!(null===(t=window.location)||void 0===t||null===(l=t.search)||void 0===l?void 0:l.match(/delegated=true/i))}},!0).then((function(e){e.success?window.alert("Foreign Key Added Successfully!"):window.alert("Update Failed, Please Try again."),setTimeout((function(){f&&f(!1)}),1e3)}))},children:"Add Foreign Key"})]}),v&&(0,n.jsx)("button",{className:"light-gray w-full",onClick:function(e){delete d.foreignKey,f&&f(!1)},children:"Cancel"})]})}},64838:function(e,t,l){l.d(t,{Z:function(){return n}});var a=l(85893);l(67294);function n(e){var t=e.targetField;return(0,a.jsxs)("div",{className:"flex flex-col items-start gap-0.5",style:{minWidth:"70px"},children:[(0,a.jsx)("label",{htmlFor:"rich_text_option",children:"Text Type"}),(0,a.jsxs)("select",{name:"rich_text_option",id:"rich_text_option",className:"px-2",onChange:function(e){switch(delete t.json,delete t.richText,delete t.yaml,delete t.html,delete t.javascript,delete t.shell,e.target.value){case"plain":default:break;case"rte":t.richText=!0;break;case"json":t.json=!0;break;case"yaml":t.yaml=!0;break;case"html":t.html=!0;break;case"css":t.css=!0;break;case"javascript":t.javascript=!0;break;case"shell":t.shell=!0}},defaultValue:t.richText?"rte":t.json?"json":t.yaml?"yaml":t.html?"html":t.javascript?"javascript":t.shell?"shell":t.css?"css":"plain",children:[(0,a.jsx)("option",{value:"plain",children:"Plain Text"}),(0,a.jsx)("option",{value:"rte",children:"Rich Text"}),(0,a.jsx)("option",{value:"json",children:"JSON"}),(0,a.jsx)("option",{value:"yaml",children:"YAML"}),(0,a.jsx)("option",{value:"html",children:"HTML"}),(0,a.jsx)("option",{value:"css",children:"CSS"}),(0,a.jsx)("option",{value:"javascript",children:"Javascript"}),(0,a.jsx)("option",{value:"shell",children:"Shell"})]})]})}},59471:function(e,t,l){l.d(t,{Z:function(){return r}});var a=l(85893),n=l(67294),i=l(20745),s=l(41352);function r(e){var t=e.children,l=e.open,s=(e.setOpen,e.onClose),r=e.maxWidth;return n.useEffect((function(){if(l){var e=document.createElement("div");e.className="modal-wrapper",(0,i.createRoot)(e).render((0,a.jsx)(d,{onClose:s,maxWidth:r,children:t})),document.body.appendChild(e)}else document.querySelectorAll(".modal-wrapper").forEach((function(e){var t;null===(t=e.parentElement)||void 0===t||t.removeChild(e)}))}),[l]),(0,a.jsx)(a.Fragment,{})}function d(e){var t=e.children,l=e.onClose,i=e.maxWidth,r=(e.open,n.useRef());return(0,a.jsxs)(n.Fragment,{children:[(0,a.jsx)("div",{className:"modal-cancel",onClick:function(e){o({modalEl:e.target.closest(".modal-wrapper"),closeFn:l})}}),(0,a.jsxs)("div",{className:"modal-content",style:{maxWidth:i||void 0},ref:r,children:[t," ",(0,a.jsx)("button",{className:"ghost modal-cancel-button",onClick:function(e){o({modalEl:e.target.closest(".modal-wrapper"),closeFn:l})},children:(0,a.jsx)(s.Z,{})})]})]})}function o(e){var t,l=e.modalEl,a=e.closeFn;a&&a(),null===(t=l.parentElement)||void 0===t||t.removeChild(l)}},89594:function(e){e.exports=JSON.parse('[{"title":"VARCHAR","name":"VARCHAR","value":"0-255","argument":true,"description":"Varchar is simply letters and numbers within the range 0 - 255","maxValue":255},{"title":"TINYINT","name":"TINYINT","value":"0-100","description":"TINYINT means Integers: 0 to 100","maxValue":127},{"title":"SMALLINT","name":"SMALLINT","value":"0-255","description":"SMALLINT means Integers: 0 to 240933","maxValue":32767},{"title":"MEDIUMINT","name":"MEDIUMINT","value":"0-255","description":"MEDIUMINT means Integers: 0 to 1245568545560","maxValue":8388607},{"title":"INT","name":"INT","value":"0-255","description":"INT means Integers: 0 to 12560","maxValue":2147483647},{"title":"BIGINT","name":"BIGINT","value":"0-255","description":"BIGINT means Integers: 0 to 1245569056767568545560","maxValue":2e+63},{"title":"TINYTEXT","name":"TINYTEXT","value":"0-255","description":"Text with 255 max characters","maxValue":127},{"title":"TEXT","name":"TEXT","value":"0-100","description":"MEDIUMTEXT is just text with max length 16,777,215","maxValue":127},{"title":"MEDIUMTEXT","name":"MEDIUMTEXT","value":"0-255","description":"MEDIUMTEXT is just text with max length 16,777,215","maxValue":127},{"title":"LONGTEXT","name":"LONGTEXT","value":"0-255","description":"LONGTEXT is just text with max length 4,294,967,295","maxValue":127},{"title":"UUID","name":"UUID","valueLiteral":"UUID()","description":"A Unique ID"}]')}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/amp.js b/dsql-app/.local_dist/static/chunks/amp.js new file mode 100644 index 0000000..68821bd --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/amp.js @@ -0,0 +1,950 @@ +/* + * ATTENTION: An "eval-source-map" devtool has been used. + * This devtool is neither made for production nor for readable output files. + * It uses "eval()" calls to create a separate source file with attached SourceMaps in the browser devtools. + * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/) + * or disable the default devtool with "devtool: false". + * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/). + */ +(self["webpackChunk_N_E"] = self["webpackChunk_N_E"] || []).push([["amp"],{ + +/***/ "./node_modules/@swc/helpers/lib/_array_like_to_array.js": +/*!***************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_array_like_to_array.js ***! + \***************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _arrayLikeToArray;\nfunction _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];\n return arr2;\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXJyYXlfbGlrZV90b19hcnJheS5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBLDBDQUEwQyxTQUFTO0FBQ25EO0FBQ0EiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL0Bzd2MvaGVscGVycy9saWIvX2FycmF5X2xpa2VfdG9fYXJyYXkuanM/NWViMiJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9hcnJheUxpa2VUb0FycmF5O1xuZnVuY3Rpb24gX2FycmF5TGlrZVRvQXJyYXkoYXJyLCBsZW4pIHtcbiAgICBpZiAobGVuID09IG51bGwgfHwgbGVuID4gYXJyLmxlbmd0aCkgbGVuID0gYXJyLmxlbmd0aDtcbiAgICBmb3IodmFyIGkgPSAwLCBhcnIyID0gbmV3IEFycmF5KGxlbik7IGkgPCBsZW47IGkrKylhcnIyW2ldID0gYXJyW2ldO1xuICAgIHJldHVybiBhcnIyO1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_array_like_to_array.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_array_with_holes.js": +/*!************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_array_with_holes.js ***! + \************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _arrayWithHoles;\nfunction _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXJyYXlfd2l0aF9ob2xlcy5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL19hcnJheV93aXRoX2hvbGVzLmpzP2VjMDAiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmRlZmF1bHQgPSBfYXJyYXlXaXRoSG9sZXM7XG5mdW5jdGlvbiBfYXJyYXlXaXRoSG9sZXMoYXJyKSB7XG4gICAgaWYgKEFycmF5LmlzQXJyYXkoYXJyKSkgcmV0dXJuIGFycjtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_array_with_holes.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_array_without_holes.js": +/*!***************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_array_without_holes.js ***! + \***************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _arrayWithoutHoles;\nvar _arrayLikeToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_array_like_to_array.js */ \"./node_modules/@swc/helpers/lib/_array_like_to_array.js\"));\nfunction _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return (0, _arrayLikeToArrayMjs).default(arr);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXJyYXlfd2l0aG91dF9ob2xlcy5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Ysa0RBQWtELG1CQUFPLENBQUMsMEZBQTJCO0FBQ3JGO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL0Bzd2MvaGVscGVycy9saWIvX2FycmF5X3dpdGhvdXRfaG9sZXMuanM/MmZmMiJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9hcnJheVdpdGhvdXRIb2xlcztcbnZhciBfYXJyYXlMaWtlVG9BcnJheU1qcyA9IF9pbnRlcm9wUmVxdWlyZURlZmF1bHQocmVxdWlyZShcIi4vX2FycmF5X2xpa2VfdG9fYXJyYXkuanNcIikpO1xuZnVuY3Rpb24gX2FycmF5V2l0aG91dEhvbGVzKGFycikge1xuICAgIGlmIChBcnJheS5pc0FycmF5KGFycikpIHJldHVybiAoMCwgX2FycmF5TGlrZVRvQXJyYXlNanMpLmRlZmF1bHQoYXJyKTtcbn1cbmZ1bmN0aW9uIF9pbnRlcm9wUmVxdWlyZURlZmF1bHQob2JqKSB7XG4gICAgcmV0dXJuIG9iaiAmJiBvYmouX19lc01vZHVsZSA/IG9iaiA6IHtcbiAgICAgICAgZGVmYXVsdDogb2JqXG4gICAgfTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_array_without_holes.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_assert_this_initialized.js": +/*!*******************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_assert_this_initialized.js ***! + \*******************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _assertThisInitialized;\nfunction _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n return self;\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXNzZXJ0X3RoaXNfaW5pdGlhbGl6ZWQuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXNzZXJ0X3RoaXNfaW5pdGlhbGl6ZWQuanM/NWFlZSJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9hc3NlcnRUaGlzSW5pdGlhbGl6ZWQ7XG5mdW5jdGlvbiBfYXNzZXJ0VGhpc0luaXRpYWxpemVkKHNlbGYpIHtcbiAgICBpZiAoc2VsZiA9PT0gdm9pZCAwKSB7XG4gICAgICAgIHRocm93IG5ldyBSZWZlcmVuY2VFcnJvcihcInRoaXMgaGFzbid0IGJlZW4gaW5pdGlhbGlzZWQgLSBzdXBlcigpIGhhc24ndCBiZWVuIGNhbGxlZFwiKTtcbiAgICB9XG4gICAgcmV0dXJuIHNlbGY7XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_assert_this_initialized.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_async_to_generator.js": +/*!**************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_async_to_generator.js ***! + \**************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _asyncToGenerator;\nfunction _asyncToGenerator(fn) {\n return function() {\n var self = this, args = arguments;\n return new Promise(function(resolve, reject) {\n var gen = fn.apply(self, args);\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n _next(undefined);\n });\n };\n}\nfunction asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fYXN5bmNfdG9fZ2VuZXJhdG9yLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxTQUFTO0FBQ1Q7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsTUFBTTtBQUNOO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxNQUFNO0FBQ047QUFDQTtBQUNBIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL19hc3luY190b19nZW5lcmF0b3IuanM/MGUzMCJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9hc3luY1RvR2VuZXJhdG9yO1xuZnVuY3Rpb24gX2FzeW5jVG9HZW5lcmF0b3IoZm4pIHtcbiAgICByZXR1cm4g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AgIH1cbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_async_to_generator.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_class_call_check.js": +/*!************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_class_call_check.js ***! + \************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _classCallCheck;\nfunction _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fY2xhc3NfY2FsbF9jaGVjay5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fY2xhc3NfY2FsbF9jaGVjay5qcz9mZDM2Il0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX2NsYXNzQ2FsbENoZWNrO1xuZnVuY3Rpb24gX2NsYXNzQ2FsbENoZWNrKGluc3RhbmNlLCBDb25zdHJ1Y3Rvcikge1xuICAgIGlmICghKGluc3RhbmNlIGluc3RhbmNlb2YgQ29uc3RydWN0b3IpKSB7XG4gICAgICAgIHRocm93IG5ldyBUeXBlRXJyb3IoXCJDYW5ub3QgY2FsbCBhIGNsYXNzIGFzIGEgZnVuY3Rpb25cIik7XG4gICAgfVxufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_class_call_check.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_construct.js": +/*!*****************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_construct.js ***! + \*****************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _construct;\nvar _setPrototypeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_set_prototype_of.js */ \"./node_modules/@swc/helpers/lib/_set_prototype_of.js\"));\nfunction _construct(Parent, args, Class) {\n return construct.apply(null, arguments);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\nfunction isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function() {}));\n return true;\n } catch (e) {\n return false;\n }\n}\nfunction construct(Parent1, args1, Class1) {\n if (isNativeReflectConstruct()) {\n construct = Reflect.construct;\n } else {\n construct = function construct(Parent, args, Class) {\n var a = [\n null\n ];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) (0, _setPrototypeOfMjs).default(instance, Class.prototype);\n return instance;\n };\n }\n return construct.apply(null, arguments);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZ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NlID0gbmV3IENvbnN0cnVjdG9yKCk7XG4gICAgICAgICAgICBpZiAoQ2xhc3MpICgwLCBfc2V0UHJvdG90eXBlT2ZNanMpLmRlZmF1bHQoaW5zdGFuY2UsIENsYXNzLnByb3RvdHlwZSk7XG4gICAgICAgICAgICByZXR1cm4gaW5zdGFuY2U7XG4gICAgICAgIH07XG4gICAgfVxuICAgIHJldHVybiBjb25zdHJ1Y3QuYXBwbHkobnVsbCwgYXJndW1lbnRzKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_construct.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_create_class.js": +/*!********************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_create_class.js ***! + \********************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _createClass;\nfunction _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}\nfunction _defineProperties(target, props) {\n for(var i = 0; i < props.length; i++){\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fY3JlYXRlX2NsYXNzLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZjtBQUNBO0FBQ0E7QUFDQTtBQU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FibGUgPSB0cnVlO1xuICAgICAgICBPYmplY3QuZGVmaW5lUHJvcGVydHkodGFyZ2V0LCBkZXNjcmlwdG9yLmtleSwgZGVzY3JpcHRvcik7XG4gICAgfVxufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_create_class.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_create_super.js": +/*!********************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_create_super.js ***! + \********************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _createSuper;\nvar _isNativeReflectConstructMjs = _interopRequireDefault(__webpack_require__(/*! ./_is_native_reflect_construct.js */ \"./node_modules/@swc/helpers/lib/_is_native_reflect_construct.js\"));\nvar _getPrototypeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_get_prototype_of.js */ \"./node_modules/@swc/helpers/lib/_get_prototype_of.js\"));\nvar _possibleConstructorReturnMjs = _interopRequireDefault(__webpack_require__(/*! ./_possible_constructor_return.js */ \"./node_modules/@swc/helpers/lib/_possible_constructor_return.js\"));\nfunction _createSuper(Derived) {\n var hasNativeReflectConstruct = (0, _isNativeReflectConstructMjs).default();\n return function _createSuperInternal() {\n var Super = (0, _getPrototypeOfMjs).default(Derived), result;\n if (hasNativeReflectConstruct) {\n var NewTarget = (0, _getPrototypeOfMjs).default(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n return (0, _possibleConstructorReturnMjs).default(this, result);\n };\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXM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3NzaWJsZV9jb25zdHJ1Y3Rvcl9yZXR1cm4uanNcIikpO1xuZnVuY3Rpb24gX2NyZWF0ZVN1cGVyKERlcml2ZWQpIHtcbiAgICB2YXIgaGFzTmF0aXZlUmVmbGVjdENvbnN0cnVjdCA9ICgwLCBfaXNOYXRpdmVSZWZsZWN0Q29uc3RydWN0TWpzKS5kZWZhdWx0KCk7XG4gICAgcmV0dXJuIGZ1bmN0aW9uIF9jcmVhdGVTdXBlckludGVybmFsKCkge1xuICAgICAgICB2YXIgU3VwZXIgPSAoMCwgX2dldFByb3RvdHlwZU9mTWpzKS5kZWZhdWx0KERlcml2ZWQpLCByZXN1bHQ7XG4gICAgICAgIGlmIChoYXNOYXRpdmVSZWZsZWN0Q29uc3RydWN0KSB7XG4gICAgICAgICAgICB2YXIgTmV3VGFyZ2V0ID0gKDAsIF9nZXRQcm90b3R5cGVPZk1qcykuZGVmYXVsdCh0aGlzKS5jb25zdHJ1Y3RvcjtcbiAgICAgICAgICAgIHJlc3VsdCA9IFJlZmxlY3QuY29uc3RydWN0KFN1cGVyLCBhcmd1bWVudHMsIE5ld1RhcmdldCk7XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICByZXN1bHQgPSBTdXBlci5hcHBseSh0aGlzLCBhcmd1bWVudHMpO1xuICAgICAgICB9XG4gICAgICAgIHJldHVybiAoMCwgX3Bvc3NpYmxlQ29uc3RydWN0b3JSZXR1cm5NanMpLmRlZmF1bHQodGhpcywgcmVzdWx0KTtcbiAgICB9O1xufVxuZnVuY3Rpb24gX2ludGVyb3BSZXF1aXJlRGVmYXVsdChvYmopIHtcbiAgICByZXR1cm4gb2JqICYmIG9iai5fX2VzTW9kdWxlID8gb2JqIDoge1xuICAgICAgICBkZWZhdWx0OiBvYmpcbiAgICB9O1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_create_super.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_extends.js": +/*!***************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_extends.js ***! + \***************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _extends;\nfunction _extends() {\n return extends_.apply(this, arguments);\n}\nfunction extends_() {\n extends_ = Object.assign || function(target) {\n for(var i = 1; i < arguments.length; i++){\n var source = arguments[i];\n for(var key in source){\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return extends_.apply(this, arguments);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fZXh0ZW5kcy5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLHVCQUF1QixzQkFBc0I7QUFDN0M7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fZXh0ZW5kcy5qcz8zOThhIl0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX2V4dGVuZHM7XG5mdW5jdGlvbiBfZXh0ZW5kcygpIHtcbiAgICByZXR1cm4gZXh0ZW5kc18uYXBwbHkodGhpcywgYXJndW1lbnRzKTtcbn1cbmZ1bmN0aW9uIGV4dGVuZHNfKCkge1xuICAgIGV4dGVuZHNfID0gT2JqZWN0LmFzc2lnbiB8fCBmdW5jdGlvbih0YXJnZXQpIHtcbiAgICAgICAgZm9yKHZhciBpID0gMTsgaSA8IGFyZ3VtZW50cy5sZW5ndGg7IGkrKyl7XG4gICAgICAgICAgICB2YXIgc291cmNlID0gYXJndW1lbnRzW2ldO1xuICAgICAgICAgICAgZm9yKHZhciBrZXkgaW4gc291cmNlKXtcbiAgICAgICAgICAgICAgICBpZiAoT2JqZWN0LnByb3RvdHlwZS5oYXNPd25Qcm9wZXJ0eS5jYWxsKHNvdXJjZSwga2V5KSkge1xuICAgICAgICAgICAgICAgICAgICB0YXJnZXRba2V5XSA9IHNvdXJjZVtrZXldO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gdGFyZ2V0O1xuICAgIH07XG4gICAgcmV0dXJuIGV4dGVuZHNfLmFwcGx5KHRoaXMsIGFyZ3VtZW50cyk7XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_extends.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_get_prototype_of.js": +/*!************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_get_prototype_of.js ***! + \************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _getPrototypeOf;\nfunction _getPrototypeOf(o) {\n return getPrototypeOf(o);\n}\nfunction getPrototypeOf(o1) {\n getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return getPrototypeOf(o1);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fZ2V0X3Byb3RvdHlwZV9vZi5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL19nZXRfcHJvdG90eXBlX29mLmpzPzY4N2IiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmRlZmF1bHQgPSBfZ2V0UHJvdG90eXBlT2Y7XG5mdW5jdGlvbiBfZ2V0UHJvdG90eXBlT2Yobykge1xuICAgIHJldHVybiBnZXRQcm90b3R5cGVPZihvKTtcbn1cbmZ1bmN0aW9uIGdldFByb3RvdHlwZU9mKG8xKSB7XG4gICAgZ2V0UHJvdG90eXBlT2YgPSBPYmplY3Quc2V0UHJvdG90eXBlT2YgPyBPYmplY3QuZ2V0UHJvdG90eXBlT2YgOiBmdW5jdGlvbiBnZXRQcm90b3R5cGVPZihvKSB7XG4gICAgICAgIHJldHVybiBvLl9fcHJvdG9fXyB8fCBPYmplY3QuZ2V0UHJvdG90eXBlT2Yobyk7XG4gICAgfTtcbiAgICByZXR1cm4gZ2V0UHJvdG90eXBlT2YobzEpO1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_get_prototype_of.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_inherits.js": +/*!****************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_inherits.js ***! + \****************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _inherits;\nvar _setPrototypeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_set_prototype_of.js */ \"./node_modules/@swc/helpers/lib/_set_prototype_of.js\"));\nfunction _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) (0, _setPrototypeOfMjs).default(subClass, superClass);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW5oZXJpdHMuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmLGdEQUFnRCxtQkFBTyxDQUFDLG9GQUF3QjtBQUNoRjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLEtBQUs7QUFDTDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW5oZXJpdHMuanM/MTQ1ZSJdLCJzb3VyY2VzQ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9ialxuICAgIH07XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_inherits.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_instanceof.js": +/*!******************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_instanceof.js ***! + \******************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _instanceof;\nfunction _instanceof(left, right) {\n if (right != null && typeof Symbol !== \"undefined\" && right[Symbol.hasInstance]) {\n return !!right[Symbol.hasInstance](left);\n } else {\n return left instanceof right;\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW5zdGFuY2VvZi5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0EsTUFBTTtBQUNOO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW5zdGFuY2VvZi5qcz9kMDIxIl0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX2luc3RhbmNlb2Y7XG5mdW5jdGlvbiBfaW5zdGFuY2VvZihsZWZ0LCByaWdodCkge1xuICAgIGlmIChyaWdodCAhPSBudWxsICYmIHR5cGVvZiBTeW1ib2wgIT09IFwidW5kZWZpbmVkXCIgJiYgcmlnaHRbU3ltYm9sLmhhc0luc3RhbmNlXSkge1xuICAgICAgICByZXR1cm4gISFyaWdodFtTeW1ib2wuaGFzSW5zdGFuY2VdKGxlZnQpO1xuICAgIH0gZWxzZSB7XG4gICAgICAgIHJldHVybiBsZWZ0IGluc3RhbmNlb2YgcmlnaHQ7XG4gICAgfVxufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_instanceof.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_interop_require_default.js": +/*!*******************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_interop_require_default.js ***! + \*******************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _interopRequireDefault;\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW50ZXJvcF9yZXF1aXJlX2RlZmF1bHQuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmO0FBQ0E7QUFDQTtBQUNBO0FBQ0EiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL0Bzd2MvaGVscGVycy9saWIvX2ludGVyb3BfcmVxdWlyZV9kZWZhdWx0LmpzPzliN2MiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmRlZmF1bHQgPSBfaW50ZXJvcFJlcXVpcmVEZWZhdWx0O1xuZnVuY3Rpb24gX2ludGVyb3BSZXF1aXJlRGVmYXVsdChvYmopIHtcbiAgICByZXR1cm4gb2JqICYmIG9iai5fX2VzTW9kdWxlID8gb2JqIDoge1xuICAgICAgICBkZWZhdWx0OiBvYmpcbiAgICB9O1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_interop_require_default.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_interop_require_wildcard.js": +/*!********************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_interop_require_wildcard.js ***! + \********************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _interopRequireWildcard;\nfunction _interopRequireWildcard(obj, nodeInterop) {\n if (!nodeInterop && obj && obj.__esModule) {\n return obj;\n }\n if (obj === null || typeof obj !== \"object\" && typeof obj !== \"function\") {\n return {\n default: obj\n };\n }\n var cache = _getRequireWildcardCache(nodeInterop);\n if (cache && cache.has(obj)) {\n return cache.get(obj);\n }\n var newObj = {};\n var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;\n for(var key in obj){\n if (key !== \"default\" && Object.prototype.hasOwnProperty.call(obj, key)) {\n var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;\n if (desc && (desc.get || desc.set)) {\n Object.defineProperty(newObj, key, desc);\n } else {\n newObj[key] = obj[key];\n }\n }\n }\n newObj.default = obj;\n if (cache) {\n cache.set(obj, newObj);\n }\n return newObj;\n}\nfunction _getRequireWildcardCache(nodeInterop1) {\n if (typeof WeakMap !== \"function\") return null;\n var cacheBabelInterop = new WeakMap();\n var cacheNodeInterop = new WeakMap();\n return (_getRequireWildcardCache = function(nodeInterop) {\n return nodeInterop ? cacheNodeInterop : cacheBabelInterop;\n })(nodeInterop1);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faW50ZXJvcF9yZXF1aXJlX3dpbGRjYXJkLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsY0FBYztBQUNkO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL19pbnRlcm9wX3JlcXVpcmVfd2lsZGNhcmQuanM/MDUxYiJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9pbnRlcm9wUmVxdWlyZVdpbGRjYXJkO1xuZnVuY3Rpb24gX2ludGVyb3BSZXF1aXJlV2lsZGNhcmQob2JqLCBub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ICAgICAgICAgICAgICAgbmV3T2JqW2tleV0gPSBvYmpba2V5XTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgIH1cbiAgICBuZXdPYmouZGVmYXVsdCA9IG9iajtcbiAgICBpZiAoY2FjaGUpIHtcbiAgICAgICAgY2FjaGUuc2V0KG9iaiwgbmV3T2JqKTtcbiAgICB9XG4gICAgcmV0dXJuIG5ld09iajtcbn1cbmZ1bmN0aW9uIF9nZXRSZXF1aXJlV2lsZGNhcmRDYWNoZShub2RlSW50ZXJvcDEpIHtcbiAgICBpZiAodHlwZW9mIFdlYWtNYXAgIT09IFwiZnVuY3Rpb25cIikgcmV0dXJuIG51bGw7XG4gICAgdmFyIGNhY2hlQmFiZWxJbnRlcm9wID0gbmV3IFdlYWtNYXAoKTtcbiAgICB2YXIgY2FjaGVOb2RlSW50ZXJvcCA9IG5ldyBXZWFrTWFwKCk7XG4gICAgcmV0dXJuIChfZ2V0UmVxdWlyZVdpbGRjYXJkQ2FjaGUgPSBmdW5jdGlvbihub2RlSW50ZXJvcCkge1xuICAgICAgICByZXR1cm4gbm9kZUludGVyb3AgPyBjYWNoZU5vZGVJbnRlcm9wIDogY2FjaGVCYWJlbEludGVyb3A7XG4gICAgfSkobm9kZUludGVyb3AxKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_interop_require_wildcard.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_is_native_function.js": +/*!**************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_is_native_function.js ***! + \**************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _isNativeFunction;\nfunction _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faXNfbmF0aXZlX2Z1bmN0aW9uLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZjtBQUNBO0FBQ0EiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL0Bzd2MvaGVscGVycy9saWIvX2lzX25hdGl2ZV9mdW5jdGlvbi5qcz81ODgwIl0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX2lzTmF0aXZlRnVuY3Rpb247XG5mdW5jdGlvbiBfaXNOYXRpdmVGdW5jdGlvbihmbikge1xuICAgIHJldHVybiBGdW5jdGlvbi50b1N0cmluZy5jYWxsKGZuKS5pbmRleE9mKFwiW25hdGl2ZSBjb2RlXVwiKSAhPT0gLTE7XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_is_native_function.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_is_native_reflect_construct.js": +/*!***********************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_is_native_reflect_construct.js ***! + \***********************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _isNativeReflectConstruct;\nfunction _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n try {\n Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));\n return true;\n } catch (e) {\n return false;\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faXNfbmF0aXZlX3JlZmxlY3RfY29uc3RydWN0LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsbUZBQW1GO0FBQ25GO0FBQ0EsTUFBTTtBQUNOO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faXNfbmF0aXZlX3JlZmxlY3RfY29uc3RydWN0LmpzPzA0M2IiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmRlZmF1bHQgPSBfaXNOYXRpdmVSZWZsZWN0Q29uc3RydWN0O1xuZnVuY3Rpb24gX2lzTmF0aXZlUmVmbGVjdENvbnN0cnVjdCgpIHtcbiAgICBpZiAodHlwZW9mIFJlZmxlY3QgPT09IFwidW5kZWZpbmVkXCIgfHwgIVJlZmxlY3QuY29uc3RydWN0KSByZXR1cm4gZmFsc2U7XG4gICAgaWYgKFJlZmxlY3QuY29uc3RydWN0LnNoYW0pIHJldHVybiBmYWxzZTtcbiAgICBpZiAodHlwZW9mIFByb3h5ID09PSBcImZ1bmN0aW9uXCIpIHJldHVybiB0cnVlO1xuICAgIHRyeSB7XG4gICAgICAgIEJvb2xlYW4ucHJvdG90eXBlLnZhbHVlT2YuY2FsbChSZWZsZWN0LmNvbnN0cnVjdChCb29sZWFuLCBbXSwgZnVuY3Rpb24oKSB7fSkpO1xuICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICB9IGNhdGNoIChlKSB7XG4gICAgICAgIHJldHVybiBmYWxzZTtcbiAgICB9XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_is_native_reflect_construct.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_iterable_to_array.js": +/*!*************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_iterable_to_array.js ***! + \*************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _iterableToArray;\nfunction _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && iter[Symbol.iterator] != null || iter[\"@@iterator\"] != null) return Array.from(iter);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faXRlcmFibGVfdG9fYXJyYXkuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9faXRlcmFibGVfdG9fYXJyYXkuanM/MzIzZSJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9pdGVyYWJsZVRvQXJyYXk7XG5mdW5jdGlvbiBfaXRlcmFibGVUb0FycmF5KGl0ZXIpIHtcbiAgICBpZiAodHlwZW9mIFN5bWJvbCAhPT0gXCJ1bmRlZmluZWRcIiAmJiBpdGVyW1N5bWJvbC5pdGVyYXRvcl0gIT0gbnVsbCB8fCBpdGVyW1wiQEBpdGVyYXRvclwiXSAhPSBudWxsKSByZXR1cm4gQXJyYXkuZnJvbShpdGVyKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_iterable_to_array.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_non_iterable_rest.js": +/*!*************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_non_iterable_rest.js ***! + \*************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _nonIterableRest;\nfunction _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fbm9uX2l0ZXJhYmxlX3Jlc3QuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fbm9uX2l0ZXJhYmxlX3Jlc3QuanM/OGE0NCJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9ub25JdGVyYWJsZVJlc3Q7XG5mdW5jdGlvbiBfbm9uSXRlcmFibGVSZXN0KCkge1xuICAgIHRocm93IG5ldyBUeXBlRXJyb3IoXCJJbnZhbGlkIGF0dGVtcHQgdG8gZGVzdHJ1Y3R1cmUgbm9uLWl0ZXJhYmxlIGluc3RhbmNlLlxcXFxuSW4gb3JkZXIgdG8gYmUgaXRlcmFibGUsIG5vbi1hcnJheSBvYmplY3RzIG11c3QgaGF2ZSBhIFtTeW1ib2wuaXRlcmF0b3JdKCkgbWV0aG9kLlwiKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_non_iterable_rest.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_non_iterable_spread.js": +/*!***************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_non_iterable_spread.js ***! + \***************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _nonIterableSpread;\nfunction _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fbm9uX2l0ZXJhYmxlX3NwcmVhZC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL19ub25faXRlcmFibGVfc3ByZWFkLmpzPzE2NmYiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmRlZmF1bHQgPSBfbm9uSXRlcmFibGVTcHJlYWQ7XG5mdW5jdGlvbiBfbm9uSXRlcmFibGVTcHJlYWQoKSB7XG4gICAgdGhyb3cgbmV3IFR5cGVFcnJvcihcIkludmFsaWQgYXR0ZW1wdCB0byBzcHJlYWQgbm9uLWl0ZXJhYmxlIGluc3RhbmNlLlxcXFxuSW4gb3JkZXIgdG8gYmUgaXRlcmFibGUsIG5vbi1hcnJheSBvYmplY3RzIG11c3QgaGF2ZSBhIFtTeW1ib2wuaXRlcmF0b3JdKCkgbWV0aG9kLlwiKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_non_iterable_spread.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_object_without_properties_loose.js": +/*!***************************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_object_without_properties_loose.js ***! + \***************************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _objectWithoutPropertiesLoose;\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for(i = 0; i < sourceKeys.length; i++){\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fb2JqZWN0X3dpdGhvdXRfcHJvcGVydGllc19sb29zZS5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLGVBQWUsdUJBQXVCO0FBQ3RDO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fb2JqZWN0X3dpdGhvdXRfcHJvcGVydGllc19sb29zZS5qcz80Y2I5Il0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX29iamVjdFdpdGhvdXRQcm9wZXJ0aWVzTG9vc2U7XG5mdW5jdGlvbiBfb2JqZWN0V2l0aG91dFByb3BlcnRpZXNMb29zZShzb3VyY2UsIGV4Y2x1ZGVkKSB7XG4gICAgaWYgKHNvdXJjZSA9PSBudWxsKSByZXR1cm4ge307XG4gICAgdmFyIHRhcmdldCA9IHt9O1xuICAgIHZhciBzb3VyY2VLZXlzID0gT2JqZWN0LmtleXMoc291cmNlKTtcbiAgICB2YXIga2V5LCBpO1xuICAgIGZvcihpID0gMDsgaSA8IHNvdXJjZUtleXMubGVuZ3RoOyBpKyspe1xuICAgICAgICBrZXkgPSBzb3VyY2VLZXlzW2ldO1xuICAgICAgICBpZiAoZXhjbHVkZWQuaW5kZXhPZihrZXkpID49IDApIGNvbnRpbnVlO1xuICAgICAgICB0YXJnZXRba2V5XSA9IHNvdXJjZVtrZXldO1xuICAgIH1cbiAgICByZXR1cm4gdGFyZ2V0O1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_object_without_properties_loose.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_possible_constructor_return.js": +/*!***********************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_possible_constructor_return.js ***! + \***********************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _possibleConstructorReturn;\nvar _assertThisInitializedMjs = _interopRequireDefault(__webpack_require__(/*! ./_assert_this_initialized.js */ \"./node_modules/@swc/helpers/lib/_assert_this_initialized.js\"));\nvar _typeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_type_of.js */ \"./node_modules/@swc/helpers/lib/_type_of.js\"));\nfunction _possibleConstructorReturn(self, call) {\n if (call && ((0, _typeOfMjs).default(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n return (0, _assertThisInitializedMjs).default(self);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fcG9zc2libGVfY29uc3RydWN0b3JfcmV0dXJuLmpz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VybiAoMCwgX2Fzc2VydFRoaXNJbml0aWFsaXplZE1qcykuZGVmYXVsdChzZWxmKTtcbn1cbmZ1bmN0aW9uIF9pbnRlcm9wUmVxdWlyZURlZmF1bHQob2JqKSB7XG4gICAgcmV0dXJuIG9iaiAmJiBvYmouX19lc01vZHVsZSA/IG9iaiA6IHtcbiAgICAgICAgZGVmYXVsdDogb2JqXG4gICAgfTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_possible_constructor_return.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_set_prototype_of.js": +/*!************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_set_prototype_of.js ***! + \************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _setPrototypeOf;\nfunction _setPrototypeOf(o, p) {\n return setPrototypeOf(o, p);\n}\nfunction setPrototypeOf(o1, p1) {\n setPrototypeOf = Object.setPrototypeOf || function setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return setPrototypeOf(o1, p1);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fc2V0X3Byb3RvdHlwZV9vZi5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL0Bzd2MvaGVscGVycy9saWIvX3NldF9wcm90b3R5cGVfb2YuanM/ZmViOSJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF9zZXRQcm90b3R5cGVPZjtcbmZ1bmN0aW9uIF9zZXRQcm90b3R5cGVPZihvLCBwKSB7XG4gICAgcmV0dXJuIHNldFByb3RvdHlwZU9mKG8sIHApO1xufVxuZnVuY3Rpb24gc2V0UHJvdG90eXBlT2YobzEsIHAxKSB7XG4gICAgc2V0UHJvdG90eXBlT2YgPSBPYmplY3Quc2V0UHJvdG90eXBlT2YgfHwgZnVuY3Rpb24gc2V0UHJvdG90eXBlT2YobywgcCkge1xuICAgICAgICBvLl9fcHJvdG9fXyA9IHA7XG4gICAgICAgIHJldHVybiBvO1xuICAgIH07XG4gICAgcmV0dXJuIHNldFByb3RvdHlwZU9mKG8xLCBwMSk7XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_set_prototype_of.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_sliced_to_array.js": +/*!***********************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_sliced_to_array.js ***! + \***********************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _slicedToArray;\nvar _arrayWithHolesMjs = _interopRequireDefault(__webpack_require__(/*! ./_array_with_holes.js */ \"./node_modules/@swc/helpers/lib/_array_with_holes.js\"));\nvar _iterableToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_iterable_to_array.js */ \"./node_modules/@swc/helpers/lib/_iterable_to_array.js\"));\nvar _nonIterableRestMjs = _interopRequireDefault(__webpack_require__(/*! ./_non_iterable_rest.js */ \"./node_modules/@swc/helpers/lib/_non_iterable_rest.js\"));\nvar _unsupportedIterableToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_unsupported_iterable_to_array.js */ \"./node_modules/@swc/helpers/lib/_unsupported_iterable_to_array.js\"));\nfunction _slicedToArray(arr, i) {\n return (0, _arrayWithHolesMjs).default(arr) || (0, _iterableToArrayMjs).default(arr, i) || (0, _unsupportedIterableToArrayMjs).default(arr, i) || (0, _nonIterableRestMjs).default();\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fc2xpY2VkX3RvX2FycmF5LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0Ysa0JBQWU7QUFDZixnREFBZ0QsbUJBQU8sQ0FBQyxvRkFBd0I7QUFDaEYsaURBQWlELG1CQUFPLENBQUMsc0ZBQXlCO0FBQ2xGLGlEQUFpRCxtQkFBTyxDQUFDLHNGQUF5QjtBQUNsRiw0REFBNEQsbUJBQU8sQ0FBQyw4R0FBcUM7QUFDekc7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fc2xpY2VkX3RvX2FycmF5LmpzPzk5MjAiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTog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///./node_modules/@swc/helpers/lib/_sliced_to_array.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_to_consumable_array.js": +/*!***************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_to_consumable_array.js ***! + \***************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _toConsumableArray;\nvar _arrayWithoutHolesMjs = _interopRequireDefault(__webpack_require__(/*! ./_array_without_holes.js */ \"./node_modules/@swc/helpers/lib/_array_without_holes.js\"));\nvar _iterableToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_iterable_to_array.js */ \"./node_modules/@swc/helpers/lib/_iterable_to_array.js\"));\nvar _nonIterableSpreadMjs = _interopRequireDefault(__webpack_require__(/*! ./_non_iterable_spread.js */ \"./node_modules/@swc/helpers/lib/_non_iterable_spread.js\"));\nvar _unsupportedIterableToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_unsupported_iterable_to_array.js */ \"./node_modules/@swc/helpers/lib/_unsupported_iterable_to_array.js\"));\nfunction _toConsumableArray(arr) {\n return (0, _arrayWithoutHolesMjs).default(arr) || (0, _iterableToArrayMjs).default(arr) || (0, _unsupportedIterableToArrayMjs).default(arr) || (0, _nonIterableSpreadMjs).default();\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdG9fY29uc3VtYWJsZV9hcnJheS5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2YsbURBQW1ELG1CQUFPLENBQUMsMEZBQTJCO0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gKDAsIF9hcnJheVdpdGhvdXRIb2xlc01qcykuZGVmYXVsdChhcnIpIHx8ICgwLCBfaXRlcmFibGVUb0FycmF5TWpzKS5kZWZhdWx0KGFycikgfHwgKDAsIF91bnN1cHBvcnRlZEl0ZXJhYmxlVG9BcnJheU1qcykuZGVmYXVsdChhcnIpIHx8ICgwLCBfbm9uSXRlcmFibGVTcHJlYWRNanMpLmRlZmF1bHQoKTtcbn1cbmZ1bmN0aW9uIF9pbnRlcm9wUmVxdWlyZURlZmF1bHQob2JqKSB7XG4gICAgcmV0dXJuIG9iaiAmJiBvYmouX19lc01vZHVsZSA/IG9iaiA6IHtcbiAgICAgICAgZGVmYXVsdDogb2JqXG4gICAgfTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_to_consumable_array.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_ts_generator.js": +/*!********************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_ts_generator.js ***! + \********************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nObject.defineProperty(exports, \"default\", ({\n enumerable: true,\n get: function() {\n return _tslib.__generator;\n }\n}));\nvar _tslib = __webpack_require__(/*! tslib */ \"./node_modules/tslib/tslib.es6.mjs\");\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdHNfZ2VuZXJhdG9yLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2IsOENBQTZDO0FBQzdDO0FBQ0EsQ0FBQyxFQUFDO0FBQ0YsMkNBQTBDO0FBQzFDO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsQ0FBQyxFQUFDO0FBQ0YsYUFBYSxtQkFBTyxDQUFDLGlEQUFPIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9Ac3djL2hlbHBlcnMvbGliL190c19nZW5lcmF0b3IuanM/YzU4ZCJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcImRlZmF1bHRcIiwge1xuICAgIGVudW1lcmFibGU6IHRydWUsXG4gICAgZ2V0OiBmdW5jdGlvbigpIHtcbiAgICAgICAgcmV0dXJuIF90c2xpYi5fX2dlbmVyYXRvcjtcbiAgICB9XG59KTtcbnZhciBfdHNsaWIgPSByZXF1aXJlKFwidHNsaWJcIik7XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_ts_generator.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_type_of.js": +/*!***************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_type_of.js ***! + \***************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _typeof;\nfunction _typeof(obj) {\n \"@swc/helpers - typeof\";\n return obj && obj.constructor === Symbol ? \"symbol\" : typeof obj;\n}\n;\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdHlwZV9vZi5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdHlwZV9vZi5qcz82MjdlIl0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX3R5cGVvZjtcbmZ1bmN0aW9uIF90eXBlb2Yob2JqKSB7XG4gICAgXCJAc3djL2hlbHBlcnMgLSB0eXBlb2ZcIjtcbiAgICByZXR1cm4gb2JqICYmIG9iai5jb25zdHJ1Y3RvciA9PT0gU3ltYm9sID8gXCJzeW1ib2xcIiA6IHR5cGVvZiBvYmo7XG59XG47XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_type_of.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_unsupported_iterable_to_array.js": +/*!*************************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_unsupported_iterable_to_array.js ***! + \*************************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _unsupportedIterableToArray;\nvar _arrayLikeToArrayMjs = _interopRequireDefault(__webpack_require__(/*! ./_array_like_to_array.js */ \"./node_modules/@swc/helpers/lib/_array_like_to_array.js\"));\nfunction _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return (0, _arrayLikeToArrayMjs).default(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(n);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return (0, _arrayLikeToArrayMjs).default(o, minLen);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdW5zdXBwb3J0ZWRfaXRlcmFibGVfdG9fYXJyYXkuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQUFDLEVBQUM7QUFDRixrQkFBZTtBQUNmLGtEQUFrRCxtQkFBTyxDQUFDLDBGQUEyQjtBQUNyRjtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fdW5zdXBwb3J0ZWRfaXRlcmFibGVfdG9fYXJyYXkuanM/ZDQ5MiJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuZGVmYXVsdCA9IF91bnN1cHBvcnRlZEl0ZXJhYmxlVG9BcnJheTtcbnZhciBfYXJyYXlMaWtlVG9BcnJheU1qcyA9IF9pbnRlcm9wUmVxdWlyZURlZmF1bHQocmVxdWlyZShcIi4vX2FycmF5X2xpa2VfdG9fYXJyYXkuanNcIikpO1xuZnVuY3Rpb24gX3Vuc3VwcG9ydGVkSXRlcmFibGVUb0FycmF5KG8sIG1pbkxlbikge1xuICAgIGlmICghbykgcmV0dXJuO1xuICAgIGlmICh0eXBlb2YgbyA9PT0gXCJzdHJpbmdcIikgcmV0dXJuICgwLCBfYXJyYXlMaWtlVG9BcnJheU1qcykuZGVmYXVsdChvLCBtaW5MZW4pO1xuICAgIHZhciBuID0gT2JqZWN0LnByb3RvdHlwZS50b1N0cmluZy5jYWxsKG8pLnNsaWNlKDgsIC0xKTtcbiAgICBpZiAobiA9PT0gXCJPYmplY3RcIiAmJiBvLmNvbnN0cnVjdG9yKSBuID0gby5jb25zdHJ1Y3Rvci5uYW1lO1xuICAgIGlmIChuID09PSBcIk1hcFwiIHx8IG4gPT09IFwiU2V0XCIpIHJldHVybiBBcnJheS5mcm9tKG4pO1xuICAgIGlmIChuID09PSBcIkFyZ3VtZW50c1wiIHx8IC9eKD86VWl8SSludCg/Ojh8MTZ8MzIpKD86Q2xhbXBlZCk/QXJyYXkkLy50ZXN0KG4pKSByZXR1cm4gKDAsIF9hcnJheUxpa2VUb0FycmF5TWpzKS5kZWZhdWx0KG8sIG1pbkxlbik7XG59XG5mdW5jdGlvbiBfaW50ZXJvcFJlcXVpcmVEZWZhdWx0KG9iaikge1xuICAgIHJldHVybiBvYmogJiYgb2JqLl9fZXNNb2R1bGUgPyBvYmogOiB7XG4gICAgICAgIGRlZmF1bHQ6IG9ialxuICAgIH07XG59XG4iXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_unsupported_iterable_to_array.js\n")); + +/***/ }), + +/***/ "./node_modules/@swc/helpers/lib/_wrap_native_super.js": +/*!*************************************************************!*\ + !*** ./node_modules/@swc/helpers/lib/_wrap_native_super.js ***! + \*************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = _wrapNativeSuper;\nvar _constructMjs = _interopRequireDefault(__webpack_require__(/*! ./_construct.js */ \"./node_modules/@swc/helpers/lib/_construct.js\"));\nvar _isNativeFunctionMjs = _interopRequireDefault(__webpack_require__(/*! ./_is_native_function.js */ \"./node_modules/@swc/helpers/lib/_is_native_function.js\"));\nvar _getPrototypeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_get_prototype_of.js */ \"./node_modules/@swc/helpers/lib/_get_prototype_of.js\"));\nvar _setPrototypeOfMjs = _interopRequireDefault(__webpack_require__(/*! ./_set_prototype_of.js */ \"./node_modules/@swc/helpers/lib/_set_prototype_of.js\"));\nfunction _wrapNativeSuper(Class) {\n return wrapNativeSuper(Class);\n}\nfunction _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n default: obj\n };\n}\nfunction wrapNativeSuper(Class1) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n wrapNativeSuper = function wrapNativeSuper(Class) {\n if (Class === null || !(0, _isNativeFunctionMjs).default(Class)) return Class;\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n _cache.set(Class, Wrapper);\n }\n function Wrapper() {\n return (0, _constructMjs).default(Class, arguments, (0, _getPrototypeOfMjs).default(this).constructor);\n }\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return (0, _setPrototypeOfMjs).default(Wrapper, Class);\n };\n return wrapNativeSuper(Class1);\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvQHN3Yy9oZWxwZXJzL2xpYi9fd3JhcF9uYXRpdmVfc3VwZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYiw4Q0FBNkM7QUFDN0M7QUFDQSxDQU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gICAgICAgIF9jYWNoZS5zZXQoQ2xhc3MsIFdyYXBwZXIpO1xuICAgICAgICB9XG4gICAgICAgIGZ1bmN0aW9uIFdyYXBwZXIoKSB7XG4gICAgICAgICAgICByZXR1cm4gKDAsIF9jb25zdHJ1Y3RNanMpLmRlZmF1bHQoQ2xhc3MsIGFyZ3VtZW50cywgKDAsIF9nZXRQcm90b3R5cGVPZk1qcykuZGVmYXVsdCh0aGlzKS5jb25zdHJ1Y3Rvcik7XG4gICAgICAgIH1cbiAgICAgICAgV3JhcHBlci5wcm90b3R5cGUgPSBPYmplY3QuY3JlYXRlKENsYXNzLnByb3RvdHlwZSwge1xuICAgICAgICAgICAgY29uc3RydWN0b3I6IHtcbiAgICAgICAgICAgICAgICB2YWx1ZTogV3JhcHBlcixcbiAgICAgICAgICAgICAgICBlbnVtZXJhYmxlOiBmYWxzZSxcbiAgICAgICAgICAgICAgICB3cml0YWJsZTogdHJ1ZSxcbiAgICAgICAgICAgICAgICBjb25maWd1cmFibGU6IHRydWVcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSk7XG4gICAgICAgIHJldHVybiAoMCwgX3NldFByb3RvdHlwZU9mTWpzKS5kZWZhdWx0KFdyYXBwZXIsIENsYXNzKTtcbiAgICB9O1xuICAgIHJldHVybiB3cmFwTmF0aXZlU3VwZXIoQ2xhc3MxKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/@swc/helpers/lib/_wrap_native_super.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/add-base-path.js": +/*!********************************************************!*\ + !*** ./node_modules/next/dist/client/add-base-path.js ***! + \********************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addBasePath = addBasePath;\nvar _addPathPrefix = __webpack_require__(/*! ../shared/lib/router/utils/add-path-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js\");\nvar _normalizeTrailingSlash = __webpack_require__(/*! ./normalize-trailing-slash */ \"./node_modules/next/dist/client/normalize-trailing-slash.js\");\nvar basePath = false || \"\";\nfunction addBasePath(path, required) {\n if (false) {}\n return (0, _normalizeTrailingSlash).normalizePathTrailingSlash((0, _addPathPrefix).addPathPrefix(path, basePath));\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=add-base-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9hZGQtYmFzZS1wYXRoLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsbUJBQW1CLEdBQUdFLFdBQVcsQ0FBQztBQUNsQyxJQUFJQyxjQUFjLEdBQUdDLG1CQUFPLENBQUMsdUhBQTRDLENBQUM7QUFDMUUsSUFBSUMsdUJBQXVCLEdBQUdELG1CQUFPLENBQUMsK0ZBQTRCLENBQUM7QUFDbkUsSUFBTUUsUUFBUSxHQUFHQyxNQUFrQyxJQUFJLEVBQUU7QUFDekQsU0FBU0wsV0FBVyxDQUFDUSxJQUFJLEVBQUVDLFFBQVEsRUFBRTtJQUNqQyxJQUFJSixLQUEwQyxFQUFFLEVBSS9DO0lBQ0QsT0FBTyxDQUFDLENBQUMsRUFBRUYsdUJBQXVCLEVBQUVRLDBCQUEwQixDQUFDLENBQUMsQ0FBQyxFQUFFVixjQUFjLEVBQUVXLGFBQWEsQ0FBQ0osSUFBSSxFQUFFSixRQUFRLENBQUMsQ0FBQyxDQUFDO0FBQ3RILENBQUM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QYXRoUHJlZml4IiwicmVxdWlyZSIsIl9ub3JtYWxpemVUcmFpbGluZ1NsYXNoIiwiYmFzZVBhdGgiLCJwcm9jZXNzIiwiZW52IiwiX19ORVhUX1JPVVRFUl9CQVNFUEFUSCIsInBhdGgiLCJyZXF1aXJlZCIsIl9fTkVYVF9NQU5VQUxfQ0xJRU5UX0JBU0VfUEFUSCIsIm5vcm1hbGl6ZVBhdGhUcmFpbGluZ1NsYXNoIiwiYWRkUGF0aFByZWZpeCIsImRlZmF1bHQiLCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/add-base-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/add-locale.js": +/*!*****************************************************!*\ + !*** ./node_modules/next/dist/client/add-locale.js ***! + \*****************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addLocale = void 0;\nvar _normalizeTrailingSlash = __webpack_require__(/*! ./normalize-trailing-slash */ \"./node_modules/next/dist/client/normalize-trailing-slash.js\");\nvar addLocale = function(path) {\n for(var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++){\n args[_key - 1] = arguments[_key];\n }\n if (false) { var _instance; }\n return path;\n};\nexports.addLocale = addLocale;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=add-locale.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=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lc01vZHVsZScsIHsgdmFsdWU6IHRydWUgfSk7XG4gIE9iamVjdC5hc3NpZ24oZXhwb3J0cy5kZWZhdWx0LCBleHBvcnRzKTtcbiAgbW9kdWxlLmV4cG9ydHMgPSBleHBvcnRzLmRlZmF1bHQ7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPWFkZC1sb2NhbGUuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiYWRkTG9jYWxlIiwiX25vcm1hbGl6ZVRyYWlsaW5nU2xhc2giLCJyZXF1aXJlIiwicGF0aCIsImFyZ3MiLCJwcm9jZXNzIiwiZW52IiwiX19ORVhUX0kxOE5fU1VQUE9SVCIsIm5vcm1hbGl6ZVBhdGhUcmFpbGluZ1NsYXNoIiwiZGVmYXVsdCIsIl9fZXNNb2R1bGUiLCJhc3NpZ24iLCJtb2R1bGUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/add-locale.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/detect-domain-locale.js": +/*!***************************************************************!*\ + !*** ./node_modules/next/dist/client/detect-domain-locale.js ***! + \***************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.detectDomainLocale = void 0;\nvar detectDomainLocale = function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n if (false) { var _instance; }\n};\nexports.detectDomainLocale = detectDomainLocale;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=detect-domain-locale.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9kZXRlY3QtZG9tYWluLWxvY2FsZS5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTs7Ozs7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCwwQkFBMEIsR0FBRyxLQUFLLENBQUMsQ0FBQztBQUNwQyxJQUFNRSxrQkFBa0IsR0FBRyxXQUFXO3FDQUFQQyxJQUFJO1FBQUpBLElBQUk7O0lBQy9CLElBQUlDLEtBQStCLEVBQUUsa0JBRXBDO0FBQ0wsQ0FBQztBQUNESiwwQkFBMEIsR0FBR0Usa0JBQWtCLENBQUM7QUFFaEQsSUFBSSxDQUFDLE9BQU9GLE9BQU8sQ0FBQ1EsT0FBTyxLQUFLLFVBQVUsSUFBSyxPQUFPUixPQUFPLENBQUNRLE9BQU8sS0FBSyxRQUFRLElBQUlSLE9BQU8sQ0FBQ1EsT0FBTyxLQUFLLElBQUksQ0FBQyxJQUFLLE9BQU9SLE9BQU8sQ0FBQ1EsT0FBTyxDQUFDQyxVQUFVLEtBQUssV0FBVyxFQUFFO0lBQ3JLWCxNQUFNLENBQUNDLGNBQWMsQ0FBQ0MsT0FBTyxDQUFDUSxPQUFPLEVBQUUsWUFBWSxFQUFFO1FBQUVQLEtBQUssRUFBRSxJQUFJO0tBQUUsQ0FBQyxDQUFDO0lBQ3RFSCxNQUFNLENBQUNZLE1BQU0sQ0FBQ1YsT0FBTyxDQUFDUSxPQUFPLEVBQUVSLE9BQU8sQ0FBQyxDQUFDO0lBQ3hDVyxNQUFNLENBQUNYLE9BQU8sR0FBR0EsT0FBT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tb2R1bGUuZXhwb3J0cyA9IGV4cG9ydHMuZGVmYXVsdDtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9ZGV0ZWN0LWRvbWFpbi1sb2NhbGUuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiZGV0ZWN0RG9tYWluTG9jYWxlIiwiYXJncyIsInByb2Nlc3MiLCJlbnYiLCJfX05FWFRfSTE4Tl9TVVBQT1JUIiwicmVxdWlyZSIsImRlZmF1bHQiLCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/detect-domain-locale.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/dev/amp-dev.js": +/*!******************************************************!*\ + !*** ./node_modules/next/dist/client/dev/amp-dev.js ***! + \******************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _tsGenerator = (__webpack_require__(/*! @swc/helpers/lib/_ts_generator.js */ \"./node_modules/@swc/helpers/lib/_ts_generator.js\")[\"default\"]);\nvar _async_to_generator = (__webpack_require__(/*! @swc/helpers/lib/_async_to_generator.js */ \"./node_modules/@swc/helpers/lib/_async_to_generator.js\")[\"default\"]);\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _fouc = __webpack_require__(/*! ./fouc */ \"./node_modules/next/dist/client/dev/fouc.js\");\nvar _onDemandEntriesClient = _interop_require_default(__webpack_require__(/*! ./on-demand-entries-client */ \"./node_modules/next/dist/client/dev/on-demand-entries-client.js\"));\nvar _websocket = __webpack_require__(/*! ./error-overlay/websocket */ \"./node_modules/next/dist/client/dev/error-overlay/websocket.js\");\nvar data = JSON.parse(document.getElementById(\"__NEXT_DATA__\").textContent);\nwindow.__NEXT_DATA__ = data;\nvar assetPrefix = data.assetPrefix, page = data.page;\nassetPrefix = assetPrefix || \"\";\nvar mostRecentHash = null;\n/* eslint-disable-next-line */ var curHash = __webpack_require__.h();\nvar hotUpdatePath = assetPrefix + (assetPrefix.endsWith(\"/\") ? \"\" : \"/\") + \"_next/static/webpack/\";\n// Is there a newer version of this code available?\nfunction isUpdateAvailable() {\n // __webpack_hash__ is the hash of the current compilation.\n // It's a global variable injected by Webpack.\n /* eslint-disable-next-line */ return mostRecentHash !== __webpack_require__.h();\n}\n// Webpack disallows updates in other states.\nfunction canApplyUpdates() {\n return module.hot.status() === \"idle\";\n}\nfunction tryApplyUpdates() {\n return _tryApplyUpdates.apply(this, arguments);\n}\nfunction _tryApplyUpdates() {\n _tryApplyUpdates = // reloads the page when it has changed.\n _async_to_generator(function() {\n var res, jsonData, curPage, pageUpdated, err;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n if (!isUpdateAvailable() || !canApplyUpdates()) {\n return [\n 2\n ];\n }\n _state.label = 1;\n case 1:\n _state.trys.push([\n 1,\n 4,\n ,\n 5\n ]);\n return [\n 4,\n fetch(typeof __webpack_require__.j !== \"undefined\" ? \"\".concat(hotUpdatePath).concat(curHash, \".\").concat(__webpack_require__.j, \".hot-update.json\") : \"\".concat(hotUpdatePath).concat(curHash, \".hot-update.json\"))\n ];\n case 2:\n res = _state.sent();\n return [\n 4,\n res.json()\n ];\n case 3:\n jsonData = _state.sent();\n curPage = page === \"/\" ? \"index\" : page;\n pageUpdated = (Array.isArray(jsonData.c) ? jsonData.c : Object.keys(jsonData.c)).some(function(mod) {\n return mod.indexOf(\"pages\".concat(curPage.startsWith(\"/\") ? curPage : \"/\".concat(curPage))) !== -1 || mod.indexOf(\"pages\".concat(curPage.startsWith(\"/\") ? curPage : \"/\".concat(curPage)).replace(/\\//g, \"\\\\\")) !== -1;\n });\n if (pageUpdated) {\n document.location.reload(true);\n } else {\n curHash = mostRecentHash;\n }\n return [\n 3,\n 5\n ];\n case 4:\n err = _state.sent();\n console.error(\"Error occurred checking for update\", err);\n document.location.reload(true);\n return [\n 3,\n 5\n ];\n case 5:\n return [\n 2\n ];\n }\n });\n });\n return _tryApplyUpdates.apply(this, arguments);\n}\n(0, _websocket).addMessageListener(function(event) {\n if (event.data === \"\\uD83D\\uDC93\") {\n return;\n }\n try {\n var message = JSON.parse(event.data);\n if (message.action === \"sync\" || message.action === \"built\") {\n if (!message.hash) {\n return;\n }\n mostRecentHash = message.hash;\n tryApplyUpdates();\n } else if (message.action === \"reloadPage\") {\n document.location.reload(true);\n }\n } catch (ex) {\n console.warn(\"Invalid HMR message: \" + event.data + \"\\n\" + ex);\n }\n});\n(0, _websocket).connectHMR({\n assetPrefix: assetPrefix,\n path: \"/_next/webpack-hmr\"\n});\n(0, _fouc).displayContent();\n(0, _onDemandEntriesClient).default(data.page);\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=amp-dev.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9kZXYvYW1wLWRldi5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTs7Ozs7QUFDYixJQUFJQSxtQkFBbUIsR0FBR0MseUlBQTBEO0FBQ3BGLElBQUlFLHdCQUF3QixHQUFHRixtSkFBK0Q7QUFDOUYsSUFBSUcsS0FBSyxHQUFHSCxtQkFBTyxDQUFDLDJEQUFRLENBQUM7QUFDN0IsSUFBSUksc0JBQXNCLEdBQUdGLHdCQUF3QixDQUFDRixtQkFBTyxDQUFDLG1HQUE0QixDQUFDLENBQUM7QUFDNUYsSUFBSUssVUFBVSxH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Iiwic29tZSIsIm1vZCIsImluZGV4T2YiLCJzdGFydHNXaXRoIiwicmVwbGFjZSIsImxvY2F0aW9uIiwicmVsb2FkIiwiY29uc29sZSIsImVycm9yIiwiYWRkTWVzc2FnZUxpc3RlbmVyIiwiZXZlbnQiLCJtZXNzYWdlIiwiYWN0aW9uIiwiaGFzaCIsImV4Iiwid2FybiIsImNvbm5lY3RITVIiLCJwYXRoIiwiZGlzcGxheUNvbnRlbnQiLCJleHBvcnRzIiwiX19lc01vZHVsZSIsImRlZmluZVByb3BlcnR5IiwidmFsdWUiLCJhc3NpZ24iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/dev/amp-dev.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/dev/error-overlay/websocket.js": +/*!**********************************************************************!*\ + !*** ./node_modules/next/dist/client/dev/error-overlay/websocket.js ***! + \**********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addMessageListener = addMessageListener;\nexports.sendMessage = sendMessage;\nexports.connectHMR = connectHMR;\nvar source;\nvar eventCallbacks = [];\nvar lastActivity = Date.now();\nfunction getSocketProtocol(assetPrefix) {\n var protocol = location.protocol;\n try {\n // assetPrefix is a url\n protocol = new URL(assetPrefix).protocol;\n } catch (_) {}\n return protocol === \"http:\" ? \"ws\" : \"wss\";\n}\nfunction addMessageListener(cb) {\n eventCallbacks.push(cb);\n}\nfunction sendMessage(data) {\n if (!source || source.readyState !== source.OPEN) return;\n return source.send(data);\n}\nfunction connectHMR(options) {\n if (!options.timeout) {\n options.timeout = 5 * 1000;\n }\n function init() {\n if (source) source.close();\n function handleOnline() {\n if (options.log) console.log(\"[HMR] connected\");\n lastActivity = Date.now();\n }\n function handleMessage(event) {\n lastActivity = Date.now();\n eventCallbacks.forEach(function(cb) {\n cb(event);\n });\n }\n var timer;\n function handleDisconnect() {\n clearInterval(timer);\n source.close();\n setTimeout(init, options.timeout);\n }\n timer = setInterval(function() {\n if (Date.now() - lastActivity > options.timeout) {\n handleDisconnect();\n }\n }, options.timeout / 2);\n var hostname = location.hostname, port = location.port;\n var protocol = getSocketProtocol(options.assetPrefix || \"\");\n var assetPrefix = options.assetPrefix.replace(/^\\/+/, \"\");\n var url = \"\".concat(protocol, \"://\").concat(hostname, \":\").concat(port).concat(assetPrefix ? \"/\".concat(assetPrefix) : \"\");\n if (assetPrefix.startsWith(\"http\")) {\n url = \"\".concat(protocol, \"://\").concat(assetPrefix.split(\"://\")[1]);\n }\n source = new window.WebSocket(\"\".concat(url).concat(options.path));\n source.onopen = handleOnline;\n source.onerror = handleDisconnect;\n source.onmessage = handleMessage;\n }\n init();\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=websocket.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9kZXYvZXJyb3Itb3ZlcmxheS93ZWJzb2NrZXQuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCwwQkFBMEIsR0FBR0Usa0JBQWtCLENBQUM7QUFDaERGLG1CQUFtQixHQUFHRyxXQUFXLENBQUM7QUFDbENILGtCQUFrQixHQUFHSSxVQUFVLENBQUM7QUFDaEMsSUFBSUMsTUFBTTtBQUNWLElBQU1DLGNBQWMsR0FBRyxFQUFFO0FBQ3pCLElBQUlDLFlBQVksR0FBR0MsSUFBSSxDQUFDQyxHQUFHLEVBQUU7QUFDN0IsU0FBU0MsaUJBQWlCLENBQUND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Zm9yRWFjaCgoY2IpPT57XG4gICAgICAgICAgICAgICAgY2IoZXZlbnQpO1xuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgbGV0IHRpbWVyO1xuICAgICAgICBmdW5jdGlvbiBoYW5kbGVEaXNjb25uZWN0KCkge1xuICAgICAgICAgICAgY2xlYXJJbnRlcnZhbCh0aW1lcik7XG4gICAgICAgICAgICBzb3VyY2UuY2xvc2UoKTtcbiAgICAgICAgICAgIHNldFRpbWVvdXQoaW5pdCwgb3B0aW9ucy50aW1lb3V0KTtcbiAgICAgICAgfVxuICAgICAgICB0aW1lciA9IHNldEludGVydmFsKGZ1bmN0aW9uKCkge1xuICAgICAgICAgICAgaWYgKERhdGUubm93KCkgLSBsYXN0QWN0aXZpdHkgPiBvcHRpb25zLnRpbWVvdXQpIHtcbiAgICAgICAgICAgICAgICBoYW5kbGVEaXNjb25uZWN0KCk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sIG9wdGlvbnMudGltZW91dCAvIDIpO1xuICAgICAgICBjb25zdCB7IGhvc3RuYW1lICwgcG9ydCAgfSA9IGxvY2F0aW9uO1xuICAgICAgICBjb25zdCBwcm90b2NvbCA9IGdldFNvY2tldFByb3RvY29sKG9wdGlvbnMuYXNzZXRQcmVmaXggfHwgJycpO1xuICAgICAgICBjb25zdCBhc3NldFByZWZpeCA9IG9wdGlvbnMuYXNzZXRQcmVmaXgucmVwbGFjZSgvXlxcLysvLCAnJyk7XG4gICAgICAgIGxldCB1cmwgPSBgJHtwcm90b2NvbH06Ly8ke2hvc3RuYW1lfToke3BvcnR9JHthc3NldFByZWZpeCA/IGAvJHthc3NldFByZWZpeH1gIDogJyd9YDtcbiAgICAgICAgaWYgKGFzc2V0UHJlZml4LnN0YXJ0c1dpdGgoJ2h0dHAnKSkge1xuICAgICAgICAgICAgdXJsID0gYCR7cHJvdG9jb2x9Oi8vJHthc3NldFByZWZpeC5zcGxpdCgnOi8vJylbMV19YDtcbiAgICAgICAg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VJMIiwiXyIsImNiIiwicHVzaCIsImRhdGEiLCJyZWFkeVN0YXRlIiwiT1BFTiIsInNlbmQiLCJvcHRpb25zIiwidGltZW91dCIsImluaXQiLCJjbG9zZSIsImhhbmRsZU9ubGluZSIsImxvZyIsImNvbnNvbGUiLCJoYW5kbGVNZXNzYWdlIiwiZXZlbnQiLCJmb3JFYWNoIiwidGltZXIiLCJoYW5kbGVEaXNjb25uZWN0IiwiY2xlYXJJbnRlcnZhbCIsInNldFRpbWVvdXQiLCJzZXRJbnRlcnZhbCIsImhvc3RuYW1lIiwicG9ydCIsInJlcGxhY2UiLCJ1cmwiLCJzdGFydHNXaXRoIiwic3BsaXQiLCJ3aW5kb3ciLCJXZWJTb2NrZXQiLCJwYXRoIiwib25vcGVuIiwib25lcnJvciIsIm9ubWVzc2FnZSIsImRlZmF1bHQiLCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/dev/error-overlay/websocket.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/dev/fouc.js": +/*!***************************************************!*\ + !*** ./node_modules/next/dist/client/dev/fouc.js ***! + \***************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.displayContent = displayContent;\n// This wrapper function is used to safely select the best available function\n// to schedule removal of the no-FOUC styles workaround. requestAnimationFrame\n// is the ideal choice, but when used in iframes, there are no guarantees that\n// the callback will actually be called, which could stall the promise returned\n// from displayContent.\n//\n// See: https://www.vector-logic.com/blog/posts/on-request-animation-frame-and-embedded-iframes\nvar safeCallbackQueue = function(callback) {\n if (window.requestAnimationFrame && window.self === window.top) {\n window.requestAnimationFrame(callback);\n } else {\n window.setTimeout(callback);\n }\n};\nfunction displayContent() {\n return new Promise(function(resolve) {\n safeCallbackQueue(function() {\n for(var x = document.querySelectorAll(\"[data-next-hide-fouc]\"), i = x.length; i--;){\n x[i].parentNode.removeChild(x[i]);\n }\n resolve();\n });\n });\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=fouc.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9kZXYvZm91Yy5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHNCQUFzQixHQUFHRSxjQUFjLENBQUM7QUFDeEMsNkVBQTZFO0FBQzdFLDhFQUE4RTtBQUM5RSw4RUFBOEU7QUFDOUUsK0VBQStFO0FBQy9FLHVCQUF1QjtBQUN2QixFQUFFO0FBQ0YsK0ZBQStGO0FBQy9GLElBQU1DLGlCQUFpQixHQUFHLFNBQUNDLFFBQVEsRUFBRztJQUNsQyxJQUFJQyxNQUFNLENBQUNDLHFCQUFxQixJQUFJRCxNQUFNLENBQUNFLElBQUksS0FBS0YsTUFBTSxDQUFDRyxHQUFHLEVBQUU7UUFDNURILE1BQU0sQ0FBQ0MscUJBQXFCLENBQUNGLFFBQVEsQ0FBQyxDQUFDO0lBQzNDLE9BQU87UUFDSEMsTUFBTSxDQUFDSSxVQUFVLENBQUNMLFFBQVEsQ0FBQyxDQUFDO0lBQ2hDLENBQUM7QUFDTCxDQUFDO0FBQ0QsU0FBU0YsY0FBYyxHQUFHO0lBQ3RCLE9BQU8sSUFBSVEsT0FBTyxDQUFDLFNBQUNDLE9BQU8sRUFBRztRQUMxQlIsaUJBQWlCLENBQUMsV0FBVztZQUN6QixJQUFJLElBQUlTLENBQUMsR0FBR0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1hdGlvbkZyYW1lIiwic2VsZiIsInRvcCIsInNldFRpbWVvdXQiLCJQcm9taXNlIiwicmVzb2x2ZSIsIngiLCJkb2N1bWVudCIsInF1ZXJ5U2VsZWN0b3JBbGwiLCJpIiwibGVuZ3RoIiwicGFyZW50Tm9kZSIsInJlbW92ZUNoaWxkIiwiZGVmYXVsdCIsIl9fZXNNb2R1bGUiLCJhc3NpZ24iLCJtb2R1bGUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/dev/fouc.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/dev/on-demand-entries-client.js": +/*!***********************************************************************!*\ + !*** ./node_modules/next/dist/client/dev/on-demand-entries-client.js ***! + \***********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _tsGenerator = (__webpack_require__(/*! @swc/helpers/lib/_ts_generator.js */ \"./node_modules/@swc/helpers/lib/_ts_generator.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = void 0;\nvar _async_to_generator = (__webpack_require__(/*! @swc/helpers/lib/_async_to_generator.js */ \"./node_modules/@swc/helpers/lib/_async_to_generator.js\")[\"default\"]);\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _router = _interop_require_default(__webpack_require__(/*! next/router */ \"./node_modules/next/router.js\"));\nvar _websocket = __webpack_require__(/*! ./error-overlay/websocket */ \"./node_modules/next/dist/client/dev/error-overlay/websocket.js\");\nvar _default = _async_to_generator(function(page) {\n return _tsGenerator(this, function(_state) {\n if (page) {\n // in AMP the router isn't initialized on the client and\n // client-transitions don't occur so ping initial page\n setInterval(function() {\n (0, _websocket).sendMessage(JSON.stringify({\n event: \"ping\",\n page: page\n }));\n }, 2500);\n } else {\n _router.default.ready(function() {\n setInterval(function() {\n // when notFound: true is returned we should use the notFoundPage\n // as the Router.pathname will point to the 404 page but we want\n // to ping the source page that returned notFound: true instead\n var notFoundSrcPage = self.__NEXT_DATA__.notFoundSrcPage;\n var pathname = (_router.default.pathname === \"/404\" || _router.default.pathname === \"/_error\") && notFoundSrcPage ? notFoundSrcPage : _router.default.pathname;\n (0, _websocket).sendMessage(JSON.stringify({\n event: \"ping\",\n page: pathname\n }));\n }, 2500);\n });\n }\n (0, _websocket).addMessageListener(function(event) {\n if (event.data.indexOf(\"{\") === -1) return;\n try {\n var payload = JSON.parse(event.data);\n // don't attempt fetching the page if we're already showing\n // the dev overlay as this can cause the error to be triggered\n // repeatedly\n if (payload.event === \"pong\" && payload.invalid && !self.__NEXT_DATA__.err) {\n // Payload can be invalid even if the page does exist.\n // So, we check if it can be created.\n fetch(location.href, {\n credentials: \"same-origin\"\n }).then(function(pageRes) {\n if (pageRes.status === 200) {\n // Page exists now, reload\n location.reload();\n } else {\n // Page doesn't exist\n if (self.__NEXT_DATA__.page === _router.default.pathname && _router.default.pathname !== \"/_error\") {\n // We are still on the page,\n // reload to show 404 error page\n location.reload();\n }\n }\n });\n }\n } catch (err) {\n console.error(\"on-demand-entries failed to parse response\", err);\n }\n });\n return [\n 2\n ];\n });\n});\nexports[\"default\"] = _default;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=on-demand-entries-client.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9kZXYvb24tZGVtYW5kLWVudHJpZXMtY2xpZW50LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhOzs7OztBQUNiQSw4Q0FBNkM7SUFD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ICAgICAgICAgICAgIGNyZWRlbnRpYWxzOiAnc2FtZS1vcmlnaW4nXG4gICAgICAgICAgICAgICAgfSkudGhlbigocGFnZVJlcyk9PntcbiAgICAgICAgICAgICAgICAgICAgaWYgKHBhZ2VSZXMuc3RhdHVzID09PSAyMDApIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIFBhZ2UgZXhpc3RzIG5vdywgcmVsb2FkXG4gICAgICAgICAgICAgICAgICAgICAgICBsb2NhdGlvbi5yZWxvYWQoKTtcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIFBhZ2UgZG9lc24ndCBleGlzdFxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHNlbGYuX19ORVhUX0RBVEFfXy5wYWdlID09PSBfcm91dGVyLmRlZmF1bHQucGF0aG5hbWUgJiYgX3JvdXRlci5kZWZhdWx0LnBhdGhuYW1lICE9PSAnL19lcnJvcicpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyBXZSBhcmUgc3RpbGwgb24gdGhlIHBhZ2UsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gcmVsb2FkIHRvIHNob3cgNDA0IGVycm9yIHBhZ2VcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2NhdGlvbi5yZWxvYWQoKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgfVxuICAgICAgICB9IGNhdGNoIChlcnIpIHtcbiAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoJ29uLWRlbWFuZC1lbnRyaWVzIGZhaWxlZCB0byBwYXJzZSByZXNwb25zZScsIGVycik7XG4gICAgICAgIH1cbiAgICB9KTtcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gX2RlZmF1bHQ7XG5cbmlmICgodHlwZW9mIGV4cG9ydHMuZGVmYX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LCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/dev/on-demand-entries-client.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/has-base-path.js": +/*!********************************************************!*\ + !*** ./node_modules/next/dist/client/has-base-path.js ***! + \********************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.hasBasePath = hasBasePath;\nvar _pathHasPrefix = __webpack_require__(/*! ../shared/lib/router/utils/path-has-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js\");\nvar basePath = false || \"\";\nfunction hasBasePath(path) {\n return (0, _pathHasPrefix).pathHasPrefix(path, basePath);\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=has-base-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9oYXMtYmFzZS1wYXRoLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsbUJBQW1CLEdBQUdFLFdBQVcsQ0FBQztBQUNsQyxJQUFJQyxjQUFjLEdBQUdDLG1CQUFPLENBQUMsdUhBQTRDLENBQUM7QUFDMUUsSUFBTUMsUUFBUSxHQUFHQyxNQUFrQyxJQUFJLEVBQUU7QUFDekQsU0FBU0osV0FBVyxDQUFDTyxJQUFJLEVBQUU7SUFDdkIsT0FBTyxDQUFDLENBQUMsRUFBRU4sY0FBY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vzcy5lbnYuX19ORVhUX1JPVVRFUl9CQVNFUEFUSCB8fCAnJztcbmZ1bmN0aW9uIGhhc0Jhc2VQYXRoKHBhdGgpIHtcbiAgICByZXR1cm4gKDAsIF9wYXRoSGFzUHJlZml4KS5wYXRoSGFzUHJlZml4KHBhdGgsIGJhc2VQYXRoKTtcbn1cblxuaWYgKCh0eXBlb2YgZXhwb3J0cy5kZWZhdWx0ID09PSAnZnVuY3Rpb24nIHx8ICh0eXBlb2YgZXhwb3J0cy5kZWZhdWx0ID09PSAnb2JqZWN0JyAmJiBleHBvcnRzLmRlZmF1bHQgIT09IG51bGwpKSAmJiB0eXBlb2YgZXhwb3J0cy5kZWZhdWx0Ll9fZXNNb2R1bGUgPT09ICd1bmRlZmluZWQnKSB7XG4gIE9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLmRlZmF1bHQsICdfX2VzTW9kdWxlJywgeyB2YWx1ZTogdHJ1ZSB9KTtcbiAgT2JqZWN0LmFzc2lnbihleHBvcnRzLmRlZmF1bHQsIGV4cG9ydHMpO1xuICBtb2R1bGUuZXhwb3J0cyA9IGV4cG9ydHMuZGVmYXVsdDtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9aGFzLWJhc2UtcGF0aC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJoYXNCYXNlUGF0aCIsIl9wYXRoSGFzUHJlZml4IiwicmVxdWlyZSIsImJhc2VQYXRoIiwicHJvY2VzcyIsImVudiIsIl9fTkVYVF9ST1VURVJfQkFTRVBBVEgiLCJwYXRoIiwicGF0aEhhc1ByZWZpeCIsImRlZmF1bHQiLCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/has-base-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/head-manager.js": +/*!*******************************************************!*\ + !*** ./node_modules/next/dist/client/head-manager.js ***! + \*******************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _instanceof = (__webpack_require__(/*! @swc/helpers/lib/_instanceof.js */ \"./node_modules/@swc/helpers/lib/_instanceof.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = initHeadManager;\nexports.isEqualNode = isEqualNode;\nexports.DOMAttributeNames = void 0;\nfunction initHeadManager() {\n return {\n mountedInstances: new Set(),\n updateHead: function(head) {\n var tags = {};\n head.forEach(function(h) {\n if (// it won't be inlined. In this case revert to the original behavior\n h.type === \"link\" && h.props[\"data-optimized-fonts\"]) {\n if (document.querySelector('style[data-href=\"'.concat(h.props[\"data-href\"], '\"]'))) {\n return;\n } else {\n h.props.href = h.props[\"data-href\"];\n h.props[\"data-href\"] = undefined;\n }\n }\n var components = tags[h.type] || [];\n components.push(h);\n tags[h.type] = components;\n });\n var titleComponent = tags.title ? tags.title[0] : null;\n var title = \"\";\n if (titleComponent) {\n var children = titleComponent.props.children;\n title = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n }\n if (title !== document.title) document.title = title;\n [\n \"meta\",\n \"base\",\n \"link\",\n \"style\",\n \"script\"\n ].forEach(function(type) {\n updateElements(type, tags[type] || []);\n });\n }\n };\n}\nvar DOMAttributeNames = {\n acceptCharset: \"accept-charset\",\n className: \"class\",\n htmlFor: \"for\",\n httpEquiv: \"http-equiv\",\n noModule: \"noModule\"\n};\nexports.DOMAttributeNames = DOMAttributeNames;\nfunction reactElementToDOM(param) {\n var type = param.type, props = param.props;\n var el = document.createElement(type);\n for(var p in props){\n if (!props.hasOwnProperty(p)) continue;\n if (p === \"children\" || p === \"dangerouslySetInnerHTML\") continue;\n // we don't render undefined props to the DOM\n if (props[p] === undefined) continue;\n var attr = DOMAttributeNames[p] || p.toLowerCase();\n if (type === \"script\" && (attr === \"async\" || attr === \"defer\" || attr === \"noModule\")) {\n el[attr] = !!props[p];\n } else {\n el.setAttribute(attr, props[p]);\n }\n }\n var children = props.children, dangerouslySetInnerHTML = props.dangerouslySetInnerHTML;\n if (dangerouslySetInnerHTML) {\n el.innerHTML = dangerouslySetInnerHTML.__html || \"\";\n } else if (children) {\n el.textContent = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n }\n return el;\n}\nfunction isEqualNode(oldTag, newTag) {\n if (_instanceof(oldTag, HTMLElement) && _instanceof(newTag, HTMLElement)) {\n var nonce = newTag.getAttribute(\"nonce\");\n // Only strip the nonce if `oldTag` has had it stripped. An element's nonce attribute will not\n // be stripped if there is no content security policy response header that includes a nonce.\n if (nonce && !oldTag.getAttribute(\"nonce\")) {\n var cloneTag = newTag.cloneNode(true);\n cloneTag.setAttribute(\"nonce\", \"\");\n cloneTag.nonce = nonce;\n return nonce === oldTag.nonce && oldTag.isEqualNode(cloneTag);\n }\n }\n return oldTag.isEqualNode(newTag);\n}\nfunction updateElements(type, components) {\n var headEl = document.getElementsByTagName(\"head\")[0];\n var headCountEl = headEl.querySelector(\"meta[name=next-head-count]\");\n if (true) {\n if (!headCountEl) {\n console.error(\"Warning: next-head-count is missing. https://nextjs.org/docs/messages/next-head-count-missing\");\n return;\n }\n }\n var headCount = Number(headCountEl.content);\n var oldTags = [];\n for(var i = 0, j = headCountEl.previousElementSibling; i < headCount; i++, j = (j == null ? void 0 : j.previousElementSibling) || null){\n var ref;\n if ((j == null ? void 0 : (ref = j.tagName) == null ? void 0 : ref.toLowerCase()) === type) {\n oldTags.push(j);\n }\n }\n var newTags = components.map(reactElementToDOM).filter(function(newTag) {\n for(var k = 0, len = oldTags.length; k < len; k++){\n var oldTag = oldTags[k];\n if (isEqualNode(oldTag, newTag)) {\n oldTags.splice(k, 1);\n return false;\n }\n }\n return true;\n });\n oldTags.forEach(function(t) {\n var ref;\n return (ref = t.parentNode) == null ? void 0 : ref.removeChild(t);\n });\n newTags.forEach(function(t) {\n return headEl.insertBefore(t, headCountEl);\n });\n headCountEl.content = (headCount - oldTags.length + newTags.length).toString();\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=head-manager.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9oZWFkLW1hbmFnZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7Ozs7O0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsa0JBQWUsR0FBR0csZUFBZSxDQUFDO0FBQ2xDSCxtQkFBbUIsR0FBR0ksV0FBVyxDQUFDO0FBQ2xDSix5QkFBeUIsR0FBRyxLQUFLLENBQUMsQ0FBQztBQUNuQyxTQUFTRyxlQUFlLEdBQUc7SUFDdkIsT0FBTztRQUNIRyxnQkFBZ0IsRUFBRSxJQUFJQyxHQUFHLEVBQUU7UUFDM0JDLFVBQVUsRUFBRSxTQUFDQyxJQUFJLEVBQUc7WUFDaEIsSUFBTUMsSUFBSSxHQUFHLEVBQUU7WUFDZkQsSUFBSSxDQUFDRSxPQUFPLENBQUMsU0FBQ0MsQ0FBQyxFQUFHO2dCQUNkLElBQ0Esb0VBQW9FO2dCQUNwRUEsQ0FBQyxDQUFDQyxJQUFJLEtBQUssTUFBTSxJQUFJRCxDQUFDLENBQUNFLEtBQUssQ0FBQyxzQkFBc0IsQ0FBQyxFQUFFO29CQUNsRCxJQUFJQyxRQUFRLENBQUNDLGFBQWEsQ0FBQyxtQkFBa0IsQ0FBdUIsTUFBRSxDQUF2QkosQ0FBQ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gICAgICAgICAgICAgICAgaWYgKC8vIElmIHRoZSBmb250IHRhZyBpcyBsb2FkZWQgb25seSBvbiBjbGllbnQgbmF2aWdhdGlvblxuICAgICAgICAgICAgICAgIC8vIGl0IHdvbid0IGJlIGlubGluZWQuIEluIHRoaXMgY2FzZSByZXZlcnQgdG8gdGhlIG9yaWdpbmFsIGJlaGF2aW9yXG4gICAgICAgICAgICAgICAgaC50eXBlID09PSAnbGluaycgJiYgaC5wcm9wc1snZGF0YS1vcHRpbWl6ZWQtZm9udHMnXSkge1xuICAgICAgICAgICAgICAgICAgICBpZiAoZG9jdW1lbnQucXVlcnlTZWxlY3Rvcihgc3R5bGVbZGF0YS1ocmVmPVwiJHtoLnByb3BzWydkYXRhLWhyZWYnXX1cIl1gKSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICAgICAgaC5wcm9wcy5ocmVmID0gaC5wcm9wc1snZGF0YS1ocmVmJ107XG4gICAgICAgICAgICAgICAgICAgICAgICBoLnByb3BzWydkYXRhLWhyZWYnXSA9IHVuZGVmaW5lZDtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBjb25zdCBjb21wb25lbnRzID0gdGFnc1toLnR5cGVdIHx8IFtdO1xuICAgICAgICAgICAgICAgIGNvbXBvbmVudHMucHVzaChoKTtcbiAgICAgICAgICAgICAgICB0YWdzW2gudHlwZV0gPSBjb21wb25lbnRzO1xuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICBjb25zdCB0aXRsZUNvbXBvbmVudCA9IHRhZ3MudGl0bGUgPyB0YWdzLnRpdGxlWzBdIDogbnVsbDtcbiAgICAgICAgICAgIGxldCB0aXRsZSA9ICcnO1xuICAgICAgICAgICAgaWYgKHRpdGxlQ29tcG9uZW50KSB7XG4gICAgICAgICAgICAgICAgY29uc3QgeyBjaGlsZHJlbiAgfSA9IHRpdGxlQ29tcG9uZW50LnByb3BzO1xuICAgICAgICAgICAgICAgIHRpdGxlID0gdHlwZW9mIGNoaWxkcmVuID09PSAnc3RyaW5nJyA/IGNoaWxkcmVuIDogQXJyYXkuaXNBcnJheShjaGlsZHJlbikgPyBjaGlsZHJlbi5qb2luKCcnKSA6ICcnO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKHRpdGxlICE9PSBkb2N1bWVudC50aXRsZSkgZG9jdW1lbnQudGl0bGUgPSB0aXRsZTtcbiAgICAgICAgICAgIFtcbiAgICAgICAgICAgICAgICAnbWV0YScsXG4gICAgICAgICAgICAgICAgJ2Jhc2UnLFxuICAgICAgICAgICAgICAgICdsaW5rJyxcbiAgICAgICAgICAgICAgICAnc3R5bGUnLFxuICAgICAgICAgICAgICAgICdzY3JpcHQnXG4gICAgICAgICAgICBdLmZvckVhY2goKHR5cGUpPT57XG4gICAgICAgICAgICAgICAgdXBkYXRlRWxlbWVudHModHlwZSwgdGFnc1t0eXBlXSB8fCBbXSk7XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgIH07XG59XG5jb25zdCBET01BdHRyaWJ1dGVOYW1lcyA9IHtcbiAgICBhY2NlcHRDaGFyc2V0OiAnYWNjZXB0LWNoYXJzZXQnLFxuICAgIGNsYXNzTmFtZTogJ2NsYXNzJyxcbiAgICBodG1sRm9yOiAnZm9yJyxcbiAgICBodHRwRXF1aXY6ICdodHRwLWVxdWl2JyxcbiAgICBub01vZHVsZTogJ25vTW9kdWxlJ1xufTtcbmV4cG9ydHMuRE9NQXR0cmlidXRlTmFtZXMgPSBET01BdHRyaWJ1dGVOYW1lcztcbmZ1bmN0aW9uIHJlYWN0RWxlbWVudFRvRE9NKHsgdHlwZSAsIHByb3BzICB9KSB7XG4gICAgY29uc3QgZWwgPSBkb2N1bWVudC5jcmVhdGVFbGVtZW50KHR5cGUpO1xuICAgIGZvcihjb25zdCBwIGluIHByb3BzKXtcbi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m9sZFRhZ3MiLCJpIiwiaiIsInByZXZpb3VzRWxlbWVudFNpYmxpbmciLCJyZWYiLCJ0YWdOYW1lIiwibmV3VGFncyIsIm1hcCIsImZpbHRlciIsImsiLCJsZW4iLCJsZW5ndGgiLCJzcGxpY2UiLCJ0IiwicGFyZW50Tm9kZSIsInJlbW92ZUNoaWxkIiwiaW5zZXJ0QmVmb3JlIiwidG9TdHJpbmciLCJfX2VzTW9kdWxlIiwiYXNzaWduIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/head-manager.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/normalize-trailing-slash.js": +/*!*******************************************************************!*\ + !*** ./node_modules/next/dist/client/normalize-trailing-slash.js ***! + \*******************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.normalizePathTrailingSlash = void 0;\nvar _removeTrailingSlash = __webpack_require__(/*! ../shared/lib/router/utils/remove-trailing-slash */ \"./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js\");\nvar _parsePath = __webpack_require__(/*! ../shared/lib/router/utils/parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nvar normalizePathTrailingSlash = function(path) {\n if (!path.startsWith(\"/\") || undefined) {\n return path;\n }\n var ref = (0, _parsePath).parsePath(path), pathname = ref.pathname, query = ref.query, hash = ref.hash;\n if (false) {}\n return \"\".concat((0, _removeTrailingSlash).removeTrailingSlash(pathname)).concat(query).concat(hash);\n};\nexports.normalizePathTrailingSlash = normalizePathTrailingSlash;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=normalize-trailing-slash.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL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-trailing-slash.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/remove-base-path.js": +/*!***********************************************************!*\ + !*** ./node_modules/next/dist/client/remove-base-path.js ***! + \***********************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.removeBasePath = removeBasePath;\nvar _hasBasePath = __webpack_require__(/*! ./has-base-path */ \"./node_modules/next/dist/client/has-base-path.js\");\nvar basePath = false || \"\";\nfunction removeBasePath(path) {\n if (false) {}\n path = path.slice(basePath.length);\n if (!path.startsWith(\"/\")) path = \"/\".concat(path);\n return path;\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=remove-base-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9yZW1vdmUtYmFzZS1wYXRoLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsc0JBQXNCLEdBQUdFLGNBQWMsQ0FBQztBQUN4QyxJQUFJQyxZQUFZLEdBQUdDLG1CQUFPLENBQUMseUVBQWlCLENBQUM7QUFDN0MsSUFBTUMsUUFBUSxHQUFHQyxNQUFrQyxJQUFJLEVBQUU7QUFDekQsU0FBU0osY0FBYyxDQUFDTyxJQUFJLEVBQUU7SUFDMUIsSUFBSUgsS0FBMEMsRUFBRSxFQUkvQztJQUNERyxJQUFJLEdBQUdBLElBQUksQ0FBQ0csS0FBSyxDQUFDUCxRQUFRLENBQUNRLE1BQU0sQ0FBQyxDQUFDO0lBQ25DLEl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9ydHMiLCJ2YWx1ZSIsInJlbW92ZUJhc2VQYXRoIiwiX2hhc0Jhc2VQYXRoIiwicmVxdWlyZSIsImJhc2VQYXRoIiwicHJvY2VzcyIsImVudiIsIl9fTkVYVF9ST1VURVJfQkFTRVBBVEgiLCJwYXRoIiwiX19ORVhUX01BTlVBTF9DTElFTlRfQkFTRV9QQVRIIiwiaGFzQmFzZVBhdGgiLCJzbGljZSIsImxlbmd0aCIsInN0YXJ0c1dpdGgiLCJkZWZhdWx0IiwiX19lc01vZHVsZSIsImFzc2lnbiIsIm1vZHVsZSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/remove-base-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/remove-locale.js": +/*!********************************************************!*\ + !*** ./node_modules/next/dist/client/remove-locale.js ***! + \********************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.removeLocale = removeLocale;\nvar _parsePath = __webpack_require__(/*! ../shared/lib/router/utils/parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nfunction removeLocale(path, locale) {\n if (false) { var localeLower, pathLower, pathname; }\n return path;\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=remove-locale.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9yZW1vdmUtbG9jYWxlLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsb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KGV4cG9ydHMuZGVmYXVsdCwgJ19fZXNNb2R1bGUnLCB7IHZhbHVlOiB0cnVlIH0pO1xuICBPYmplY3QuYXNzaWduKGV4cG9ydHMuZGVmYXVsdCwgZXhwb3J0cyk7XG4gIG1vZHVsZS5leHBvcnRzID0gZXhwb3J0cy5kZWZhdWx0O1xufVxuXG4vLyMgc291cmNlTWFwcGluZ1VSTD1yZW1vdmUtbG9jYWxlLmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsInJlbW92ZUxvY2FsZSIsIl9wYXJzZVBhdGgiLCJyZXF1aXJlIiwicGF0aCIsImxvY2FsZSIsInByb2Nlc3MiLCJlbnYiLCJfX05FWFRfSTE4Tl9TVVBQT1JUIiwicGF0aG5hbWUiLCJwYXJzZVBhdGgiLCJwYXRoTG93ZXIiLCJ0b0xvd2VyQ2FzZSIsImxvY2FsZUxvd2VyIiwic3RhcnRzV2l0aCIsImxlbmd0aCIsInNsaWNlIiwiZGVmYXVsdCIsIl9fZXNNb2R1bGUiLCJhc3NpZ24iLCJtb2R1bGUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/remove-locale.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/request-idle-callback.js": +/*!****************************************************************!*\ + !*** ./node_modules/next/dist/client/request-idle-callback.js ***! + \****************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.cancelIdleCallback = exports.requestIdleCallback = void 0;\nvar requestIdleCallback = typeof self !== \"undefined\" && self.requestIdleCallback && self.requestIdleCallback.bind(window) || function(cb) {\n var start = Date.now();\n return setTimeout(function() {\n cb({\n didTimeout: false,\n timeRemaining: function timeRemaining() {\n return Math.max(0, 50 - (Date.now() - start));\n }\n });\n }, 1);\n};\nexports.requestIdleCallback = requestIdleCallback;\nvar cancelIdleCallback = typeof self !== \"undefined\" && self.cancelIdleCallback && self.cancelIdleCallback.bind(window) || function(id) {\n return clearTimeout(id);\n};\nexports.cancelIdleCallback = cancelIdleCallback;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=request-idle-callback.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9yZXF1ZXN0LWlkbGUtY2FsbGJhY2suanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCwwQkFBMEIsR0FBR0EsMkJBQTJCLEdBQUcsS0FBSyxDQUFDLENBQUM7QUFDbEUsSUFBTUcsbUJBQW1CLEdBQUcsT0FBT0MsSUFBSSxLQUFLLFdBQVcsSUFBSUEsSUFBSSxDQUFDRCxtQkFBbUIsSUFBSUMsSUFBSSxDQUFDRCxtQkFBbUIsQ0FBQ0UsSUFBSSxDQUFDQyxNQUFNLENBQUMsSUFBSSxTQUFTQyxFQUFFLEVBQUU7SUFDekksSUFBSUMsS0FBSyxHQUFHQyxJQUFJLENBQUNDLEdBQUcsRUFBRTtJQUN0QixPQUFPQyxVQUFVLENBQUMsV0FBVztRQUN6QkosRUFBRSxDQUFDO1lBQ0NLLFVBQVUsRUFBRSxLQUFLO1lBQ2pCQyxhQUFhLEVBQUUsU0FBZkEsYUFBYSxHQUFhO2dCQUN0QixPQUFPQyxJQUFJLENBQUNDLEdBQUcsQ0FBQyxDQUFDLEVBQUUsRUFBRSxHQUFJTixDQUFBQSxJQUFJLENBQUNDLEdBQUcsRUFBRSx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# sourceURL=webpack-internal:///./node_modules/next/dist/client/request-idle-callback.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/route-loader.js": +/*!*******************************************************!*\ + !*** ./node_modules/next/dist/client/route-loader.js ***! + \*******************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.markAssetError = markAssetError;\nexports.isAssetError = isAssetError;\nexports.getClientBuildManifest = getClientBuildManifest;\nexports.createRouteLoader = createRouteLoader;\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _getAssetPathFromRoute = _interop_require_default(__webpack_require__(/*! ../shared/lib/router/utils/get-asset-path-from-route */ \"./node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js\"));\nvar _trustedTypes = __webpack_require__(/*! ./trusted-types */ \"./node_modules/next/dist/client/trusted-types.js\");\nvar _requestIdleCallback = __webpack_require__(/*! ./request-idle-callback */ \"./node_modules/next/dist/client/request-idle-callback.js\");\n// 3.8s was arbitrarily chosen as it's what https://web.dev/interactive\n// considers as \"Good\" time-to-interactive. We must assume something went\n// wrong beyond this point, and then fall-back to a full page transition to\n// show the user something of value.\nvar MS_MAX_IDLE_DELAY = 3800;\nfunction withFuture(key, map, generator) {\n var entry = map.get(key);\n if (entry) {\n if (\"future\" in entry) {\n return entry.future;\n }\n return Promise.resolve(entry);\n }\n var resolver;\n var prom = new Promise(function(resolve) {\n resolver = resolve;\n });\n map.set(key, entry = {\n resolve: resolver,\n future: prom\n });\n return generator ? generator() // eslint-disable-next-line no-sequences\n .then(function(value) {\n return resolver(value), value;\n }).catch(function(err) {\n map.delete(key);\n throw err;\n }) : prom;\n}\nfunction hasPrefetch(link) {\n try {\n link = document.createElement(\"link\");\n return(// with relList.support\n !!window.MSInputMethodContext && !!document.documentMode || link.relList.supports(\"prefetch\"));\n } catch (e) {\n return false;\n }\n}\nvar canPrefetch = hasPrefetch();\nfunction prefetchViaDom(href, as, link) {\n return new Promise(function(res, rej) {\n var selector = '\\n link[rel=\"prefetch\"][href^=\"'.concat(href, '\"],\\n link[rel=\"preload\"][href^=\"').concat(href, '\"],\\n script[src^=\"').concat(href, '\"]');\n if (document.querySelector(selector)) {\n return res();\n }\n link = document.createElement(\"link\");\n // The order of property assignment here is intentional:\n if (as) link.as = as;\n link.rel = \"prefetch\";\n link.crossOrigin = undefined;\n link.onload = res;\n link.onerror = rej;\n // `href` should always be last:\n link.href = href;\n document.head.appendChild(link);\n });\n}\nvar ASSET_LOAD_ERROR = Symbol(\"ASSET_LOAD_ERROR\");\nfunction markAssetError(err) {\n return Object.defineProperty(err, ASSET_LOAD_ERROR, {});\n}\nfunction isAssetError(err) {\n return err && ASSET_LOAD_ERROR in err;\n}\nfunction appendScript(src, script) {\n return new Promise(function(resolve, reject) {\n script = document.createElement(\"script\");\n // The order of property assignment here is intentional.\n // 1. Setup success/failure hooks in case the browser synchronously\n // executes when `src` is set.\n script.onload = resolve;\n script.onerror = function() {\n return reject(markAssetError(new Error(\"Failed to load script: \".concat(src))));\n };\n // 2. Configure the cross-origin attribute before setting `src` in case the\n // browser begins to fetch.\n script.crossOrigin = undefined;\n // 3. Finally, set the source and inject into the DOM in case the child\n // must be appended for fetching to start.\n script.src = src;\n document.body.appendChild(script);\n });\n}\n// We wait for pages to be built in dev before we start the route transition\n// timeout to prevent an un-necessary hard navigation in development.\nvar devBuildPromise;\n// Resolve a promise that times out after given amount of milliseconds.\nfunction resolvePromiseWithTimeout(p, ms, err) {\n return new Promise(function(resolve, reject) {\n var cancelled = false;\n p.then(function(r) {\n // Resolved, cancel the timeout\n cancelled = true;\n resolve(r);\n }).catch(reject);\n // We wrap these checks separately for better dead-code elimination in\n // production bundles.\n if (true) {\n (devBuildPromise || Promise.resolve()).then(function() {\n (0, _requestIdleCallback).requestIdleCallback(function() {\n return setTimeout(function() {\n if (!cancelled) {\n reject(err);\n }\n }, ms);\n });\n });\n }\n if (false) {}\n });\n}\nfunction getClientBuildManifest() {\n if (self.__BUILD_MANIFEST) {\n return Promise.resolve(self.__BUILD_MANIFEST);\n }\n var onBuildManifest = new Promise(function(resolve) {\n // Mandatory because this is not concurrent safe:\n var cb = self.__BUILD_MANIFEST_CB;\n self.__BUILD_MANIFEST_CB = function() {\n resolve(self.__BUILD_MANIFEST);\n cb && cb();\n };\n });\n return resolvePromiseWithTimeout(onBuildManifest, MS_MAX_IDLE_DELAY, markAssetError(new Error(\"Failed to load client build manifest\")));\n}\nfunction getFilesForRoute(assetPrefix, route) {\n if (true) {\n var scriptUrl = assetPrefix + \"/_next/static/chunks/pages\" + encodeURI((0, _getAssetPathFromRoute).default(route, \".js\"));\n return Promise.resolve({\n scripts: [\n (0, _trustedTypes).__unsafeCreateTrustedScriptURL(scriptUrl)\n ],\n // Styles are handled by `style-loader` in development:\n css: []\n });\n }\n return getClientBuildManifest().then(function(manifest) {\n if (!(route in manifest)) {\n throw markAssetError(new Error(\"Failed to lookup route: \".concat(route)));\n }\n var allFiles = manifest[route].map(function(entry) {\n return assetPrefix + \"/_next/\" + encodeURI(entry);\n });\n return {\n scripts: allFiles.filter(function(v) {\n return v.endsWith(\".js\");\n }).map(function(v) {\n return (0, _trustedTypes).__unsafeCreateTrustedScriptURL(v);\n }),\n css: allFiles.filter(function(v) {\n return v.endsWith(\".css\");\n })\n };\n });\n}\nfunction createRouteLoader(assetPrefix) {\n var maybeExecuteScript = function maybeExecuteScript(src) {\n // With HMR we might need to \"reload\" scripts when they are\n // disposed and readded. Executing scripts twice has no functional\n // differences\n if (false) { var prom; } else {\n return appendScript(src);\n }\n };\n var fetchStyleSheet = function fetchStyleSheet(href) {\n var prom = styleSheets.get(href);\n if (prom) {\n return prom;\n }\n styleSheets.set(href, prom = fetch(href).then(function(res) {\n if (!res.ok) {\n throw new Error(\"Failed to load stylesheet: \".concat(href));\n }\n return res.text().then(function(text) {\n return {\n href: href,\n content: text\n };\n });\n }).catch(function(err) {\n throw markAssetError(err);\n }));\n return prom;\n };\n var entrypoints = new Map();\n var loadedScripts = new Map();\n var styleSheets = new Map();\n var routes = new Map();\n return {\n whenEntrypoint: function whenEntrypoint(route) {\n return withFuture(route, entrypoints);\n },\n onEntrypoint: function onEntrypoint(route, execute) {\n (execute ? Promise.resolve().then(function() {\n return execute();\n }).then(function(exports1) {\n return {\n component: exports1 && exports1.default || exports1,\n exports: exports1\n };\n }, function(err) {\n return {\n error: err\n };\n }) : Promise.resolve(undefined)).then(function(input) {\n var old = entrypoints.get(route);\n if (old && \"resolve\" in old) {\n if (input) {\n entrypoints.set(route, input);\n old.resolve(input);\n }\n } else {\n if (input) {\n entrypoints.set(route, input);\n } else {\n entrypoints.delete(route);\n }\n // when this entrypoint has been resolved before\n // the route is outdated and we want to invalidate\n // this cache entry\n routes.delete(route);\n }\n });\n },\n loadRoute: function loadRoute(route, prefetch) {\n var _this = this;\n return withFuture(route, routes, function() {\n var devBuildPromiseResolve;\n if (true) {\n devBuildPromise = new Promise(function(resolve) {\n devBuildPromiseResolve = resolve;\n });\n }\n return resolvePromiseWithTimeout(getFilesForRoute(assetPrefix, route).then(function(param) {\n var scripts = param.scripts, css = param.css;\n return Promise.all([\n entrypoints.has(route) ? [] : Promise.all(scripts.map(maybeExecuteScript)),\n Promise.all(css.map(fetchStyleSheet)), \n ]);\n }).then(function(res) {\n return _this.whenEntrypoint(route).then(function(entrypoint) {\n return {\n entrypoint: entrypoint,\n styles: res[1]\n };\n });\n }), MS_MAX_IDLE_DELAY, markAssetError(new Error(\"Route did not complete loading: \".concat(route)))).then(function(param) {\n var entrypoint = param.entrypoint, styles = param.styles;\n var res = Object.assign({\n styles: styles\n }, entrypoint);\n return \"error\" in entrypoint ? entrypoint : res;\n }).catch(function(err) {\n if (prefetch) {\n // we don't want to cache errors during prefetch\n throw err;\n }\n return {\n error: err\n };\n }).finally(function() {\n return devBuildPromiseResolve == null ? void 0 : devBuildPromiseResolve();\n });\n });\n },\n prefetch: function prefetch(route) {\n var _this = this;\n // https://github.com/GoogleChromeLabs/quicklink/blob/453a661fa1fa940e2d2e044452398e38c67a98fb/src/index.mjs#L115-L118\n // License: Apache 2.0\n var cn;\n if (cn = navigator.connection) {\n // Don't prefetch if using 2G or if Save-Data is enabled.\n if (cn.saveData || /2g/.test(cn.effectiveType)) return Promise.resolve();\n }\n return getFilesForRoute(assetPrefix, route).then(function(output) {\n return Promise.all(canPrefetch ? output.scripts.map(function(script) {\n return prefetchViaDom(script.toString(), \"script\");\n }) : []);\n }).then(function() {\n (0, _requestIdleCallback).requestIdleCallback(function() {\n return _this.loadRoute(route, true).catch(function() {});\n });\n }).catch(function() {});\n }\n };\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=route-loader.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9yb3V0ZS1sb2FkZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxzQkFBc0IsR0FBR0UsY0FBYyxDQUFDO0FBQ3hDRixvQkFBb0IsR0FBR0csWUFBWSxDQUFDO0FBQ3BDSCw4QkFBOEIsR0FBR0ksc0JBQXNCLENBQUM7QUFDeERKLHlCQUF5QixHQUFHSyxpQkFBaUIsQ0FBQztBQUM5QyxJQUFJQyx3QkFBd0IsR0FBR0MsbUpBQStEO0FBQzlGLElBQUlFLHNCQUFzQixHQUFHSCx3QkFBd0IsQ0FBQ0MsbUJBQU8sQ0FBQywySUFBc0QsQ0FBQyxDQUFDO0FBQ3RILElBQUlHLGFBQWEsR0FBR0gsbUJBQU8sQ0FBQyx5RUFBaUIsQ0FBQztBQUM5QyxJQUFJSSxvQkFBb0IsR0FBR0osbUJBQU8sQ0FBQyx5RkFBeUIsQ0FBQztBQUM3RCx1RUFBdUU7QUFDdkUseUVBQXlFO0FBQ3pFLDJFQUEyRTtBQUMzRSxvQ0FBb0M7QUFDcEMsSUFBTUssaUJBQWlCLEdBQUcsSUFBSTtBQUM5QixTQUFTQyxVQUFVLENBQUNDLEdBQUcsRUFBRUMsR0FBRyxFQUFFQyxTQUFTLEVBQUU7SUFDckMsSUFBSUMsS0FBSyxHQUFHRixHQUFHLENBQUNHLEdBQUcsQ0FBQ0osR0FBRyxDQUFDO0lBQ3hCLElBQUlHLEtBQUssRUFBRTtRQUNQLElBQUksUUFBUSxJQUFJQSxLQUFL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RsZUNhbGxiYWNrKS5yZXF1ZXN0SWRsZUNhbGxiYWNrKCgpPT5zZXRUaW1lb3V0KCgpPT57XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIWNhbmNlbGxlZCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlamVjdChlcnIpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9LCBtcykpO1xuICAgICAgICAgICAgfSk7XG4gICAgICAgIH1cbiAgICAgICAgaWYgKHByb2Nlc3MuZW52Lk5PREVfRU5WICE9PSAnZGV2ZWxvcG1lbnQnKSB7XG4gICAgICAgICAgICAoMCwgX3JlcXVlc3RJZGxlQ2FsbGJhY2spLnJlcXVlc3RJZGxlQ2FsbGJhY2soKCk9PnNldFRpbWVvdXQoKCk9PntcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFjYW5jZWxsZWQpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHJlamVjdChlcnIpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfSwgbXMpKTtcbiAgICAgICAgfVxuICAgIH0pO1xufVxuZnVuY3Rpb24gZ2V0Q2xpZW50QnVpbGRNYW5pZmVzdCgpIHtcbiAgICBpZiAoc2VsZi5fX0JVSUxEX01BTklGRVNUKSB7XG4gICAgICAgIHJldHVybiBQcm9taXNlLnJlc29sdmUoc2VsZi5fX0JVSUxEX01BTklGRVNUKTtcbiAgICB9XG4gICAgY29uc3Qgb25CdWlsZE1hbmlmZXN0ID0gbmV3IFByb21pc2UoKHJlc29sdmUpPT57XG4gICAgICAgIC8vIE1hbmRhdG9yeSBiZWNhdXNlIHRoaXMgaXMgbm90IGNvbmN1cnJlbnQgc2FmZTpcbiAgICAgICAgY29uc3QgY2IgPSBzZWxmLl9fQlVJTERfTUFOSUZFU1RfQ0I7XG4gICAgICAgIHNlbGYuX19CVUlMRF9NQU5JRkVTVF9DQiA9ICgpPT57XG4gICAgICAgIC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nlc3MuZW52Lk5PREVfRU5WICE9PSAnZGV2ZWxvcG1lbnQnKSB7XG4gICAgICAgICAgICBsZXQgcHJvbSA9IGxvYWRlZFNjcmlwdHMuZ2V0KHNyYy50b1N0cmluZygpKTtcbiAgICAgICAgICAgIGlmIChwcm9tKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIHByb207XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICAvLyBTa2lwIGV4ZWN1dGluZyBzY3JpcHQgaWYgaXQncyBhbHJlYWR5IGluIHRoZSBET006XG4gICAgICAgICAgICBpZiAoZG9jdW1lbnQucXVlcnlTZWxlY3Rvcihgc2NyaXB0W3NyY149XCIke3NyY31cIl1gKSkge1xuICAgICAgICAgICAgICAgIHJldHVybiBQcm9taXNlLnJlc29sdmUoKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGxvYWRlZFNjcmlwdHMuc2V0KHNyYy50b1N0cmluZygpLCBwcm9tID0gYXBwZW5kU2NyaXB0KHNyYykpO1xuICAgICAgICAgICAgcmV0dXJuIHByb207XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICByZXR1cm4gYXBwZW5kU2NyaXB0KHNyYyk7XG4gICAgICAgIH1cbiAgICB9XG4gICAgZnVuY3Rpb24gZmV0Y2hTdHlsZVNoZWV0KGhyZWYpIHtcbiAgICAgICAgbGV0IHByb20gPSBzdHlsZVNoZWV0cy5nZXQoaHJlZik7XG4gICAgICAgIGlmIChwcm9tKSB7XG4gICAgICAgICAgICByZXR1cm4gcHJvbTtcbiAgICAgICAgfVxuICAgICAgICBzdHlsZVNoZWV0cy5zZXQoaHJlZiwgcHJvbSA9IGZldGNoKGhyZWYpLnRoZW4oKHJlcyk9PntcbiAgICAgICAgICAgIGlmICghcmVzLm9rKSB7XG4gICAgICAgICAgICAgICAgdGhyb3cgbmV3IEVycm9yKGBGYWlsZWQgdG8gbG9hZCBzdHlsZXNoZWV0OiAke2hyZWZ9YCk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4gcmVzLnRleHQoKS50aGVuKCh0ZXh0KT0+KHtcbiAgICAgICAgICAgICAgICAgICAgaHJlZjogaHJlZixcbiAgICAgICAgICAgICAgICAgICAgY29udGVudDogdGV4dFxuICAgICAgICAgICAgICAgIH0pKTtcbiAgICAgICAgfSkuY2F0Y2goKGVycik9PntcbiAgICAgICAgICAgIHRocm93IG1hcmtBc3NldEVycm9yKGVycik7XG4gICAgICAgIH0pKTtcbiAgICAgICAgcmV0dXJuIHByb207XG4gICAgfVxuICAgIHJldHVybiB7XG4gICAgICAgIHdoZW5FbnRyeXBvaW50IChyb3V0ZSkge1xuICAgICAgICAgICAgcmV0dXJuIHdpdGhGdXR1cmUocm91dGUsIGVudHJ5cG9pbnRzKTtcbiAgICAgICAgfSxcbiAgICAgICAgb25FbnRyeXBvaW50IChyb3V0ZSwgZXhlY3V0ZSkge1xuICAgICAgICAgICAgKGV4ZWN1dGUgPyBQcm9taXNlLnJlc29sdmUoKS50aGVuKCgpPT5leGVjdXRlKCkpLnRoZW4oKGV4cG9ydHMpPT4oe1xuICAgICAgICAgICAgICAgICAgICBjb21wb25lbnQ6IGV4cG9ydHMgJiYgZXhwb3J0cy5kZWZhdWx0IHx8IGV4cG9ydHMsXG4gICAgICAgICAgICAgICAgICAgIGV4cG9ydHM6IGV4cG9ydHNcbiAgICAgICAgICAgICAgICB9KSwgKGVycik9Pih7XG4gICAgICAgICAgICAgICAgICAgIGVycm9yOiBlcnJcbiAgICAgICAgICAgICAgICB9KSkgOiBQcm9taXNlLnJlc29sdmUodW5kZWZpbmVkKSkudGhlbigoaW5wdXQpPT57XG4gICAgICAgICAgICAgICAgY29uc3Qgb2xkID0gZW50cnlwb2ludHMuZ2V0KHJvdXRlKTtcbiAgICAgICAgICAgICAgICBpZiAob2xkICYmICdyZXNvbHZlJyBpbiBvbGQpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKGlucHV0KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBlbnRyeXBvaW50cy5zZXQocm91dGUsIGlucHV0KTtcbiAgICAgICAgICAgICAgICAgICAgICAgIG9sZC5yZXNvbHZlKGlucHV0KTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChpbnB1dCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgZW50cnlwb2ludHMuc2V0KHJvdXRlLCBpbnB1dCk7XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBlbnRyeXBvaW50cy5kZWxldGUocm91dGUpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIC8vIHdoZW4gdGhpcyBlbnRyeXBvaW50IGhhcyBiZWVuIHJlc29sdmVkIGJlZm9yZVxuICAgICAgICAgICAgICAgICAgICAvLyB0aGUgcm91dGUgaXMgb3V0ZGF0ZWQgYW5kIHdlIHdhbnQgdG8gaW52YWxpZGF0ZVxuICAgICAgICAgICAgICAgICAgICAvLyB0aGlzIGNhY2hlIGVudHJ5XG4gICAgICAgICAgICAgICAgICAgIHJvdXRlcy5kZWxldGUocm91dGUpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9LFxuICAgICAgICBsb2FkUm91dGUgKHJvdXRlLCBwcmVmZXRjaCkge1xuICAgICAgICAgICAgcmV0dXJuIHdpdGhGdXR1cmUocm91dGUsIHJvdXRlcywgKCk9PntcbiAgICAgICAgICAgICAgICBsZXQgZGV2QnVpbGRQcm9taXNlUmVzb2x2ZTtcbiAgICAgICAgICAgICAgICBpZiAocHJvY2Vzcy5lbnYuTk9ERV9FTlYgPT09ICdkZXZlbG9wbWVudCcpIHtcbiAgICAgICAgICAgICAgICAgICAgZGV2QnVpbGRQcm9taXNlID0gbmV3IFByb21pc2UoKHJlc29sdmUpPT57XG4gICAgICAgICAgICAgICAgICAgICAgICBkZXZCdWlsZFByb21pc2VSZXNvbHZlID0gcmVzb2x2ZTtcbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJldHVybiByZXNvbHZlUHJvbWlzZVdpdGhUaW1lb3V0KGdldEZpbGVzRm9yUm91dGUoYXNzZXRQcmVmaXgsIHJvdXRlKS50aGVuKCh7IHNjcmlwdHMgLCBjc3MgIH0pPT57XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBQcm9taXNlLmFsbChbXG4gICAgICAgICAgICAgICAgICAgICAgICBlbnRyeXBvaW50cy5oYXMocm91dGUpID8gW10gOiBQcm9taXNlLmFsbChzY3JpcHRzLm1hcChtYXliZUV4ZWN1dGVTY3JpcHQpKSxcbiAgICAgICAgICAgICAgICAgICAgICAgIFByb21pc2UuYWxsKGNzcy5tYXAoZmV0Y2hTdHlsZVNoZWV0KSksIFxuICAgICAgICAgICAgICAgICAgICBdKTtcbiAgICAgICAgICAgICAgICB9KS50aGVuKChyZXMpPT57XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLndoZW5FbnRyeXBvaW50KHJvdXRlKS50aGVuKChlbnRyeXBvaW50KT0+KHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBlbnRyeXBvaW50LFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN0eWxlczogcmVzWzFdXG4gICAgICAgICAgICAgICAgICAgICAgICB9KSk7XG4gICAgICAgICAgICAgICAgfSksIE1TX01BWF9JRExFX0RFTEFZLCBtYXJrQXNzZXRFcnJvcihuZXcgRXJyb3IoYFJvdXRlIGRpZCBub3QgY29tcGxldGUgbG9hZGluZzogJHtyb3V0ZX1gKSkpLnRoZW4oKHsgZW50cnlwb2ludCAsIHN0eWxlcyAgfSk9PntcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcmVzID0gT2JqZWN0LmFzc2lnbih7XG4gICAgICAgICAgICAgICAgICAgICAgICBzdHlsZXM6IHN0eWxlc1xuICAgICAgICAgICAgICAgICAgICB9LCBlbnRyeXBvaW50KTtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuICdlcnJvcicgaW4gZW50cnlwb2ludCA/IGVudHJ5cG9pbnQgOiByZXM7XG4gICAgICAgICAgICAgICAgfSkuY2F0Y2goKGVycik9PntcbiAgICAgICAgICAgICAgICAgICAgaWYgKHByZWZldGNoKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyB3ZSBkb24ndCB3YW50IHRvIGNhY2hlIGVycm9ycyBkdXJpbmcgcHJlZmV0Y2hcbiAgICAgICAgICAgICAgICAgICAgICAgIHRocm93IGVycjtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgZXJyb3I6IGVyclxuICAgICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIH0pLmZpbmFsbHkoKCk9PntcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGRldkJ1aWxkUHJvbWlzZVJlc29sdmUgPT0gbnVsbCA/IHZvaWQgMCA6IGRldkJ1aWxkUHJvbWlzZVJlc29sdmUoKTtcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9LFxuICAgICAgICBwcmVmZXRjaCAocm91dGUpIHtcbiAgICAgICAgICAgIC8vIGh0dHBzOi8vZ2l0aHViLmNvbS9Hb29nbGVDaHJvbWVMYWJzL3F1aWNrbGluay9ibG9iLzQ1M2E2NjFmYTFmYTk0MGUyZDJlMDQ0NDUyMzk4ZTM4YzY3YTk4ZmIvc3JjL2luZGV4Lm1qcyNMMTE1LUwxMThcbiAgICAgICAgICAgIC8vIExpY2Vuc2U6IEFwYWNoZSAyLjBcbiAgICAgICAgICAgIGxldCBjbjtcbiAgICAgICAgICAgIGlmIChjbiA9IG5hdmlnYXRvci5jb25uZWN0aW9uKSB7XG4gICAgICAgICAg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vbiIsInNhdmVEYXRhIiwidGVzdCIsImVmZmVjdGl2ZVR5cGUiLCJvdXRwdXQiLCJfX2VzTW9kdWxlIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/route-loader.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/router.js": +/*!*************************************************!*\ + !*** ./node_modules/next/dist/client/router.js ***! + \*************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _construct = (__webpack_require__(/*! @swc/helpers/lib/_construct.js */ \"./node_modules/@swc/helpers/lib/_construct.js\")[\"default\"]);\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nvar _s = $RefreshSig$();\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nObject.defineProperty(exports, \"Router\", ({\n enumerable: true,\n get: function get() {\n return _router.default;\n }\n}));\nObject.defineProperty(exports, \"withRouter\", ({\n enumerable: true,\n get: function get() {\n return _withRouter.default;\n }\n}));\nexports.useRouter = useRouter;\nexports.createRouter = createRouter;\nexports.makePublicRouterInstance = makePublicRouterInstance;\nexports[\"default\"] = void 0;\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _react = _interop_require_default(__webpack_require__(/*! react */ \"./node_modules/react/index.js\"));\nvar _router = _interop_require_default(__webpack_require__(/*! ../shared/lib/router/router */ \"./node_modules/next/dist/shared/lib/router/router.js\"));\nvar _routerContext = __webpack_require__(/*! ../shared/lib/router-context */ \"./node_modules/next/dist/shared/lib/router-context.js\");\nvar _isError = _interop_require_default(__webpack_require__(/*! ../lib/is-error */ \"./node_modules/next/dist/lib/is-error.js\"));\nvar _withRouter = _interop_require_default(__webpack_require__(/*! ./with-router */ \"./node_modules/next/dist/client/with-router.js\"));\nvar singletonRouter = {\n router: null,\n readyCallbacks: [],\n ready: function ready(cb) {\n if (this.router) return cb();\n if (true) {\n this.readyCallbacks.push(cb);\n }\n }\n};\n// Create public properties and methods of the router in the singletonRouter\nvar urlPropertyFields = [\n \"pathname\",\n \"route\",\n \"query\",\n \"asPath\",\n \"components\",\n \"isFallback\",\n \"basePath\",\n \"locale\",\n \"locales\",\n \"defaultLocale\",\n \"isReady\",\n \"isPreview\",\n \"isLocaleDomain\",\n \"domainLocales\", \n];\nvar routerEvents = [\n \"routeChangeStart\",\n \"beforeHistoryChange\",\n \"routeChangeComplete\",\n \"routeChangeError\",\n \"hashChangeStart\",\n \"hashChangeComplete\", \n];\nvar coreMethodFields = [\n \"push\",\n \"replace\",\n \"reload\",\n \"back\",\n \"prefetch\",\n \"beforePopState\", \n];\n// Events is a static property on the router, the router doesn't have to be initialized to use it\nObject.defineProperty(singletonRouter, \"events\", {\n get: function get() {\n return _router.default.events;\n }\n});\nfunction getRouter() {\n if (!singletonRouter.router) {\n var message = \"No router instance found.\\n\" + 'You should only use \"next/router\" on the client side of your app.\\n';\n throw new Error(message);\n }\n return singletonRouter.router;\n}\nurlPropertyFields.forEach(function(field) {\n // Here we need to use Object.defineProperty because we need to return\n // the property assigned to the actual router\n // The value might get changed as we change routes and this is the\n // proper way to access it\n Object.defineProperty(singletonRouter, field, {\n get: function get() {\n var router = getRouter();\n return router[field];\n }\n });\n});\ncoreMethodFields.forEach(function(field) {\n singletonRouter[field] = function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n var _router;\n var router = getRouter();\n return (_router = router)[field].apply(_router, _toConsumableArray(args));\n };\n});\nrouterEvents.forEach(function(event) {\n singletonRouter.ready(function() {\n _router.default.events.on(event, function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n var eventField = \"on\".concat(event.charAt(0).toUpperCase()).concat(event.substring(1));\n var _singletonRouter = singletonRouter;\n if (_singletonRouter[eventField]) {\n try {\n var __singletonRouter;\n (__singletonRouter = _singletonRouter)[eventField].apply(__singletonRouter, _toConsumableArray(args));\n } catch (err) {\n console.error(\"Error when running the Router event: \".concat(eventField));\n console.error((0, _isError).default(err) ? \"\".concat(err.message, \"\\n\").concat(err.stack) : err + \"\");\n }\n }\n });\n });\n});\nvar _default = singletonRouter;\nexports[\"default\"] = _default;\nfunction useRouter() {\n _s();\n return _react.default.useContext(_routerContext.RouterContext);\n}\n_s(useRouter, \"gDsCjeeItUuvgOWf1v4qoK9RF6k=\");\nfunction createRouter() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n singletonRouter.router = _construct(_router.default, _toConsumableArray(args));\n singletonRouter.readyCallbacks.forEach(function(cb) {\n return cb();\n });\n singletonRouter.readyCallbacks = [];\n return singletonRouter.router;\n}\nfunction makePublicRouterInstance(router) {\n var scopedRouter = router;\n var instance = {};\n var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;\n try {\n for(var _iterator = urlPropertyFields[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){\n var property = _step.value;\n if (typeof scopedRouter[property] === \"object\") {\n instance[property] = Object.assign(Array.isArray(scopedRouter[property]) ? [] : {}, scopedRouter[property]) // makes sure query is not stateful\n ;\n continue;\n }\n instance[property] = scopedRouter[property];\n }\n } catch (err) {\n _didIteratorError = true;\n _iteratorError = err;\n } finally{\n try {\n if (!_iteratorNormalCompletion && _iterator.return != null) {\n _iterator.return();\n }\n } finally{\n if (_didIteratorError) {\n throw _iteratorError;\n }\n }\n }\n // Events is a static property on the router, the router doesn't have to be initialized to use it\n instance.events = _router.default.events;\n coreMethodFields.forEach(function(field) {\n instance[field] = function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n var _scopedRouter;\n return (_scopedRouter = scopedRouter)[field].apply(_scopedRouter, _toConsumableArray(args));\n };\n });\n return instance;\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=router.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9yb3V0ZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7Ozs7Ozs7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNISCwwQ0FBeUM7SUFDckNJLFVBQVUsRUFBRSxJQUFJO0lBQ2hCQyxHQUFHLEVBQUUsU0FBTEEsR0FBRyxHQUFhO1FBQ1osT0FBT0MsT0FBTyxDQUFDQyxPQUFPLENBQUM7SUFDM0IsQ0FBQztDQUNKLEVBQUMsQ0FBQztBQUNIUCw4Q0FBNkM7SUFDekNJLFVBQVUsRUFBRSxJQUFJO0lBQ2hCQyxHQUFHLEVBQUUsU0FBTEEsR0FBRyxHQUFhO1FBQ1osT0FBT0csV0FBVyxDQUFDRCxPQUFPLENBQUM7SUFDL0IsQ0FBQztDQUNKLEVBQUMsQ0FBQztBQUNITCxpQkFBaUIsR0FBR08sU0FBUyxDQUFDO0FBQzlCUCxvQkFBb0IsR0FBR1EsWUFBWSxDQUFDO0FBQ3BDUixnQ0FBZ0MsR0FBR1Msd0JBQXdCLENBQUM7QUFDNURULGtCQUFlLEdBQUcsS0FBSyxDQUFDLENBQUM7QUFDekIsSUFBSVUsd0JBQXdCLEdBQUdDLG1KQUErRDtBQUM5RixJQUFJQyxNQUFNLEdBQUdGLH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m91dGVyIiwicmVhZHlDYWxsYmFja3MiLCJyZWFkeSIsImNiIiwicHVzaCIsInVybFByb3BlcnR5RmllbGRzIiwicm91dGVyRXZlbnRzIiwiY29yZU1ldGhvZEZpZWxkcyIsImV2ZW50cyIsImdldFJvdXRlciIsIm1lc3NhZ2UiLCJFcnJvciIsImZvckVhY2giLCJmaWVsZCIsImFyZ3MiLCJldmVudCIsIm9uIiwiZXZlbnRGaWVsZCIsImNoYXJBdCIsInRvVXBwZXJDYXNlIiwic3Vic3RyaW5nIiwiX3NpbmdsZXRvblJvdXRlciIsImVyciIsImNvbnNvbGUiLCJlcnJvciIsInN0YWNrIiwiX2RlZmF1bHQiLCJ1c2VDb250ZXh0IiwiUm91dGVyQ29udGV4dCIsInNjb3BlZFJvdXRlciIsImluc3RhbmNlIiwicHJvcGVydHkiLCJhc3NpZ24iLCJBcnJheSIsImlzQXJyYXkiLCJfX2VzTW9kdWxlIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/router.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/script.js": +/*!*************************************************!*\ + !*** ./node_modules/next/dist/client/script.js ***! + \*************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _slicedToArray = (__webpack_require__(/*! @swc/helpers/lib/_sliced_to_array.js */ \"./node_modules/@swc/helpers/lib/_sliced_to_array.js\")[\"default\"]);\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nvar _s = $RefreshSig$();\n\"client\";\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.handleClientScriptLoad = handleClientScriptLoad;\nexports.initScriptLoader = initScriptLoader;\nexports[\"default\"] = void 0;\nvar _extends = (__webpack_require__(/*! @swc/helpers/lib/_extends.js */ \"./node_modules/@swc/helpers/lib/_extends.js\")[\"default\"]);\nvar _interop_require_wildcard = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_wildcard.js */ \"./node_modules/@swc/helpers/lib/_interop_require_wildcard.js\")[\"default\"]);\nvar _object_without_properties_loose = (__webpack_require__(/*! @swc/helpers/lib/_object_without_properties_loose.js */ \"./node_modules/@swc/helpers/lib/_object_without_properties_loose.js\")[\"default\"]);\nvar _react = _interop_require_wildcard(__webpack_require__(/*! react */ \"./node_modules/react/index.js\"));\nvar _headManagerContext = __webpack_require__(/*! ../shared/lib/head-manager-context */ \"./node_modules/next/dist/shared/lib/head-manager-context.js\");\nvar _headManager = __webpack_require__(/*! ./head-manager */ \"./node_modules/next/dist/client/head-manager.js\");\nvar _requestIdleCallback = __webpack_require__(/*! ./request-idle-callback */ \"./node_modules/next/dist/client/request-idle-callback.js\");\n\"client\";\nvar ScriptCache = new Map();\nvar LoadCache = new Set();\nvar ignoreProps = [\n \"onLoad\",\n \"onReady\",\n \"dangerouslySetInnerHTML\",\n \"children\",\n \"onError\",\n \"strategy\", \n];\nvar loadScript = function(props) {\n var src = props.src, id = props.id, _onLoad = props.onLoad, onLoad = _onLoad === void 0 ? function() {} : _onLoad, _onReady = props.onReady, onReady = _onReady === void 0 ? null : _onReady, dangerouslySetInnerHTML = props.dangerouslySetInnerHTML, _children = props.children, children = _children === void 0 ? \"\" : _children, _strategy = props.strategy, strategy = _strategy === void 0 ? \"afterInteractive\" : _strategy, onError = props.onError;\n var cacheKey = id || src;\n // Script has already loaded\n if (cacheKey && LoadCache.has(cacheKey)) {\n return;\n }\n // Contents of this script are already loading/loaded\n if (ScriptCache.has(src)) {\n LoadCache.add(cacheKey);\n // It is possible that multiple `next/script` components all have same \"src\", but has different \"onLoad\"\n // This is to make sure the same remote script will only load once, but \"onLoad\" are executed in order\n ScriptCache.get(src).then(onLoad, onError);\n return;\n }\n /** Execute after the script first loaded */ var afterLoad = function() {\n // Run onReady for the first time after load event\n if (onReady) {\n onReady();\n }\n // add cacheKey to LoadCache when load successfully\n LoadCache.add(cacheKey);\n };\n var el = document.createElement(\"script\");\n var loadPromise = new Promise(function(resolve, reject) {\n el.addEventListener(\"load\", function(e) {\n resolve();\n if (onLoad) {\n onLoad.call(this, e);\n }\n afterLoad();\n });\n el.addEventListener(\"error\", function(e) {\n reject(e);\n });\n }).catch(function(e) {\n if (onError) {\n onError(e);\n }\n });\n if (dangerouslySetInnerHTML) {\n el.innerHTML = dangerouslySetInnerHTML.__html || \"\";\n afterLoad();\n } else if (children) {\n el.textContent = typeof children === \"string\" ? children : Array.isArray(children) ? children.join(\"\") : \"\";\n afterLoad();\n } else if (src) {\n el.src = src;\n // do not add cacheKey into LoadCache for remote script here\n // cacheKey will be added to LoadCache when it is actually loaded (see loadPromise above)\n ScriptCache.set(src, loadPromise);\n }\n var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;\n try {\n for(var _iterator = Object.entries(props)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){\n var _value = _slicedToArray(_step.value, 2), k = _value[0], value = _value[1];\n if (value === undefined || ignoreProps.includes(k)) {\n continue;\n }\n var attr = _headManager.DOMAttributeNames[k] || k.toLowerCase();\n el.setAttribute(attr, value);\n }\n } catch (err) {\n _didIteratorError = true;\n _iteratorError = err;\n } finally{\n try {\n if (!_iteratorNormalCompletion && _iterator.return != null) {\n _iterator.return();\n }\n } finally{\n if (_didIteratorError) {\n throw _iteratorError;\n }\n }\n }\n if (strategy === \"worker\") {\n el.setAttribute(\"type\", \"text/partytown\");\n }\n el.setAttribute(\"data-nscript\", strategy);\n document.body.appendChild(el);\n};\nfunction handleClientScriptLoad(props) {\n var _strategy = props.strategy, strategy = _strategy === void 0 ? \"afterInteractive\" : _strategy;\n if (strategy === \"lazyOnload\") {\n window.addEventListener(\"load\", function() {\n (0, _requestIdleCallback).requestIdleCallback(function() {\n return loadScript(props);\n });\n });\n } else {\n loadScript(props);\n }\n}\nfunction loadLazyScript(props) {\n if (document.readyState === \"complete\") {\n (0, _requestIdleCallback).requestIdleCallback(function() {\n return loadScript(props);\n });\n } else {\n window.addEventListener(\"load\", function() {\n (0, _requestIdleCallback).requestIdleCallback(function() {\n return loadScript(props);\n });\n });\n }\n}\nfunction addBeforeInteractiveToCache() {\n var scripts = _toConsumableArray(document.querySelectorAll('[data-nscript=\"beforeInteractive\"]')).concat(_toConsumableArray(document.querySelectorAll('[data-nscript=\"beforePageRender\"]')));\n scripts.forEach(function(script) {\n var cacheKey = script.id || script.getAttribute(\"src\");\n LoadCache.add(cacheKey);\n });\n}\nfunction initScriptLoader(scriptLoaderItems) {\n scriptLoaderItems.forEach(handleClientScriptLoad);\n addBeforeInteractiveToCache();\n}\nfunction Script(props) {\n _s();\n var id = props.id, _src = props.src, src = _src === void 0 ? \"\" : _src, _onLoad = props.onLoad, onLoad = _onLoad === void 0 ? function() {} : _onLoad, _onReady = props.onReady, onReady = _onReady === void 0 ? null : _onReady, _strategy = props.strategy, strategy = _strategy === void 0 ? \"afterInteractive\" : _strategy, onError = props.onError, restProps = _object_without_properties_loose(props, [\n \"id\",\n \"src\",\n \"onLoad\",\n \"onReady\",\n \"strategy\",\n \"onError\"\n ]);\n // Context is available only during SSR\n var ref = (0, _react).useContext(_headManagerContext.HeadManagerContext), updateScripts = ref.updateScripts, scripts = ref.scripts, getIsSsr = ref.getIsSsr;\n /**\n * - First mount:\n * 1. The useEffect for onReady executes\n * 2. hasOnReadyEffectCalled.current is false, but the script hasn't loaded yet (not in LoadCache)\n * onReady is skipped, set hasOnReadyEffectCalled.current to true\n * 3. The useEffect for loadScript executes\n * 4. hasLoadScriptEffectCalled.current is false, loadScript executes\n * Once the script is loaded, the onLoad and onReady will be called by then\n * [If strict mode is enabled / is wrapped in component]\n * 5. The useEffect for onReady executes again\n * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped\n * 7. The useEffect for loadScript executes again\n * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped\n *\n * - Second mount:\n * 1. The useEffect for onReady executes\n * 2. hasOnReadyEffectCalled.current is false, but the script has already loaded (found in LoadCache)\n * onReady is called, set hasOnReadyEffectCalled.current to true\n * 3. The useEffect for loadScript executes\n * 4. The script is already loaded, loadScript bails out\n * [If strict mode is enabled / is wrapped in component]\n * 5. The useEffect for onReady executes again\n * 6. hasOnReadyEffectCalled.current is true, so entire effect is skipped\n * 7. The useEffect for loadScript executes again\n * 8. hasLoadScriptEffectCalled.current is true, so entire effect is skipped\n */ var hasOnReadyEffectCalled = (0, _react).useRef(false);\n (0, _react).useEffect(function() {\n var cacheKey = id || src;\n if (!hasOnReadyEffectCalled.current) {\n // Run onReady if script has loaded before but component is re-mounted\n if (onReady && cacheKey && LoadCache.has(cacheKey)) {\n onReady();\n }\n hasOnReadyEffectCalled.current = true;\n }\n }, [\n onReady,\n id,\n src\n ]);\n var hasLoadScriptEffectCalled = (0, _react).useRef(false);\n (0, _react).useEffect(function() {\n if (!hasLoadScriptEffectCalled.current) {\n if (strategy === \"afterInteractive\") {\n loadScript(props);\n } else if (strategy === \"lazyOnload\") {\n loadLazyScript(props);\n }\n hasLoadScriptEffectCalled.current = true;\n }\n }, [\n props,\n strategy\n ]);\n if (strategy === \"beforeInteractive\" || strategy === \"worker\") {\n if (updateScripts) {\n scripts[strategy] = (scripts[strategy] || []).concat([\n _extends({\n id: id,\n src: src,\n onLoad: onLoad,\n onReady: onReady,\n onError: onError\n }, restProps), \n ]);\n updateScripts(scripts);\n } else if (getIsSsr && getIsSsr()) {\n // Script has already loaded during SSR\n LoadCache.add(id || src);\n } else if (getIsSsr && !getIsSsr()) {\n loadScript(props);\n }\n }\n return null;\n}\n_s(Script, \"kiDojfm/3Ev+ZrEJMYf7ieqO4Lc=\");\n_c = Script;\nObject.defineProperty(Script, \"__nextScript\", {\n value: true\n});\nvar _default = Script;\nexports[\"default\"] = _default;\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=script.js.map\nvar _c;\n$RefreshReg$(_c, \"Script\");\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC9zY3JpcHQuanMuanMiLCJtYXBwaW5ncyI6IkFBQ2E7Ozs7Ozs7QUFEYixRQUFRLENBQUM7QUFFVEEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCw4QkFBOEIsR0FBR0Usc0JBQXNCLENBQUM7QUFDeERGLHdCQUF3QixHQUFHRyxnQkFBZ0IsQ0FBQztBQUM1Q0gsa0JBQWUsR0FBRyxLQUFLLENBQUMsQ0FBQztBQUN6QixJQUFJSyxRQUFRLEdBQUdDLG1IQUErQztBQUM5RCxJQUFJQyx5QkFBeUIsR0FBR0QscUpBQWdFO0FBQ2hHLElBQUlFLGdDQUFnQyxHQUFHRixtS0FBdUU7QUFDOUcsSUFBSUcsTUFBTSxHQUFHRix5QkFBeUIsQ0FBQ0QsbUJBQU8sQ0FBQyw0Q0FBTyxDQUFDLENBQUM7QUFDeEQsSUFBSUksbUJBQW1CLEdBQUdKLG1CQUFPLENBQUMsdUdBQW9DLENBQUM7QUFDdkUsSUFBSUssWUFBWSxHQUFHTCxtQkFBTyxDQUFDLHVFQUFnQixDQUFDO0FBQzVDLElBQUlNLG9CQUFvQixHQUFHTixtQkFBTyxDQUFDLHlGQUF5QixDQUFDO0FBQzdELFFBQVEsQ0FBQztBQUNULElBQU1PLFdBQVcsR0FBRyxJQUFJQyxHQUFHLEVBQUU7QUFDN0IsSUFBTUMsU0FBUyxHQUFHLElBQUlDLEdBQUcsRUFBRTtBQUMzQixJQUFNQyxXQUFXLE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4gb25SZWFkeSBmb3IgdGhlIGZpcnN0IHRpbWUgYWZ0ZXIgbG9hZCBldmVudFxuICAgICAgICBpZiAob25SZWFkeSkge1xuICAgICAgICAgICAgb25SZWFkeSgpO1xuICAgICAgICB9XG4gICAgICAgIC8vIGFkZCBjYWNoZUtleSB0byBMb2FkQ2FjaGUgd2hlbiBsb2FkIHN1Y2Nlc3NmdWxseVxuICAgICAgICBMb2FkQ2FjaGUuYWRkKGNhY2hlS2V5KTtcbiAgICB9O1xuICAgIGNvbnN0IGVsID0gZG9jdW1lbnQuY3JlYXRlRWxlbWVudCgnc2NyaXB0Jyk7XG4gICAgY29uc3QgbG9hZFByb21pc2UgPSBuZXcgUHJvbWlzZSgocmVzb2x2ZSwgcmVqZWN0KT0+e1xuICAgICAgICBlbC5hZGRFdmVudExpc3RlbmVyKCdsb2FkJywgZnVuY3Rpb24oZSkge1xuICAgICAgICAgICAgcmVzb2x2ZSgpO1xuICAgICAgICAgICAgaWYgKG9uTG9hZCkge1xuICAgICAgICAgICAgICAgIG9uTG9hZC5jYWxsKHRoaXMsIGUpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgYWZ0ZXJMb2FkKCk7XG4gICAgICAgIH0pO1xuICAgICAgICBlbC5hZGRFdmVudExpc3RlbmVyKCdlcnJvcicsIGZ1bmN0aW9uKGUpIHtcbiAgICAgICAgICAgIHJlamVjdChlKTtcbiAgICAgICAgfSk7XG4gICAgfSkuY2F0Y2goZnVuY3Rpb24oZSkge1xuICAgICAgICBpZiAob25FcnJvcikge1xuICAgICAgICAgICAgb25FcnJvcihlKTtcbiAgICAgICAgfVxuICAgIH0pO1xuICAgIGlmIChkYW5nZXJvdXNseVNldElubmVySFRNTCkge1xuICAgICAgICBlbC5pbm5lckhUTUwgPSBkYW5nZXJvdXNseVNldElubmVySFRNTC5fX2h0bWwgfHwgJyc7XG4gICAgICAgIGFmdGVyTG9hZCgpO1xuICAgIH0gZWxzZSBpZiAoY2hpbGRyZW4pIHtcbi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bGVkLmN1cnJlbnQgPSB0cnVlO1xuICAgICAgICB9XG4gICAgfSwgW1xuICAgICAgICBwcm9wcyxcbiAgICAgICAgc3RyYXRlZ3lcbiAgICBdKTtcbiAgICBpZiAoc3RyYXRlZ3kgPT09ICdiZWZvcmVJbnRlcmFjdGl2ZScgfHwgc3RyYXRlZ3kgPT09ICd3b3JrZXInKSB7XG4gICAgICAgIGlmICh1cGRhdGVTY3JpcHRzKSB7XG4gICAgICAgICAgICBzY3JpcHRzW3N0cmF0ZWd5XSA9IChzY3JpcHRzW3N0cmF0ZWd5XSB8fCBbXSkuY29uY2F0KFtcbiAgICAgICAgICAgICAgICBfZXh0ZW5kcyh7XG4gICAgICAgICAgICAgICAgICAgIGlkLFxuICAgICAgICAgICAgICAgICAgICBzcmMsXG4gICAgICAgICAgICAgICAgICAgIG9uTG9hZCxcbiAgICAgICAgICAgICAgICAgICAgb25SZWFkeSxcbiAgICAgICAgICAgICAgICAgICAgb25FcnJvclxuICAgICAgICAgICAgICAgIH0sIHJlc3RQcm9wcyksIFxuICAgICAgICAgICAgXSk7XG4gICAgICAgICAgICB1cGRhdGVTY3JpcHRzKHNjcmlwdHMpO1xuICAgICAgICB9IGVsc2UgaWYgKGdldElzU3NyICYmIGdldElzU3NyKCkpIHtcbiAgICAgICAgICAgIC8vIFNjcmlwdCBoYXMgYWxyZWFkeSBsb2FkZWQgZHVyaW5nIFNTUlxuICAgICAgICAgICAgTG9hZENhY2hlLmFkZChpZCB8fCBzcmMpO1xuICAgICAgICB9IGVsc2UgaWYgKGdldElzU3NyICYmICFnZXRJc1NzcigpKSB7XG4gICAgICAgICAgICBsb2FkU2NyaXB0KHByb3BzKTtcbiAgICAgICAgfVxuICAgIH1cbiAgICByZXR1cm4gbnVsbDtcbn1cbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShTY3JpcHQsICdfX25leHRTY3JpcHQnLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xudmFyIF9kZWZhdWx0ID0gU2Ny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aGlsZHJlbiIsInN0cmF0ZWd5Iiwib25FcnJvciIsImNhY2hlS2V5IiwiaGFzIiwiYWRkIiwiZ2V0IiwidGhlbiIsImFmdGVyTG9hZCIsImVsIiwiZG9jdW1lbnQiLCJjcmVhdGVFbGVtZW50IiwibG9hZFByb21pc2UiLCJQcm9taXNlIiwicmVzb2x2ZSIsInJlamVjdCIsImFkZEV2ZW50TGlzdGVuZXIiLCJlIiwiY2FsbCIsImNhdGNoIiwiaW5uZXJIVE1MIiwiX19odG1sIiwidGV4dENvbnRlbnQiLCJBcnJheSIsImlzQXJyYXkiLCJqb2luIiwic2V0IiwiZW50cmllcyIsImsiLCJ1bmRlZmluZWQiLCJpbmNsdWRlcyIsImF0dHIiLCJET01BdHRyaWJ1dGVOYW1lcyIsInRvTG93ZXJDYXNlIiwic2V0QXR0cmlidXRlIiwiYm9keSIsImFwcGVuZENoaWxkIiwid2luZG93IiwicmVxdWVzdElkbGVDYWxsYmFjayIsImxvYWRMYXp5U2NyaXB0IiwicmVhZHlTdGF0ZSIsImFkZEJlZm9yZUludGVyYWN0aXZlVG9DYWNoZSIsInNjcmlwdHMiLCJxdWVyeVNlbGVjdG9yQWxsIiwiZm9yRWFjaCIsInNjcmlwdCIsImdldEF0dHJpYnV0ZSIsInNjcmlwdExvYWRlckl0ZW1zIiwiU2NyaXB0IiwicmVzdFByb3BzIiwidXNlQ29udGV4dCIsIkhlYWRNYW5hZ2VyQ29udGV4dCIsInVwZGF0ZVNjcmlwdHMiLCJnZXRJc1NzciIsImhhc09uUmVhZHlFZmZlY3RDYWxsZWQiLCJ1c2VSZWYiLCJ1c2VFZmZlY3QiLCJjdXJyZW50IiwiaGFzTG9hZFNjcmlwdEVmZmVjdENhbGxlZCIsImNvbmNhdCIsIl9kZWZhdWx0IiwiX19lc01vZHVsZSIsImFzc2lnbiIsIm1vZHVsZSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/script.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/trusted-types.js": +/*!********************************************************!*\ + !*** ./node_modules/next/dist/client/trusted-types.js ***! + \********************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.__unsafeCreateTrustedScriptURL = __unsafeCreateTrustedScriptURL;\n/**\n * Stores the Trusted Types Policy. Starts as undefined and can be set to null\n * if Trusted Types is not supported in the browser.\n */ var policy;\n/**\n * Getter for the Trusted Types Policy. If it is undefined, it is instantiated\n * here or set to null if Trusted Types is not supported in the browser.\n */ function getPolicy() {\n if (typeof policy === \"undefined\" && \"object\" !== \"undefined\") {\n var ref;\n policy = ((ref = window.trustedTypes) == null ? void 0 : ref.createPolicy(\"nextjs\", {\n createHTML: function(input) {\n return input;\n },\n createScript: function(input) {\n return input;\n },\n createScriptURL: function(input) {\n return input;\n }\n })) || null;\n }\n return policy;\n}\nfunction __unsafeCreateTrustedScriptURL(url) {\n var ref;\n return ((ref = getPolicy()) == null ? void 0 : ref.createScriptURL(url)) || url;\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=trusted-types.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC90cnVzdGVkLXR5cGVzLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsc0NBQXNDLEdBQUdFLDhCQUE4QixDQUFDO0FBQ3hFOzs7Q0FHQyxHQUFHLElBQUlDLE1BQU07QUFDZDs7O0NBR0MsR0FBRyxTQ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gfSk7XG4gIE9iamVjdC5hc3NpZ24oZXhwb3J0cy5kZWZhdWx0LCBleHBvcnRzKTtcbiAgbW9kdWxlLmV4cG9ydHMgPSBleHBvcnRzLmRlZmF1bHQ7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPXRydXN0ZWQtdHlwZXMuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiX191bnNhZmVDcmVhdGVUcnVzdGVkU2NyaXB0VVJMIiwicG9saWN5IiwiZ2V0UG9saWN5IiwicmVmIiwid2luZG93IiwidHJ1c3RlZFR5cGVzIiwiY3JlYXRlUG9saWN5IiwiY3JlYXRlSFRNTCIsImlucHV0IiwiY3JlYXRlU2NyaXB0IiwiY3JlYXRlU2NyaXB0VVJMIiwidXJsIiwiZGVmYXVsdCIsIl9fZXNNb2R1bGUiLCJhc3NpZ24iLCJtb2R1bGUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/trusted-types.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/client/with-router.js": +/*!******************************************************!*\ + !*** ./node_modules/next/dist/client/with-router.js ***! + \******************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = withRouter;\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _react = _interop_require_default(__webpack_require__(/*! react */ \"./node_modules/react/index.js\"));\nvar _router = __webpack_require__(/*! ./router */ \"./node_modules/next/dist/client/router.js\");\nfunction withRouter(ComposedComponent) {\n var WithRouterWrapper = function WithRouterWrapper(props) {\n _s();\n return /*#__PURE__*/ _react.default.createElement(ComposedComponent, Object.assign({\n router: (0, _router).useRouter()\n }, props));\n };\n var _s = $RefreshSig$();\n _s(WithRouterWrapper, \"CeygcqajjFExIxFEzW4x/gfWEGQ=\");\n WithRouterWrapper.getInitialProps = ComposedComponent.getInitialProps;\n WithRouterWrapper.origGetInitialProps = ComposedComponent.origGetInitialProps;\n if (true) {\n var name = ComposedComponent.displayName || ComposedComponent.name || \"Unknown\";\n WithRouterWrapper.displayName = \"withRouter(\".concat(name, \")\");\n }\n return WithRouterWrapper;\n}\nif ((typeof exports.default === \"function\" || typeof exports.default === \"object\" && exports.default !== null) && typeof exports.default.__esModule === \"undefined\") {\n Object.defineProperty(exports.default, \"__esModule\", {\n value: true\n });\n Object.assign(exports.default, exports);\n module.exports = exports.default;\n} //# sourceMappingURL=with-router.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NsaWVudC93aXRoLXJvdXRlci5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELGtCQUFlLEdBQUdHLFVBQVUsQ0FBQztBQUM3QixJQUFJQyx3QkFBd0IsR0FBR0MsbUpBQStEO0FBQzlGLElBQUlDLE1BQU0sR0FBR0Ysd0JBQXdCLENBQUNDLG1CQUFPLENBQUMsNENBQU8sQ0FBQyxDQUFDO0FBQ3ZELElBQUlFLE9BQU8sR0FBR0YsbUJBQU8sQ0FBQywyREFBVSxDQUFDO0FBQ2pDLFNBQVNGLFVBQVUsQ0FBQ0ssaUJBQWlCLEVBQUU7UUFDMUJDLGlCQUFpQixHQUExQixTQUFTQSxpQkFBaUIsQ0FBQ0MsS0FBSyxFQUFFOztRQUM5QixPQUFPLFdBQVcsR0FBR0osTUFBTSxDQUFDSixPQUFPLENBQUNTLGFBQWEsQ0FBQ0gsaUJBQWlCLEVBQUVWLE1BQU0sQ0FBQ2MsTUFBTSxDQUFDO1lB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ZV9kZWZhdWx0IiwicmVxdWlyZSIsIl9yZWFjdCIsIl9yb3V0ZXIiLCJDb21wb3NlZENvbXBvbmVudCIsIldpdGhSb3V0ZXJXcmFwcGVyIiwicHJvcHMiLCJjcmVhdGVFbGVtZW50IiwiYXNzaWduIiwicm91dGVyIiwidXNlUm91dGVyIiwiZ2V0SW5pdGlhbFByb3BzIiwib3JpZ0dldEluaXRpYWxQcm9wcyIsInByb2Nlc3MiLCJuYW1lIiwiZGlzcGxheU5hbWUiLCJfX2VzTW9kdWxlIiwibW9kdWxlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/client/with-router.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/escape-regexp.js": +/*!************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/escape-regexp.js ***! + \************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.escapeStringRegexp = escapeStringRegexp;\n// regexp is based on https://github.com/sindresorhus/escape-string-regexp\nvar reHasRegExp = /[|\\\\{}()[\\]^$+*?.-]/;\nvar reReplaceRegExp = /[|\\\\{}()[\\]^$+*?.-]/g;\nfunction escapeStringRegexp(str) {\n // see also: https://github.com/lodash/lodash/blob/2da024c3b4f9947a48517639de7560457cd4ec6c/escapeRegExp.js#L23\n if (reHasRegExp.test(str)) {\n return str.replace(reReplaceRegExp, \"\\\\$&\");\n }\n return str;\n} //# sourceMappingURL=escape-regexp.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvZXNjYXBlLXJlZ2V4cC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO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XRodWIuY29tL2xvZGFzaC9sb2Rhc2gvYmxvYi8yZGEwMjRjM2I0Zjk5NDdhNDg1MTc2MzlkZTc1NjA0NTdjZDRlYzZjL2VzY2FwZVJlZ0V4cC5qcyNMMjNcbiAgICBpZiAocmVIYXNSZWdFeHAudGVzdChzdHIpKSB7XG4gICAgICAgIHJldHVybiBzdHIucmVwbGFjZShyZVJlcGxhY2VSZWdFeHAsICdcXFxcJCYnKTtcbiAgICB9XG4gICAgcmV0dXJuIHN0cjtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9ZXNjYXBlLXJlZ2V4cC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJlc2NhcGVTdHJpbmdSZWdleHAiLCJyZUhhc1JlZ0V4cCIsInJlUmVwbGFjZVJlZ0V4cCIsInN0ciIsInRlc3QiLCJyZXBsYWNlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/escape-regexp.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/head-manager-context.js": +/*!*******************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/head-manager-context.js ***! + \*******************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.HeadManagerContext = void 0;\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _react = _interop_require_default(__webpack_require__(/*! react */ \"./node_modules/react/index.js\"));\nvar HeadManagerContext = _react.default.createContext({});\nexports.HeadManagerContext = HeadManagerContext;\nif (true) {\n HeadManagerContext.displayName = \"HeadManagerContext\";\n} //# sourceMappingURL=head-manager-context.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9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1xudmFyIF9yZWFjdCA9IF9pbnRlcm9wX3JlcXVpcmVfZGVmYXVsdChyZXF1aXJlKFwicmVhY3RcIikpO1xuY29uc3QgSGVhZE1hbmFnZXJDb250ZXh0ID0gX3JlYWN0LmRlZmF1bHQuY3JlYXRlQ29udGV4dCh7fSk7XG5leHBvcnRzLkhlYWRNYW5hZ2VyQ29udGV4dCA9IEhlYWRNYW5hZ2VyQ29udGV4dDtcbmlmIChwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ3Byb2R1Y3Rpb24nKSB7XG4gICAgSGVhZE1hbmFnZXJDb250ZXh0LmRpc3BsYXlOYW1lID0gJ0hlYWRNYW5hZ2VyQ29udGV4dCc7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPWhlYWQtbWFuYWdlci1jb250ZXh0LmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsIkhlYWRNYW5hZ2VyQ29udGV4dCIsIl9pbnRlcm9wX3JlcXVpcmVfZGVmYXVsdCIsInJlcXVpcmUiLCJkZWZhdWx0IiwiX3JlYWN0IiwiY3JlYXRlQ29udGV4dCIsInByb2Nlc3MiLCJkaXNwbGF5TmFtZSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/head-manager-context.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js": +/*!*************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js ***! + \*************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.normalizeLocalePath = normalizeLocalePath;\nfunction normalizeLocalePath(pathname, locales) {\n var detectedLocale;\n // first item will be empty string from splitting at first char\n var pathnameParts = pathname.split(\"/\");\n (locales || []).some(function(locale) {\n if (pathnameParts[1] && pathnameParts[1].toLowerCase() === locale.toLowerCase()) {\n detectedLocale = locale;\n pathnameParts.splice(1, 1);\n pathname = pathnameParts.join(\"/\") || \"/\";\n return true;\n }\n return false;\n });\n return {\n pathname: pathname,\n detectedLocale: detectedLocale\n };\n} //# sourceMappingURL=normalize-locale-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvaTE4bi9ub3JtYWxpemUtbG9jYWxlLXBhdGguanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCwyQkFBMkIsR0FBR0UsbUJBQW1CLENBQUM7QUFDbEQsU0FBU0EsbUJBQW1CLENBQUNDLFFBQVEsRUFBRUMsT0FBTyxFQUFFO0lBQzVDLElBQUlDLGNBQWM7SUFDbEIsK0RBQStEO0lBQy9ELElBQU1DLGFBQWEsR0FBR0gsUUFBUSxDQUFDSSxLQUFLLENBQUMsR0FBRyxDQUFDO0lBQ3hDSCxDQUFBQSxPQUFPLElBQUksRUFBRSxFQUFFSSxJQUFJLENBQUMsU0FBQ0MsTUFBTSxFQUFHO1FBQzNCLElBQUlILGFBQWEsQ0FBQyxDQUFDLENBQUMsSUFBSUEsYUFBYSxDQUFDLENBQUMsQ0FBQyxDQUFDSSxXQUFXLEVBQUUsS0FBS0QsTUFBTSxDQUFDQyxXQUFXLEVBQUUsRUFBRTtZQUM3RUwsY0FBYyxHQUFHSSxNQUFNLENBQUM7WUFDeEJILGFBQWEsQ0FBQ0ssTUFBTSxDQUFDLENBQUMsRUFBRSxDQUFDLENBQUMsQ0FBQztZQUMzQlIsUUFBUSxHQUFHRyxhQUFhLENBQUNNLElBQUksQ0FBQyxHQUFHLENBQUMsSUFBSSxHQUFHLENBQUM7WUFDMUM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VBhcnRzLnNwbGljZSgxLCAxKTtcbiAgICAgICAgICAgIHBhdGhuYW1lID0gcGF0aG5hbWVQYXJ0cy5qb2luKCcvJykgfHwgJy8nO1xuICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgIH0pO1xuICAgIHJldHVybiB7XG4gICAgICAgIHBhdGhuYW1lLFxuICAgICAgICBkZXRlY3RlZExvY2FsZVxuICAgIH07XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPW5vcm1hbGl6ZS1sb2NhbGUtcGF0aC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJub3JtYWxpemVMb2NhbGVQYXRoIiwicGF0aG5hbWUiLCJsb2NhbGVzIiwiZGV0ZWN0ZWRMb2NhbGUiLCJwYXRobmFtZVBhcnRzIiwic3BsaXQiLCJzb21lIiwibG9jYWxlIiwidG9Mb3dlckNhc2UiLCJzcGxpY2UiLCJqb2luIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/is-plain-object.js": +/*!**************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/is-plain-object.js ***! + \**************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.getObjectClassLabel = getObjectClassLabel;\nexports.isPlainObject = isPlainObject;\nfunction getObjectClassLabel(value) {\n return Object.prototype.toString.call(value);\n}\nfunction isPlainObject(value) {\n if (getObjectClassLabel(value) !== \"[object Object]\") {\n return false;\n }\n var prototype = Object.getPrototypeOf(value);\n /**\n * this used to be previously:\n *\n * `return prototype === null || prototype === Object.prototype`\n *\n * but Edge Runtime expose Object from vm, being that kind of type-checking wrongly fail.\n *\n * It was changed to the current implementation since it's resilient to serialization.\n */ return prototype === null || prototype.hasOwnProperty(\"isPrototypeOf\");\n} //# sourceMappingURL=is-plain-object.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvaXMtcGxhaW4tb2JqZWN0LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsMkJBQTJCLEdBQUdFLG1CQUFtQixDQUFDO0FBQ2xERixxQkFBcUIsR0FBR0csYUFBYSxDQUFDO0FBQ3RDLFNBQVNELG1CQUFtQixDQUFDRCxLQUFLLEVBQUU7SUFDaEMsT0FBT0gsTUFBTSxDQUFDTSxTQUFTLENBQUNDLFFBQVEsQ0FBQ0MsSUFBSSxDQUFDTCxLQUFLLENBQUMsQ0FBQztBQUNqRCxDQUFDO0FBQ0QsU0FBU0UsYUFBYSxDQUFDRixLQUFLLEVBQUU7SUFDMUIsSUFBSUMsbUJBQW1CLENBQUNELEtBQUssQ0FBQyxLQUFLLGlCQUFpQixFQUFFO1FBQ2xELE9BQU8sS0FBSyxDQUFDO0lBQ2pCLENBQUM7SUFDRCxJQUFNRyxTQUFTLEdBQUdOLE1BQU0sQ0FBQ1MsY0FBYyxDQUFDTixLQUFLLENBQUM7SUFDOUM7Ozs7Ozs7O0dBUUQsR0FBRyxPQUFPRyxTQUFTLEtBQUssSUFBSSxJQUFJQSxTQUFTLENBQUNJLGNBQWMsQ0FBQyxlQUFlLENBQUMsQ0FBQztBQUM3RSxDQUFDLENBRUQsMkNBQTJDIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9uZXh0L2Rpc3Qvc2hhcmVkL2xpYi9pcy1wbGFpbi1vYmpl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A9PT0gbnVsbCB8fCBwcm90b3R5cGUuaGFzT3duUHJvcGVydHkoJ2lzUHJvdG90eXBlT2YnKTtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9aXMtcGxhaW4tb2JqZWN0LmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsImdldE9iamVjdENsYXNzTGFiZWwiLCJpc1BsYWluT2JqZWN0IiwicHJvdG90eXBlIiwidG9TdHJpbmciLCJjYWxsIiwiZ2V0UHJvdG90eXBlT2YiLCJoYXNPd25Qcm9wZXJ0eSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/is-plain-object.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/mitt.js": +/*!***************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/mitt.js ***! + \***************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = mitt;\nfunction mitt() {\n var all = Object.create(null);\n return {\n on: function on(type, handler) {\n (all[type] || (all[type] = [])).push(handler);\n },\n off: function off(type, handler) {\n if (all[type]) {\n all[type].splice(all[type].indexOf(handler) >>> 0, 1);\n }\n },\n emit: function emit(type) {\n for(var _len = arguments.length, evts = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++){\n evts[_key - 1] = arguments[_key];\n }\n (all[type] || []).slice().map(function(handler) {\n handler.apply(void 0, _toConsumableArray(evts));\n });\n }\n };\n} //# sourceMappingURL=mitt.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2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dKSB7XG4gICAgICAgICAgICAgICAgYWxsW3R5cGVdLnNwbGljZShhbGxbdHlwZV0uaW5kZXhPZihoYW5kbGVyKSA+Pj4gMCwgMSk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sXG4gICAgICAgIGVtaXQgKHR5cGUsIC4uLmV2dHMpIHtcbiAgICAgICAgICAgIChhbGxbdHlwZV0gfHwgW10pLnNsaWNlKCkubWFwKChoYW5kbGVyKT0+e1xuICAgICAgICAgICAgICAgIGhhbmRsZXIoLi4uZXZ0cyk7XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgIH07XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPW1pdHQuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiZGVmYXVsdCIsIm1pdHQiLCJhbGwiLCJjcmVhdGUiLCJvbiIsInR5cGUiLCJoYW5kbGVyIiwicHVzaCIsIm9mZiIsInNwbGljZSIsImluZGV4T2YiLCJlbWl0IiwiZXZ0cyIsInNsaWNlIiwibWFwIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/mitt.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js": +/*!******************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js ***! + \******************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.denormalizePagePath = denormalizePagePath;\nvar _utils = __webpack_require__(/*! ../router/utils */ \"./node_modules/next/dist/shared/lib/router/utils/index.js\");\nvar _normalizePathSep = __webpack_require__(/*! ./normalize-path-sep */ \"./node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js\");\nfunction denormalizePagePath(page) {\n var _page = (0, _normalizePathSep).normalizePathSep(page);\n return _page.startsWith(\"/index/\") && !(0, _utils).isDynamicRoute(_page) ? _page.slice(6) : _page !== \"/index\" ? _page : \"/\";\n} //# sourceMappingURL=denormalize-page-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcGFnZS1wYXRoL2Rlbm9ybWFsaXplLXBhZ2UtcGF0aC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELDJCQUEyQixHQUFHRSxtQkFBbUIsQ0FBQztBQUNsRCxJQUFJQyxNQUFNLEdBQUdDLG1CQUFPLENBQUMsa0ZBQWlCLENBQUM7QUFDdkMsSUFBSUMsaUJBQWlCLEdBQUdELG1CQUFPLENBQUMsaUdBQXNCLENBQUM7QUFDdkQsU0FBU0YsbUJBQW1CLENBQUNJLElBQUksRUFBRTtJQUMvQixJQUFJQyxLQUFLLEdBQUcsQ0FBQyxDQUFDLEVBQUVGLGlCQUFpQixFQUFFRyxnQkFBZ0IsQ0FBQ0YsSUFBSSxDQUFDO0lBQ3pELE9BQU9DLEtBQUssQ0FBQ0UsVUFBVSxDQUFDLFNBQVMsQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLEVBQUVOLE1BQU0sRUFBRU8sY0FBYyxDQUFDSCxLQUFLLENBQUMsR0FBR0EsS0FBSyxDQUFDSSxLQUFLLENBQUMsQ0FBQyxDQUFDLEdBQUdKLEtBQUssS0FBSyxRQUFRLEdBQUdBLEtBQUssR0FBRyxHQUFHLENBQUM7QUFDakksQ0FBQyxDQUVELGlEQUFpRCIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcGFnZS1wYXRoL2Rlbm9ybWFsaXpl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ist/shared/lib/page-path/denormalize-page-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js": +/*!***************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js ***! + \***************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.normalizePathSep = normalizePathSep;\nfunction normalizePathSep(path) {\n return path.replace(/\\\\/g, \"/\");\n} //# sourceMappingURL=normalize-path-sep.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcGFnZS1wYXRoL25vcm1hbGl6ZS1wYXRoLXNlcC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHdCQUF3QixHQUFHRSxnQkFBZ0IsQ0FBQztBQUM1QyxTQUFTQSxnQkFBZ0IsQ0FBQ0MsSUFBSSxFQUFFO0lBQzVCLE9BQU9BLElBQUksQ0FBQ0MsT0FBTyxRQUFRLEdBQUcsQ0FBQyxDQUFDO0FBQ3BDLENBQUMsQ0FFRCw4Q0FBOEMiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL25leHQvZGlzdC9zaGFyZWQvbGliL3BhZ2UtcGF0aC9ub3JtYWxpemUtcGF0aC1zZXAuanM/YmFiOCJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMubm9ybWFsaXplUGF0aFNlcCA9IG5vcm1hbGl6ZVBhdGhTZXA7XG5mdW5jdGlvbiBub3JtYWxpemVQYXRoU2VwKHBhdGgpIHtcbiAgICByZXR1cm4gcGF0aC5yZXBsYWNlKC9cXFxcL2csICcvJyk7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPW5vcm1hbGl6ZS1wYXRoLXNlcC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJub3JtYWxpemVQYXRoU2VwIiwicGF0aCIsInJlcGxhY2UiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router-context.js": +/*!*************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router-context.js ***! + \*************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.RouterContext = void 0;\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _react = _interop_require_default(__webpack_require__(/*! react */ \"./node_modules/react/index.js\"));\nvar RouterContext = _react.default.createContext(null);\nexports.RouterContext = RouterContext;\nif (true) {\n RouterContext.displayName = \"RouterContext\";\n} //# sourceMappingURL=router-context.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyLWNvbnRleHQuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxxQkFBcUIsR0FBRyxLQUFLLENBQUMsQ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dwcm9kdWN0aW9uJykge1xuICAgIFJvdXRlckNvbnRleHQuZGlzcGxheU5hbWUgPSAnUm91dGVyQ29udGV4dCc7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPXJvdXRlci1jb250ZXh0LmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsIlJvdXRlckNvbnRleHQiLCJfaW50ZXJvcF9yZXF1aXJlX2RlZmF1bHQiLCJyZXF1aXJlIiwiZGVmYXVsdCIsIl9yZWFjdCIsImNyZWF0ZUNvbnRleHQiLCJwcm9jZXNzIiwiZGlzcGxheU5hbWUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router-context.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/router.js": +/*!************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/router.js ***! + \************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _classCallCheck = (__webpack_require__(/*! @swc/helpers/lib/_class_call_check.js */ \"./node_modules/@swc/helpers/lib/_class_call_check.js\")[\"default\"]);\nvar _createClass = (__webpack_require__(/*! @swc/helpers/lib/_create_class.js */ \"./node_modules/@swc/helpers/lib/_create_class.js\")[\"default\"]);\nvar _slicedToArray = (__webpack_require__(/*! @swc/helpers/lib/_sliced_to_array.js */ \"./node_modules/@swc/helpers/lib/_sliced_to_array.js\")[\"default\"]);\nvar _tsGenerator = (__webpack_require__(/*! @swc/helpers/lib/_ts_generator.js */ \"./node_modules/@swc/helpers/lib/_ts_generator.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.matchesMiddleware = matchesMiddleware;\nexports.isLocalURL = isLocalURL;\nexports.interpolateAs = interpolateAs;\nexports.resolveHref = resolveHref;\nexports.createKey = createKey;\nexports[\"default\"] = void 0;\nvar _async_to_generator = (__webpack_require__(/*! @swc/helpers/lib/_async_to_generator.js */ \"./node_modules/@swc/helpers/lib/_async_to_generator.js\")[\"default\"]);\nvar _extends = (__webpack_require__(/*! @swc/helpers/lib/_extends.js */ \"./node_modules/@swc/helpers/lib/_extends.js\")[\"default\"]);\nvar _interop_require_default = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_default.js */ \"./node_modules/@swc/helpers/lib/_interop_require_default.js\")[\"default\"]);\nvar _interop_require_wildcard = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_wildcard.js */ \"./node_modules/@swc/helpers/lib/_interop_require_wildcard.js\")[\"default\"]);\nvar _normalizeTrailingSlash = __webpack_require__(/*! ../../../client/normalize-trailing-slash */ \"./node_modules/next/dist/client/normalize-trailing-slash.js\");\nvar _removeTrailingSlash = __webpack_require__(/*! ./utils/remove-trailing-slash */ \"./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js\");\nvar _routeLoader = __webpack_require__(/*! ../../../client/route-loader */ \"./node_modules/next/dist/client/route-loader.js\");\nvar _script = __webpack_require__(/*! ../../../client/script */ \"./node_modules/next/dist/client/script.js\");\nvar _isError = _interop_require_wildcard(__webpack_require__(/*! ../../../lib/is-error */ \"./node_modules/next/dist/lib/is-error.js\"));\nvar _denormalizePagePath = __webpack_require__(/*! ../page-path/denormalize-page-path */ \"./node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js\");\nvar _normalizeLocalePath = __webpack_require__(/*! ../i18n/normalize-locale-path */ \"./node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js\");\nvar _mitt = _interop_require_default(__webpack_require__(/*! ../mitt */ \"./node_modules/next/dist/shared/lib/mitt.js\"));\nvar _utils = __webpack_require__(/*! ../utils */ \"./node_modules/next/dist/shared/lib/utils.js\");\nvar _isDynamic = __webpack_require__(/*! ./utils/is-dynamic */ \"./node_modules/next/dist/shared/lib/router/utils/is-dynamic.js\");\nvar _parseRelativeUrl = __webpack_require__(/*! ./utils/parse-relative-url */ \"./node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js\");\nvar _querystring = __webpack_require__(/*! ./utils/querystring */ \"./node_modules/next/dist/shared/lib/router/utils/querystring.js\");\nvar _resolveRewrites = _interop_require_default(__webpack_require__(/*! ./utils/resolve-rewrites */ \"?506d\"));\nvar _routeMatcher = __webpack_require__(/*! ./utils/route-matcher */ \"./node_modules/next/dist/shared/lib/router/utils/route-matcher.js\");\nvar _routeRegex = __webpack_require__(/*! ./utils/route-regex */ \"./node_modules/next/dist/shared/lib/router/utils/route-regex.js\");\nvar _formatUrl = __webpack_require__(/*! ./utils/format-url */ \"./node_modules/next/dist/shared/lib/router/utils/format-url.js\");\nvar _detectDomainLocale = __webpack_require__(/*! ../../../client/detect-domain-locale */ \"./node_modules/next/dist/client/detect-domain-locale.js\");\nvar _parsePath = __webpack_require__(/*! ./utils/parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nvar _addLocale = __webpack_require__(/*! ../../../client/add-locale */ \"./node_modules/next/dist/client/add-locale.js\");\nvar _removeLocale = __webpack_require__(/*! ../../../client/remove-locale */ \"./node_modules/next/dist/client/remove-locale.js\");\nvar _removeBasePath = __webpack_require__(/*! ../../../client/remove-base-path */ \"./node_modules/next/dist/client/remove-base-path.js\");\nvar _addBasePath = __webpack_require__(/*! ../../../client/add-base-path */ \"./node_modules/next/dist/client/add-base-path.js\");\nvar _hasBasePath = __webpack_require__(/*! ../../../client/has-base-path */ \"./node_modules/next/dist/client/has-base-path.js\");\nvar _getNextPathnameInfo = __webpack_require__(/*! ./utils/get-next-pathname-info */ \"./node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js\");\nvar _formatNextPathnameInfo = __webpack_require__(/*! ./utils/format-next-pathname-info */ \"./node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js\");\nvar _compareStates = __webpack_require__(/*! ./utils/compare-states */ \"./node_modules/next/dist/shared/lib/router/utils/compare-states.js\");\nvar _isBot = __webpack_require__(/*! ./utils/is-bot */ \"./node_modules/next/dist/shared/lib/router/utils/is-bot.js\");\nfunction buildCancellationError() {\n return Object.assign(new Error(\"Route Cancelled\"), {\n cancelled: true\n });\n}\nfunction matchesMiddleware(options) {\n return _matchesMiddleware.apply(this, arguments);\n}\nfunction _matchesMiddleware() {\n _matchesMiddleware = _async_to_generator(function(options) {\n var matchers, ref, asPathname, cleanedAs, asWithBasePathAndLocale;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n return [\n 4,\n Promise.resolve(options.router.pageLoader.getMiddleware())\n ];\n case 1:\n matchers = _state.sent();\n if (!matchers) return [\n 2,\n false\n ];\n ref = (0, _parsePath).parsePath(options.asPath), asPathname = ref.pathname;\n cleanedAs = (0, _hasBasePath).hasBasePath(asPathname) ? (0, _removeBasePath).removeBasePath(asPathname) : asPathname;\n asWithBasePathAndLocale = (0, _addBasePath).addBasePath((0, _addLocale).addLocale(cleanedAs, options.locale));\n // Check only path match on client. Matching \"has\" should be done on server\n // where we can access more info such as headers, HttpOnly cookie, etc.\n return [\n 2,\n matchers.some(function(m) {\n return new RegExp(m.regexp).test(asWithBasePathAndLocale);\n })\n ];\n }\n });\n });\n return _matchesMiddleware.apply(this, arguments);\n}\nfunction stripOrigin(url) {\n var origin = (0, _utils).getLocationOrigin();\n return url.startsWith(origin) ? url.substring(origin.length) : url;\n}\nfunction omit(object, keys) {\n var omitted = {};\n Object.keys(object).forEach(function(key) {\n if (!keys.includes(key)) {\n omitted[key] = object[key];\n }\n });\n return omitted;\n}\nfunction isLocalURL(url) {\n // prevent a hydration mismatch on href for url with anchor refs\n if (!(0, _utils).isAbsoluteUrl(url)) return true;\n try {\n // absolute urls can be local if they are on the same origin\n var locationOrigin = (0, _utils).getLocationOrigin();\n var resolved = new URL(url, locationOrigin);\n return resolved.origin === locationOrigin && (0, _hasBasePath).hasBasePath(resolved.pathname);\n } catch (_) {\n return false;\n }\n}\nfunction interpolateAs(route, asPathname, query) {\n var interpolatedRoute = \"\";\n var dynamicRegex = (0, _routeRegex).getRouteRegex(route);\n var dynamicGroups = dynamicRegex.groups;\n var dynamicMatches = (asPathname !== route ? (0, _routeMatcher).getRouteMatcher(dynamicRegex)(asPathname) : \"\") || // Fall back to reading the values from the href\n // TODO: should this take priority; also need to change in the router.\n query;\n interpolatedRoute = route;\n var params = Object.keys(dynamicGroups);\n if (!params.every(function(param) {\n var value = dynamicMatches[param] || \"\";\n var _param = dynamicGroups[param], repeat = _param.repeat, optional = _param.optional;\n // support single-level catch-all\n // TODO: more robust handling for user-error (passing `/`)\n var replaced = \"[\".concat(repeat ? \"...\" : \"\").concat(param, \"]\");\n if (optional) {\n replaced = \"\".concat(!value ? \"/\" : \"\", \"[\").concat(replaced, \"]\");\n }\n if (repeat && !Array.isArray(value)) value = [\n value\n ];\n return (optional || param in dynamicMatches) && // Interpolate group into data URL if present\n (interpolatedRoute = interpolatedRoute.replace(replaced, repeat ? value.map(// path delimiter escaped since they are being inserted\n // into the URL and we expect URL encoded segments\n // when parsing dynamic route params\n function(segment) {\n return encodeURIComponent(segment);\n }).join(\"/\") : encodeURIComponent(value)) || \"/\");\n })) {\n interpolatedRoute = \"\" // did not satisfy all requirements\n ;\n // n.b. We ignore this error because we handle warning for this case in\n // development in the `` component directly.\n }\n return {\n params: params,\n result: interpolatedRoute\n };\n}\nfunction resolveHref(router, href, resolveAs) {\n // we use a dummy base url for relative urls\n var base;\n var urlAsString = typeof href === \"string\" ? href : (0, _formatUrl).formatWithValidation(href);\n // repeated slashes and backslashes in the URL are considered\n // invalid and will never match a Next.js page/file\n var urlProtoMatch = urlAsString.match(/^[a-zA-Z]{1,}:\\/\\//);\n var urlAsStringNoProto = urlProtoMatch ? urlAsString.slice(urlProtoMatch[0].length) : urlAsString;\n var urlParts = urlAsStringNoProto.split(\"?\");\n if ((urlParts[0] || \"\").match(/(\\/\\/|\\\\)/)) {\n console.error(\"Invalid href passed to next/router: \".concat(urlAsString, \", repeated forward-slashes (//) or backslashes \\\\ are not valid in the href\"));\n var normalizedUrl = (0, _utils).normalizeRepeatedSlashes(urlAsStringNoProto);\n urlAsString = (urlProtoMatch ? urlProtoMatch[0] : \"\") + normalizedUrl;\n }\n // Return because it cannot be routed by the Next.js router\n if (!isLocalURL(urlAsString)) {\n return resolveAs ? [\n urlAsString\n ] : urlAsString;\n }\n try {\n base = new URL(urlAsString.startsWith(\"#\") ? router.asPath : router.pathname, \"http://n\");\n } catch (_) {\n // fallback to / for invalid asPath values e.g. //\n base = new URL(\"/\", \"http://n\");\n }\n try {\n var finalUrl = new URL(urlAsString, base);\n finalUrl.pathname = (0, _normalizeTrailingSlash).normalizePathTrailingSlash(finalUrl.pathname);\n var interpolatedAs = \"\";\n if ((0, _isDynamic).isDynamicRoute(finalUrl.pathname) && finalUrl.searchParams && resolveAs) {\n var query = (0, _querystring).searchParamsToUrlQuery(finalUrl.searchParams);\n var ref = interpolateAs(finalUrl.pathname, finalUrl.pathname, query), result = ref.result, params = ref.params;\n if (result) {\n interpolatedAs = (0, _formatUrl).formatWithValidation({\n pathname: result,\n hash: finalUrl.hash,\n query: omit(query, params)\n });\n }\n }\n // if the origin didn't change, it means we received a relative href\n var resolvedHref = finalUrl.origin === base.origin ? finalUrl.href.slice(finalUrl.origin.length) : finalUrl.href;\n return resolveAs ? [\n resolvedHref,\n interpolatedAs || resolvedHref\n ] : resolvedHref;\n } catch (_1) {\n return resolveAs ? [\n urlAsString\n ] : urlAsString;\n }\n}\nfunction prepareUrlAs(router, url, as) {\n // If url and as provided as an object representation,\n // we'll format them into the string version here.\n var ref = _slicedToArray(resolveHref(router, url, true), 2), resolvedHref = ref[0], resolvedAs = ref[1];\n var origin = (0, _utils).getLocationOrigin();\n var hrefHadOrigin = resolvedHref.startsWith(origin);\n var asHadOrigin = resolvedAs && resolvedAs.startsWith(origin);\n resolvedHref = stripOrigin(resolvedHref);\n resolvedAs = resolvedAs ? stripOrigin(resolvedAs) : resolvedAs;\n var preparedUrl = hrefHadOrigin ? resolvedHref : (0, _addBasePath).addBasePath(resolvedHref);\n var preparedAs = as ? stripOrigin(resolveHref(router, as)) : resolvedAs || resolvedHref;\n return {\n url: preparedUrl,\n as: asHadOrigin ? preparedAs : (0, _addBasePath).addBasePath(preparedAs)\n };\n}\nfunction resolveDynamicRoute(pathname, pages) {\n var cleanPathname = (0, _removeTrailingSlash).removeTrailingSlash((0, _denormalizePagePath).denormalizePagePath(pathname));\n if (cleanPathname === \"/404\" || cleanPathname === \"/_error\") {\n return pathname;\n }\n // handle resolving href for dynamic routes\n if (!pages.includes(cleanPathname)) {\n // eslint-disable-next-line array-callback-return\n pages.some(function(page) {\n if ((0, _isDynamic).isDynamicRoute(page) && (0, _routeRegex).getRouteRegex(page).re.test(cleanPathname)) {\n pathname = page;\n return true;\n }\n });\n }\n return (0, _removeTrailingSlash).removeTrailingSlash(pathname);\n}\nfunction getMiddlewareData(source, response, options) {\n var nextConfig = {\n basePath: options.router.basePath,\n i18n: {\n locales: options.router.locales\n },\n trailingSlash: Boolean(false)\n };\n var rewriteHeader = response.headers.get(\"x-nextjs-rewrite\");\n var rewriteTarget = rewriteHeader || response.headers.get(\"x-nextjs-matched-path\");\n var matchedPath = response.headers.get(\"x-matched-path\");\n if (matchedPath && !rewriteTarget && !matchedPath.includes(\"__next_data_catchall\") && !matchedPath.includes(\"/_error\") && !matchedPath.includes(\"/404\")) {\n // leverage x-matched-path to detect next.config.js rewrites\n rewriteTarget = matchedPath;\n }\n if (rewriteTarget) {\n if (rewriteTarget.startsWith(\"/\")) {\n var parsedRewriteTarget = (0, _parseRelativeUrl).parseRelativeUrl(rewriteTarget);\n var pathnameInfo = (0, _getNextPathnameInfo).getNextPathnameInfo(parsedRewriteTarget.pathname, {\n nextConfig: nextConfig,\n parseData: true\n });\n var fsPathname = (0, _removeTrailingSlash).removeTrailingSlash(pathnameInfo.pathname);\n return Promise.all([\n options.router.pageLoader.getPageList(),\n (0, _routeLoader).getClientBuildManifest(), \n ]).then(function(param) {\n var _param = _slicedToArray(param, 2), pages = _param[0], ref = _param[1], rewrites = ref.__rewrites;\n var as = (0, _addLocale).addLocale(pathnameInfo.pathname, pathnameInfo.locale);\n if ((0, _isDynamic).isDynamicRoute(as) || !rewriteHeader && pages.includes((0, _normalizeLocalePath).normalizeLocalePath((0, _removeBasePath).removeBasePath(as), options.router.locales).pathname)) {\n var parsedSource = (0, _getNextPathnameInfo).getNextPathnameInfo((0, _parseRelativeUrl).parseRelativeUrl(source).pathname, {\n parseData: true\n });\n as = (0, _addBasePath).addBasePath(parsedSource.pathname);\n parsedRewriteTarget.pathname = as;\n }\n if (false) { var result; } else if (!pages.includes(fsPathname)) {\n var resolvedPathname = resolveDynamicRoute(fsPathname, pages);\n if (resolvedPathname !== fsPathname) {\n fsPathname = resolvedPathname;\n }\n }\n var resolvedHref = !pages.includes(fsPathname) ? resolveDynamicRoute((0, _normalizeLocalePath).normalizeLocalePath((0, _removeBasePath).removeBasePath(parsedRewriteTarget.pathname), options.router.locales).pathname, pages) : fsPathname;\n if ((0, _isDynamic).isDynamicRoute(resolvedHref)) {\n var matches = (0, _routeMatcher).getRouteMatcher((0, _routeRegex).getRouteRegex(resolvedHref))(as);\n Object.assign(parsedRewriteTarget.query, matches || {});\n }\n return {\n type: \"rewrite\",\n parsedAs: parsedRewriteTarget,\n resolvedHref: resolvedHref\n };\n });\n }\n var src = (0, _parsePath).parsePath(source);\n var pathname = (0, _formatNextPathnameInfo).formatNextPathnameInfo(_extends({}, (0, _getNextPathnameInfo).getNextPathnameInfo(src.pathname, {\n nextConfig: nextConfig,\n parseData: true\n }), {\n defaultLocale: options.router.defaultLocale,\n buildId: \"\"\n }));\n return Promise.resolve({\n type: \"redirect-external\",\n destination: \"\".concat(pathname).concat(src.query).concat(src.hash)\n });\n }\n var redirectTarget = response.headers.get(\"x-nextjs-redirect\");\n if (redirectTarget) {\n if (redirectTarget.startsWith(\"/\")) {\n var src1 = (0, _parsePath).parsePath(redirectTarget);\n var pathname1 = (0, _formatNextPathnameInfo).formatNextPathnameInfo(_extends({}, (0, _getNextPathnameInfo).getNextPathnameInfo(src1.pathname, {\n nextConfig: nextConfig,\n parseData: true\n }), {\n defaultLocale: options.router.defaultLocale,\n buildId: \"\"\n }));\n return Promise.resolve({\n type: \"redirect-internal\",\n newAs: \"\".concat(pathname1).concat(src1.query).concat(src1.hash),\n newUrl: \"\".concat(pathname1).concat(src1.query).concat(src1.hash)\n });\n }\n return Promise.resolve({\n type: \"redirect-external\",\n destination: redirectTarget\n });\n }\n return Promise.resolve({\n type: \"next\"\n });\n}\nfunction withMiddlewareEffects(options) {\n return matchesMiddleware(options).then(function(matches) {\n if (matches && options.fetchData) {\n return options.fetchData().then(function(data) {\n return getMiddlewareData(data.dataHref, data.response, options).then(function(effect) {\n return {\n dataHref: data.dataHref,\n cacheKey: data.cacheKey,\n json: data.json,\n response: data.response,\n text: data.text,\n effect: effect\n };\n });\n }).catch(function(_err) {\n /**\n * TODO: Revisit this in the future.\n * For now we will not consider middleware data errors to be fatal.\n * maybe we should revisit in the future.\n */ return null;\n });\n }\n return null;\n });\n}\nvar manualScrollRestoration = false && 0;\nvar SSG_DATA_NOT_FOUND = Symbol(\"SSG_DATA_NOT_FOUND\");\nfunction fetchRetry(url, attempts, options) {\n return fetch(url, {\n // Cookies are required to be present for Next.js' SSG \"Preview Mode\".\n // Cookies may also be required for `getServerSideProps`.\n //\n // > `fetch` won’t send cookies, unless you set the credentials init\n // > option.\n // https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch\n //\n // > For maximum browser compatibility when it comes to sending &\n // > receiving cookies, always supply the `credentials: 'same-origin'`\n // > option instead of relying on the default.\n // https://github.com/github/fetch#caveats\n credentials: \"same-origin\",\n method: options.method || \"GET\",\n headers: Object.assign({}, options.headers, {\n \"x-nextjs-data\": \"1\"\n })\n }).then(function(response) {\n return !response.ok && attempts > 1 && response.status >= 500 ? fetchRetry(url, attempts - 1, options) : response;\n });\n}\nvar backgroundCache = {};\nfunction handleSmoothScroll(fn) {\n var htmlElement = document.documentElement;\n var existing = htmlElement.style.scrollBehavior;\n htmlElement.style.scrollBehavior = \"auto\";\n fn();\n htmlElement.style.scrollBehavior = existing;\n}\nfunction tryToParseAsJSON(text) {\n try {\n return JSON.parse(text);\n } catch (error) {\n return null;\n }\n}\nfunction fetchNextData(param) {\n var dataHref = param.dataHref, inflightCache = param.inflightCache, isPrefetch = param.isPrefetch, hasMiddleware = param.hasMiddleware, isServerRender = param.isServerRender, parseJSON = param.parseJSON, persistCache = param.persistCache, isBackground = param.isBackground, unstable_skipClientCache = param.unstable_skipClientCache;\n var ref = new URL(dataHref, window.location.href), cacheKey = ref.href;\n var ref1;\n var getData = function(params) {\n return fetchRetry(dataHref, isServerRender ? 3 : 1, {\n headers: isPrefetch ? {\n purpose: \"prefetch\"\n } : {},\n method: (ref1 = params == null ? void 0 : params.method) != null ? ref1 : \"GET\"\n }).then(function(response) {\n if (response.ok && (params == null ? void 0 : params.method) === \"HEAD\") {\n return {\n dataHref: dataHref,\n response: response,\n text: \"\",\n json: {},\n cacheKey: cacheKey\n };\n }\n return response.text().then(function(text) {\n if (!response.ok) {\n /**\n * When the data response is a redirect because of a middleware\n * we do not consider it an error. The headers must bring the\n * mapped location.\n * TODO: Change the status code in the handler.\n */ if (hasMiddleware && [\n 301,\n 302,\n 307,\n 308\n ].includes(response.status)) {\n return {\n dataHref: dataHref,\n response: response,\n text: text,\n json: {},\n cacheKey: cacheKey\n };\n }\n if (!hasMiddleware && response.status === 404) {\n var ref;\n if ((ref = tryToParseAsJSON(text)) == null ? void 0 : ref.notFound) {\n return {\n dataHref: dataHref,\n json: {\n notFound: SSG_DATA_NOT_FOUND\n },\n response: response,\n text: text,\n cacheKey: cacheKey\n };\n }\n }\n var error = new Error(\"Failed to load static props\");\n /**\n * We should only trigger a server-side transition if this was\n * caused on a client-side transition. Otherwise, we'd get into\n * an infinite loop.\n */ if (!isServerRender) {\n (0, _routeLoader).markAssetError(error);\n }\n throw error;\n }\n return {\n dataHref: dataHref,\n json: parseJSON ? tryToParseAsJSON(text) : null,\n response: response,\n text: text,\n cacheKey: cacheKey\n };\n });\n }).then(function(data) {\n if (!persistCache || \"development\" !== \"production\" || 0) {\n delete inflightCache[cacheKey];\n }\n return data;\n }).catch(function(err) {\n delete inflightCache[cacheKey];\n throw err;\n });\n };\n // when skipping client cache we wait to update\n // inflight cache until successful data response\n // this allows racing click event with fetching newer data\n // without blocking navigation when stale data is available\n if (unstable_skipClientCache && persistCache) {\n return getData({}).then(function(data) {\n inflightCache[cacheKey] = Promise.resolve(data);\n return data;\n });\n }\n if (inflightCache[cacheKey] !== undefined) {\n return inflightCache[cacheKey];\n }\n return inflightCache[cacheKey] = getData(isBackground ? {\n method: \"HEAD\"\n } : {});\n}\nfunction createKey() {\n return Math.random().toString(36).slice(2, 10);\n}\nfunction handleHardNavigation(param) {\n var url = param.url, router = param.router;\n // ensure we don't trigger a hard navigation to the same\n // URL as this can end up with an infinite refresh\n if (url === (0, _addBasePath).addBasePath((0, _addLocale).addLocale(router.asPath, router.locale))) {\n throw new Error(\"Invariant: attempted to hard navigate to the same URL \".concat(url, \" \").concat(location.href));\n }\n window.location.href = url;\n}\nvar getCancelledHandler = function(param) {\n var route = param.route, router = param.router;\n var cancelled = false;\n var cancel = router.clc = function() {\n cancelled = true;\n };\n var handleCancelled = function() {\n if (cancelled) {\n var error = new Error('Abort fetching component for route: \"'.concat(route, '\"'));\n error.cancelled = true;\n throw error;\n }\n if (cancel === router.clc) {\n router.clc = null;\n }\n };\n return handleCancelled;\n};\nvar Router = /*#__PURE__*/ function() {\n function Router(pathname1, query1, as1, param) {\n var initialProps = param.initialProps, pageLoader = param.pageLoader, App = param.App, wrapApp = param.wrapApp, Component = param.Component, err = param.err, subscription = param.subscription, isFallback = param.isFallback, locale = param.locale, locales = param.locales, defaultLocale = param.defaultLocale, domainLocales = param.domainLocales, isPreview = param.isPreview;\n var _this = this;\n _classCallCheck(this, Router);\n // Server Data Cache\n this.sdc = {};\n this.isFirstPopStateEvent = true;\n this._key = createKey();\n this.onPopState = function(e) {\n var isFirstPopStateEvent = _this.isFirstPopStateEvent;\n _this.isFirstPopStateEvent = false;\n var state = e.state;\n if (!state) {\n // We get state as undefined for two reasons.\n // 1. With older safari (< 8) and older chrome (< 34)\n // 2. When the URL changed with #\n //\n // In the both cases, we don't need to proceed and change the route.\n // (as it's already changed)\n // But we can simply replace the state with the new changes.\n // Actually, for (1) we don't need to nothing. But it's hard to detect that event.\n // So, doing the following for (1) does no harm.\n var pathname = _this.pathname, query = _this.query;\n _this.changeState(\"replaceState\", (0, _formatUrl).formatWithValidation({\n pathname: (0, _addBasePath).addBasePath(pathname),\n query: query\n }), (0, _utils).getURL());\n return;\n }\n // __NA is used to identify if the history entry can be handled by the app-router.\n if (state.__NA) {\n window.location.reload();\n return;\n }\n if (!state.__N) {\n return;\n }\n // Safari fires popstateevent when reopening the browser.\n if (isFirstPopStateEvent && _this.locale === state.options.locale && state.as === _this.asPath) {\n return;\n }\n var forcedScroll;\n var url = state.url, as = state.as, options = state.options, key = state.key;\n if (false) { var v; }\n _this._key = key;\n var pathname1 = (0, _parseRelativeUrl).parseRelativeUrl(url).pathname;\n // Make sure we don't re-render on initial load,\n // can be caused by navigating back from an external site\n if (_this.isSsr && as === (0, _addBasePath).addBasePath(_this.asPath) && pathname1 === (0, _addBasePath).addBasePath(_this.pathname)) {\n return;\n }\n // If the downstream application returns falsy, return.\n // They will then be responsible for handling the event.\n if (_this._bps && !_this._bps(state)) {\n return;\n }\n _this.change(\"replaceState\", url, as, Object.assign({}, options, {\n shallow: options.shallow && _this._shallow,\n locale: options.locale || _this.defaultLocale,\n // @ts-ignore internal value not exposed on types\n _h: 0\n }), forcedScroll);\n };\n // represents the current component key\n var route = (0, _removeTrailingSlash).removeTrailingSlash(pathname1);\n // set up the component cache (by route keys)\n this.components = {};\n // We should not keep the cache, if there's an error\n // Otherwise, this cause issues when when going back and\n // come again to the errored page.\n if (pathname1 !== \"/_error\") {\n this.components[route] = {\n Component: Component,\n initial: true,\n props: initialProps,\n err: err,\n __N_SSG: initialProps && initialProps.__N_SSG,\n __N_SSP: initialProps && initialProps.__N_SSP\n };\n }\n this.components[\"/_app\"] = {\n Component: App,\n styleSheets: []\n };\n // Backwards compat for Router.router.events\n // TODO: Should be remove the following major version as it was never documented\n this.events = Router.events;\n this.pageLoader = pageLoader;\n // if auto prerendered and dynamic route wait to update asPath\n // until after mount to prevent hydration mismatch\n var autoExportDynamic = (0, _isDynamic).isDynamicRoute(pathname1) && self.__NEXT_DATA__.autoExport;\n this.basePath = false || \"\";\n this.sub = subscription;\n this.clc = null;\n this._wrapApp = wrapApp;\n // make sure to ignore extra popState in safari on navigating\n // back from external site\n this.isSsr = true;\n this.isLocaleDomain = false;\n this.isReady = !!(self.__NEXT_DATA__.gssp || self.__NEXT_DATA__.gip || self.__NEXT_DATA__.appGip && !self.__NEXT_DATA__.gsp || !autoExportDynamic && !self.location.search && !false);\n if (false) {}\n this.state = {\n route: route,\n pathname: pathname1,\n query: query1,\n asPath: autoExportDynamic ? pathname1 : as1,\n isPreview: !!isPreview,\n locale: false ? 0 : undefined,\n isFallback: isFallback\n };\n this._initialMatchesMiddlewarePromise = Promise.resolve(false);\n if (true) {\n // make sure \"as\" doesn't start with double slashes or else it can\n // throw an error as it's considered invalid\n if (!as1.startsWith(\"//\")) {\n // in order for `e.state` to work on the `onpopstate` event\n // we have to register the initial route upon initialization\n var options = {\n locale: locale\n };\n var asPath = (0, _utils).getURL();\n this._initialMatchesMiddlewarePromise = matchesMiddleware({\n router: this,\n locale: locale,\n asPath: asPath\n }).then(function(matches) {\n options._shouldResolveHref = as1 !== pathname1;\n _this.changeState(\"replaceState\", matches ? asPath : (0, _formatUrl).formatWithValidation({\n pathname: (0, _addBasePath).addBasePath(pathname1),\n query: query1\n }), asPath, options);\n return matches;\n });\n }\n window.addEventListener(\"popstate\", this.onPopState);\n // enable custom scroll restoration handling when available\n // otherwise fallback to browser's default handling\n if (false) {}\n }\n }\n _createClass(Router, [\n {\n key: \"reload\",\n value: function reload() {\n window.location.reload();\n }\n },\n {\n /**\n * Go back in history\n */ key: \"back\",\n value: function back() {\n window.history.back();\n }\n },\n {\n /**\n * Performs a `pushState` with arguments\n * @param url of the route\n * @param as masks `url` for the browser\n * @param options object you can define `shallow` and other options\n */ key: \"push\",\n value: function push(url, as) {\n var options = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};\n if (false) {}\n var ref;\n ref = prepareUrlAs(this, url, as), url = ref.url, as = ref.as, ref;\n return this.change(\"pushState\", url, as, options);\n }\n },\n {\n /**\n * Performs a `replaceState` with arguments\n * @param url of the route\n * @param as masks `url` for the browser\n * @param options object you can define `shallow` and other options\n */ key: \"replace\",\n value: function replace(url, as) {\n var options = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};\n var ref;\n ref = prepareUrlAs(this, url, as), url = ref.url, as = ref.as, ref;\n return this.change(\"replaceState\", url, as, options);\n }\n },\n {\n key: \"change\",\n value: function change(method, url, as, options, forcedScroll) {\n var _this = this;\n return _async_to_generator(function() {\n var isQueryUpdating, shouldResolveHref, nextState, readyStateChange, isSsr, prevLocale, parsedAs, localePathResult, didNavigate, ref, detectedDomain, asNoBasePath, _shallow, shallow, _scroll, scroll, routeProps, cleanedAs, localeChange, err, parsed, pathname, query, pages, rewrites, ref1, ref2, err1, resolvedAs, isMiddlewareMatch, rewritesResult, route, routeMatch, parsedAs1, asPathname, routeRegex, shouldInterpolate, interpolatedAs, missingParams, ref21, ref3, routeInfo, cleanedParsedPathname, prefixedAs, rewriteAs, localeResult, routeRegex1, curRouteMatch, error, props, __N_SSG, __N_SSP, component, scripts, destination, parsedHref, ref4, newUrl, newAs, notFoundRoute, _, _route, isValidShallowRoute, _scroll1, shouldScroll, resetScroll, upcomingRouterState, upcomingScrollState, canSkipUpdating, hashRegex, err11;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n if (!isLocalURL(url)) {\n handleHardNavigation({\n url: url,\n router: _this\n });\n return [\n 2,\n false\n ];\n }\n isQueryUpdating = options._h;\n shouldResolveHref = isQueryUpdating || options._shouldResolveHref || (0, _parsePath).parsePath(url).pathname === (0, _parsePath).parsePath(as).pathname;\n nextState = _extends({}, _this.state);\n readyStateChange = _this.isReady !== true;\n _this.isReady = true;\n isSsr = _this.isSsr;\n if (!isQueryUpdating) {\n _this.isSsr = false;\n }\n // if a route transition is already in progress before\n // the query updating is triggered ignore query updating\n if (isQueryUpdating && _this.clc) {\n return [\n 2,\n false\n ];\n }\n prevLocale = nextState.locale;\n if (false) {}\n // marking route changes as a navigation start entry\n if (_utils.ST) {\n performance.mark(\"routeChange\");\n }\n _shallow = options.shallow, shallow = _shallow === void 0 ? false : _shallow, _scroll = options.scroll, scroll = _scroll === void 0 ? true : _scroll;\n routeProps = {\n shallow: shallow\n };\n if (_this._inFlightRoute && _this.clc) {\n if (!isSsr) {\n Router.events.emit(\"routeChangeError\", buildCancellationError(), _this._inFlightRoute, routeProps);\n }\n _this.clc();\n _this.clc = null;\n }\n as = (0, _addBasePath).addBasePath((0, _addLocale).addLocale((0, _hasBasePath).hasBasePath(as) ? (0, _removeBasePath).removeBasePath(as) : as, options.locale, _this.defaultLocale));\n cleanedAs = (0, _removeLocale).removeLocale((0, _hasBasePath).hasBasePath(as) ? (0, _removeBasePath).removeBasePath(as) : as, nextState.locale);\n _this._inFlightRoute = as;\n localeChange = prevLocale !== nextState.locale;\n if (!(!isQueryUpdating && _this.onlyAHashChange(cleanedAs) && !localeChange)) return [\n 3,\n 5\n ];\n nextState.asPath = cleanedAs;\n Router.events.emit(\"hashChangeStart\", as, routeProps);\n // TODO: do we need the resolved href when only a hash change?\n _this.changeState(method, url, as, _extends({}, options, {\n scroll: false\n }));\n if (scroll) {\n _this.scrollToHash(cleanedAs);\n }\n _state.label = 1;\n case 1:\n _state.trys.push([\n 1,\n 3,\n ,\n 4\n ]);\n return [\n 4,\n _this.set(nextState, _this.components[nextState.route], null)\n ];\n case 2:\n _state.sent();\n return [\n 3,\n 4\n ];\n case 3:\n err = _state.sent();\n if ((0, _isError).default(err) && err.cancelled) {\n Router.events.emit(\"routeChangeError\", err, cleanedAs, routeProps);\n }\n throw err;\n case 4:\n Router.events.emit(\"hashChangeComplete\", as, routeProps);\n return [\n 2,\n true\n ];\n case 5:\n parsed = (0, _parseRelativeUrl).parseRelativeUrl(url);\n pathname = parsed.pathname, query = parsed.query;\n _state.label = 6;\n case 6:\n _state.trys.push([\n 6,\n 8,\n ,\n 9\n ]);\n return [\n 4,\n Promise.all([\n _this.pageLoader.getPageList(),\n (0, _routeLoader).getClientBuildManifest(),\n _this.pageLoader.getMiddleware()\n ])\n ];\n case 7:\n ref1 = _slicedToArray.apply(void 0, [\n _state.sent(),\n 2\n ]), pages = ref1[0], ref2 = ref1[1], rewrites = ref2.__rewrites, ref2, ref1;\n return [\n 3,\n 9\n ];\n case 8:\n err1 = _state.sent();\n // If we fail to resolve the page list or client-build manifest, we must\n // do a server-side transition:\n handleHardNavigation({\n url: as,\n router: _this\n });\n return [\n 2,\n false\n ];\n case 9:\n // If asked to change the current URL we should reload the current page\n // (not location.reload() but reload getInitialProps and other Next.js stuffs)\n // We also need to set the method = replaceState always\n // as this should not go into the history (That's how browsers work)\n // We should compare the new asPath to the current asPath, not the url\n if (!_this.urlIsNew(cleanedAs) && !localeChange) {\n method = \"replaceState\";\n }\n resolvedAs = as;\n // url and as should always be prefixed with basePath by this\n // point by either next/link or router.push/replace so strip the\n // basePath from the pathname to match the pages dir 1-to-1\n pathname = pathname ? (0, _removeTrailingSlash).removeTrailingSlash((0, _removeBasePath).removeBasePath(pathname)) : pathname;\n return [\n 4,\n matchesMiddleware({\n asPath: as,\n locale: nextState.locale,\n router: _this\n })\n ];\n case 10:\n isMiddlewareMatch = _state.sent();\n if (options.shallow && isMiddlewareMatch) {\n pathname = _this.pathname;\n }\n if (shouldResolveHref && pathname !== \"/_error\") {\n options._shouldResolveHref = true;\n if (false) {} else {\n parsed.pathname = resolveDynamicRoute(pathname, pages);\n if (parsed.pathname !== pathname) {\n pathname = parsed.pathname;\n parsed.pathname = (0, _addBasePath).addBasePath(pathname);\n if (!isMiddlewareMatch) {\n url = (0, _formatUrl).formatWithValidation(parsed);\n }\n }\n }\n }\n if (!isLocalURL(as)) {\n if (true) {\n throw new Error('Invalid href: \"'.concat(url, '\" and as: \"').concat(as, '\", received relative href and external as') + \"\\nSee more info: https://nextjs.org/docs/messages/invalid-relative-url-external-as\");\n }\n handleHardNavigation({\n url: as,\n router: _this\n });\n return [\n 2,\n false\n ];\n }\n resolvedAs = (0, _removeLocale).removeLocale((0, _removeBasePath).removeBasePath(resolvedAs), nextState.locale);\n route = (0, _removeTrailingSlash).removeTrailingSlash(pathname);\n routeMatch = false;\n if ((0, _isDynamic).isDynamicRoute(route)) {\n parsedAs1 = (0, _parseRelativeUrl).parseRelativeUrl(resolvedAs);\n asPathname = parsedAs1.pathname;\n routeRegex = (0, _routeRegex).getRouteRegex(route);\n routeMatch = (0, _routeMatcher).getRouteMatcher(routeRegex)(asPathname);\n shouldInterpolate = route === asPathname;\n interpolatedAs = shouldInterpolate ? interpolateAs(route, asPathname, query) : {};\n if (!routeMatch || shouldInterpolate && !interpolatedAs.result) {\n missingParams = Object.keys(routeRegex.groups).filter(function(param) {\n return !query[param];\n });\n if (missingParams.length > 0 && !isMiddlewareMatch) {\n if (true) {\n console.warn(\"\".concat(shouldInterpolate ? \"Interpolating href\" : \"Mismatching `as` and `href`\", \" failed to manually provide \") + \"the params: \".concat(missingParams.join(\", \"), \" in the `href`'s `query`\"));\n }\n throw new Error((shouldInterpolate ? \"The provided `href` (\".concat(url, \") value is missing query values (\").concat(missingParams.join(\", \"), \") to be interpolated properly. \") : \"The provided `as` value (\".concat(asPathname, \") is incompatible with the `href` value (\").concat(route, \"). \")) + \"Read more: https://nextjs.org/docs/messages/\".concat(shouldInterpolate ? \"href-interpolation-failed\" : \"incompatible-href-as\"));\n }\n } else if (shouldInterpolate) {\n as = (0, _formatUrl).formatWithValidation(Object.assign({}, parsedAs1, {\n pathname: interpolatedAs.result,\n query: omit(query, interpolatedAs.params)\n }));\n } else {\n // Merge params into `query`, overwriting any specified in search\n Object.assign(query, routeMatch);\n }\n }\n if (!isQueryUpdating) {\n Router.events.emit(\"routeChangeStart\", as, routeProps);\n }\n _state.label = 11;\n case 11:\n _state.trys.push([\n 11,\n 21,\n ,\n 22\n ]);\n return [\n 4,\n _this.getRouteInfo({\n route: route,\n pathname: pathname,\n query: query,\n as: as,\n resolvedAs: resolvedAs,\n routeProps: routeProps,\n locale: nextState.locale,\n isPreview: nextState.isPreview,\n hasMiddleware: isMiddlewareMatch\n })\n ];\n case 12:\n routeInfo = _state.sent();\n if (\"route\" in routeInfo && isMiddlewareMatch) {\n pathname = routeInfo.route || route;\n route = pathname;\n if (!routeProps.shallow) {\n query = Object.assign({}, routeInfo.query || {}, query);\n }\n cleanedParsedPathname = (0, _hasBasePath).hasBasePath(parsed.pathname) ? (0, _removeBasePath).removeBasePath(parsed.pathname) : parsed.pathname;\n if (routeMatch && pathname !== cleanedParsedPathname) {\n Object.keys(routeMatch).forEach(function(key) {\n if (routeMatch && query[key] === routeMatch[key]) {\n delete query[key];\n }\n });\n }\n if ((0, _isDynamic).isDynamicRoute(pathname)) {\n prefixedAs = !routeProps.shallow && routeInfo.resolvedAs ? routeInfo.resolvedAs : (0, _addBasePath).addBasePath((0, _addLocale).addLocale(new URL(as, location.href).pathname, nextState.locale), true);\n rewriteAs = prefixedAs;\n if ((0, _hasBasePath).hasBasePath(rewriteAs)) {\n rewriteAs = (0, _removeBasePath).removeBasePath(rewriteAs);\n }\n if (false) {}\n routeRegex1 = (0, _routeRegex).getRouteRegex(pathname);\n curRouteMatch = (0, _routeMatcher).getRouteMatcher(routeRegex1)(rewriteAs);\n if (curRouteMatch) {\n Object.assign(query, curRouteMatch);\n }\n }\n }\n // If the routeInfo brings a redirect we simply apply it.\n if (\"type\" in routeInfo) {\n if (routeInfo.type === \"redirect-internal\") {\n return [\n 2,\n _this.change(method, routeInfo.newUrl, routeInfo.newAs, options)\n ];\n } else {\n handleHardNavigation({\n url: routeInfo.destination,\n router: _this\n });\n return [\n 2,\n new Promise(function() {})\n ];\n }\n }\n error = routeInfo.error, props = routeInfo.props, __N_SSG = routeInfo.__N_SSG, __N_SSP = routeInfo.__N_SSP;\n component = routeInfo.Component;\n if (component && component.unstable_scriptLoader) {\n scripts = [].concat(component.unstable_scriptLoader());\n scripts.forEach(function(script) {\n (0, _script).handleClientScriptLoad(script.props);\n });\n }\n if (!((__N_SSG || __N_SSP) && props)) return [\n 3,\n 18\n ];\n if (props.pageProps && props.pageProps.__N_REDIRECT) {\n // Use the destination from redirect without adding locale\n options.locale = false;\n destination = props.pageProps.__N_REDIRECT;\n // check if destination is internal (resolves to a page) and attempt\n // client-navigation if it is falling back to hard navigation if\n // it's not\n if (destination.startsWith(\"/\") && props.pageProps.__N_REDIRECT_BASE_PATH !== false) {\n parsedHref = (0, _parseRelativeUrl).parseRelativeUrl(destination);\n parsedHref.pathname = resolveDynamicRoute(parsedHref.pathname, pages);\n ref4 = prepareUrlAs(_this, destination, destination), newUrl = ref4.url, newAs = ref4.as;\n return [\n 2,\n _this.change(method, newUrl, newAs, options)\n ];\n }\n handleHardNavigation({\n url: destination,\n router: _this\n });\n return [\n 2,\n new Promise(function() {})\n ];\n }\n nextState.isPreview = !!props.__N_PREVIEW;\n if (!(props.notFound === SSG_DATA_NOT_FOUND)) return [\n 3,\n 18\n ];\n _state.label = 13;\n case 13:\n _state.trys.push([\n 13,\n 15,\n ,\n 16\n ]);\n return [\n 4,\n _this.fetchComponent(\"/404\")\n ];\n case 14:\n _state.sent();\n notFoundRoute = \"/404\";\n return [\n 3,\n 16\n ];\n case 15:\n _ = _state.sent();\n notFoundRoute = \"/_error\";\n return [\n 3,\n 16\n ];\n case 16:\n return [\n 4,\n _this.getRouteInfo({\n route: notFoundRoute,\n pathname: notFoundRoute,\n query: query,\n as: as,\n resolvedAs: resolvedAs,\n routeProps: {\n shallow: false\n },\n locale: nextState.locale,\n isPreview: nextState.isPreview\n })\n ];\n case 17:\n routeInfo = _state.sent();\n if (\"type\" in routeInfo) {\n throw new Error(\"Unexpected middleware effect on /404\");\n }\n _state.label = 18;\n case 18:\n Router.events.emit(\"beforeHistoryChange\", as, routeProps);\n _this.changeState(method, url, as, options);\n if (isQueryUpdating && pathname === \"/_error\" && ((ref21 = self.__NEXT_DATA__.props) == null ? void 0 : (ref3 = ref21.pageProps) == null ? void 0 : ref3.statusCode) === 500 && (props == null ? void 0 : props.pageProps)) {\n // ensure statusCode is still correct for static 500 page\n // when updating query information\n props.pageProps.statusCode = 500;\n }\n isValidShallowRoute = options.shallow && nextState.route === ((_route = routeInfo.route) != null ? _route : route);\n shouldScroll = (_scroll1 = options.scroll) != null ? _scroll1 : !options._h && !isValidShallowRoute;\n resetScroll = shouldScroll ? {\n x: 0,\n y: 0\n } : null;\n upcomingRouterState = _extends({}, nextState, {\n route: route,\n pathname: pathname,\n query: query,\n asPath: cleanedAs,\n isFallback: false\n });\n upcomingScrollState = forcedScroll != null ? forcedScroll : resetScroll;\n canSkipUpdating = options._h && !upcomingScrollState && !readyStateChange && !localeChange && (0, _compareStates).compareRouterStates(upcomingRouterState, _this.state);\n if (!!canSkipUpdating) return [\n 3,\n 20\n ];\n return [\n 4,\n _this.set(upcomingRouterState, routeInfo, upcomingScrollState).catch(function(e) {\n if (e.cancelled) error = error || e;\n else throw e;\n })\n ];\n case 19:\n _state.sent();\n if (error) {\n if (!isQueryUpdating) {\n Router.events.emit(\"routeChangeError\", error, cleanedAs, routeProps);\n }\n throw error;\n }\n if (false) {}\n if (!isQueryUpdating) {\n Router.events.emit(\"routeChangeComplete\", as, routeProps);\n }\n hashRegex = /#.+$/;\n if (shouldScroll && hashRegex.test(as)) {\n _this.scrollToHash(as);\n }\n _state.label = 20;\n case 20:\n return [\n 2,\n true\n ];\n case 21:\n err11 = _state.sent();\n if ((0, _isError).default(err11) && err11.cancelled) {\n return [\n 2,\n false\n ];\n }\n throw err11;\n case 22:\n return [\n 2\n ];\n }\n });\n })();\n }\n },\n {\n key: \"changeState\",\n value: function changeState(method, url, as) {\n var options = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : {};\n if (true) {\n if (typeof window.history === \"undefined\") {\n console.error(\"Warning: window.history is not available.\");\n return;\n }\n if (typeof window.history[method] === \"undefined\") {\n console.error(\"Warning: window.history.\".concat(method, \" is not available\"));\n return;\n }\n }\n if (method !== \"pushState\" || (0, _utils).getURL() !== as) {\n this._shallow = options.shallow;\n window.history[method]({\n url: url,\n as: as,\n options: options,\n __N: true,\n key: this._key = method !== \"pushState\" ? this._key : createKey()\n }, // Passing the empty string here should be safe against future changes to the method.\n // https://developer.mozilla.org/en-US/docs/Web/API/History/replaceState\n \"\", as);\n }\n }\n },\n {\n key: \"handleRouteInfoError\",\n value: function handleRouteInfoError(err, pathname, query, as, routeProps, loadErrorFail) {\n var _this = this;\n return _async_to_generator(function() {\n var props, ref, Component, styleSheets, routeInfo, gipErr, routeInfoErr;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n console.error(err);\n if (err.cancelled) {\n // bubble up cancellation errors\n throw err;\n }\n if ((0, _routeLoader).isAssetError(err) || loadErrorFail) {\n Router.events.emit(\"routeChangeError\", err, as, routeProps);\n // If we can't load the page it could be one of following reasons\n // 1. Page doesn't exists\n // 2. Page does exist in a different zone\n // 3. Internal error while loading the page\n // So, doing a hard reload is the proper way to deal with this.\n handleHardNavigation({\n url: as,\n router: _this\n });\n // Changing the URL doesn't block executing the current code path.\n // So let's throw a cancellation error stop the routing logic.\n throw buildCancellationError();\n }\n _state.label = 1;\n case 1:\n _state.trys.push([\n 1,\n 7,\n ,\n 8\n ]);\n return [\n 4,\n _this.fetchComponent(\"/_error\")\n ];\n case 2:\n ref = _state.sent(), Component = ref.page, styleSheets = ref.styleSheets;\n routeInfo = {\n props: props,\n Component: Component,\n styleSheets: styleSheets,\n err: err,\n error: err\n };\n if (!!routeInfo.props) return [\n 3,\n 6\n ];\n _state.label = 3;\n case 3:\n _state.trys.push([\n 3,\n 5,\n ,\n 6\n ]);\n return [\n 4,\n _this.getInitialProps(Component, {\n err: err,\n pathname: pathname,\n query: query\n })\n ];\n case 4:\n routeInfo.props = _state.sent();\n return [\n 3,\n 6\n ];\n case 5:\n gipErr = _state.sent();\n console.error(\"Error in error page `getInitialProps`: \", gipErr);\n routeInfo.props = {};\n return [\n 3,\n 6\n ];\n case 6:\n return [\n 2,\n routeInfo\n ];\n case 7:\n routeInfoErr = _state.sent();\n return [\n 2,\n _this.handleRouteInfoError((0, _isError).default(routeInfoErr) ? routeInfoErr : new Error(routeInfoErr + \"\"), pathname, query, as, routeProps, true)\n ];\n case 8:\n return [\n 2\n ];\n }\n });\n })();\n }\n },\n {\n key: \"getRouteInfo\",\n value: function getRouteInfo(param) {\n var requestedRoute = param.route, pathname = param.pathname, query = param.query, as = param.as, resolvedAs = param.resolvedAs, routeProps = param.routeProps, locale = param.locale, hasMiddleware = param.hasMiddleware, isPreview = param.isPreview, unstable_skipClientCache = param.unstable_skipClientCache;\n var _this = this;\n return _async_to_generator(function() {\n var route, ref, ref4, ref5, handleCancelled, existingInfo, cachedRouteInfo, fetchNextDataParams, data, routeInfo, _tmp, isValidElementType, shouldFetchData, ref1, props, cacheKey, err;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n route = requestedRoute;\n _state.label = 1;\n case 1:\n _state.trys.push([\n 1,\n 6,\n ,\n 7\n ]);\n handleCancelled = getCancelledHandler({\n route: route,\n router: _this\n });\n existingInfo = _this.components[route];\n if (routeProps.shallow && existingInfo && _this.route === route) {\n return [\n 2,\n existingInfo\n ];\n }\n if (hasMiddleware) {\n existingInfo = undefined;\n }\n cachedRouteInfo = existingInfo && !(\"initial\" in existingInfo) && \"development\" !== \"development\" ? 0 : undefined;\n fetchNextDataParams = {\n dataHref: _this.pageLoader.getDataHref({\n href: (0, _formatUrl).formatWithValidation({\n pathname: pathname,\n query: query\n }),\n skipInterpolation: true,\n asPath: resolvedAs,\n locale: locale\n }),\n hasMiddleware: true,\n isServerRender: _this.isSsr,\n parseJSON: true,\n inflightCache: _this.sdc,\n persistCache: !isPreview,\n isPrefetch: false,\n unstable_skipClientCache: unstable_skipClientCache\n };\n return [\n 4,\n withMiddlewareEffects({\n fetchData: function() {\n return fetchNextData(fetchNextDataParams);\n },\n asPath: resolvedAs,\n locale: locale,\n router: _this\n })\n ];\n case 2:\n data = _state.sent();\n handleCancelled();\n if ((data == null ? void 0 : (ref = data.effect) == null ? void 0 : ref.type) === \"redirect-internal\" || (data == null ? void 0 : (ref4 = data.effect) == null ? void 0 : ref4.type) === \"redirect-external\") {\n return [\n 2,\n data.effect\n ];\n }\n if ((data == null ? void 0 : (ref5 = data.effect) == null ? void 0 : ref5.type) === \"rewrite\") {\n route = (0, _removeTrailingSlash).removeTrailingSlash(data.effect.resolvedHref);\n pathname = data.effect.resolvedHref;\n query = _extends({}, query, data.effect.parsedAs.query);\n resolvedAs = (0, _removeBasePath).removeBasePath((0, _normalizeLocalePath).normalizeLocalePath(data.effect.parsedAs.pathname, _this.locales).pathname);\n // Check again the cache with the new destination.\n existingInfo = _this.components[route];\n if (routeProps.shallow && existingInfo && _this.route === route && !hasMiddleware) {\n // If we have a match with the current route due to rewrite,\n // we can copy the existing information to the rewritten one.\n // Then, we return the information along with the matched route.\n return [\n 2,\n _extends({}, existingInfo, {\n route: route\n })\n ];\n }\n }\n if (route === \"/api\" || route.startsWith(\"/api/\")) {\n handleHardNavigation({\n url: as,\n router: _this\n });\n return [\n 2,\n new Promise(function() {})\n ];\n }\n _tmp = cachedRouteInfo;\n if (_tmp) return [\n 3,\n 4\n ];\n return [\n 4,\n _this.fetchComponent(route).then(function(res) {\n return {\n Component: res.page,\n styleSheets: res.styleSheets,\n __N_SSG: res.mod.__N_SSG,\n __N_SSP: res.mod.__N_SSP\n };\n })\n ];\n case 3:\n _tmp = _state.sent();\n _state.label = 4;\n case 4:\n routeInfo = _tmp;\n if (true) {\n isValidElementType = (__webpack_require__(/*! next/dist/compiled/react-is */ \"./node_modules/next/dist/compiled/react-is/index.js\").isValidElementType);\n if (!isValidElementType(routeInfo.Component)) {\n throw new Error('The default export is not a React Component in page: \"'.concat(pathname, '\"'));\n }\n }\n shouldFetchData = routeInfo.__N_SSG || routeInfo.__N_SSP;\n return [\n 4,\n _this._getData(_async_to_generator(function() {\n var ref, json, _cacheKey, _tmp, _tmp1;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n if (!shouldFetchData) return [\n 3,\n 4\n ];\n if (!(data == null ? void 0 : data.json)) return [\n 3,\n 1\n ];\n _tmp = data;\n return [\n 3,\n 3\n ];\n case 1:\n return [\n 4,\n fetchNextData({\n dataHref: _this.pageLoader.getDataHref({\n href: (0, _formatUrl).formatWithValidation({\n pathname: pathname,\n query: query\n }),\n asPath: resolvedAs,\n locale: locale\n }),\n isServerRender: _this.isSsr,\n parseJSON: true,\n inflightCache: _this.sdc,\n persistCache: !isPreview,\n isPrefetch: false,\n unstable_skipClientCache: unstable_skipClientCache\n })\n ];\n case 2:\n _tmp = _state.sent();\n _state.label = 3;\n case 3:\n ref = _tmp, json = ref.json, _cacheKey = ref.cacheKey;\n return [\n 2,\n {\n cacheKey: _cacheKey,\n props: json || {}\n }\n ];\n case 4:\n _tmp1 = {\n headers: {},\n cacheKey: \"\"\n };\n return [\n 4,\n _this.getInitialProps(routeInfo.Component, {\n pathname: pathname,\n query: query,\n asPath: as,\n locale: locale,\n locales: _this.locales,\n defaultLocale: _this.defaultLocale\n })\n ];\n case 5:\n return [\n 2,\n (_tmp1.props = _state.sent(), _tmp1)\n ];\n }\n });\n }))\n ];\n case 5:\n ref1 = _state.sent(), props = ref1.props, cacheKey = ref1.cacheKey;\n // Only bust the data cache for SSP routes although\n // middleware can skip cache per request with\n // x-middleware-cache: no-cache as well\n if (routeInfo.__N_SSP && fetchNextDataParams.dataHref) {\n delete _this.sdc[cacheKey];\n }\n // we kick off a HEAD request in the background\n // when a non-prefetch request is made to signal revalidation\n if (!_this.isPreview && routeInfo.__N_SSG && \"development\" !== \"development\") {}\n props.pageProps = Object.assign({}, props.pageProps);\n routeInfo.props = props;\n routeInfo.route = route;\n routeInfo.query = query;\n routeInfo.resolvedAs = resolvedAs;\n _this.components[route] = routeInfo;\n return [\n 2,\n routeInfo\n ];\n case 6:\n err = _state.sent();\n return [\n 2,\n _this.handleRouteInfoError((0, _isError).getProperError(err), pathname, query, as, routeProps)\n ];\n case 7:\n return [\n 2\n ];\n }\n });\n })();\n }\n },\n {\n key: \"set\",\n value: function set(state, data, resetScroll) {\n this.state = state;\n return this.sub(data, this.components[\"/_app\"].Component, resetScroll);\n }\n },\n {\n /**\n * Callback to execute before replacing router state\n * @param cb callback to be executed\n */ key: \"beforePopState\",\n value: function beforePopState(cb) {\n this._bps = cb;\n }\n },\n {\n key: \"onlyAHashChange\",\n value: function onlyAHashChange(as) {\n if (!this.asPath) return false;\n var ref = _slicedToArray(this.asPath.split(\"#\"), 2), oldUrlNoHash = ref[0], oldHash = ref[1];\n var ref1 = _slicedToArray(as.split(\"#\"), 2), newUrlNoHash = ref1[0], newHash = ref1[1];\n // Makes sure we scroll to the provided hash if the url/hash are the same\n if (newHash && oldUrlNoHash === newUrlNoHash && oldHash === newHash) {\n return true;\n }\n // If the urls are change, there's more than a hash change\n if (oldUrlNoHash !== newUrlNoHash) {\n return false;\n }\n // If the hash has changed, then it's a hash only change.\n // This check is necessary to handle both the enter and\n // leave hash === '' cases. The identity case falls through\n // and is treated as a next reload.\n return oldHash !== newHash;\n }\n },\n {\n key: \"scrollToHash\",\n value: function scrollToHash(as) {\n var ref = _slicedToArray(as.split(\"#\"), 2), tmp = ref[1], hash = tmp === void 0 ? \"\" : tmp;\n // Scroll to top if the hash is just `#` with no value or `#top`\n // To mirror browsers\n if (hash === \"\" || hash === \"top\") {\n handleSmoothScroll(function() {\n return window.scrollTo(0, 0);\n });\n return;\n }\n // Decode hash to make non-latin anchor works.\n var rawHash = decodeURIComponent(hash);\n // First we check if the element by id is found\n var idEl = document.getElementById(rawHash);\n if (idEl) {\n handleSmoothScroll(function() {\n return idEl.scrollIntoView();\n });\n return;\n }\n // If there's no element with the id, we check the `name` property\n // To mirror browsers\n var nameEl = document.getElementsByName(rawHash)[0];\n if (nameEl) {\n handleSmoothScroll(function() {\n return nameEl.scrollIntoView();\n });\n }\n }\n },\n {\n key: \"urlIsNew\",\n value: function urlIsNew(asPath) {\n return this.asPath !== asPath;\n }\n },\n {\n /**\n * Prefetch page code, you may wait for the data during page rendering.\n * This feature only works in production!\n * @param url the href of prefetched page\n * @param asPath the as path of the prefetched page\n */ key: \"prefetch\",\n value: function prefetch(url) {\n var asPath = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : url, options = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};\n var _this = this;\n return _async_to_generator(function() {\n var parsed, pathname, query, parsedAs, localePathResult, pages, resolvedAs, locale, rewrites, ref, rewritesResult, route;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n if ( true && (0, _isBot).isBot(window.navigator.userAgent)) {\n // No prefetches for bots that render the link since they are typically navigating\n // links via the equivalent of a hard navigation and hence never utilize these\n // prefetches.\n return [\n 2\n ];\n }\n parsed = (0, _parseRelativeUrl).parseRelativeUrl(url);\n pathname = parsed.pathname, query = parsed.query;\n if (false) {}\n return [\n 4,\n _this.pageLoader.getPageList()\n ];\n case 1:\n pages = _state.sent();\n resolvedAs = asPath;\n locale = typeof options.locale !== \"undefined\" ? options.locale || undefined : _this.locale;\n if (true) return [\n 3,\n 3\n ];\n return [\n 4,\n (0, _routeLoader).getClientBuildManifest()\n ];\n case 2:\n ref = _state.sent(), rewrites = ref.__rewrites, ref;\n rewritesResult = (0, _resolveRewrites).default((0, _addBasePath).addBasePath((0, _addLocale).addLocale(asPath, _this.locale), true), pages, rewrites, parsed.query, function(p) {\n return resolveDynamicRoute(p, pages);\n }, _this.locales);\n if (rewritesResult.externalDest) {\n return [\n 2\n ];\n }\n resolvedAs = (0, _removeLocale).removeLocale((0, _removeBasePath).removeBasePath(rewritesResult.asPath), _this.locale);\n if (rewritesResult.matchedPage && rewritesResult.resolvedHref) {\n // if this directly matches a page we need to update the href to\n // allow the correct page chunk to be loaded\n pathname = rewritesResult.resolvedHref;\n parsed.pathname = pathname;\n url = (0, _formatUrl).formatWithValidation(parsed);\n }\n _state.label = 3;\n case 3:\n parsed.pathname = resolveDynamicRoute(parsed.pathname, pages);\n if ((0, _isDynamic).isDynamicRoute(parsed.pathname)) {\n pathname = parsed.pathname;\n parsed.pathname = pathname;\n Object.assign(query, (0, _routeMatcher).getRouteMatcher((0, _routeRegex).getRouteRegex(parsed.pathname))((0, _parsePath).parsePath(asPath).pathname) || {});\n url = (0, _formatUrl).formatWithValidation(parsed);\n }\n // Prefetch is not supported in development mode because it would trigger on-demand-entries\n if (true) {\n return [\n 2\n ];\n }\n route = (0, _removeTrailingSlash).removeTrailingSlash(pathname);\n return [\n 4,\n Promise.all([\n _this.pageLoader._isSsg(route).then(function(isSsg) {\n return isSsg ? fetchNextData({\n dataHref: _this.pageLoader.getDataHref({\n href: url,\n asPath: resolvedAs,\n locale: locale\n }),\n isServerRender: false,\n parseJSON: true,\n inflightCache: _this.sdc,\n persistCache: !_this.isPreview,\n isPrefetch: true,\n unstable_skipClientCache: options.unstable_skipClientCache || options.priority && !!true\n }).then(function() {\n return false;\n }) : false;\n }),\n _this.pageLoader[options.priority ? \"loadPage\" : \"prefetch\"](route)\n ])\n ];\n case 4:\n _state.sent();\n return [\n 2\n ];\n }\n });\n })();\n }\n },\n {\n key: \"fetchComponent\",\n value: function fetchComponent(route) {\n var _this = this;\n return _async_to_generator(function() {\n var handleCancelled, componentResult, err;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n handleCancelled = getCancelledHandler({\n route: route,\n router: _this\n });\n _state.label = 1;\n case 1:\n _state.trys.push([\n 1,\n 3,\n ,\n 4\n ]);\n return [\n 4,\n _this.pageLoader.loadPage(route)\n ];\n case 2:\n componentResult = _state.sent();\n handleCancelled();\n return [\n 2,\n componentResult\n ];\n case 3:\n err = _state.sent();\n handleCancelled();\n throw err;\n case 4:\n return [\n 2\n ];\n }\n });\n })();\n }\n },\n {\n key: \"_getData\",\n value: function _getData(fn) {\n var _this = this;\n var cancelled = false;\n var cancel = function() {\n cancelled = true;\n };\n this.clc = cancel;\n return fn().then(function(data) {\n if (cancel === _this.clc) {\n _this.clc = null;\n }\n if (cancelled) {\n var err = new Error(\"Loading initial props cancelled\");\n err.cancelled = true;\n throw err;\n }\n return data;\n });\n }\n },\n {\n key: \"_getFlightData\",\n value: function _getFlightData(dataHref) {\n // Do not cache RSC flight response since it's not a static resource\n return fetchNextData({\n dataHref: dataHref,\n isServerRender: true,\n parseJSON: false,\n inflightCache: this.sdc,\n persistCache: false,\n isPrefetch: false\n }).then(function(param) {\n var text = param.text;\n return {\n data: text\n };\n });\n }\n },\n {\n key: \"getInitialProps\",\n value: function getInitialProps(Component, ctx) {\n var ref = this.components[\"/_app\"], App = ref.Component;\n var AppTree = this._wrapApp(App);\n ctx.AppTree = AppTree;\n return (0, _utils).loadGetInitialProps(App, {\n AppTree: AppTree,\n Component: Component,\n router: this,\n ctx: ctx\n });\n }\n },\n {\n key: \"route\",\n get: function get() {\n return this.state.route;\n }\n },\n {\n key: \"pathname\",\n get: function get() {\n return this.state.pathname;\n }\n },\n {\n key: \"query\",\n get: function get() {\n return this.state.query;\n }\n },\n {\n key: \"asPath\",\n get: function get() {\n return this.state.asPath;\n }\n },\n {\n key: \"locale\",\n get: function get() {\n return this.state.locale;\n }\n },\n {\n key: \"isFallback\",\n get: function get() {\n return this.state.isFallback;\n }\n },\n {\n key: \"isPreview\",\n get: function get() {\n return this.state.isPreview;\n }\n }\n ]);\n return Router;\n}();\nRouter.events = (0, _mitt).default();\nexports[\"default\"] = Router; //# sourceMappingURL=router.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }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lZEhyZWYpKShhcyk7XG4gICAgICAgICAgICAgICAgICAgIE9iamVjdC5hc3NpZ24ocGFyc2VkUmV3cml0ZVRhcmdldC5xdWVyeSwgbWF0Y2hlcyB8fCB7fSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgICAgICAgIHR5cGU6ICdyZXdyaXRlJyxcbiAgICAgICAgICAgICAgICAgICAgcGFyc2VkQXM6IHBhcnNlZFJld3JpdGVUYXJnZXQsXG4gICAgICAgICAgICAgICAgICAgIHJlc29sdmVkSHJlZlxuICAgICAgICAgICAgICAgIH07XG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgICAgICBjb25zdCBzcmMgPSAoMCwgX3BhcnNlUGF0aCkucGFyc2VQYXRoKHNvdXJjZSk7XG4gICAgICAgIGNvbnN0IHBhdGhuYW1lID0gKDAsIF9mb3JtYXROZXh0UGF0aG5hbWVJbmZvKS5mb3JtYXROZXh0UGF0aG5hbWVJbmZvKF9leHRlbmRzKHt9LCAoMCwgX2dldE5leHRQYXRobmFtZUluZm8pLmdldE5leHRQYXRobmFtZUluZm8oc3JjLnBhdGhuYW1lLCB7XG4gICAgICAgICAgICBuZXh0Q29uZmlnLFxuICAgICAgICAgICAgcGFyc2VEYXRhOiB0cnVlXG4gICAgICAgIH0pLCB7XG4gICAgICAgICAgICBkZWZhdWx0TG9jYWxlOiBvcHRpb25zLnJvdXRlci5kZWZhdWx0TG9jYWxlLFxuICAgICAgICAgICAgYnVpbGRJZDogJydcbiAgICAgICAgfSkpO1xuICAgICAgICByZXR1cm4gUHJvbWlzZS5yZXNvbHZlKHtcbiAgICAgICAgICAgIHR5cGU6ICdyZWRpcmVjdC1leHRlcm5hbCcsXG4gICAgICAgICAgICBkZXN0aW5hdGlvbjogYCR7cGF0aG5hbWV9JHtzcmMucXVlcnl9JHtzcmMuaGFzaH1gXG4gICAgICAgIH0pO1xuICAgIH1cbiAgICBjb25zdCByZWRpcmVjdFRhcmdldCA9IHJlc3BvbnNlLmhlYWRlcnMuZ2V0KCd4LW5leHRqcy1yZWRpcmVjdCcpO1xuICAgIGlmIChyZWRpcmVjdFRhcmdldCkge1xuICAgICAgICBpZiAocmVkaXJlY3RUYXJnZXQuc3RhcnRzV2l0aCgnLycpKSB7XG4gICAgICAgICAgICBjb25zdCBzcmMgPSAoMCwgX3BhcnNlUGF0aCkucGFyc2VQYXRoKHJlZGlyZWN0VGFyZ2V0KTtcbiAgICAgICAgICAgIGNvbnN0IHBhdGhuYW1lID0gKDAsIF9mb3JtYXROZXh0UGF0aG5hbWVJbmZvKS5mb3JtYXROZXh0UGF0aG5hbWVJbmZvKF9leHRlbmRzKHt9LCAoMCwgX2dldE5leHRQYXRobmFtZUluZm8pLmdldE5leHRQYXRobmFtZUluZm8oc3JjLnBhdGhuYW1lLCB7XG4gICAgICAgICAgICAgICAgbmV4dENvbmZpZyxcbiAgICAgICAgICAgICAgICBwYXJzZURhdGE6IHRydWVcbiAgICAgICAgICAgIH0pLCB7XG4gICAgICAgICAgICAgICAgZGVmYXVsdExvY2FsZTogb3B0aW9ucy5yb3V0ZXIuZGVmYXVsdExvY2FsZSxcbiAgICAgICAgICAgICAgICBidWlsZElkOiAnJ1xuICAgICAgICAgICAgfSkpO1xuICAgICAgICAgICAgcmV0dXJuIFByb21pc2UucmVzb2x2ZSh7XG4gICAgICAgICAgICAgICAgdHlwZTogJ3JlZGlyZWN0LWludGVybmFsJyxcbiAgICAgICAgICAgICAgICBuZXdBczogYCR7cGF0aG5hbWV9JHtzcmMucXVlcnl9JHtzcmMuaGFzaH1gLFxuICAgICAgICAgICAgICAgIG5ld1VybDogYCR7cGF0aG5hbWV9JHtzcmMucXVlcnl9JHtzcmMuaGFzaH1gXG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gUHJvbWlzZS5yZXNvbHZlKHtcbiAgICAgICAgICAgIHR5cGU6ICdyZWRpcmVjdC1leHRlcm5hbCcsXG4gICAgICAgICAgICBkZXN0aW5hdGlvbjogcmVkaXJlY3RUYXJnZXRcbiAgICAgICAgfSk7XG4gICAgfVxuICAgIHJldHVybiBQcm9taXNlLnJlc29sdmUoe1xuICAgICAgICB0eXBlOiAnbmV4dCdcbiAgICB9KTtcbn1cbmZ1bmN0aW9uIHdpdGhNaWRkbGV3YXJlRWZmZWN0cyhvcHRpb25zKSB7XG4gICAgcmV0dXJuIG1hdGNoZXNNaWRkbGV3YXJlKG9wdGlvbnMpLnRoZW4oKG1hdGNoZXMpPT57XG4gICAgICAgIGlmIChtYXRjaGVzICYmIG9wdGlvbnMuZmV0Y2hEYXRhKSB7XG4gICAgICAgICAgICByZXR1cm4gb3B0aW9ucy5mZXRjaERhdGEoKS50aGVuKChkYXRhKT0+Z2V0TWlkZGxld2FyZURhdGEoZGF0YS5kYXRhSHJlZiwgZGF0YS5yZXNwb25zZSwgb3B0aW9ucykudGhlbigoZWZmZWN0KT0+KHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGFIcmVmOiBkYXRhLmRhdGFIcmVmLFxuICAgICAgICAgICAgICAgICAgICAgICAgY2FjaGVLZXk6IGRhdGEuY2FjaGVLZXksXG4gICAgICAgICAgICAgICAgICAgICAgICBqc29uOiBkYXRhLmpzb24sXG4gICAgICAgICAgICAgICAgICAgICAgICByZXNwb25zZTogZGF0YS5yZXNwb25zZSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHRleHQ6IGRhdGEudGV4dCxcbiAgICAgICAgICAgICAgICAgICAgICAgIGVmZmVjdFxuICAgICAgICAgICAgICAgICAgICB9KSkpLmNhdGNoKChfZXJyKT0+e1xuICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAqIFRPRE86IFJldmlzaXQgdGhpcyBpbiB0aGUgZnV0dXJlLlxuICAgICAgICAgICAqIEZvciBub3cgd2Ugd2lsbCBub3QgY29uc2lkZXIgbWlkZGxld2FyZSBkYXRhIGVycm9ycyB0byBiZSBmYX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ICAgICAgIG1ldGhvZDogKHJlZjEgPSBwYXJhbXMgPT0gbnVsbCA/IHZvaWQgMCA6IHBhcmFtcy5tZXRob2QpICE9IG51bGwgPyByZWYxIDogJ0dFVCdcbiAgICAgICAgfSkudGhlbigocmVzcG9uc2UpPT57XG4gICAgICAgICAgICBpZiAocmVzcG9uc2Uub2sgJiYgKHBhcmFtcyA9PSBudWxsID8gdm9pZCAwIDogcGFyYW1zLm1ldGhvZCkgPT09ICdIRUFEJykge1xuICAgICAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgICAgICAgIGRhdGFIcmVmLFxuICAgICAgICAgICAgICAgICAgICByZXNwb25zZSxcbiAgICAgICAgICAgICAgICAgICAgdGV4dDogJycsXG4gICAgICAgICAgICAgICAgICAgIGpzb246IHt9LFxuICAgICAgICAgICAgICAgICAgICBjYWNoZUtleVxuICAgICAgICAgICAgICAgIH07XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4gcmVzcG9uc2UudGV4dCgpLnRoZW4oKHRleHQpPT57XG4gICAgICAgICAgICAgICAgaWYgKCFyZXNwb25zZS5vaykge1xuICAgICAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAqIFdoZW4gdGhlIGRhdGEgcmVzcG9uc2UgaXMgYSByZWRpcmVjdCBiZWNhdXNlIG9mIGEgbWlkZGxld2FyZVxuICAgICAgICAgICAgICogd2UgZG8gbm90IGNvbnNpZGVyIGl0IGFuIGVycm9yLiBUaGUgaGVhZGVycyBtdXN0IGJyaW5nIHRoZVxuICAgICAgICAgICAgICogbWFwcGVkIGxvY2F0aW9uLlxuICAgICAgICAgICAgICogVE9ETzogQ2hhbmdlIHRoZSBzdGF0dXMgY29kZSBpbiB0aGUgaGFuZGxlci5cbiAgICAgICAgICAgICAqLyBpZiAoaGFzTWlkZGxld2FyZSAmJiBbXG4gICAgICAgICAgICAgICAgICAgICAgICAzMDEsXG4gICAgICAgICAgICAgICAgICAgICAgICAzMDIsXG4gICAgICAgICAgICAgICAgICAgICAgICAzMDcsXG4gICAgICAgICAgICAgICAgICAgICAgICAzMDhcbiAgICAgICAgICAgICAgICAgICAgXS5pbmNsdWRlcyhyZXNwb25zZS5zdGF0dXMpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRhdGFIcmVmLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJlc3BvbnNlLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRleHQsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAganNvbjoge30sXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY2FjaGVLZXlcbiAgICAgICAgICAgICAgICAgICAgICAgIH07XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgaWYgKCFoYXNNaWRkbGV3YXJlICYmIHJlc3BvbnNlLnN0YXR1cyA9PT0gNDA0KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICB2YXIgcmVmO1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKChyZWYgPSB0cnlUb1BhcnNlQXNKU09OKHRleHQpKSA9PSBudWxsID8gdm9pZCAwIDogcmVmLm5vdEZvdW5kKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF0YUhyZWYsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGpzb246IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5vdEZvdW5kOiBTU0dfREFUQV9OT1RfRk9VTkRcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcmVzcG9uc2UsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRleHQsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhY2hlS2V5XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBjb25zdCBlcnJvciA9IG5ldyBFcnJvcihgRmFpbGVkIHRvIGxvYWQgc3RhdGljIHByb3BzYCk7XG4gICAgICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAgICogV2Ugc2hvdWxkIG9ubHkgdHJpZ2dlciBhIHNlcnZlci1zaWRlIHRyYW5zaXRpb24gaWYgdGhpcyB3YXNcbiAgICAgICAgICAgICAqIGNhdXNlZCBvbiBhIGNsaWVudC1zaWRlIHRyYW5zaXRpb24uIE90aGVyd2lzZSwgd2UnZCBnZXQgaW50b1xuICAgICAgICAgICAgICogYW4gaW5maW5pdGUgbG9vcC5cbiAgICAgICAgICAgICAqLyBpZiAoIWlzU2VydmVyUmVuZGVyKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAoMCwgX3JvdXRlTG9hZGVyKS5tYXJrQXNzZXRFcnJvcihlcnJvcik7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgdGhyb3cgZXJyb3I7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgICAgICAgIGRhdGFIcmVmLFxuICAgICAgICAgICAgICAgICAgICBqc29uOiBwYXJzZUpTT04gPyB0cnlUb1BhcnNlQXNKU09OKHRleHQpIDogbnVsbCxcbiAgICAgICAgICAgICAgICAgICAgcmVzcG9uc2UsXG4gICAgICAgICAgICAgICAgICAgIHRleHQsXG4gICAgICAgICAgICAgICAgICAgIGNhY2hlS2V5XG4gICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9KS50aGVuKChkYXRhKT0+e1xuICAgICAgICAgICAgaWYgKCFwZXJzaXN0Q2FjaGUgfHwgcHJvY2Vzcy5lbnYu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ZiAocHJvY2Vzcy5lbnYuX19ORVhUX0kxOE5fU1VQUE9SVCkge1xuICAgICAgICAgICAgICAgICAgICAvLyBpZiB3ZSBhcmUgbmF2aWdhdGluZyB0byBhIGRvbWFpbiBsb2NhbGUgZW5zdXJlIHdlIHJlZGlyZWN0IHRvIHRoZVxuICAgICAgICAgICAgICAgICAgICAvLyBjb3JyZWN0IGRvbWFpblxuICAgICAgICAgICAgICAgICAgICBpZiAoIWRpZE5hdmlnYXRlICYmIGRldGVjdGVkRG9tYWluICYmIF90aGlzLmlzTG9jYWxlRG9tYWluICYmIHNlbGYubG9jYXRpb24uaG9zdG5hbWUgIT09IGRldGVjdGVkRG9tYWluLmRvbWFpbikge1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgYXNOb0Jhc2VQYXRoID0gKDAsIF9yZW1vdmVCYXNlUGF0aCkucmVtb3ZlQmFzZVBhdGgoYXMpO1xuICAgICAgICAgICAgICAgICAgICAgICAgaGFuZGxlSGFyZE5hdmlnYXRpb24oe1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVybDogYGh0dHAke2RldGVjdGVkRG9tYWluLmh0dHAgPyAnJyA6ICdzJ306Ly8ke2RldGVjdGVkRG9tYWluLmRvbWFpbn0keygwLCBfYWRkQmFzZVBhdGgpLmFkZEJhc2VQYXRoKGAke25leHRTdGF0ZS5sb2NhbGUgPT09IGRldGVjdGVkRG9tYWluLmRlZmF1bHRMb2NhbGUgPyAnJyA6IGAvJHtuZXh0U3RhdGUubG9jYWxlfWB9JHthc05vQmFzZVBhdGggPT09ICcvJyA/ICcnIDogYXNOb0Jhc2VQYXRofWAgfHwgJy8nKX1gLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJvdXRlcjogX3RoaXNcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgLy8gdGhpcyB3YXMgcHJldmlvdXNseSBhIHJldHVybiBidXQgd2FzIHJlbW92ZWQgaW4gZmF2b3JcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIG9mIGJldHRlciBkZWFkIGNvZGUgZWxpbWluYXRpb24gd2l0aCByZWdlbmVyYXRvciBydW50aW1lXG4gICAgICAgICAgICAgICAgICAgICAgICBkaWROYXZpZ2F0ZSA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgaWYgKGRpZE5hdmlnYXRlKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBuZXcgUHJvbWlzZSgoKT0+e30pO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIC8vIG1hcmtpbmcgcm91dGUgY2hhbmdlcyBhcyBhIG5hdmlnYXRpb24gc3RhcnQgZW50cnlcbiAgICAgICAgICAgIGlmIChfdXRpbHMuU1QpIHtcbiAgICAgICAgICAgICAgICBwZXJmb3JtYW5jZS5tYXJrKCdyb3V0ZUNoYW5nZScpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgY29uc3QgeyBzaGFsbG93ID1mYWxzZSAsIHNjcm9sbCA9dHJ1ZSAgfSA9IG9wdGlvbnM7XG4gICAgICAgICAgICBjb25zdCByb3V0ZVByb3BzID0ge1xuICAgICAgICAgICAgICAgIHNoYWxsb3dcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgICBpZiAoX3RoaXMuX2luRmxpZ2h0Um91dGUgJiYgX3RoaXMuY2xjKSB7XG4gICAgICAgICAgICAgICAgaWYgKCFpc1Nzcikge1xuICAgICAgICAgICAgICAgICAgICBSb3V0ZXIuZXZlbnRzLmVtaXQoJ3JvdXRlQ2hhbmdlRXJyb3InLCBidWlsZENhbmNlbGxhdGlvbkVycm9yKCksIF90aGlzLl9pbkZsaWdodFJvdXRlLCByb3V0ZVByb3BzKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgX3RoaXMuY2xjKCk7XG4gICAgICAgICAgICAg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bWl0KCdoYXNoQ2hhbmdlU3RhcnQnLCBhcywgcm91dGVQcm9wcyk7XG4gICAgICAgICAgICAgICAgLy8gVE9ETzogZG8gd2UgbmVlZCB0aGUgcmVzb2x2ZWQgaHJlZiB3aGVuIG9ubHkgYSBoYXNoIGNoYW5nZT9cbiAgICAgICAgICAgICAgICBfdGhpcy5jaGFuZ2VTdGF0ZShtZXRob2QsIHVybCwgYXMsIF9leHRlbmRzKHt9LCBvcHRpb25zLCB7XG4gICAgICAgICAgICAgICAgICAgIHNjcm9sbDogZmFsc2VcbiAgICAgICAgICAgICAgICB9KSk7XG4gICAgICAgICAgICAgICAgaWYgKHNjcm9sbCkge1xuICAgICAgICAgICAgICAgICAgICBfdGhpcy5zY3JvbGxUb0hhc2goY2xlYW5lZEFzKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICAgICAgeWllbGQgX3RoaXMuc2V0KG5leHRTdGF0ZSwgX3RoaXMuY29tcG9uZW50c1tuZXh0U3RhdGUucm91dGVdLCBudWxsKTtcbiAgICAgICAgICAgICAgICB9IGNhdGNoIChlcnIpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKCgwLCBfaXNFcnJvcikuZGVmYXVsdChlcnIpICYmIGVyci5jYW5jZWxsZWQpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIFJvdXRlci5ldmVudHMuZW1pdCgncm91dGVDaGFuZ2VFcnJvcicsIGVyciwgY2xlYW5lZEFzLCByb3V0ZVByb3BzKTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB0aHJvdyBlcnI7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIFJvdXRlci5ldmVudHMuZW1pdCgnaGFzaENoYW5nZUNvbXBsZXRlJywgYXMsIHJvdXRlUHJvcHMpO1xuICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xuICAgICAgICAgICAgfVxuICAgIC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AgfVxuICAgICAgICAgICAgaWYgKHNob3VsZFJlc29sdmVIcmVmICYmIHBhdGhuYW1lICE9PSAnL19lcnJvcicpIHtcbiAgICAgICAgICAgICAgICBvcHRpb25zLl9zaG91bGRSZXNvbHZlSHJlZiA9IHRydWU7XG4gICAgICAgICAgICAgICAgaWYgKHByb2Nlc3MuZW52Ll9fTkVYVF9IQVNfUkVXUklURVMgJiYgYXMuc3RhcnRzV2l0aCgnLycpKSB7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHJld3JpdGVzUmVzdWx0ID0gKDAsIF9yZXNvbHZlUmV3cml0ZXMpLmRlZmF1bHQoKDAsIF9hZGRCYXNlUGF0aCkuYWRkQmFzZVBhdGgoKDAsIF9hZGRMb2NhbGUpLmFkZExvY2FsZShjbGVhbmVkQXMsIG5leHRTdGF0ZS5sb2NhbGUpLCB0cnVlKSwgcGFnZXMsIHJld3JpdGVzLCBxdWVyeSwgKHApPT5yZXNvbHZlRHluYW1pY1JvdXRlKHAsIHBhZ2VzKSwgX3RoaXMubG9jYWxlcyk7XG4gICAgICAgICAgICAgICAgICAgIGlmIChyZXdyaXRlc1Jlc3VsdC5leHRlcm5hbERlc3QpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGhhbmRsZUhhcmROYXZpZ2F0aW9uKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGFzLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJvdXRlcjogX3RoaXNcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgaWYgKCFpc01pZGRsZXdhcmVNYXRjaCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgcmVzb2x2ZWRBcyA9IHJld3JpdGVzUmVzdWx0LmFzUGF0aDtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBpZiAocmV3cml0ZXNSZXN1bHQubWF0Y2hlZFBhZ2UgJiYgcmV3cml0ZXNSZXN1bHQucmVzb2x2ZWRIcmVmKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBpZiB0aGlzIGRpcmVjdGx5IG1hdGNoZXMgYSBwYWdlIHdlIG5lZWQgdG8gdXBkYXRlIHRoZSBocmVmIHRvXG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBhbGxvdyB0aGUgY29ycmVjdCBwYWdlIGNodW5rIHRvIGJlIGxvYWRlZFxuICAgICAgICAgICAgICAgICAgICAgICAgcGF0aG5hbWUgPSByZXdyaXRlc1Jlc3VsdC5yZXNvbHZlZEhyZWY7XG4gICAgICAgICAgICAgICAgICAgICAgICBwYXJzZWQucGF0aG5hbWUgPSAoMCwgX2FkZEJhc2VQYXRoKS5hZGRCYXNlUGF0aChwYXRobmFtZSk7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIWlzTWlkZGxld2FyZU1hdGNoKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsID0gKDAsIF9mb3JtYXRVcmwpLmZvcm1hdFdpdGhWYWxpZGF0aW9uKHBhcnNlZCk7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICBwYXJzZWQucGF0aG5hbWUgPSByZXNvbHZlRHluYW1pY1JvdXRlKHBhdGhuYW1lLCBwYWdlcyk7XG4gICAgICAgICAgICAgICAgICAgIGlmIChwYXJzZWQucGF0aG5hbWUgIT09IHBhdGhuYW1lKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBwYXRobmFtZSA9IHBhcnNlZC5wYXRobmFtZTtcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlZC5wYXRobmFtZSA9ICgwLCBfYWRkQmFzZVBhdGgpLmFkZEJhc2VQYXRoKHBhdGhuYW1lKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICghaXNNaWRkbGV3YXJlTWF0Y2gpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmwgPSAoMCwgX2Zvcm1hdFVybCkuZm9ybWF0V2l0aFZhbGlkYXRpb24ocGFyc2VkKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmICghaXNMb2NhbFVSTChhcykpIHtcbiAgICAgICAgICAgICAgICBpZiAocHJvY2Vzcy5lbnYuTk9ERV9FTlYgIT09ICdwcm9kdWN0aW9uJykge1xuICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoYEludmFsaWQgaHJlZjogXCIke3VybH1cIiBhbmQgYXM6IFwiJHthc31cIiwgcmVjZWl2ZWQgcmVsYXRpdmUgaHJlZiBhbmQgZXh0ZXJuYWwgYXNgICsgYFxcblNlZSBtb3JlIGluZm86IGh0dHBzOi8vbmV4dGpzLm9yZy9kb2NzL21lc3NhZ2VzL2ludmFsaWQtcmVsYXRpdmUtdXJsLWV4dGVybmFsLWFzYCk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGhhbmRsZUhhcmROYXZpZ2F0aW9uKHtcbiAgICAgICAgICAgICAgICAgICAgdXJsOiBhcyxcbiAgICAgICAgICAgICAgICAgICAgcm91dGVyOiBfdGhpc1xuICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIHJldHVybiBmYWxzZTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJlc29sdmVkQXMgPSAoMCwgX3JlbW92ZUxvY2FsZSkucmVtb3ZlTG9jYWxlKCgwLCBfcmVtb3ZlQmFzZVBhdGgpLnJlbW92ZUJhc2VQYXRoKHJlc29sdmVkQXMpLCBuZXh0U3RhdGUubG9jYWxlKTtcbiAgIC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YmxlLWhyZWYtYXMnfWApO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChzaG91bGRJbnRlcnBvbGF0ZSkge1xuICAgICAgICAgICAgICAgICAgICBhcyA9ICgwLCBfZm9ybWF0VXJsKS5mb3JtYXRXaXRoVmFsaWRhdGlvbihPYmplY3QuYXNzaWduKHt9LCBwYXJzZWRBcywge1xuICAgICAgICAgICAgICAgICAgICAgICAgcGF0aG5hbWU6IGludGVycG9sYXRlZEFzLnJlc3VsdCxcbiAgICAgICAgICAgICAgICAgICAgICAgIHF1ZXJ5OiBvbWl0KHF1ZXJ5LCBpbnRlcnBvbGF0ZWRBcy5wYXJhbXMpXG4gICAgICAgICAgICAgICAgICAgIH0pKTtcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICAvLyBNZXJnZSBwYXJhbXMgaW50byBgcXVlcnlgLCBvdmVyd3JpdGluZyBhbnkgc3BlY2lmaWVkIGluIHNlYXJjaFxuICAgICAgICAgICAgICAgICAgICBPYmplY3QuYXNzaWduKHF1ZXJ5LCByb3V0ZU1hdGNoKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAoIWlzUXVlcnlVcGRhdGluZykge1xuICAgICAgICAgICAgICAgIFJvdXRlci5ldmVudHMuZW1pdCgncm91dGVDaGFuZ2VTdGFydCcsIGFzLCByb3V0ZVByb3BzKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICAgICAgdmFyIHJlZjIsIHJlZjM7XG4gICAgICAgICAgICAgICAgbGV0IHJvdXRlSW5mbyA9IHlpZWxkIF90aGlzLmdldFJvdXRlSW5mbyh7XG4gICAgICAgICAgICAgICAgICAgIHJvdXRlLFxuICAgICAgICAgICAgICAgICAgICBwYXRobmFtZSxcbiAgICAgICAgICAgICAgICAgICAgcXVlcnksXG4gICAgICAgICAgICAgICAgICAgIGFzLFxuICAgICAgICAgICAgICAgICAgICByZXNvbHZlZEFzLFxuICAgICAgICAgICAgICAgICAgICByb3V0ZVByb3BzLFxuICAgICAgICAgICAgICAgICAgICBsb2NhbGU6IG5leHRTdGF0ZS5sb2NhbGUsXG4gICAgICAgICAgICAgICAgICAgIGlzUHJldmlldzogbmV4dFN0YXRlLmlzUHJldmlldyxcbiAgICAgICAgICAgICAgICAgICAgaGFzTWlkZGxld2FyZTogaXNNaWRkbGV3YXJlTWF0Y2hcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICBpZiAoJ3JvdXRlJyBpbiByb3V0ZUluZm8gJiYgaXNNaWRkbGV3YXJlTWF0Y2gpIHtcbiAgICAgICAgICAgICAgICAgICAgcGF0aG5hbWUgPSByb3V0ZUluZm8ucm91dGUgfHwgcm91dGU7XG4gICAgICAgICAgICAgICAgICAgIHJvdXRlID0gcGF0aG5hbWU7XG4gICAgICAgICAgICAgICAgICAgIGlmICghcm91dGVQcm9wcy5zaGFsbG93KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBxdWVyeSA9IE9iamVjdC5hc3NpZ24oe30sIHJvdXRlSW5mby5xdWVyeSB8fCB7fSwgcXVlcnkpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IGNsZWFuZWRQYXJzZWRQYXRobmFtZSA9ICgwLCBfaGFzQmFzZVBhdGgpLmhhc0Jhc2VQYXRoKHBhcnNlZC5wYXRobmFtZSkgPyAoMCwgX3JlbW92ZUJhc2VQYXRoKS5yZW1vdmVCYXNlUGF0aChwYXJzZWQucGF0aG5hbWUpIDogcGFyc2VkLnBhdGhuYW1lO1xuICAgICAgICAgICAgICAgICAgICBpZiAocm91dGVNYXRjaCAmJiBwYXRobmFtZSAhPT0gY2xlYW5lZFBhcnNlZFBhdGhuYW1lKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBPYmplY3Qua2V5cyhyb3V0ZU1hdGNoKS5mb3JFYWNoKChrZXkpPT57XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHJvdXRlTWF0Y2ggJiYgcXVlcnlba2V5XSA9PT0gcm91dGVNYXRjaFtrZXldKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRlbGV0ZSBxdWVyeVtrZXldO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIGlmICgoMCwgX2lzRHluYW1pYykuaXNEeW5hbWljUm91dGUocGF0aG5hbWUpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zdCBwcmVmaXhlZEFzID0gIXJvdXRlUHJvcHMuc2hhbGxvdyAmJiByb3V0ZUluZm8ucmVzb2x2ZWRBcyA/IHJvdXRlSW5mby5yZXNvbHZlZEFzIDogKDAsIF9hZGRCYXNlUGF0aCkuYWRkQmFzZVBhdGgoKDAsIF9hZGRMb2NhbGUpLmFkZExvY2FsZShuZXcgVVJMKGFzLCBsb2NhdGlvbi5ocmVmKS5wYXRobmFtZSwgbmV4dFN0YXRlLmxvY2FsZSksIHRydWUpO1xuICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHJld3JpdGVBcyA9IHByZWZpeGVkQXM7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoKDAsIF9oYXNCYXNlUGF0aCkuaGFzQmFzZVBhdGgocmV3cml0ZUFzKSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJld3JpdGVBcyA9ICgwLCBfcmVtb3ZlQmFzZVBhdGgpLnJlbW92ZUJhc2VQYXRoKHJld3JpdGVBcyk7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAocHJvY2Vzcy5lbnYuX19ORVhUX0kxOE5fU1VQUE9SVCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGxvY2FsZVJlc3VsdCA9ICgwLCBfbm9ybWFsaXplTG9jYWxlUGF0aCkubm9ybWFsaXplTG9jYWxlUGF0aChyZXdyaXRlQXMsIF90aGlzLmxvY2FsZXMpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5leHRTdGF0ZS5sb2NhbGUgPSBsb2NhbGVSZXN1bHQuZGV0ZWN0ZWRMb2NhbGUgfHwgbmV4dFN0YXRlLmxvY2FsZTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXdyaXRlQXMgPSBsb2NhbGVSZXN1bHQucGF0aG5hbWU7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zdCByb3V0ZVJlZ2V4ID0gKDAsIF9yb3V0ZVJlZ2V4KS5nZXRSb3V0ZVJlZ2V4KHBhdGhuYW1lKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGN1clJvdXRlTWF0Y2ggPSAoMCwgX3JvdXRlTWF0Y2hlcikuZ2V0Um91dGVNYXRjaGVyKHJvdXRlUmVnZXgpKHJld3JpdGVBcyk7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoY3VyUm91dGVNYXRjaCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIE9iamVjdC5hc3NpZ24ocXVlcnksIGN1clJvdXRlTWF0Y2gpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIC8vIElmIHRoZSByb3V0ZUluZm8gYnJpbmdzIGEgcmVkaXJlY3Qgd2Ugc2ltcGx5IGFwcGx5IGl0LlxuICAgICAgICAgICAgICAgIGlmICgndHlwZScgaW4gcm91dGVJbmZvKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChyb3V0ZUluZm8udHlwZSA9PT0gJ3JlZGlyZWN0LWludGVybmFsJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIF90aGlzLmNoYW5nZShtZXRob2QsIHJvdXRlSW5mby5uZXdVcmwsIHJvdXRlSW5mby5uZXdBcywgb3B0aW9ucyk7XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBoYW5kbGVIYXJkTmF2aWdhdGlvbih7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiByb3V0ZUluZm8uZGVzdGluYXRpb24sXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcm91dGVyOiBfdGhpc1xuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gbmV3IFByb21pc2UoKCk9Pnt9KTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBsZXQgeyBlcnJvciAsIHByb3BzICwgX19OX1NTRyAsIF9fTl9TU1AgIH0gPSByb3V0ZUluZm87XG4gICAgICAgICAgICAgICAgY29uc3QgY29tcG9uZW50ID0gcm91dGVJbmZvLkNvbXBvbmVudDtcbiAgICAgICAgICAgICAgICBpZiAoY29tcG9uZW50ICYmIGNvbXBvbmVudC51bnN0YWJsZV9zY3JpcHRMb2FkZXIpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc3Qgc2NyaXB0cyA9IFtdLmNvbmNhdChjb21wb25lbnQudW5zdGFibGVfc2NyaXB0TG9hZGVyKCkpO1xuICAgICAgICAgICAgICAgICAgICBzY3JpcHRzLmZvckVhY2goKHNjcmlwdCk9PntcbiAgICAgICAgICAgICAgICAgICAgICAgICgwLCBfc2NyaXB0KS5oYW5kbGVDbGllbnRTY3JpcHRMb2FkKHNjcmlwdC5wcm9wcyk7XG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyBoYW5kbGUgcmVkaXJlY3Qgb24gY2xpZW50LXRyYW5zaXRpb25cbiAgICAgICAgICAgICAgICBpZiAoKF9fTl9TU0cgfHwgX19OX1NTUCkgJiYgcHJvcHMpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKHByb3BzLnBhZ2VQcm9wcyAmJiBwcm9wcy5wYWdlUHJvcHMuX19OX1JFRElSRUNUKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBVc2UgdGhlIGRlc3RpbmF0aW9uIGZyb20gcmVkaXJlY3Qgd2l0aG91dCBhZGRpbmcgbG9jYWxlXG4gICAgICAgICAgICAgICAgICAgICAgICBvcHRpb25zLmxvY2FsZSA9IGZhbHNlO1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgZGVzdGluYXRpb24gPSBwcm9wcy5wYWdlUHJvcHMuX19OX1JFRElSRUNUO1xuICAgICAgICAgICAgICAgICAgICAgICAgLy8gY2hlY2sgaWYgZGVzdGluYXRpb24gaXMgaW50ZXJuYWwgKHJlc29sdmVzIHRvIGEgcGFnZSkgYW5kIGF0dGVtcHRcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIGNsaWVudC1uYXZpZ2F0aW9uIGlmIGl0IGlzIGZhbGxpbmcgYmFjayB0byBoYXJkIG5hdmlnYXRpb24gaWZcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIGl0J3Mgbm90XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoZGVzdGluYXRpb24uc3RhcnRzV2l0aCgnLycpICYmIHByb3BzLnBhZ2VQcm9wcy5fX05fUkVESVJFQ1RfQkFTRV9QQVRIICE9PSBmYWxzZSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHBhcnNlZEhyZWYgPSAoMCwgX3BhcnNlUmVsYXRpdmVVcmwpLnBhcnNlUmVsYXRpdmVVcmwoZGVzdGluYXRpb24pO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhcnNlZEhyZWYucGF0aG5hbWUgPSByZXNvbHZlRHluYW1pY1JvdXRlKHBhcnNlZEhyZWYucGF0aG5hbWUsIHBhZ2VzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCB7IHVybDogbmV3VXJsICwgYXM6IG5ld0FzICB9ID0gcHJlcGFyZVVybEFzKF90aGlzLCBkZXN0aW5hdGlvbiwgZGVzdGluYXRpb24pO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBfdGhpcy5jaGFuZ2UobWV0aG9kLCBuZXdVcmwsIG5ld0FzLCBvcHRpb25zKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgICAgIGhhbmRsZUhhcmROYXZpZ2F0aW9uKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGRlc3RpbmF0aW9uLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJvdXRlcjogX3RoaXNcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG5ldyBQcm9taXNlKCgpPT57fSk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgbmV4dFN0YXRlLmlzUHJldmlldyA9ICEhcHJvcHMuX19OX1BSRVZJRVc7XG4gICAgICAgICAgICAgICAgICAgIC8vIGhhbmRsZSBTU0cgZGF0YSA0MDRcbiAgICAgICAgICAgICAgICAgICAgaWYgKHByb3BzLm5vdEZvdW5kID09PSBTU0dfREFUQV9OT1RfRk9VTkQpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGxldCBub3RGb3VuZFJvdXRlO1xuICAgICAgICAgICAgICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB5aWVsZCBfdGhpcy5mZXRjaENvbXBvbmVudCgnLzQwNCcpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5vdEZvdW5kUm91dGUgPSAnLzQwNCc7XG4gICAgICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChfKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbm90Rm91bmRSb3V0ZSA9ICcvX2Vycm9yJztcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgICAgIHJvdXRlSW5mbyA9IHlpZWxkIF90aGlzLmdldFJvdXRlSW5mbyh7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcm91dGU6IG5vdEZvdW5kUm91dGUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGF0aG5hbWU6IG5vdEZvdW5kUm91dGUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcXVlcnksXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYXMsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmVzb2x2ZWRBcyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByb3V0ZVByb3BzOiB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNoYWxsb3c6IGZhbHNlXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2NhbGU6IG5leHRTdGF0ZS5sb2NhbGUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaXNQcmV2aWV3OiBuZXh0U3RhdGUuaXNQcmV2aWV3XG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICgndHlwZScgaW4gcm91dGVJbmZvKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhyb3cgbmV3IEVycm9yKGBVbmV4cGVjdGVkIG1pZGRsZXdhcmUgZWZmZWN0IG9uIC80MDRgKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBSb3V0ZXIuZXZlbnRzLmVtaXQ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qcy9pc3N1ZXMvMzcxMzlcbiAgICAgICAgICAgICAgICBjb25zdCBjYW5Ta2lwVXBkYXRpbmcgPSBvcHRpb25zLl9oICYmICF1cGNvbWluZ1Njcm9sbFN0YXRlICYmICFyZWFkeVN0YXRlQ2hhbmdlICYmICFsb2NhbGVDaGFuZ2UgJiYgKDAsIF9jb21wYXJlU3RhdGVzKS5jb21wYXJlUm91dGVyU3RhdGVzKHVwY29taW5nUm91dGVyU3RhdGUsIF90aGlzLnN0YXRlKTtcbiAgICAgICAgICAgICAgICBpZiAoIWNhblNraXBVcGRhdGluZykge1xuICAgICAgICAgICAgICAgICAgICB5aWVsZCBfdGhpcy5zZXQodXBjb21pbmdSb3V0ZXJTdGF0ZSwgcm91dGVJbmZvLCB1cGNvbWluZ1Njcm9sbFN0YXRlKS5jYXRjaCgoZSk9PntcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlLmNhbmNlbGxlZCkgZXJyb3IgPSBlcnJvciB8fCBlO1xuICAgICAgICAgICAgICAgICAgICAgICAgZWxzZSB0aHJvdyBlO1xuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgaWYgKGVycm9yKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoIWlzUXVlcnlVcGRhdGluZykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIFJvdXRlci5ldmVudHMuZW1pdCgncm91dGVDaGFuZ2VFcnJvcicsIGVycm9yLCBjbGVhbmVkQXMsIHJvdXRlUHJvcHMpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgICAgdGhyb3cgZXJyb3I7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgaWYgKHByb2Nlc3MuZW52Ll9fTkVYVF9JMThOX1NVUFBPUlQpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChuZXh0U3RhdGUubG9jYWxlKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZG9jdW1lbnQuZG9jdW1lbnRFbGVtZW50LmxhbmcgPSBuZXh0U3RhdGUubG9jYWxlO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIGlmICghaXNRdWVyeVVwZGF0aW5nKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBSb3V0ZXIuZXZlbnRzLmVtaXQoJ3JvdXRlQ2hhbmdlQ29tcGxldGUnLCBhcywgcm91dGVQcm9wcyk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgLy8gQSBoYXNoIG1hcmsgIyBpcyB0aGUgb3B0aW9uYWwgbGFzdCBwYXJ0IG9mIGEgVVJMXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IGhhc2hSZWdleCA9IC8jLiskLztcbiAgICAgICAgICAgICAgICAgICAgaWYgKHNob3VsZFNjcm9sbCAmJiBoYXNoUmVnZXgudGVzdChhcykpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIF90aGlzLnNjcm9sbFRvSGFzaChhcyk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICB9IGNhdGNoIChlcnIxKSB7XG4gICAgICAgICAgICAgICAgaWYgKCgwLCBfaXNFcnJvcikuZGVmYXVsdChlcnIxKSAmJiBlcnIxLmNhbmNlbGxlZCkge1xuICAgICAgICAgICAgICAgICAgICByZXR1cm4gZmFsc2U7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHRocm93IGVycjE7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0pKCk7XG4gICAgfVxuICAgIGNoYW5nZVN0YXRlKG1ldGhvZCwgdXJsLCBhcywgb3B0aW9ucyA9IHt9KSB7XG4gICAgICAgIGlmIChwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ3Byb2R1Y3Rpb24nKSB7XG4gICAgICAgICAgICBpZiAodHlwZW9mIHdpbmRvdy5oaXN0b3J5ID09PSAndW5kZWZpbmVkJykge1xuICAgICAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoYFdhcm5pbmc6IHdpbmRvdy5oaXN0b3J5IGlzIG5vdCBhdmFpbGFibGUuYCk7XG4gICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKHR5cGVvZiB3aW5kb3cuaGlzdG9yeVttZXRob2RdID09PSAndW5kZWZpbmVkJykge1xuICAgICAgICAgICAgICAgIGNvbnNvbGUuZXJyb3IoYFdhcm5pbmc6IHdpbmRvdy5oaXN0b3J5LiR7bWV0aG9kfSBpcyBub3QgYXZhaWxhYmxlYCk7XG4gICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIGlmIChtZXRob2QgIT09ICdwdXNoU3RhdGUnIHx8ICgwLCBfdXRpbHMpLmdldFVSTCgpICE9PSBhcykge1xuICAgICAgICAgICAgdGhpcy5fc2hhbGxvdyA9IG9wdGlvbnMuc2hhbGxvdztcbiAgICAgICAgICAgIHdpbmRvdy5oaXN0b3J5W21ldGhvZF0oe1xuICAgICAgICAgICAgICAgIHVybCxcbiAgICAgICAgICAgICAgICBhcyxcbiAgICAgICAgICAgICAgICBvcHRpb25zLFxuICAgICAgICAgICAgICAgIF9fTjogdHJ1ZSxcbiAgICAgICAgICAgICAgICBrZXk6IHRoaXMuX2tleSA9IG1ldGhvZCAhPT0gJ3B1c2hTdGF0ZScgPyB0aGlzLl9rZXkgOiBjcmVhdGVLZXkoKVxuICAgICAgICAgICAgfSwgLy8gTW9zdCBicm93c2VycyBjdXJyZW50bHkgaWdub3JlcyB0aGlzIHBhcmFtZXRlciwgYWx0aG91Z2ggdGhleSBtYXkgdXNlIGl0IGluIHRoZSBmdXR1cmUuXG4gICAgICA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UGFnZSBkb2VzIGV4aXN0IGluIGEgZGlmZmVyZW50IHpvbmVcbiAgICAgICAgICAgICAgICAvLyAgMy4gSW50ZXJuYWwgZXJyb3Igd2hpbGUgbG9hZGluZyB0aGUgcGFnZVxuICAgICAgICAgICAgICAgIC8vIFNvLCBkb2luZyBhIGhhcmQgcmVsb2FkIGlzIHRoZSBwcm9wZXIgd2F5IHRvIGRlYWwgd2l0aCB0aGlzLlxuICAgICAgICAgICAgICAgIGhhbmRsZUhhcmROYXZpZ2F0aW9uKHtcbiAgICAgICAgICAgICAgICAgICAgdXJsOiBhcyxcbiAgICAgICAgICAgICAgICAgICAgcm91dGVyOiBfdGhpc1xuICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgIC8vIENoYW5naW5nIHRoZSBVUkwgZG9lc24ndCBibG9jayBleGVjdXRpbmcgdGhlIGN1cnJlbnQgY29kZSBwYXRoLlxuICAgICAgICAgICAgICAgIC8vIFNvIGxldCdzIHRocm93IGEgY2FuY2VsbGF0aW9uIGVycm9yIHN0b3AgdGhlIHJvdXRpbmcgbG9naWMuXG4gICAgICAgICAgICAgICAgdGhyb3cgYnVpbGRDYW5jZWxsYXRpb25FcnJvcigpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICBsZXQgcHJvcHM7XG4gICAgICAgICAgICAgICAgY29uc3QgeyBwYWdlOiBDb21wb25lbnQgLCBzdHlsZVNoZWV0cyAgfSA9IHlpZWxkIF90aGlzLmZldGNoQ29tcG9uZW50KCcvX2Vycm9yJyk7XG4gICAgICAgICAgICAgICAgY29uc3Qgcm91dGVJbmZvID0ge1xuICAgICAgICAgICAgICAgICAgICBwcm9wcyxcbiAgICAgICAgICAgICAgICAgICAgQ29tcG9uZW50LFxuICAgICAgICAgICAgICAgICAgICBzdHlsZVNoZWV0cyxcbiAgICAgICAgICAgICAgICAgICAgZXJyLFxuICAgICAgICAgICAgICAgICAgICBlcnJvcjogZXJyXG4gICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICBpZiAoIXJvdXRlSW5mby5wcm9wcykge1xuICAgICAgICAgICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICAgICAgICAgICAgcm91dGVJbmZvLnByb3BzID0geWllbGQgX3RoaXMuZ2V0SW5pdGlhbFByb3BzKENvbXBvbmVudCwge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVycixcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXRobmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBxdWVyeVxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgICAgIH0gY2F0Y2ggKGdpcEVycikge1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcignRXJyb3IgaW4gZXJyb3IgcGFnZSBgZ2V0SW5pdGlhbFByb3BzYDogJywgZ2lwRXJyKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIHJvdXRlSW5mby5wcm9wcyA9IHt9O1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJldHVybiByb3V0ZUluZm87XG4gICAgICAgICAgICB9IGNhdGNoIChyb3V0ZUluZm9FcnIpIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gX3RoaXMuaGFuZGxlUm91dGVJbmZvRXJyb3IoKDAsIF9pc0Vycm9yKS5kZWZhdWx0KHJvdXRlSW5mb0VycikgPyByb3V0ZUluZm9FcnIgOiBuZXcgRXJyb3Iocm91dGVJbmZvRXJyICsgJycpLCBwYXRobmFtZSwgcXVlcnksIGFzLCByb3V0ZVByb3BzLCB0cnVlKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSkoKTtcbiAgICB9XG4gICAgZ2V0Um91dGVJbmZvKHsgcm91dGU6IHJlcXVlc3RlZFJvdXRlICwgcGF0aG5hbWUgLCBxdWVyeSAsIGFzICwgcmV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m4gZXhpc3RpbmdJbmZvO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAoaGFzTWlkZGxld2FyZSkge1xuICAgICAgICAgICAgICAgICAgICBleGlzdGluZ0luZm8gPSB1bmRlZmluZWQ7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGxldCBjYWNoZWRSb3V0ZUluZm8gPSBleGlzdGluZ0luZm8gJiYgISgnaW5pdGlhbCcgaW4gZXhpc3RpbmdJbmZvKSAmJiBwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ2RldmVsb3BtZW50JyA/IGV4aXN0aW5nSW5mbyA6IHVuZGVmaW5lZDtcbiAgICAgICAgICAgICAgICBjb25zdCBmZXRjaE5leHREYXRhUGFyYW1zID0ge1xuICAgICAgICAgICAgICAgICAgICBkYXRhSHJlZjogX3RoaXMucGFnZUxvYWRlci5nZXREYXRhSHJlZih7XG4gICAgICAgICAgICAgICAgICAgICAgICBocmVmOiAoMCwgX2Zvcm1hdFVybCkuZm9ybWF0V2l0aFZhbGlkYXRpb24oe1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBhdGhuYW1lLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHF1ZXJ5XG4gICAgICAgICAgICAgICAgICAgICAgICB9KSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHNraXBJbnRlcnBvbGF0aW9uOiB0cnVlLFxuICAgICAgICAgICAgICAgICAgICAgICAgYXNQYXRoOiByZXNvbHZlZEFzLFxuICAgICAgICAgICAgICAgICAgICAgICAgbG9jYWxlXG4gICAgICAgICAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgICAgICAgICBoYXNNaWRkbGV3YXJlOiB0cnVlLFxuICAgICAgICAgICAgICAgICAgICBpc1NlcnZlclJlbmRlcjogX3RoaXMuaXNTc3IsXG4gICAgICAgICAgICAgICAgICAgIHBhcnNlSlNPTjogdHJ1ZSxcbiAgICAgICAgICAgICAgICAgICAgaW5mbGlnaHRDYWNoZTogX3RoaXMuc2RjLFxuICAgICAgICAgICAgICAgICAgICBwZXJzaXN0Q2FjaGU6ICFpc1ByZXZpZXcsXG4gICAgICAgICAgICAgICAgICAgIGlzUHJlZmV0Y2g6IGZhbHNlLFxuICAgICAgICAgICAgICAgICAgICB1bnN0YWJsZV9za2lwQ2xpZW50Q2FjaGVcbiAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIGNvbnN0IGRhdGEgPSB5aWVsZCB3aXRoTWlkZGxld2FyZUVmZmVjdHMoe1xuICAgICAgICAgICAgICAgICAgICBmZXRjaERhdGE6ICgpPT5mZXRjaE5leHREYXRhKGZldGNoTmV4dERhdGFQYXJhbXMpLFxuICAgICAgICAgICAgICAgICAgICBhc1BhdGg6IHJlc29sdmVkQXMsXG4gICAgICAgICAgICAgICAgICAgIGxvY2FsZTogbG9jYWxlLFxuICAgICAgICAgICAgICAgICAgICByb3V0ZXI6IF90aGlzXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgaGFuZGxlQ2FuY2VsbGVkKCk7XG4gICAgICAgICAgICAgICAgaWYgKChkYXRhID09IG51bGwgPyB2b2lkIDAgOiAocmVmID0gZGF0YS5lZmZlY3QpID09IG51bGwgPyB2b2lkIDAgOiByZWYudHlwZSkgPT09ICdyZWRpcmVjdC1pbnRlcm5hbCcgfHwgKGRhdGEgPT0gbnVsbCA/IHZvaWQgMCA6IChyZWY0ID0gZGF0YS5lZmZlY3QpID09IG51bGwgPyB2b2lkIDAgOiByZWY0LnR5cGUpID09PSAncmVkaXJlY3QtZXh0ZXJuYWwnKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBkYXRhLmVmZmVjdDtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgaWYgKChkYXRhID09IG51bGwgPyB2b2lkIDAgOiAocmVmNSA9IGRhdGEuZWZmZWN0KSA9PSBudWxsID8gdm9pZCAwIDogcmVmNS50eXBlKSA9P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gb25lLlxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gVGhlbiwgd2UgcmV0dXJuIHRoZSBpbmZvcm1hdGlvbiBhbG9uZyB3aXRoIHRoZSBtYXRjaGVkIHJvdXRlLlxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIF9leHRlbmRzKHt9LCBleGlzdGluZ0luZm8sIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICByb3V0ZVxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgaWYgKHJvdXRlID09PSAnL2FwaScgfHwgcm91dGUuc3RhcnRzV2l0aCgnL2FwaS8nKSkge1xuICAgICAgICAgICAgICAgICAgICBoYW5kbGVIYXJkTmF2aWdhdGlvbih7XG4gICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGFzLFxuICAgICAgICAgICAgICAgICAgICAgICAgcm91dGVyOiBfdGhpc1xuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG5ldyBQcm9taXNlKCgpPT57fSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGNvbnN0IHJvdXRlSW5mbyA9IGNhY2hlZFJvdXRlSW5mbyB8fCAoeWllbGQgX3RoaXMuZmV0Y2hDb21wb25lbnQocm91dGUpLnRoZW4oKHJlcyk9Pih7XG4gICAgICAgICAgICAgICAgICAgICAgICBDb21wb25lbnQ6IHJlcy5wYWdlLFxuICAgICAgICAgICAgICAgICAgICAgICAgc3R5bGVTaGVldHM6IHJlcy5zdHlsZVNoZWV0cyxcbiAgICAgICAgICAgICAgICAgICAgICAgIF9fTl9TU0c6IHJlcy5tb2QuX19OX1NTRyxcbiAgICAgICAgICAgICAgICAgICAgICAgIF9fTl9TU1A6IHJlcy5tb2QuX19OX1NTUFxuICAgICAgICAgICAgICAgICAgICB9KSkpO1xuICAgICAgICAgICAgICAgIGlmIChwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ3Byb2R1Y3Rpb24nKSB7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHsgaXNWYWxpZEVsZW1lbnRUeXBlICB9ID0gcmVxdWlyZSgnbmV4dC9kaXN0L2NvbXBpbGVkL3JlYWN0LWlzJyk7XG4gICAgICAgICAgICAgICAgICAgIGlmICghaXNWYWxpZEVsZW1lbnRUeXBlKHJvdXRlSW5mby5Db21wb25lbnQpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoYFRoZSBkZWZhdWx0IGV4cG9ydCBpcyBub3QgYSBSZWFjdCBDb21wb25lbnQgaW4gcGFnZTogXCIke3BhdGhuYW1lfVwiYCk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgY29uc3Qgc2hvdWxkRmV0Y2hEYXRhID0gcm91dGVJbmZvLl9fTl9TU0cgfHwgcm91dGVJbmZvLl9fTl9TU1A7XG4gICAgICAgICAgICAgICAgY29uc3QgeyBwcm9wcyAsIGNhY2hlS2V5ICB9ID0geWllbGQgX3RoaXMuX2dldERhdGEoX2FzeW5jX3RvX2dlbmVyYXRvcihmdW5jdGlvbiooKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChzaG91bGRGZXRjaERhdGEpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHsganNvbiAsIGNhY2hlS2V5OiBfY2FjaGVLZXkgIH0gPSAoZGF0YSA9PSBudWxsID8gdm9pZCAwIDogZGF0YS5qc29uKSA/IGRhdGEgOiB5aWVsZCBmZXRjaE5leHREYXRhKHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkYXRhSHJlZjogX3RoaXMucGFnZUxvYWRlci5nZXREYXRhSHJlZih7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGhyZWY6ICgwLCBfZm9ybWF0VXJsKS5mb3JtYXRXaXRoVmFsaWRhdGlvbih7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXRobmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHF1ZXJ5XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhc1BhdGg6IHJlc29sdmVkQXMsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxvY2FsZVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlzU2VydmVyUmVuZGVyOiBfdGhpcy5pc1NzcixcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXJzZUpTT046IHRydWUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaW5mbGlnaHRDYWNoZTogX3RoaXMuc2RjLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBlcnNpc3RDYWNoZTogIWlzUHJldmlldyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpc1ByZWZldGNoOiBmYWxzZSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB1bnN0YWJsZV9za2lwQ2xpZW50Q2FjaGVcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjYWNoZUtleTogX2NhY2hlS2V5LFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHByb3BzOiBqc29uIHx8IHt9XG4gICAgICAgICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAgICAgICAgICAgICBoZWFkZXJzOiB7fSxcbiAgICAgICAgICAgICAgICAgICAgICAgIGNhY2hlS2V5OiAnJyxcbiAgICAgICAgICAgICAgICAgICAgICAgIHByb3BzOiB5aWVsZCBfdGhpcy5nZXRJbml0aWFsUHJvcHMocm91dGVJbmZvLkNvbXBvbmVudCwgLy8gd2UgcHJvdmlkZSBBcHBUcmVlIGxhdGVyIHNvIHRoaXMgbmVlZHMgdG8gYmUgYGFueWBcbiAgICAgICAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYXRobmFtZSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBxdWVyeSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhc1BhdGg6IGFzLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2NhbGVzOiBfdGhpcy5sb2NhbGVzLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRlZmF1bHRMb2NhbGU6IF90aGlzLmRlZmF1bHRMb2NhbGVcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICAgICAgICAgIH07XG4gICAgICAgICAgICAgICAgfSkpO1xuICAgICAgICAgICAgICAgIC8vIE9ubHkgYnVzdCB0aGUgZGF0YSBjYWNoZSBmb3IgU1NQIHJvdXRlcyBhbHRob3VnaFxuICAgICAgICAgICAgICAgIC8vIG1pZGRsZXdhcmUgY2FuIHNraXAgY2FjaGUgcGVyIHJlcXVlc3Qgd2l0aFxuICAgICAgICAgICAgICAgIC8vIHgtbWlkZGxld2FyZS1jYWNoZTogbm8tY2FjaGUgYXMgd2VsbFxuICAgICAgICAgICAgICAgIGlmIChyb3V0ZUluZm8uX19OX1NTUCAmJiBmZXRjaE5leHREYXRhUGFyYW1zLmRhdGFIcmVmKSB7XG4gICAgICAgICAgICAgICAgICAgIGRlbGV0ZSBfdGhpcy5zZGNbY2FjaGVLZXldO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAvLyB3ZSBraWNrIG9mZiBhIEhFQUQgcmVxdWVzdCBpbiB0aGUgYmFja2dyb3VuZFxuICAgICAgICAgICAgICAgIC8vIHdoZW4gYSBub24tcHJlZmV0Y2ggcmVxdWVzdCBpcyBtYWRlIHRvIHNpZ25hbCByZXZhbGlkYXRpb25cbiAgICAgICAgICAgICAgICBpZiAoIV90aGlzLmlzUHJldmlldyAmJiByb3V0ZUluZm8uX19OX1NTRyAmJiBwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ2RldmVsb3BtZW50Jykge1xuICAgICAgICAgICAgICAgICAgICBmZXRjaE5leHREYXRhKE9iamVjdC5hc3NpZ24oe30sIGZldGNoTmV4dERhdGFQYXJhbXMsIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlzQmFja2dyb3VuZDogdHJ1ZSxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBlcnNpc3RDYWNoZTogZmFsc2UsXG4gICAgICAgICAgICAgICAgICAgICAgICBpbmZsaWdodENhY2hlOiBiYWNrZ3JvdW5kQ2FjaGVcbiAgICAgICAgICAgICAgICAgICAgfSkpLmNhdGNoKCgpPT57fSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHByb3BzLnBhZ2VQcm9wcyA9IE9iamVjdC5hc3NpZ24oe30sIHByb3BzLnBhZ2VQcm9wcyk7XG4gICAgICAgICAgICAgICAgcm91dGVJbmZvLnByb3BzID0gcHJvcHM7XG4gICAgICAgICAgICAgICAgcm91dGVJbmZvLnJvdXRlID0gcm91dGU7XG4gICAgICAgICAgICAgICAgcm91dGVJbmZvLnF1ZXJ5ID0gcXVlcnk7XG4gICAgICAgICAgICAgICAgcm91dGVJbmZvLnJlc29sdmVkQXMgPSByZXNvbHZlZEFzO1xuICAgICAgICAgICAgICAgIF90aGlzLmNvbXBvbmVudHNbcm91dGVdID0gcm91dGVJbmZvO1xuICAgICAgICAgICAgICAgIHJldHVybiByb3V0ZUluZm87XG4gICAgICAgICAgICB9IGNhdGNoIChlcnIpIHtcbiAgICAgICAgICAgIC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ICAgICAgIH1cbiAgICAgICAgICAgIC8vIFByZWZldGNoIGlzIG5vdCBzdXBwb3J0ZWQgaW4gZGV2ZWxvcG1lbnQgbW9kZSBiZWNhdXNlIGl0IHdvdWxkIHRyaWdnZXIgb24tZGVtYW5kLWVudHJpZXNcbiAgICAgICAgICAgIGlmIChwcm9jZXNzLmVudi5OT0RFX0VOViAhPT0gJ3Byb2R1Y3Rpb24nKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgY29uc3Qgcm91dGUgPSAoMCwgX3JlbW92ZVRyYWlsaW5nU2xhc2gpLnJlbW92ZVRyYWlsaW5nU2xhc2gocGF0aG5hbWUpO1xuICAgICAgICAgICAgeWllbGQgUHJvbWlzZS5hbGwoW1xuICAgICAgICAgICAgICAgIF90aGlzLnBhZ2VMb2FkZXIuX2lzU3NnKHJvdXRlKS50aGVuKChpc1NzZyk9PntcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGlzU3NnID8gZmV0Y2hOZXh0RGF0YSh7XG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhSHJlZjogX3RoaXMucGFnZUxvYWRlci5nZXREYXRhSHJlZih7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaHJlZjogdXJsLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFzUGF0aDogcmVzb2x2ZWRBcyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsb2NhbGU6IGxvY2FsZVxuICAgICAgICAgICAgICAgICAgICAgICAgfSksXG4gICAgICAgICAgICAgICAgICAgICAgICBpc1NlcnZlclJlbmRlcjogZmFsc2UsXG4gICAgICAgICAgICAgICAgICAgICAgICBwYXJzZUpTT046IHRydWUsXG4gICAgICAgICAgICAgICAgICAgICAgICBpbmZsaWdodENhY2hlOiBfdGhpcy5zZGMsXG4gICAgICAgICAgICAgICAgICAgICAgICBwZXJzaXN0Q2FjaGU6ICFfdGhpcy5pc1ByZXZpZXcsXG4gICAgICAgICAgICAgICAgICAgICAgICBpc1ByZWZldGNoOiB0cnVlLFxuICAgICAgICAgICAgICAgICAgICAgICAgdW5zdGFibGVfc2tpcENsaWVudENhY2hlOiBvcHRpb25zLnVuc3RhYmxlX3NraXBDbGllbnRDYWNoZSB8fCBvcHRpb25zLnByaW9yaXR5ICYmICEhcHJvY2Vzcy5lbnYuX19ORVhUX09QVElNSVNUSUNfQ0xJRU5UX0NBQ0hFXG4gICAgICAgICAgICAgICAgICAgIH0pLnRoZW4oKCk9PmZhbHNlKSA6IGZhbHNlO1xuICAgICAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgICAgIF90aGlzLnBhZ2VMb2FkZXJbb3B0aW9ucy5wcmlvcml0eSA/ICdsb2FkUGFnZScgOiAncHJlZmV0Y2gnXShyb3V0ZSksIFxuICAgICAgICAgICAgXSk7XG4gICAgICAgIH0pKCk7XG4gICAgfVxuICAgIGZldGNoQ29tcG9uZW50KHJvdXRlKSB7XG4gICAgICAgIHZhciBfdGhpcyA9IHRoaXM7XG4gICAgICAgIHJldHVybiBfYXN5bmNfdG9fZ2VuZXJhdG9yKGZ1bmN0aW9uKigpIHtcbiAgICAgICAgICAgIGNvbnN0IGhhbmRsZUNhbmNlbGxlZCA9IGdldENhbmNlbGxlZEhhbmRsZXIoe1xuICAgICAgICAgICAgICAgIHJvdXRlLFxuICAgICAgICAgICAgICAgIHJvdXRlcjogX3RoaXNcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICBjb25zdCBjb21wb25lbnRSZXN1bHQgPSB5aWVsZCBfdGhpcy5wYWdlTG9hZGVyLmxvYWRQYWdlKHJvdXRlKTtcbiAgICAgICAgICAgICAgICBoYW5kbGVDYW5jZWxsZWQoKTtcbiAgICAgICAgICAgICAgICByZXR1cm4gY29tcG9uZW50UmVzdWx0O1xuICAgICAgICAgICAgfSBjYXRjaCAoZXJyKSB7XG4gICAgICAgICAgICAgICAgaGFuZGxlQ2FuY2VsbGVkKCk7XG4gICAgICAgICAgICAgICAgdGhyb3cgZXJyO1xuICAgICAgICAgICAgfVxuICAgICAgICB9KSgpO1xuICAgIH1cbiAgICBfZ2V0RGF0YShmbikge1xuICAgICAgICBsZXQgY2FuY2VsbGVkID0gZmFsc2U7XG4gICAgICAgIGNvbnN0IGNhbmNlbCA9ICgpPT57XG4gICAgICAgICAgICBjYW5jZWxsZWQgPSB0cnVlO1xuICAgICAgICB9O1xuICAgICAgICB0aGlzLmNsYyA9IGNhbmNlbDtcbiAgICAgICAgcmV0dXJuIGZuKCkudGhlbigoZGF0YSk9PntcbiAgICAgICAgICAgIGlmIChjYW5jZWwgPT09IHRoaXMuY2xjKSB7XG4gICAgICAgICAgICAgICAgdGhpcy5jbGMgPSBudWxsO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKGNhbmNlbGxlZCkge1xuICAgICAgICAgICAgICAgIGNvbnN0IGVyciA9IG5ldyBFcnJvcignTG9hZGluZyBpbml0aWFsIHByb3BzIGNhbmNlbGxlZCcpO1xuICAgICAgICAgICAgICAgIGVyci5jYW5jZWxsZWQgPSB0cnVlO1xuICAgICAgICAgICAgICAgIHRocm93IGVycjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiBkYXRhO1xuICAgICAgICB9KTtcbiAgICB9XG4gICAgX2dldEZsaWdodERhdGEoZGF0YUhyZWYpIHtcbiAgICAgICAgLy8gRG8gbm90IGNhY2hlIFJTQyBmbGlnaHQgcmVzcG9uc2Ugc2luY2UgaXQncyBub3QgYSBzdGF0aWMgcmVzb3VyY2VcbiAgICAgICAgcmV0dXJuIGZldGNoTmV4dERhdGEoe1xuICAgICAgICAgICAgZGF0YUhyZWYsXG4gICAgICAgICAgICBpc1NlcnZlclJlbmRlcjogdHJ1ZSxcbiAgICAgICAgICAgIHBhcnNlSlNPTjogZmFsc2UsXG4gICAgICAgICAgICBpbmZsaWdodENhY2hlOiB0aGlzLnNk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zdGF0ZS5fX05BKSB7XG4gICAgICAgICAgICAgICAgd2luZG93LmxvY2F0aW9uLnJlbG9hZCgpO1xuICAgICAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmICghc3RhdGUuX19OKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgLy8gU2FmYXJpIGZpcmVzIHBvcHN0YXRlZXZlbnQgd2hlbiByZW9wZW5pbmcgdGhlIGJyb3dzZXIuXG4gICAgICAgICAgICBpZiAoaXNGaXJzdFBvcFN0YXRlRXZlbnQgJiYgdGhpcy5sb2NhbGUgPT09IHN0YXRlLm9wdGlvbnMubG9jYWxlICYmIHN0YXRlLmFzID09PSB0aGlzLmFzUGF0aCkge1xuICAgICAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGxldCBmb3JjZWRTY3JvbGw7XG4gICAgICAgICAgICBjb25zdCB7IHVybCAsIGFzICwgb3B0aW9ucyAsIGtleSAgfSA9IHN0YXRlO1xuICAgICAgICAgICAgaWYgKHByb2Nlc3MuZW52Ll9fTkVYVF9TQ1JPTExfUkVTVE9SQVRJT04pIHtcbiAgICAgICAgICAgICAgICBpZiAobWFudWFsU2Nyb2xsUmVzdG9yYXRpb24pIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMuX2tleSAhPT0ga2V5KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBTbmFwc2hvdCBjdXJyZW50IHNjcm9sbCBwb3NpdGlvbjpcbiAgICAgICAgICAgICAgICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2Vzc2lvblN0b3JhZ2Uuc2V0SXRlbSgnX19uZXh0X3Njcm9sbF8nICsgdGhpcy5fa2V5LCBKU09OLnN0cmluZ2lmeSh7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHg6IHNlbGYucGFnZVhPZmZzZXQsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHk6IHNlbGYucGFnZVlPZmZzZXRcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KSk7XG4gICAgICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlKSB7fVxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gUmVzdG9yZSBvbGQgc2Nyb2xsIHBvc2l0aW9uOlxuICAgICAgICAgICAgICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCB2ID0gc2Vzc2lvblN0b3JhZ2UuZ2V0SXRlbSgnX19uZXh0X3Njcm9sbF8nICsga2V5KTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3JjZWRTY3JvbGwgPSBKU09OLnBhcnNlKHYpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfSBjYXRjaCAoZTEpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3JjZWRTY3JvbGwgPSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHg6IDAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHk6IDBcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICAgICAgdGhpcy5fa2V5ID0ga2V5O1xuICAgICAgICAgICAgY29uc3QgeyBwYXRobmFtZSAgfSA9ICgwLCBfcGFyc2VSZWxhdGl2ZVVybCkucGFyc2VSZWxhdGl2ZVVybCh1cmwpO1xuICAgICAgICAgICAgLy8gTWFrZSBzdXJlIHdlIGRvbid0IHJlLXJlbmRlciBvbiBpbml0aWFsIGxvYWQsXG4gICAgICAgICAgICAvLyBjYW4gYmUgY2F1c2VkIGJ5IG5hdmlnYXRpbmcgYmFjayBmcm9tIGFuIGV4dGVybmFsIHNpdGVcbiAgICAgICAgICAgIGlmICh0aGlzLmlzU3NyICYmIGFzID09PSAoMCwgX2FkZEJhc2VQYXRoKS5hZGRCYXNlUGF0aCh0aGlzLmFzUGF0aCkgJiYgcGF0aG5hbWUgPT09ICgwLCBfYWRkQmFzZVBhdGgpLmFkZEJhc2VQYXRoKHRoaXMucGF0aG5hbWUpKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgLy8gSWYgdGhlIGRvd25zdHJlYW0gYXBwbGljYXRpb24gcmV0dXJucyBmYWxzeSwgcmV0dXJuLlxuICAgICAgICAgICAgLy8gVGhleSB3aWxsIHRoZW4gYmUgcmVzcG9uc2libGUgZm9yIGhhbmRsaW5nIHRoZSBldmVudC5cbiAgICAgICAgICAgIGlmICh0aGlzLl9icHMgJiYgIXRoaXMuX2JwcyhzdGF0ZSkpIHtcbiAgICAgICAgICAgICAgICByZXR1cm47XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICB0aGlzLmNoYW5nZSgncmVwbGFjZVN0YXRlJywgdXJsLCBhcywgT2JqZWN0LmFzc2lnbih7fSwgb3B0aW9ucywge1xuICAgICAgICAgICAgICAgIHNoYWxsb3c6IG9wdGlvbnMuc2hhbGxvdyAmJiB0aGlzLl9zaGFsbG93LFxuICAgICAgICAgICAgICAgIGxvY2FsZTogb3B0aW9ucy5sb2NhbGUgfHwgdGhpcy5kZWZhdWx0TG9jYWxlLFxuICAgICAgICAgICAgICAgIC8vIEB0cy1pZ25vcmUgaW50ZXJuYWwgdmFsdWUgbm90IGV4cG9zZWQgb24gdHlwZXNcbiAgICAgICAgICAgICAgICBfaDogMFxuICAgICAgICAgICAgfSksIGZvcmNlZFNjcm9sbCk7XG4gICAgICAgIH07XG4gICAgICAgIC8vIHJlcHJlc2VudHMgdGhlIGN1cnJlbnQgY29tcG9uZW50IGtleVxuICAgICAgICBjb25zdCByb3V0ZSA9ICgwLCBfcmVtb3ZlVHJhaWxpbmdTbGFzaCkucmVtb3ZlVHJhaWxpbmdTbGFzaChwYXRobmFtZTEpO1xuICAgICAgICAvLyBzZXQgdXAgdGhlIGNvbXBvbmVudCBjYWNoZSAoYnkgcm91dGUga2V5cylcbiAgICAgICAgdGhpcy5jb21wb25lbnRzID0ge307XG4gICAgICAgIC8vIFdlIHNob3VsZCBub3Qga2VlcCB0aGUgY2FjaGUsIGlmIHRoZXJlJ3MgYW4gZXJyb3JcbiAgICAgICAgLy8gT3RoZXJ3aXNlLCB0aGlzIGNhdXNlIGlzc3VlcyB3aGVuIHdoZW4gZ29pbmcgYmFjayBhbmRcbiAgICAgICAgLy8gY29tZSBhZ2FpbiB0byB0aGUgZXJyb3JlZCBwYWdlLlxuICAgICAgICBpZiAocGF0aG5hbWUxICE9PSAnL19lcnJvcicpIHtcbiAgICAgICAgICAgIHRoaXMuY29tcG9uZW50c1tyb3V0ZV0gPSB7XG4gICAgICAgICAgICAgICAgQ29tcG9uZW50LFxuICAgICAgICAgICAgICAgIGluaXRpYWw6IHRydWUsXG4gICAgICAgICAgICAgICAgcHJvcHM6IGluaXRpYWxQcm9wcyxcbiAgICAgICAgICAgICAgICBlcnIsXG4gICAgICAgICAgICAgICAgX19OX1NTRzogaW5pdGlhbFByb3BzICYmIGluaXRpYWxQcm9wcy5fX05fU1NHLFxuICAgICAgICAgICAgICAgIF9fTl9TU1A6IGluaXRpYWxQcm9wcyAmJiBpbml0aWFsUHJvcHMuX19OX1NTUFxuICAgICAgICAgICAgfTtcbiAgICAgICAgfVxuICAgICAgICB0aGlzLmNvbXBvbmVudHNbJy9fYXBwJ10gPSB7XG4gICAgICAgICAgICBDb21wb25lbnQ6IEFwcCxcbiAgICAgICAgICAgIHN0eWxlU2hlZXRzOiBbXVxuICAgICAgICB9O1xuICAgICAgICAvLyBCYWNrd2FyZHMgY29tcGF0IGZvciBSb3V0ZXIucm91dGVyLmV2ZW50c1xuICAgICAgICAvLyBUT0RPOiBTaG91bGQgYmUg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BpZiAodHlwZW9mIHdpbmRvdyAhPT0gJ3VuZGVmaW5lZCcpIHtcbiAgICAgICAgICAgIC8vIG1ha2Ugc3VyZSBcImFzXCIgZG9lc24ndCBzdGFydCB3aXRoIGRvdWJsZSBzbGFzaGVzIG9yIGVsc2UgaXQgY2FuXG4gICAgICAgICAgICAvLyB0aHJvdyBhbiBlcnJvciBhcyBpdCdzIGNvbnNpZGVyZWQgaW52YWxpZFxuICAgICAgICAgICAgaWYgKCFhczEuc3RhcnRzV2l0aCgnLy8nKSkge1xuICAgICAgICAgICAgICAgIC8vIGluIG9yZGVyIGZvciBgZS5zdGF0ZWAgdG8gd29yayBvbiB0aGUgYG9ucG9wc3RhdGVgIGV2ZW50XG4gICAgICAgICAgICAgICAgLy8gd2UgaGF2ZSB0byByZWdpc3RlciB0aGUgaW5pdGlhbCByb3V0ZSB1cG9uIGluaXRpYWxpemF0aW9uXG4gICAgICAgICAgICAgICAgY29uc3Qgb3B0aW9ucyA9IHtcbiAgICAgICAgICAgICAgICAgICAgbG9jYWxlXG4gICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICBjb25zdCBhc1BhdGggPSAoMCwgX3V0aWxzKS5nZXRVUkwoKTtcbiAgICAgICAgICAgICAgICB0aGlzLl9pbml0aWFsTWF0Y2hlc01pZGRsZXdhcmVQcm9taXNlID0gbWF0Y2hlc01pZGRsZXdhcmUoe1xuICAgICAgICAgICAgICAgICAgICByb3V0ZXI6IHRoaXMsXG4gICAgICAgICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgICAgICAgYXNQYXRoXG4gICAgICAgICAgICAgICAgfSkudGhlbigobWF0Y2hlcyk9PntcbiAgICAgICAgICAgICAgICAgICAgb3B0aW9ucy5fc2hvdWxkUmVzb2x2ZUhyZWYgPSBhczEgIT09IHBhdGhuYW1lMTtcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5jaGFuZ2VTdGF0ZSgncmVwbGFjZVN0YXRlJywgbWF0Y2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hhc2giLCJzY3JvbGxUbyIsInJhd0hhc2giLCJkZWNvZGVVUklDb21wb25lbnQiLCJpZEVsIiwiZ2V0RWxlbWVudEJ5SWQiLCJzY3JvbGxJbnRvVmlldyIsIm5hbWVFbCIsImdldEVsZW1lbnRzQnlOYW1lIiwicHJlZmV0Y2giLCJpc0JvdCIsIm5hdmlnYXRvciIsInVzZXJBZ2VudCIsIl9pc1NzZyIsImlzU3NnIiwicHJpb3JpdHkiLCJfX05FWFRfT1BUSU1JU1RJQ19DTElFTlRfQ0FDSEUiLCJjb21wb25lbnRSZXN1bHQiLCJsb2FkUGFnZSIsIl9nZXRGbGlnaHREYXRhIiwiY3R4IiwiQXBwVHJlZSIsImxvYWRHZXRJbml0aWFsUHJvcHMiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/router.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/add-locale.js": +/*!**********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/add-locale.js ***! + \**********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addLocale = addLocale;\nvar _addPathPrefix = __webpack_require__(/*! ./add-path-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js\");\nvar _pathHasPrefix = __webpack_require__(/*! ./path-has-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js\");\nfunction addLocale(path, locale, defaultLocale, ignorePrefix) {\n if (locale && locale !== defaultLocale && (ignorePrefix || !(0, _pathHasPrefix).pathHasPrefix(path.toLowerCase(), \"/\".concat(locale.toLowerCase())) && !(0, _pathHasPrefix).pathHasPrefix(path.toLowerCase(), \"/api\"))) {\n return (0, _addPathPrefix).addPathPrefix(path, \"/\".concat(locale));\n }\n return path;\n} //# sourceMappingURL=add-locale.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=ut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HVlIiwiYWRkTG9jYWxlIiwiX2FkZFBhdGhQcmVmaXgiLCJyZXF1aXJlIiwiX3BhdGhIYXNQcmVmaXgiLCJwYXRoIiwibG9jYWxlIiwiZGVmYXVsdExvY2FsZSIsImlnbm9yZVByZWZpeCIsInBhdGhIYXNQcmVmaXgiLCJ0b0xvd2VyQ2FzZSIsImFkZFBhdGhQcmVmaXgiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/add-locale.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js": +/*!***************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js ***! + \***************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addPathPrefix = addPathPrefix;\nvar _parsePath = __webpack_require__(/*! ./parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nfunction addPathPrefix(path, prefix) {\n if (!path.startsWith(\"/\") || !prefix) {\n return path;\n }\n var ref = (0, _parsePath).parsePath(path), pathname = ref.pathname, query = ref.query, hash = ref.hash;\n return \"\".concat(prefix).concat(pathname).concat(query).concat(hash);\n} //# sourceMappingURL=add-path-prefix.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2FkZC1wYXRoLXByZWZpeC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHFCQUFxQixHQUFHRSxhQUFhLENBQUM7QUFDdEMsSUFBSUMsVUFBVSxHQUFHQyxtQkFBTyxDQUFDLG9GQUFjLENBQU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ICAgaWYgKCFwYXRoLnN0YXJ0c1dpdGgoJy8nKSB8fCAhcHJlZml4KSB7XG4gICAgICAgIHJldHVybiBwYXRoO1xuICAgIH1cbiAgICBjb25zdCB7IHBhdGhuYW1lICwgcXVlcnkgLCBoYXNoICB9ID0gKDAsIF9wYXJzZVBhdGgpLnBhcnNlUGF0aChwYXRoKTtcbiAgICByZXR1cm4gYCR7cHJlZml4fSR7cGF0aG5hbWV9JHtxdWVyeX0ke2hhc2h9YDtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9YWRkLXBhdGgtcHJlZml4LmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsImFkZFBhdGhQcmVmaXgiLCJfcGFyc2VQYXRoIiwicmVxdWlyZSIsInBhdGgiLCJwcmVmaXgiLCJzdGFydHNXaXRoIiwicGFyc2VQYXRoIiwicGF0aG5hbWUiLCJxdWVyeSIsImhhc2giXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js": +/*!***************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js ***! + \***************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.addPathSuffix = addPathSuffix;\nvar _parsePath = __webpack_require__(/*! ./parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nfunction addPathSuffix(path, suffix) {\n if (!path.startsWith(\"/\") || !suffix) {\n return path;\n }\n var ref = (0, _parsePath).parsePath(path), pathname = ref.pathname, query = ref.query, hash = ref.hash;\n return \"\".concat(pathname).concat(suffix).concat(query).concat(hash);\n} //# sourceMappingURL=add-path-suffix.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMapp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XRpbHMvYWRkLXBhdGgtc3VmZml4LmpzPzdiMzYiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLmFkZFBhdGhTdWZmaXggPSBhZGRQYXRoU3VmZml4O1xudmFyIF9wYXJzZVBhdGggPSByZXF1aXJlKFwiLi9wYXJzZS1wYXRoXCIpO1xuZnVuY3Rpb24gYWRkUGF0aFN1ZmZpeChwYXRoLCBzdWZmaXgpIHtcbiAgICBpZiAoIXBhdGguc3RhcnRzV2l0aCgnLycpIHx8ICFzdWZmaXgpIHtcbiAgICAgICAgcmV0dXJuIHBhdGg7XG4gICAgfVxuICAgIGNvbnN0IHsgcGF0aG5hbWUgLCBxdWVyeSAsIGhhc2ggIH0gPSAoMCwgX3BhcnNlUGF0aCkucGFyc2VQYXRoKHBhdGgpO1xuICAgIHJldHVybiBgJHtwYXRobmFtZX0ke3N1ZmZpeH0ke3F1ZXJ5fSR7aGFzaH1gO1xufVxuXG4vLyMgc291cmNlTWFwcGluZ1VSTD1hZGQtcGF0aC1zdWZmaXguanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiYWRkUGF0aFN1ZmZpeCIsIl9wYXJzZVBhdGgiLCJyZXF1aXJlIiwicGF0aCIsInN1ZmZpeCIsInN0YXJ0c1dpdGgiLCJwYXJzZVBhdGgiLCJwYXRobmFtZSIsInF1ZXJ5IiwiaGFzaCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/compare-states.js": +/*!**************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/compare-states.js ***! + \**************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.compareRouterStates = compareRouterStates;\nfunction compareRouterStates(a, b) {\n var stateKeys = Object.keys(a);\n if (stateKeys.length !== Object.keys(b).length) return false;\n for(var i = stateKeys.length; i--;){\n var key = stateKeys[i];\n if (key === \"query\") {\n var queryKeys = Object.keys(a.query);\n if (queryKeys.length !== Object.keys(b.query).length) {\n return false;\n }\n for(var j = queryKeys.length; j--;){\n var queryKey = queryKeys[j];\n if (!b.query.hasOwnProperty(queryKey) || a.query[queryKey] !== b.query[queryKey]) {\n return false;\n }\n }\n } else if (!b.hasOwnProperty(key) || a[key] !== b[key]) {\n return false;\n }\n }\n return true;\n} //# sourceMappingURL=compare-states.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2NvbXBhcmUtc3RhdGVzLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQsMkJBQTJCLEdBQUdFLG1CQUFtQixDQUFDO0FBQ2xELFNBQVNBLG1CQUFtQixDQUFDQyxDQUFDLEVBQUVDLENBQUMsRUFBRTtJQUMvQixJQUFNQyxTQUFTLEdBQUdQLE1BQU0sQ0FBQ1EsSUFBSSxDQUFDSCxDQUFDLENBQUM7SUFDaEMsSUFBSUUsU0FBUyxDQUFDRSxNQUFNLEtBQUtULE1BQU0sQ0FBQ1EsSUFBSSxDQUFDRixDQUFDLENBQUMsQ0FBQ0csTUFBTSxFQUFFLE9BQU8sS0FBSyxDQUFDO0lBQzdELElBQUksSUFBSUMsQ0FBQyxHQUFHSCxTQUFTLENBQUNFLE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mhhc093blByb3BlcnR5KHF1ZXJ5S2V5KSB8fCBhLnF1ZXJ5W3F1ZXJ5S2V5XSAhPT0gYi5xdWVyeVtxdWVyeUtleV0pIHtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIGlmICghYi5oYXNPd25Qcm9wZXJ0eShrZXkpIHx8IGFba2V5XSAhPT0gYltrZXldKSB7XG4gICAgICAgICAgICByZXR1cm4gZmFsc2U7XG4gICAgICAgIH1cbiAgICB9XG4gICAgcmV0dXJuIHRydWU7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPWNvbXBhcmUtc3RhdGVzLmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsImNvbXBhcmVSb3V0ZXJTdGF0ZXMiLCJhIiwiYiIsInN0YXRlS2V5cyIsImtleXMiLCJsZW5ndGgiLCJpIiwia2V5IiwicXVlcnlLZXlzIiwicXVlcnkiLCJqIiwicXVlcnlLZXkiLCJoYXNPd25Qcm9wZXJ0eSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/compare-states.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js": +/*!*************************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js ***! + \*************************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.formatNextPathnameInfo = formatNextPathnameInfo;\nvar _removeTrailingSlash = __webpack_require__(/*! ./remove-trailing-slash */ \"./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js\");\nvar _addPathPrefix = __webpack_require__(/*! ./add-path-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js\");\nvar _addPathSuffix = __webpack_require__(/*! ./add-path-suffix */ \"./node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js\");\nvar _addLocale = __webpack_require__(/*! ./add-locale */ \"./node_modules/next/dist/shared/lib/router/utils/add-locale.js\");\nfunction formatNextPathnameInfo(info) {\n var pathname = (0, _addLocale).addLocale(info.pathname, info.locale, info.buildId ? undefined : info.defaultLocale, info.ignorePrefix);\n if (info.buildId) {\n pathname = (0, _addPathSuffix).addPathSuffix((0, _addPathPrefix).addPathPrefix(pathname, \"/_next/data/\".concat(info.buildId)), info.pathname === \"/\" ? \"index.json\" : \".json\");\n }\n pathname = (0, _addPathPrefix).addPathPrefix(pathname, info.basePath);\n return info.trailingSlash ? !info.buildId && !pathname.endsWith(\"/\") ? (0, _addPathSuffix).addPathSuffix(pathname, \"/\") : pathname : (0, _removeTrailingSlash).removeTrailingSlash(pathname);\n} //# sourceMappingURL=format-next-pathname-info.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2Zvcm1hdC1uZXh0LXBhdGhuYW1lLWluZm8uanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCw4QkFBOEIsR0FBR0Usc0JBQXNCLENBQUM7QUFDeEQsSUFBSUMsb0JBQW9CLEdBQUdDLG1CQUFPLENBQUMsMEdBQXlCLENBQUM7QUFDN0QsSUFBSUMsY0FBYyxHQUFHRCxtQkFBTyxDQUFDLDhGQUFtQixDQUFDO0FBQ2pELElBQUlFLGNBQWMsR0FBR0YsbUJBQU8sQ0FBQyw4RkFBbUIsQ0FBQztBQUNqRCxJQUFJRyxVQUFVLEdBQUdILG1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mdTbGFzaCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/format-url.js": +/*!**********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/format-url.js ***! + \**********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.formatUrl = formatUrl;\nexports.formatWithValidation = formatWithValidation;\nexports.urlObjectKeys = void 0;\nvar _interop_require_wildcard = (__webpack_require__(/*! @swc/helpers/lib/_interop_require_wildcard.js */ \"./node_modules/@swc/helpers/lib/_interop_require_wildcard.js\")[\"default\"]);\nvar querystring = _interop_require_wildcard(__webpack_require__(/*! ./querystring */ \"./node_modules/next/dist/shared/lib/router/utils/querystring.js\"));\nvar slashedProtocols = /https?|ftp|gopher|file/;\nfunction formatUrl(urlObj) {\n var auth = urlObj.auth, hostname = urlObj.hostname;\n var protocol = urlObj.protocol || \"\";\n var pathname = urlObj.pathname || \"\";\n var hash = urlObj.hash || \"\";\n var query = urlObj.query || \"\";\n var host = false;\n auth = auth ? encodeURIComponent(auth).replace(/%3A/i, \":\") + \"@\" : \"\";\n if (urlObj.host) {\n host = auth + urlObj.host;\n } else if (hostname) {\n host = auth + (~hostname.indexOf(\":\") ? \"[\".concat(hostname, \"]\") : hostname);\n if (urlObj.port) {\n host += \":\" + urlObj.port;\n }\n }\n if (query && typeof query === \"object\") {\n query = String(querystring.urlQueryToSearchParams(query));\n }\n var search = urlObj.search || query && \"?\".concat(query) || \"\";\n if (protocol && !protocol.endsWith(\":\")) protocol += \":\";\n if (urlObj.slashes || (!protocol || slashedProtocols.test(protocol)) && host !== false) {\n host = \"//\" + (host || \"\");\n if (pathname && pathname[0] !== \"/\") pathname = \"/\" + pathname;\n } else if (!host) {\n host = \"\";\n }\n if (hash && hash[0] !== \"#\") hash = \"#\" + hash;\n if (search && search[0] !== \"?\") search = \"?\" + search;\n pathname = pathname.replace(/[?#]/g, encodeURIComponent);\n search = search.replace(\"#\", \"%23\");\n return \"\".concat(protocol).concat(host).concat(pathname).concat(search).concat(hash);\n}\nvar urlObjectKeys = [\n \"auth\",\n \"hash\",\n \"host\",\n \"hostname\",\n \"href\",\n \"path\",\n \"pathname\",\n \"port\",\n \"protocol\",\n \"query\",\n \"search\",\n \"slashes\", \n];\nexports.urlObjectKeys = urlObjectKeys;\nfunction formatWithValidation(url) {\n if (true) {\n if (url !== null && typeof url === \"object\") {\n Object.keys(url).forEach(function(key) {\n if (urlObjectKeys.indexOf(key) === -1) {\n console.warn(\"Unknown key passed via urlObject into url.format: \".concat(key));\n }\n });\n }\n }\n return formatUrl(url);\n} //# sourceMappingURL=format-url.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2Zvcm1hdC11cmwuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxpQkFBaUIsR0FBR0UsU0FBUyxDQUFDO0FBQzlCRiw0QkFBNEIsR0FBR0csb0JBQW9CLENBQUM7QUFDcERILHFCQUFxQixHQUFHLEtBQUssQ0FBQyxDQUFDO0FBQy9CLElBQUlLLHlCQUF5QixHQUFHQyxxSkFBZ0U7QUFDaEcsSUFBSUUsV0FBVyxHQUFHSCx5QkFBeUIsQ0FBQ0MsbUJBQU8sQ0FBQyxzRkFBZSxDQUFDLENBQUM7QUFDckUsSUFBTUcsZ0JBQWdCLDJCQUEyQjtBQUNqRCxTQUFTUCxTQUFTLENBQUNRLE1BQU0sRUFBRTtJQUN2QixJQUFNQyxJQUFJLEdBQWlCRCxN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xPYmplY3RLZXlzLmluZGV4T2Yoa2V5KSA9PT0gLTEpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc29sZS53YXJuKGBVbmtub3duIGtleSBwYXNzZWQgdmlhIHVybE9iamVjdCBpbnRvIHVybC5mb3JtYXQ6ICR7a2V5fWApO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgfVxuICAgIHJldHVybiBmb3JtYXRVcmwodXJsKTtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9Zm9ybWF0LXVybC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJmb3JtYXRVcmwiLCJmb3JtYXRXaXRoVmFsaWRhdGlvbiIsInVybE9iamVjdEtleXMiLCJfaW50ZXJvcF9yZXF1aXJlX3dpbGRjYXJkIiwicmVxdWlyZSIsImRlZmF1bHQiLCJxdWVyeXN0cmluZyIsInNsYXNoZWRQcm90b2NvbHMiLCJ1cmxPYmoiLCJhdXRoIiwiaG9zdG5hbWUiLCJwcm90b2NvbCIsInBhdGhuYW1lIiwiaGFzaCIsInF1ZXJ5IiwiaG9zdCIsImVuY29kZVVSSUNvbXBvbmVudCIsInJlcGxhY2UiLCJpbmRleE9mIiwicG9ydCIsIlN0cmluZyIsInVybFF1ZXJ5VG9TZWFyY2hQYXJhbXMiLCJzZWFyY2giLCJlbmRzV2l0aCIsInNsYXNoZXMiLCJ0ZXN0IiwidXJsIiwicHJvY2VzcyIsImtleXMiLCJmb3JFYWNoIiwia2V5IiwiY29uc29sZSIsIndhcm4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/format-url.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js": +/*!*************************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js ***! + \*************************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = getAssetPathFromRoute;\nfunction getAssetPathFromRoute(route) {\n var ext = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : \"\";\n var path = route === \"/\" ? \"/index\" : /^\\/index(\\/|$)/.test(route) ? \"/index\".concat(route) : \"\".concat(route);\n return path + ext;\n} //# sourceMappingURL=get-asset-path-from-route.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2dldC1hc3NldC1wYXRoLWZyb20tcm91dGUuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxrQkFBZSxHQUFHRyxxQkFBcUIsQ0FBQztBQUN4QyxTQUFTQSxxQkFBcUIsQ0FBQ0MsS0FBSyxFQUFZO1FBQVZDLEdBQUcsR0FBSEEsK0NBQVEsa0JBQUYsRUFBRTtJQUMxQyxJQUFNQyxJQUFJLEdBQUdGLEtBQUssS0FBSyxHQUFHLEdBQUcsUUFBUSxHQUFHLGlCQUFpQkcsSUFBSSxDQUFDSCxLQUFLLENBQUMsR0FBRyxRQUFPLENBQVEsT0FBTkEsS0FBSyxDQUFFLEdBQUcsRUFBQyxDQUFRLE9BQU5BLEtBQUssQ0FBRTtJQUNwRyxPQUFPRSxJQUFJLEdBQUdELEdBQUcsQ0FBQztBQUN0QixDQUFDLENBRUQscURBQXFEIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9uZXh0L2Rpc3Qvc2hhcmVkL2xpYi9yb3V0ZXIvdXRpbHMvZ2V0LWFzc2V0LXBhdGgtZnJvbS1yb3V0ZS5qcz9hNmZmIl0sInNvdXJjZXNDb250ZW50IjpbIlwidXNlIHN0cmljdFwiO1xuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsIFwiX19lc01vZHVsZVwiLCB7XG4gICAgdmFsdWU6IHRydWVcbn0pO1xuZXhwb3J0cy5kZWZhdWx0ID0gZ2V0QXNzZXRQYXRoRnJvbVJvdXRlO1xuZnVuY3Rpb24gZ2V0QXNzZXRQYXRoRnJvbVJvdXRlKHJvdXRlLCBleHQgPSAnJykge1xuICAgIGNvbnN0IHBhdGggPSByb3V0ZSA9PT0gJy8nID8gJy9pbmRleCcgOiAvXlxcL2luZGV4KFxcL3wkKS8udGVzdChyb3V0ZSkgPyBgL2luZGV4JHtyb3V0ZX1gIDogYCR7cm91dGV9YDtcbiAgICByZXR1cm4gcGF0aCArIGV4dDtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9Z2V0LWFzc2V0LXBhdGgtZnJvbS1yb3V0ZS5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJkZWZhdWx0IiwiZ2V0QXNzZXRQYXRoRnJvbVJvdXRlIiwicm91dGUiLCJleHQiLCJwYXRoIiwidGVzdCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js": +/*!**********************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js ***! + \**********************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.getNextPathnameInfo = getNextPathnameInfo;\nvar _normalizeLocalePath = __webpack_require__(/*! ../../i18n/normalize-locale-path */ \"./node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js\");\nvar _removePathPrefix = __webpack_require__(/*! ./remove-path-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js\");\nvar _pathHasPrefix = __webpack_require__(/*! ./path-has-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js\");\nfunction getNextPathnameInfo(pathname, options) {\n var _nextConfig;\n var ref = (_nextConfig = options.nextConfig) != null ? _nextConfig : {}, basePath = ref.basePath, i18n = ref.i18n, trailingSlash = ref.trailingSlash;\n var info = {\n pathname: pathname,\n trailingSlash: pathname !== \"/\" ? pathname.endsWith(\"/\") : trailingSlash\n };\n if (basePath && (0, _pathHasPrefix).pathHasPrefix(info.pathname, basePath)) {\n info.pathname = (0, _removePathPrefix).removePathPrefix(info.pathname, basePath);\n info.basePath = basePath;\n }\n if (options.parseData === true && info.pathname.startsWith(\"/_next/data/\") && info.pathname.endsWith(\".json\")) {\n var paths = info.pathname.replace(/^\\/_next\\/data\\//, \"\").replace(/\\.json$/, \"\").split(\"/\");\n var buildId = paths[0];\n info.pathname = paths[1] !== \"index\" ? \"/\".concat(paths.slice(1).join(\"/\")) : \"/\";\n info.buildId = buildId;\n }\n if (i18n) {\n var pathLocale = (0, _normalizeLocalePath).normalizeLocalePath(info.pathname, i18n.locales);\n info.locale = pathLocale == null ? void 0 : pathLocale.detectedLocale;\n info.pathname = (pathLocale == null ? void 0 : pathLocale.pathname) || info.pathname;\n }\n return info;\n} //# sourceMappingURL=get-next-pathname-info.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2dldC1uZXh0LXBhdGhuYW1lLWluZm8uanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBST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ucGF0aG5hbWUsIGkxOG4ubG9jYWxlcyk7XG4gICAgICAgIGluZm8ubG9jYWxlID0gcGF0aExvY2FsZSA9PSBudWxsID8gdm9pZCAwIDogcGF0aExvY2FsZS5kZXRlY3RlZExvY2FsZTtcbiAgICAgICAgaW5mby5wYXRobmFtZSA9IChwYXRoTG9jYWxlID09IG51bGwgPyB2b2lkIDAgOiBwYXRoTG9jYWxlLnBhdGhuYW1lKSB8fCBpbmZvLnBhdGhuYW1lO1xuICAgIH1cbiAgICByZXR1cm4gaW5mbztcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9Z2V0LW5leHQtcGF0aG5hbWUtaW5mby5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJnZXROZXh0UGF0aG5hbWVJbmZvIiwiX25vcm1hbGl6ZUxvY2FsZVBhdGgiLCJyZXF1aXJlIiwiX3JlbW92ZVBhdGhQcmVmaXgiLCJfcGF0aEhhc1ByZWZpeCIsInBhdGhuYW1lIiwib3B0aW9ucyIsIl9uZXh0Q29uZmlnIiwibmV4dENvbmZpZyIsImJhc2VQYXRoIiwiaTE4biIsInRyYWlsaW5nU2xhc2giLCJpbmZvIiwiZW5kc1dpdGgiLCJwYXRoSGFzUHJlZml4IiwicmVtb3ZlUGF0aFByZWZpeCIsInBhcnNlRGF0YSIsInN0YXJ0c1dpdGgiLCJwYXRocyIsInJlcGxhY2UiLCJzcGxpdCIsImJ1aWxkSWQiLCJzbGljZSIsImpvaW4iLCJwYXRoTG9jYWxlIiwibm9ybWFsaXplTG9jYWxlUGF0aCIsImxvY2FsZXMiLCJsb2NhbGUiLCJkZXRlY3RlZExvY2FsZSJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/index.js": +/*!*****************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/index.js ***! + \*****************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nObject.defineProperty(exports, \"getSortedRoutes\", ({\n enumerable: true,\n get: function get() {\n return _sortedRoutes.getSortedRoutes;\n }\n}));\nObject.defineProperty(exports, \"isDynamicRoute\", ({\n enumerable: true,\n get: function get() {\n return _isDynamic.isDynamicRoute;\n }\n}));\nvar _sortedRoutes = __webpack_require__(/*! ./sorted-routes */ \"./node_modules/next/dist/shared/lib/router/utils/sorted-routes.js\");\nvar _isDynamic = __webpack_require__(/*! ./is-dynamic */ \"./node_modules/next/dist/shared/lib/router/utils/is-dynamic.js\"); //# sourceMappingURL=index.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2luZGV4LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEgsbURBQWtEO0lBQzlDSSxVQUFVLEVBQUUsSUFBSTtJQUNoQkMsR0FBRyxFQUFFLFNBQUxBLEdBQUcsR0FBYTtRQUNaLE9BQU9DLGFBQWEsQ0FBQ0MsZUFBZSxDQUFDO0lBQ3pDLENBQUM7Q0FDSixFQUFDLENBQUM7QUFDSFAsa0RBQWlEO0lBQzdDSSxVQUFVLEVBQUUsSUFBSTtJQUNoQkMsR0FBRyxFQUFFLFNBQUxBLEdBQUcsR0FBYTtRQUNaLE9BQU9HLFVBQVUsQ0FBQ0MsY0FBYyxDQUFDO0lBQ3JDLENBQUM7Q0FDSixFQUFDLENBQUM7QUFDSCxJQUFJSCxhQUFhLEdBQUdJLG1CQUFPLENBQUMsMEZB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JnZXRTb3J0ZWRSb3V0ZXMiLCJfaXNEeW5hbWljIiwiaXNEeW5hbWljUm91dGUiLCJyZXF1aXJlIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/index.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/is-bot.js": +/*!******************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/is-bot.js ***! + \******************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.isBot = isBot;\nfunction isBot(userAgent) {\n return /Googlebot|Mediapartners-Google|AdsBot-Google|googleweblight|Storebot-Google|Google-PageRenderer|Bingbot|BingPreview|Slurp|DuckDuckBot|baiduspider|yandex|sogou|LinkedInBot|bitlybot|tumblr|vkShare|quora link preview|facebookexternalhit|facebookcatalog|Twitterbot|applebot|redditbot|Slackbot|Discordbot|WhatsApp|SkypeUriPreview|ia_archiver/i.test(userAgent);\n} //# sourceMappingURL=is-bot.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2lzLWJvdC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELGFBQWEsR0FBR0UsS0FBSyxDQUFDO0FBQ3RCLFNBQVNBLEtBQUssQ0FBQ0MsU0FBUyxFQUFFO0lBQ3RCLE9BQU8sb1ZBQW9WQyxJQUFJLENBQUNELFNBQVMsQ0FBQyxDQUFDO0FBQy9XLENBQUMsQ0FFRCxrQ0FBa0MiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL25leHQvZGlzdC9zaGFyZWQvbGliL3JvdXRlci91dGlscy9pcy1ib3QuanM/MDcxNSJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuaXNCb3QgPSBpc0JvdDtcbmZ1bmN0aW9uIGlzQm90KHVzZXJBZ2VudCkge1xuICAgIHJldHVybiAvR29vZ2xlYm90fE1lZGlhcGFydG5lcnMtR29vZ2xlfEFkc0JvdC1Hb29nbGV8Z29vZ2xld2VibGlnaHR8U3RvcmVib3QtR29vZ2xlfEdvb2dsZS1QYWdlUmVuZGVyZXJ8QmluZ2JvdHxCaW5nUHJldmlld3xTbHVycHxEdWNrRHVja0JvdHxiYWlkdXNwaWRlcnx5YW5kZXh8c29nb3V8TGlua2VkSW5Cb3R8Yml0bHlib3R8dHVtYmxyfHZrU2hhcmV8cXVvcmEgbGluayBwcmV2aWV3fGZhY2Vib29rZXh0ZXJuYWxoaXR8ZmFjZWJvb2tjYXRhbG9nfFR3aXR0ZXJib3R8YXBwbGVib3R8cmVkZGl0Ym90fFNsYWNrYm90fERpc2NvcmRib3R8V2hhdHNBcHB8U2t5cGVVcmlQcmV2aWV3fGlhX2FyY2hpdmVyL2kudGVzdCh1c2VyQWdlbnQpO1xufVxuXG4vLyMgc291cmNlTWFwcGluZ1VSTD1pcy1ib3QuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiaXNCb3QiLCJ1c2VyQWdlbnQiLCJ0ZXN0Il0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/is-bot.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/is-dynamic.js": +/*!**********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/is-dynamic.js ***! + \**********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.isDynamicRoute = isDynamicRoute;\n// Identify /[param]/ in route string\nvar TEST_ROUTE = /\\/\\[[^/]+?\\](?=\\/|$)/;\nfunction isDynamicRoute(route) {\n return TEST_ROUTE.test(route);\n} //# sourceMappingURL=is-dynamic.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2lzLWR5bmFtaWMuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxzQkFBc0IsR0FBR0UsY0FBYyxDQUFDO0FBQ3hDLHFDQUFxQztBQUNyQyxJQUFNQyxVQUFVLHlCQUF5QjtBQUN6QyxTQUFTRCxjQUFjLENBQUNFLEtBQUssRUFBRTtJQUMzQixPQUFPRCxVQUFVLENBQUNFLElBQUksQ0FBQ0QsS0FBSyxDQUFDLENBQUM7QUFDbEMsQ0FBQyxDQUVELHNDQUFzQyIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL2lzLWR5bmFtaWMuanM/NDZmOSJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMuaXNEeW5hbWljUm91dGUgPSBpc0R5bmFtaWNSb3V0ZTtcbi8vIElkZW50aWZ5IC9bcGFyYW1dLyBpbiByb3V0ZSBzdHJpbmdcbmNvbnN0IFRFU1RfUk9VVEUgPSAvXFwvXFxbW14vXSs/XFxdKD89XFwvfCQpLztcbmZ1bmN0aW9uIGlzRHluYW1pY1JvdXRlKHJvdXRlKSB7XG4gICAgcmV0dXJuIFRFU1RfUk9VVEUudGVzdChyb3V0ZSk7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPWlzLWR5bmFtaWMuanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiaXNEeW5hbWljUm91dGUiLCJURVNUX1JPVVRFIiwicm91dGUiLCJ0ZXN0Il0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/is-dynamic.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/parse-path.js": +/*!**********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/parse-path.js ***! + \**********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.parsePath = parsePath;\nfunction parsePath(path) {\n var hashIndex = path.indexOf(\"#\");\n var queryIndex = path.indexOf(\"?\");\n var hasQuery = queryIndex > -1 && (hashIndex < 0 || queryIndex < hashIndex);\n if (hasQuery || hashIndex > -1) {\n return {\n pathname: path.substring(0, hasQuery ? queryIndex : hashIndex),\n query: hasQuery ? path.substring(queryIndex, hashIndex > -1 ? hashIndex : undefined) : \"\",\n hash: hashIndex > -1 ? path.slice(hashIndex) : \"\"\n };\n }\n return {\n pathname: path,\n query: \"\",\n hash: \"\"\n };\n} //# sourceMappingURL=parse-path.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZX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ICcnXG4gICAgICAgIH07XG4gICAgfVxuICAgIHJldHVybiB7XG4gICAgICAgIHBhdGhuYW1lOiBwYXRoLFxuICAgICAgICBxdWVyeTogJycsXG4gICAgICAgIGhhc2g6ICcnXG4gICAgfTtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9cGFyc2UtcGF0aC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJwYXJzZVBhdGgiLCJwYXRoIiwiaGFzaEluZGV4IiwiaW5kZXhPZiIsInF1ZXJ5SW5kZXgiLCJoYXNRdWVyeSIsInBhdGhuYW1lIiwic3Vic3RyaW5nIiwicXVlcnkiLCJ1bmRlZmluZWQiLCJoYXNoIiwic2xpY2UiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/parse-path.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js": +/*!******************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js ***! + \******************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.parseRelativeUrl = parseRelativeUrl;\nvar _utils = __webpack_require__(/*! ../../utils */ \"./node_modules/next/dist/shared/lib/utils.js\");\nvar _querystring = __webpack_require__(/*! ./querystring */ \"./node_modules/next/dist/shared/lib/router/utils/querystring.js\");\nfunction parseRelativeUrl(url, base) {\n var globalBase = new URL( false ? 0 : (0, _utils).getLocationOrigin());\n var resolvedBase = base ? new URL(base, globalBase) : url.startsWith(\".\") ? new URL( false ? 0 : window.location.href) : globalBase;\n var ref = new URL(url, resolvedBase), pathname = ref.pathname, searchParams = ref.searchParams, search = ref.search, hash = ref.hash, href = ref.href, origin = ref.origin;\n if (origin !== globalBase.origin) {\n throw new Error(\"invariant: invalid relative URL, router received \".concat(url));\n }\n return {\n pathname: pathname,\n query: (0, _querystring).searchParamsToUrlQuery(searchParams),\n search: search,\n hash: hash,\n href: href.slice(globalBase.origin.length)\n };\n} //# sourceMappingURL=parse-relative-url.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3BhcnNlLXJlbGF0aXZlLXVybC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHdCQUF3QixHQUFHRSxnQkFBZ0IsQ0FBQztBQUM1QyxJQUFJQyxNQUFNLEdBQUdDLG1CQUFPLENBQUMsaUVBQWEsQ0FBQztBQUNuQyxJQUFJQyxZQUFZLEdBQUdELG1CQUFPLENBQUMsc0ZBQWUsQ0FBQztBQUMzQyxTQUFTRixnQkFBZ0IsQ0FBQ0ksR0FBRyxFQUFFQyxJQUFJLEVBQUU7SUFDakMsSUFBTUMsVUFBVSxHQUFHLElBQUlDLEdBQUcsQ0FBQyxNQUE2QixHQUFHLENBQVUsR0FBRyxDQUFDLENBQUMsRUFBRU4sTUFBTSxFQUFFTyxpQkFBaUIsRUFBRSxDQUFDO0lBQ3hHLElBQU1DLFlBQVksR0FBR0osSUFBSSxHQUFHLElBQUlFLEdBQUcsQ0FBQ0YsSUFBSSxFQUFFQyxVQUFVLENBQUMsR0FBR0YsR0FBRyxDQUFDTSxVQUFVLENBQUMsR0FBRyxDQUFDLEdBQUcsSUFBSUgsR0FBRyxDQUFDLE1BQTZCLEdBQUcsQ0FBVSxHQUFHSSxNQUFNLENBQUNDLFFBQVEsQ0FBQ0MsSUFBSSxDQUFDLEdBQUdQLFVBQVU7SUFDckssSUFBcUUsR0FBMEIsR0FBMUIsSUFBSUMsR0FBRy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KHNlYXJjaFBhcmFtcyksXG4gICAgICAgIHNlYXJjaCxcbiAgICAgICAgaGFzaCxcbiAgICAgICAgaHJlZjogaHJlZi5zbGljZShnbG9iYWxCYXNlLm9yaWdpbi5sZW5ndGgpXG4gICAgfTtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9cGFyc2UtcmVsYXRpdmUtdXJsLmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsInBhcnNlUmVsYXRpdmVVcmwiLCJfdXRpbHMiLCJyZXF1aXJlIiwiX3F1ZXJ5c3RyaW5nIiwidXJsIiwiYmFzZSIsImdsb2JhbEJhc2UiLCJVUkwiLCJnZXRMb2NhdGlvbk9yaWdpbiIsInJlc29sdmVkQmFzZSIsInN0YXJ0c1dpdGgiLCJ3aW5kb3ciLCJsb2NhdGlvbiIsImhyZWYiLCJwYXRobmFtZSIsInNlYXJjaFBhcmFtcyIsInNlYXJjaCIsImhhc2giLCJvcmlnaW4iLCJFcnJvciIsInF1ZXJ5Iiwic2VhcmNoUGFyYW1zVG9VcmxRdWVyeSIsInNsaWNlIiwibGVuZ3RoIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js": +/*!***************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js ***! + \***************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.pathHasPrefix = pathHasPrefix;\nvar _parsePath = __webpack_require__(/*! ./parse-path */ \"./node_modules/next/dist/shared/lib/router/utils/parse-path.js\");\nfunction pathHasPrefix(path, prefix) {\n if (typeof path !== \"string\") {\n return false;\n }\n var pathname = (0, _parsePath).parsePath(path).pathname;\n return pathname === prefix || pathname.startsWith(prefix + \"/\");\n} //# sourceMappingURL=path-has-prefix.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3BhdGgtaGFzLXByZWZpeC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHFCQUFxQixHQUFHRSxhQUFhLENBQUM7QUFDdEMsSUFBSUMsVUFBVSxHQUFHQyxtQkFBTyxDQUFDLG9GQUFjLENBQUM7QUFDeEMsU0FBU0YsYUFBYSxDQUFDRyxJQUFJLEVBQUVDLE1BQU0sRUFBRTtJQUNqQyxJQUFJLE9BQU9ELElBQUksS0FBSyxRQUFRLEVBQUU7UUFDMUIsT0FBTyxLQUFLLENBQUM7SUFDakIsQ0FBQztJQUNELElBQU0sUUFBVSxHQUFNLENBQUMsQ0FBQyxFQUFFRixVQUFVLEVBQUVLLFNBQVMsQ0FBQ0gsSUFBSSxDQUFDLENBQTdDRSxRQUFRO0lBQ2hCLE9BQU9BLFFBQVEsS0FBS0QsTUFBTSxJQUFJQyxRQUFRLENBQUNFLFVBQVUsQ0FBQ0gsTUFBTSxHQUFHLEdBQUcsQ0FBQyxDQUFDO0FBQ3BFLENBQUMsQ0FFRCwyQ0FBMkMiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL25leHQvZGlzdC9zaGFyZWQvbGliL3JvdXRlci91dGlscy9wYXRoLWhhcy1wcmVmaXguanM/YjUzOCJdLCJzb3VyY2VzQ29udGVudCI6WyJcInVzZSBzdHJpY3RcIjtcbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShleHBvcnRzLCBcIl9fZXNNb2R1bGVcIiwge1xuICAgIHZhbHVlOiB0cnVlXG59KTtcbmV4cG9ydHMucGF0aEhhc1ByZWZpeCA9IHBhdGhIYXNQcmVmaXg7XG52YXIgX3BhcnNlUGF0aCA9IHJlcXVpcmUoXCIuL3BhcnNlLXBhdGhcIik7XG5mdW5jdGlvbiBwYXRoSGFzUHJlZml4KHBhdGgsIHByZWZpeCkge1xuICAgIGlmICh0eXBlb2YgcGF0aCAhPT0gJ3N0cmluZycpIHtcbiAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgIH1cbiAgICBjb25zdCB7IHBhdGhuYW1lICB9ID0gKDAsIF9wYXJzZVBhdGgpLnBhcnNlUGF0aChwYXRoKTtcbiAgICByZXR1cm4gcGF0aG5hbWUgPT09IHByZWZpeCB8fCBwYXRobmFtZS5zdGFydHNXaXRoKHByZWZpeCArICcvJyk7XG59XG5cbi8vIyBzb3VyY2VNYXBwaW5nVVJMPXBhdGgtaGFzLXByZWZpeC5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJwYXRoSGFzUHJlZml4IiwiX3BhcnNlUGF0aCIsInJlcXVpcmUiLCJwYXRoIiwicHJlZml4IiwicGF0aG5hbWUiLCJwYXJzZVBhdGgiLCJzdGFydHNXaXRoIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/querystring.js": +/*!***********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/querystring.js ***! + \***********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _slicedToArray = (__webpack_require__(/*! @swc/helpers/lib/_sliced_to_array.js */ \"./node_modules/@swc/helpers/lib/_sliced_to_array.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.searchParamsToUrlQuery = searchParamsToUrlQuery;\nexports.urlQueryToSearchParams = urlQueryToSearchParams;\nexports.assign = assign;\nfunction searchParamsToUrlQuery(searchParams) {\n var query = {};\n searchParams.forEach(function(value, key) {\n if (typeof query[key] === \"undefined\") {\n query[key] = value;\n } else if (Array.isArray(query[key])) {\n query[key].push(value);\n } else {\n query[key] = [\n query[key],\n value\n ];\n }\n });\n return query;\n}\nfunction stringifyUrlQueryParam(param) {\n if (typeof param === \"string\" || typeof param === \"number\" && !isNaN(param) || typeof param === \"boolean\") {\n return String(param);\n } else {\n return \"\";\n }\n}\nfunction urlQueryToSearchParams(urlQuery) {\n var result = new URLSearchParams();\n Object.entries(urlQuery).forEach(function(param) {\n var _param = _slicedToArray(param, 2), key = _param[0], value = _param[1];\n if (Array.isArray(value)) {\n value.forEach(function(item) {\n return result.append(key, stringifyUrlQueryParam(item));\n });\n } else {\n result.set(key, stringifyUrlQueryParam(value));\n }\n });\n return result;\n}\nfunction assign(target) {\n for(var _len = arguments.length, searchParamsList = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++){\n searchParamsList[_key - 1] = arguments[_key];\n }\n searchParamsList.forEach(function(searchParams) {\n Array.from(searchParams.keys()).forEach(function(key) {\n return target.delete(key);\n });\n searchParams.forEach(function(value, key) {\n return target.append(key, value);\n });\n });\n return target;\n} //# sourceMappingURL=querystring.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3F1ZXJ5c3RyaW5nLmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhOzs7OztBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELDhCQUE4QixHQUFHRSxzQkF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aXN0IiwiZnJvbSIsImtleXMiLCJkZWxldGUiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/querystring.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js": +/*!******************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js ***! + \******************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.removePathPrefix = removePathPrefix;\nvar _pathHasPrefix = __webpack_require__(/*! ./path-has-prefix */ \"./node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js\");\nfunction removePathPrefix(path, prefix) {\n if ((0, _pathHasPrefix).pathHasPrefix(path, prefix)) {\n var withoutPrefix = path.slice(prefix.length);\n return withoutPrefix.startsWith(\"/\") ? withoutPrefix : \"/\".concat(withoutPrefix);\n }\n return path;\n} //# sourceMappingURL=remove-path-prefix.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3JlbW92ZS1wYXRoLXByZWZpeC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELHdCQUF3QixHQUFHRSxnQkFBZ0IsQ0FBQztBQUM1QyxJQUFJQyxjQUFjLEdBQUdDLG1CQUFPLENBQUMsOEZBQW1CLENBQUM7QUFDakQsU0FBU0YsZ0JBQWdCLENBQUNHLElBQUksRUFBRUMsTUFBTSxFQUFFO0lBQ3BDLElBQUksQ0FBQyxDQUFDLEVBQUVILGNBQWMsRUFBRUksYUFBYSxDQUFDRixJQUFJLEVBQUVDLE1BQU0sQ0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ufVxuXG4vLyMgc291cmNlTWFwcGluZ1VSTD1yZW1vdmUtcGF0aC1wcmVmaXguanMubWFwIl0sIm5hbWVzIjpbIk9iamVjdCIsImRlZmluZVByb3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwicmVtb3ZlUGF0aFByZWZpeCIsIl9wYXRoSGFzUHJlZml4IiwicmVxdWlyZSIsInBhdGgiLCJwcmVmaXgiLCJwYXRoSGFzUHJlZml4Iiwid2l0aG91dFByZWZpeCIsInNsaWNlIiwibGVuZ3RoIiwic3RhcnRzV2l0aCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js": +/*!*********************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js ***! + \*********************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.removeTrailingSlash = removeTrailingSlash;\nfunction removeTrailingSlash(route) {\n return route.replace(/\\/$/, \"\") || \"/\";\n} //# sourceMappingURL=remove-trailing-slash.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3JlbW92ZS10cmFpbGluZy1zbGFzaC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiQSw4Q0FBNkM7SUFDekNHLEtBQUssRUFBRSxJQUFJO0NBQ2QsRUFBQyxDQUFDO0FBQ0hELDJCQUEyQixHQUFHRSxtQkFBbUIsQ0FBQztBQUNsRCxTQUFTQSxtQkFBbUIsQ0FBQ0MsS0FBSyxFQUFFO0lBQ2hDLE9BQU9BLEtBQUssQ0FBQ0MsT0FBTyxRQUFRLEVBQUUsQ0FBQyxJQUFJLEdBQUcsQ0FBQztBQUMzQyxDQUFDLENBRUQsaURBQWlEIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9uZXh0L2Rpc3Qvc2hhcmVkL2xpYi9yb3V0ZXIvdXRpbHMvcmVtb3ZlLXRyYWlsaW5nLXNsYXNoLmpzP2VjMDYiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5PYmplY3QuZGVmaW5lUHJvcGVydHkoZXhwb3J0cywgXCJfX2VzTW9kdWxlXCIsIHtcbiAgICB2YWx1ZTogdHJ1ZVxufSk7XG5leHBvcnRzLnJlbW92ZVRyYWlsaW5nU2xhc2ggPSByZW1vdmVUcmFpbGluZ1NsYXNoO1xuZnVuY3Rpb24gcmVtb3ZlVHJhaWxpbmdTbGFzaChyb3V0ZSkge1xuICAgIHJldHVybiByb3V0ZS5yZXBsYWNlKC9cXC8kLywgJycpIHx8ICcvJztcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9cmVtb3ZlLXRyYWlsaW5nLXNsYXNoLmpzLm1hcCJdLCJuYW1lcyI6WyJPYmplY3QiLCJkZWZpbmVQcm9wZXJ0eSIsImV4cG9ydHMiLCJ2YWx1ZSIsInJlbW92ZVRyYWlsaW5nU2xhc2giLCJyb3V0ZSIsInJlcGxhY2UiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/route-matcher.js": +/*!*************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/route-matcher.js ***! + \*************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.getRouteMatcher = getRouteMatcher;\nvar _utils = __webpack_require__(/*! ../../utils */ \"./node_modules/next/dist/shared/lib/utils.js\");\nfunction getRouteMatcher(param) {\n var re = param.re, groups = param.groups;\n return function(pathname) {\n var routeMatch = re.exec(pathname);\n if (!routeMatch) {\n return false;\n }\n var decode = function(param) {\n try {\n return decodeURIComponent(param);\n } catch (_) {\n throw new _utils.DecodeError(\"failed to decode param\");\n }\n };\n var params = {};\n Object.keys(groups).forEach(function(slugName) {\n var g = groups[slugName];\n var m = routeMatch[g.pos];\n if (m !== undefined) {\n params[slugName] = ~m.indexOf(\"/\") ? m.split(\"/\").map(function(entry) {\n return decode(entry);\n }) : g.repeat ? [\n decode(m)\n ] : decode(m);\n }\n });\n return params;\n };\n} //# sourceMappingURL=route-matcher.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3JvdXRlLW1hdGNoZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCx1QkFBdUIsR0FBR0UsZUFBZSxDQUFDO0FBQzFDLElBQUlDLE1BQU0sR0FBR0MsbUJBQU8sQ0FBQyxpRUFBYSxDQUFDO0FBQ25DLFNBQVNGLGVBQWUsQ0FBQyxLQUFnQixFQUFFO1FBQWhCRyxFQUFFLEdBQUosS0FBZ0IsQ0FBZEEsRUFBRSxFQUFHQyxNQUFNLEdBQWIsS0FBZ0IsQ0FBVEEsTUFBTTtJQUNsQyxPQUFPLFNBQUNDLFFBQVEsRUFBRztRQUNmLElBQU1DLFVBQVUsR0FBR0gsRUFBRSxDQUFDSSxJQUFJLENBQUNGLFFBQVEsQ0FBQztRQUNwQyxJQUFJLENBQUNDLFVBQVUsRUFBRTtZQUNiLE9BQU8sS0FBSyxDQUFDO1FBQ2pCLENBQUM7UUFDRC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IGdyb3Vwc1tzbHVnTmFtZV07XG4gICAgICAgICAgICBjb25zdCBtID0gcm91dGVNYXRjaFtnLnBvc107XG4gICAgICAgICAgICBpZiAobSAhPT0gdW5kZWZpbmVkKSB7XG4gICAgICAgICAgICAgICAgcGFyYW1zW3NsdWdOYW1lXSA9IH5tLmluZGV4T2YoJy8nKSA/IG0uc3BsaXQoJy8nKS5tYXAoKGVudHJ5KT0+ZGVjb2RlKGVudHJ5KSkgOiBnLnJlcGVhdCA/IFtcbiAgICAgICAgICAgICAgICAgICAgZGVjb2RlKG0pXG4gICAgICAgICAgICAgICAgXSA6IGRlY29kZShtKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfSk7XG4gICAgICAgIHJldHVybiBwYXJhbXM7XG4gICAgfTtcbn1cblxuLy8jIHNvdXJjZU1hcHBpbmdVUkw9cm91dGUtbWF0Y2hlci5qcy5tYXAiXSwibmFtZXMiOlsiT2JqZWN0IiwiZGVmaW5lUHJvcGVydHkiLCJleHBvcnRzIiwidmFsdWUiLCJnZXRSb3V0ZU1hdGNoZXIiLCJfdXRpbHMiLCJyZXF1aXJlIiwicmUiLCJncm91cHMiLCJwYXRobmFtZSIsInJvdXRlTWF0Y2giLCJleGVjIiwiZGVjb2RlIiwicGFyYW0iLCJkZWNvZGVVUklDb21wb25lbnQiLCJfIiwiRGVjb2RlRXJyb3IiLCJwYXJhbXMiLCJrZXlzIiwiZm9yRWFjaCIsInNsdWdOYW1lIiwiZyIsIm0iLCJwb3MiLCJ1bmRlZmluZWQiLCJpbmRleE9mIiwic3BsaXQiLCJtYXAiLCJlbnRyeSIsInJlcGVhdCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/route-matcher.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/route-regex.js": +/*!***********************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/route-regex.js ***! + \***********************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.getRouteRegex = getRouteRegex;\nexports.getNamedRouteRegex = getNamedRouteRegex;\nexports.getNamedMiddlewareRegex = getNamedMiddlewareRegex;\nvar _extends = (__webpack_require__(/*! @swc/helpers/lib/_extends.js */ \"./node_modules/@swc/helpers/lib/_extends.js\")[\"default\"]);\nvar _escapeRegexp = __webpack_require__(/*! ../../escape-regexp */ \"./node_modules/next/dist/shared/lib/escape-regexp.js\");\nvar _removeTrailingSlash = __webpack_require__(/*! ./remove-trailing-slash */ \"./node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js\");\n/**\n * Parses a given parameter from a route to a data structure that can be used\n * to generate the parametrized route. Examples:\n * - `[...slug]` -> `{ name: 'slug', repeat: true, optional: true }`\n * - `[foo]` -> `{ name: 'foo', repeat: false, optional: true }`\n * - `bar` -> `{ name: 'bar', repeat: false, optional: false }`\n */ function parseParameter(param) {\n var optional = param.startsWith(\"[\") && param.endsWith(\"]\");\n if (optional) {\n param = param.slice(1, -1);\n }\n var repeat = param.startsWith(\"...\");\n if (repeat) {\n param = param.slice(3);\n }\n return {\n key: param,\n repeat: repeat,\n optional: optional\n };\n}\nfunction getParametrizedRoute(route) {\n var segments = (0, _removeTrailingSlash).removeTrailingSlash(route).slice(1).split(\"/\");\n var groups = {};\n var groupIndex = 1;\n return {\n parameterizedRoute: segments.map(function(segment) {\n if (segment.startsWith(\"[\") && segment.endsWith(\"]\")) {\n var ref = parseParameter(segment.slice(1, -1)), key = ref.key, optional = ref.optional, repeat = ref.repeat;\n groups[key] = {\n pos: groupIndex++,\n repeat: repeat,\n optional: optional\n };\n return repeat ? optional ? \"(?:/(.+?))?\" : \"/(.+?)\" : \"/([^/]+?)\";\n } else {\n return \"/\".concat((0, _escapeRegexp).escapeStringRegexp(segment));\n }\n }).join(\"\"),\n groups: groups\n };\n}\nfunction getRouteRegex(normalizedRoute) {\n var ref = getParametrizedRoute(normalizedRoute), parameterizedRoute = ref.parameterizedRoute, groups = ref.groups;\n return {\n re: new RegExp(\"^\".concat(parameterizedRoute, \"(?:/)?$\")),\n groups: groups\n };\n}\n/**\n * Builds a function to generate a minimal routeKey using only a-z and minimal\n * number of characters.\n */ function buildGetSafeRouteKey() {\n var routeKeyCharCode = 97;\n var routeKeyCharLength = 1;\n return function() {\n var routeKey = \"\";\n for(var i = 0; i < routeKeyCharLength; i++){\n routeKey += String.fromCharCode(routeKeyCharCode);\n routeKeyCharCode++;\n if (routeKeyCharCode > 122) {\n routeKeyCharLength++;\n routeKeyCharCode = 97;\n }\n }\n return routeKey;\n };\n}\nfunction getNamedParametrizedRoute(route) {\n var segments = (0, _removeTrailingSlash).removeTrailingSlash(route).slice(1).split(\"/\");\n var getSafeRouteKey = buildGetSafeRouteKey();\n var routeKeys = {};\n return {\n namedParameterizedRoute: segments.map(function(segment) {\n if (segment.startsWith(\"[\") && segment.endsWith(\"]\")) {\n var ref = parseParameter(segment.slice(1, -1)), key = ref.key, optional = ref.optional, repeat = ref.repeat;\n // replace any non-word characters since they can break\n // the named regex\n var cleanedKey = key.replace(/\\W/g, \"\");\n var invalidKey = false;\n // check if the key is still invalid and fallback to using a known\n // safe key\n if (cleanedKey.length === 0 || cleanedKey.length > 30) {\n invalidKey = true;\n }\n if (!isNaN(parseInt(cleanedKey.slice(0, 1)))) {\n invalidKey = true;\n }\n if (invalidKey) {\n cleanedKey = getSafeRouteKey();\n }\n routeKeys[cleanedKey] = key;\n return repeat ? optional ? \"(?:/(?<\".concat(cleanedKey, \">.+?))?\") : \"/(?<\".concat(cleanedKey, \">.+?)\") : \"/(?<\".concat(cleanedKey, \">[^/]+?)\");\n } else {\n return \"/\".concat((0, _escapeRegexp).escapeStringRegexp(segment));\n }\n }).join(\"\"),\n routeKeys: routeKeys\n };\n}\nfunction getNamedRouteRegex(normalizedRoute) {\n var result = getNamedParametrizedRoute(normalizedRoute);\n return _extends({}, getRouteRegex(normalizedRoute), {\n namedRegex: \"^\".concat(result.namedParameterizedRoute, \"(?:/)?$\"),\n routeKeys: result.routeKeys\n });\n}\nfunction getNamedMiddlewareRegex(normalizedRoute, options) {\n var parameterizedRoute = getParametrizedRoute(normalizedRoute).parameterizedRoute;\n var _catchAll = options.catchAll, catchAll = _catchAll === void 0 ? true : _catchAll;\n if (parameterizedRoute === \"/\") {\n var catchAllRegex = catchAll ? \".*\" : \"\";\n return {\n namedRegex: \"^/\".concat(catchAllRegex, \"$\")\n };\n }\n var namedParameterizedRoute = getNamedParametrizedRoute(normalizedRoute).namedParameterizedRoute;\n var catchAllGroupedRegex = catchAll ? \"(?:(/.*)?)\" : \"\";\n return {\n namedRegex: \"^\".concat(namedParameterizedRoute).concat(catchAllGroupedRegex, \"$\")\n };\n} //# sourceMappingURL=route-regex.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3JvdXRlLXJlZ2V4LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhO0FBQ2JBLDhDQUE2QztJQUN6Q0csS0FBSyxFQUFFLElBQUk7Q0FDZCxFQUFDLENBQUM7QUFDSEQscUJBQXFCLEdBQUdFLGFBQWEsQ0FBQztBQUN0Q0YsMEJBQTBCLEdBQUdHLGtCQUFrQixDQUFDO0FBQ2hESCwrQkFBK0IsR0FBR0ksdUJBQXVCLENBQUM7QUFDMUQsSUFBSUMsUUFBUSxHQUFHQyxtSEFBK0M7QUFDOUQsSUFBSUUsYUFBYSxHQUFHRixtQkFBTyxDQUFDLGlGQUFxQixDQUFDO0FBQ2xELElBQUlHLG9CQUFvQixHQUFHSCxtQkFBTyxDQUFDLDBHQUF5QixDQUFDO0FBQzdEOzs7Ozs7Q0FNQyxHQUFHLFNBQVNJLGNBQWMsQ0FBQ0MsS0FBSyxFQUFFO0lBQy9CLElBQU1D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aCgnLi4uJyk7XG4gICAgaWYgKHJlcGVhdCkge1xuICAgICAgICBwYXJhbSA9IHBhcmFtLnNsaWNlKDMpO1xuICAgIH1cbiAgICByZXR1cm4ge1xuICAgICAgICBrZXk6IHBhcmFtLFxuICAgICAgICByZXBlYXQsXG4gICAgICAgIG9wdGlvbmFsXG4gICAgfTtcbn1cbmZ1bmN0aW9uIGdldFBhcmFtZXRyaXplZFJvdXRlKHJvdXRlKSB7XG4gICAgY29uc3Qgc2VnbWVudHMgPSAoMCwgX3JlbW92ZVRyYWlsaW5nU2xhc2gpLnJlbW92ZVRyYWlsaW5nU2xhc2gocm91dGUpLnNsaWNlKDEpLnNwbGl0KCcvJyk7XG4gICAgY29uc3QgZ3JvdXBzID0ge307XG4gICAgbGV0IGdyb3VwSW5kZXggPSAxO1xuICAgIHJldHVybiB7XG4gICAgICAgIHBhcmFtZXRlcml6ZWRSb3V0ZTogc2VnbWVudHMubWFwKChzZWdtZW50KT0+e1xuICAgICAgICAgICAgaWYgKHNlZ21lbnQuc3RhcnRzV2l0aCgnWycpICYmIHNlZ21lbnQuZW5kc1dpdGgoJ10nKSkge1xuICAgICAgICAgICAgICAgIGNvbnN0IHsga2V5ICwgb3B0aW9uYWwgLCByZXBlYXQgIH0gPSBwYXJzZVBhcmFtZXRlcihzZWdtZW50LnNsaWNlKDEsIC0xKSk7XG4gICAgICAgICAgICAgICAgZ3JvdXBzW2tleV0gPSB7XG4gICAgICAgICAgICAgICAgICAgIHBvczogZ3JvdXBJbmRleCsrLFxuICAgICAgICAgICAgICAgICAgICByZXBlYXQsXG4gICAgICAgICAgICAgICAgICAgIG9wdGlvbmFsXG4gICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICByZXR1cm4gcmVwZWF0ID8gb3B0aW9uYWwgPyAnKD86LyguKz8pKT8nIDogJy8oLis/KScgOiAnLyhbXi9dKz8pJztcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIG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GwgaW52YWxpZCBhbmQgZmFsbGJhY2sgdG8gdXNpbmcgYSBrbm93blxuICAgICAgICAgICAgICAgIC8vIHNhZmUga2V5XG4gICAgICAgICAgICAgICAgaWYgKGNsZWFuZWRLZXkubGVuZ3RoID09PSAwIHx8IGNsZWFuZWRLZXkubGVuZ3RoID4gMzApIHtcbiAgICAgICAgICAgICAgICAgICAgaW52YWxpZEtleSA9IHRydWU7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGlmICghaXNOYU4ocGFyc2VJbnQoY2xlYW5lZEtleS5zbGljZSgwLCAxKSkpKSB7XG4gICAgICAgICAgICAgICAgICAgIGludmFsaWRLZXkgPSB0cnVlO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAoaW52YWxpZEtleSkge1xuICAgICAgICAgICAgICAgICAgICBjbGVhbmVkS2V5ID0gZ2V0U2FmZVJvdXRlS2V5KCk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJvdXRlS2V5c1tjbGVhbmVkS2V5XSA9IGtleTtcbiAgICAgICAgICAgICAgICByZXR1cm4gcmVwZWF0ID8gb3B0aW9uYWwgPyBgKD86Lyg/PCR7Y2xlYW5lZEtleX0+Lis/KSk/YCA6IGAvKD88JHtjbGVhbmVkS2V5fT4uKz8pYCA6IGAvKD88JHtjbGVhbmVkS2V5fT5bXi9dKz8pYDtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIGAvJHsoMCwgX2VzY2FwZVJlZ2V4cCkuZXNjYXBlU3RyaW5nUmVnZXhwKHNlZ21lbnQpfWA7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0pLmpvaW4oJycpLFxuICAgICAgICByb3V0ZUtleXNcbiAgICB9O1xufVxuZnVuY3Rpb24gZ2V0TmFtZWRSb3V0ZVJlZ2V4KG5vcm1hbGl6ZWRSb3V0ZSkge1xuICAgIGNvbnN0IHJlc3VsdCA9I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hdGNoQWxsIiwiY2F0Y2hBbGxSZWdleCIsImNhdGNoQWxsR3JvdXBlZFJlZ2V4Il0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/route-regex.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/router/utils/sorted-routes.js": +/*!*************************************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/router/utils/sorted-routes.js ***! + \*************************************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _classCallCheck = (__webpack_require__(/*! @swc/helpers/lib/_class_call_check.js */ \"./node_modules/@swc/helpers/lib/_class_call_check.js\")[\"default\"]);\nvar _createClass = (__webpack_require__(/*! @swc/helpers/lib/_create_class.js */ \"./node_modules/@swc/helpers/lib/_create_class.js\")[\"default\"]);\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.getSortedRoutes = getSortedRoutes;\nvar UrlNode = /*#__PURE__*/ function() {\n function UrlNode() {\n _classCallCheck(this, UrlNode);\n this.placeholder = true;\n this.children = new Map();\n this.slugName = null;\n this.restSlugName = null;\n this.optionalRestSlugName = null;\n }\n _createClass(UrlNode, [\n {\n key: \"insert\",\n value: function insert(urlPath) {\n this._insert(urlPath.split(\"/\").filter(Boolean), [], false);\n }\n },\n {\n key: \"smoosh\",\n value: function smoosh() {\n return this._smoosh();\n }\n },\n {\n key: \"_smoosh\",\n value: function _smoosh() {\n var prefix = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : \"/\";\n var _this = this;\n var childrenPaths = _toConsumableArray(this.children.keys()).sort();\n if (this.slugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf(\"[]\"), 1);\n }\n if (this.restSlugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf(\"[...]\"), 1);\n }\n if (this.optionalRestSlugName !== null) {\n childrenPaths.splice(childrenPaths.indexOf(\"[[...]]\"), 1);\n }\n var routes = childrenPaths.map(function(c) {\n return _this.children.get(c)._smoosh(\"\".concat(prefix).concat(c, \"/\"));\n }).reduce(function(prev, curr) {\n return _toConsumableArray(prev).concat(_toConsumableArray(curr));\n }, []);\n if (this.slugName !== null) {\n var _routes;\n (_routes = routes).push.apply(_routes, _toConsumableArray(this.children.get(\"[]\")._smoosh(\"\".concat(prefix, \"[\").concat(this.slugName, \"]/\"))));\n }\n if (!this.placeholder) {\n var r = prefix === \"/\" ? \"/\" : prefix.slice(0, -1);\n if (this.optionalRestSlugName != null) {\n throw new Error('You cannot define a route with the same specificity as a optional catch-all route (\"'.concat(r, '\" and \"').concat(r, \"[[...\").concat(this.optionalRestSlugName, ']]\").'));\n }\n routes.unshift(r);\n }\n if (this.restSlugName !== null) {\n var _routes1;\n (_routes1 = routes).push.apply(_routes1, _toConsumableArray(this.children.get(\"[...]\")._smoosh(\"\".concat(prefix, \"[...\").concat(this.restSlugName, \"]/\"))));\n }\n if (this.optionalRestSlugName !== null) {\n var _routes2;\n (_routes2 = routes).push.apply(_routes2, _toConsumableArray(this.children.get(\"[[...]]\")._smoosh(\"\".concat(prefix, \"[[...\").concat(this.optionalRestSlugName, \"]]/\"))));\n }\n return routes;\n }\n },\n {\n key: \"_insert\",\n value: function _insert(urlPaths, slugNames, isCatchAll) {\n if (urlPaths.length === 0) {\n this.placeholder = false;\n return;\n }\n if (isCatchAll) {\n throw new Error(\"Catch-all must be the last part of the URL.\");\n }\n // The next segment in the urlPaths list\n var nextSegment = urlPaths[0];\n // Check if the segment matches `[something]`\n if (nextSegment.startsWith(\"[\") && nextSegment.endsWith(\"]\")) {\n var handleSlug = function handleSlug(previousSlug, nextSlug) {\n if (previousSlug !== null) {\n // If the specific segment already has a slug but the slug is not `something`\n // This prevents collisions like:\n // pages/[post]/index.js\n // pages/[id]/index.js\n // Because currently multiple dynamic params on the same segment level are not supported\n if (previousSlug !== nextSlug) {\n // TODO: This error seems to be confusing for users, needs an error link, the description can be based on above comment.\n throw new Error(\"You cannot use different slug names for the same dynamic path ('\".concat(previousSlug, \"' !== '\").concat(nextSlug, \"').\"));\n }\n }\n slugNames.forEach(function(slug) {\n if (slug === nextSlug) {\n throw new Error('You cannot have the same slug name \"'.concat(nextSlug, '\" repeat within a single dynamic path'));\n }\n if (slug.replace(/\\W/g, \"\") === nextSegment.replace(/\\W/g, \"\")) {\n throw new Error('You cannot have the slug names \"'.concat(slug, '\" and \"').concat(nextSlug, '\" differ only by non-word symbols within a single dynamic path'));\n }\n });\n slugNames.push(nextSlug);\n };\n // Strip `[` and `]`, leaving only `something`\n var segmentName = nextSegment.slice(1, -1);\n var isOptional = false;\n if (segmentName.startsWith(\"[\") && segmentName.endsWith(\"]\")) {\n // Strip optional `[` and `]`, leaving only `something`\n segmentName = segmentName.slice(1, -1);\n isOptional = true;\n }\n if (segmentName.startsWith(\"...\")) {\n // Strip `...`, leaving only `something`\n segmentName = segmentName.substring(3);\n isCatchAll = true;\n }\n if (segmentName.startsWith(\"[\") || segmentName.endsWith(\"]\")) {\n throw new Error(\"Segment names may not start or end with extra brackets ('\".concat(segmentName, \"').\"));\n }\n if (segmentName.startsWith(\".\")) {\n throw new Error(\"Segment names may not start with erroneous periods ('\".concat(segmentName, \"').\"));\n }\n if (isCatchAll) {\n if (isOptional) {\n if (this.restSlugName != null) {\n throw new Error('You cannot use both an required and optional catch-all route at the same level (\"[...'.concat(this.restSlugName, ']\" and \"').concat(urlPaths[0], '\" ).'));\n }\n handleSlug(this.optionalRestSlugName, segmentName);\n // slugName is kept as it can only be one particular slugName\n this.optionalRestSlugName = segmentName;\n // nextSegment is overwritten to [[...]] so that it can later be sorted specifically\n nextSegment = \"[[...]]\";\n } else {\n if (this.optionalRestSlugName != null) {\n throw new Error('You cannot use both an optional and required catch-all route at the same level (\"[[...'.concat(this.optionalRestSlugName, ']]\" and \"').concat(urlPaths[0], '\").'));\n }\n handleSlug(this.restSlugName, segmentName);\n // slugName is kept as it can only be one particular slugName\n this.restSlugName = segmentName;\n // nextSegment is overwritten to [...] so that it can later be sorted specifically\n nextSegment = \"[...]\";\n }\n } else {\n if (isOptional) {\n throw new Error('Optional route parameters are not yet supported (\"'.concat(urlPaths[0], '\").'));\n }\n handleSlug(this.slugName, segmentName);\n // slugName is kept as it can only be one particular slugName\n this.slugName = segmentName;\n // nextSegment is overwritten to [] so that it can later be sorted specifically\n nextSegment = \"[]\";\n }\n }\n // If this UrlNode doesn't have the nextSegment yet we create a new child UrlNode\n if (!this.children.has(nextSegment)) {\n this.children.set(nextSegment, new UrlNode());\n }\n this.children.get(nextSegment)._insert(urlPaths.slice(1), slugNames, isCatchAll);\n }\n }\n ]);\n return UrlNode;\n}();\nfunction getSortedRoutes(normalizedPages) {\n // First the UrlNode is created, and every UrlNode can have only 1 dynamic segment\n // Eg you can't have pages/[post]/abc.js and pages/[hello]/something-else.js\n // Only 1 dynamic segment per nesting level\n // So in the case that is test/integration/dynamic-routing it'll be this:\n // pages/[post]/comments.js\n // pages/blog/[post]/comment/[id].js\n // Both are fine because `pages/[post]` and `pages/blog` are on the same level\n // So in this case `UrlNode` created here has `this.slugName === 'post'`\n // And since your PR passed through `slugName` as an array basically it'd including it in too many possibilities\n // Instead what has to be passed through is the upwards path's dynamic names\n var root = new UrlNode();\n // Here the `root` gets injected multiple paths, and insert will break them up into sublevels\n normalizedPages.forEach(function(pagePath) {\n return root.insert(pagePath);\n });\n // Smoosh will then sort those sublevels up to the point where you get the correct route definition priority\n return root.smoosh();\n} //# sourceMappingURL=sorted-routes.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvcm91dGVyL3V0aWxzL3NvcnRlZC1yb3V0ZXMuanMuanMiL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U2x1Zykge1xuICAgICAgICAgICAgICAgICAgICAgICAgdGhyb3cgbmV3IEVycm9yKGBZb3UgY2Fubm90IGhhdmUgdGhlIHNhbWUgc2x1ZyBuYW1lIFwiJHtuZXh0U2x1Z31cIiByZXBlYXQgd2l0aGluIGEgc2luZ2xlIGR5bmFtaWMgcGF0aGApO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIGlmIChzbHVnLnJlcGxhY2UoL1xcVy9nLCAnJykgPT09IG5leHRTZWdtZW50LnJlcGxhY2UoL1xcVy9nLCAnJykpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcihgWW91IGNhbm5vdCBoYXZlIHRoZSBzbHVnIG5hbWVzIFwiJHtzbHVnfVwiIGFuZCBcIiR7bmV4dFNsdWd9XCIgZGlmZmVyIG9ubHkgYnkgbm9uLXdvcmQgc3ltYm9scyB3aXRoaW4gYSBzaW5nbGUgZHluYW1pYyBwYXRoYCk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICBzbHVnTmFtZXMucHVzaChuZXh0U2x1Zyk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAoaXNDYXRjaEFsbCkge1xuICAgICAgICAgICAgICAgIGlmIChpc09wdGlvbmFsKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLnJlc3RTbHVnTmFtZSAhPSBudWxsKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgRXJyb3IoYFlvdSBjYW5ub3QgdXNlIGJvdGggYW4gcmVxdWlyZWQgYW5kIG9wdGlvbmFsIGNhdGNoLWFsbCByb3V0ZSBhdCB0aGUgc2FtZSBsZXZlbCAoXCJbLi4uJHt0aGlzLnJlc3RTbHVnTmFtZX1dXCIgYW5kIFwiJHt1cmxQYXRoc1swXX1cIiApLmApO1xuICAgICAgICAgICAgICAgICAgICB9X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b3BlcnR5IiwiZXhwb3J0cyIsInZhbHVlIiwiZ2V0U29ydGVkUm91dGVzIiwiVXJsTm9kZSIsInBsYWNlaG9sZGVyIiwiY2hpbGRyZW4iLCJNYXAiLCJzbHVnTmFtZSIsInJlc3RTbHVnTmFtZSIsIm9wdGlvbmFsUmVzdFNsdWdOYW1lIiwiaW5zZXJ0IiwidXJsUGF0aCIsIl9pbnNlcnQiLCJzcGxpdCIsImZpbHRlciIsIkJvb2xlYW4iLCJzbW9vc2giLCJfc21vb3NoIiwicHJlZml4IiwiY2hpbGRyZW5QYXRocyIsImtleXMiLCJzb3J0Iiwic3BsaWNlIiwiaW5kZXhPZiIsInJvdXRlcyIsIm1hcCIsImMiLCJnZXQiLCJyZWR1Y2UiLCJwcmV2IiwiY3VyciIsInB1c2giLCJyIiwic2xpY2UiLCJFcnJvciIsInVuc2hpZnQiLCJ1cmxQYXRocyIsInNsdWdOYW1lcyIsImlzQ2F0Y2hBbGwiLCJsZW5ndGgiLCJuZXh0U2VnbWVudCIsInN0YXJ0c1dpdGgiLCJlbmRzV2l0aCIsImhhbmRsZVNsdWciLCJwcmV2aW91c1NsdWciLCJuZXh0U2x1ZyIsImZvckVhY2giLCJzbHVnIiwicmVwbGFjZSIsInNlZ21lbnROYW1lIiwiaXNPcHRpb25hbCIsInN1YnN0cmluZyIsImhhcyIsInNldCIsIm5vcm1hbGl6ZWRQYWdlcyIsInJvb3QiLCJwYWdlUGF0aCJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/router/utils/sorted-routes.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/shared/lib/utils.js": +/*!****************************************************!*\ + !*** ./node_modules/next/dist/shared/lib/utils.js ***! + \****************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nvar _classCallCheck = (__webpack_require__(/*! @swc/helpers/lib/_class_call_check.js */ \"./node_modules/@swc/helpers/lib/_class_call_check.js\")[\"default\"]);\nvar _inherits = (__webpack_require__(/*! @swc/helpers/lib/_inherits.js */ \"./node_modules/@swc/helpers/lib/_inherits.js\")[\"default\"]);\nvar _toConsumableArray = (__webpack_require__(/*! @swc/helpers/lib/_to_consumable_array.js */ \"./node_modules/@swc/helpers/lib/_to_consumable_array.js\")[\"default\"]);\nvar _wrapNativeSuper = (__webpack_require__(/*! @swc/helpers/lib/_wrap_native_super.js */ \"./node_modules/@swc/helpers/lib/_wrap_native_super.js\")[\"default\"]);\nvar _createSuper = (__webpack_require__(/*! @swc/helpers/lib/_create_super.js */ \"./node_modules/@swc/helpers/lib/_create_super.js\")[\"default\"]);\nvar _tsGenerator = (__webpack_require__(/*! @swc/helpers/lib/_ts_generator.js */ \"./node_modules/@swc/helpers/lib/_ts_generator.js\")[\"default\"]);\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports.execOnce = execOnce;\nexports.getLocationOrigin = getLocationOrigin;\nexports.getURL = getURL;\nexports.getDisplayName = getDisplayName;\nexports.isResSent = isResSent;\nexports.normalizeRepeatedSlashes = normalizeRepeatedSlashes;\nexports.loadGetInitialProps = loadGetInitialProps;\nexports.ST = exports.SP = exports.warnOnce = exports.isAbsoluteUrl = void 0;\nvar _async_to_generator = (__webpack_require__(/*! @swc/helpers/lib/_async_to_generator.js */ \"./node_modules/@swc/helpers/lib/_async_to_generator.js\")[\"default\"]);\nfunction execOnce(fn) {\n var used = false;\n var result;\n return function() {\n for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){\n args[_key] = arguments[_key];\n }\n if (!used) {\n used = true;\n result = fn.apply(void 0, _toConsumableArray(args));\n }\n return result;\n };\n}\n// Scheme: https://tools.ietf.org/html/rfc3986#section-3.1\n// Absolute URL: https://tools.ietf.org/html/rfc3986#section-4.3\nvar ABSOLUTE_URL_REGEX = /^[a-zA-Z][a-zA-Z\\d+\\-.]*?:/;\nvar isAbsoluteUrl = function(url) {\n return ABSOLUTE_URL_REGEX.test(url);\n};\nexports.isAbsoluteUrl = isAbsoluteUrl;\nfunction getLocationOrigin() {\n var _location = window.location, protocol = _location.protocol, hostname = _location.hostname, port = _location.port;\n return \"\".concat(protocol, \"//\").concat(hostname).concat(port ? \":\" + port : \"\");\n}\nfunction getURL() {\n var href = window.location.href;\n var origin = getLocationOrigin();\n return href.substring(origin.length);\n}\nfunction getDisplayName(Component) {\n return typeof Component === \"string\" ? Component : Component.displayName || Component.name || \"Unknown\";\n}\nfunction isResSent(res) {\n return res.finished || res.headersSent;\n}\nfunction normalizeRepeatedSlashes(url) {\n var urlParts = url.split(\"?\");\n var urlNoQuery = urlParts[0];\n return urlNoQuery // first we replace any non-encoded backslashes with forward\n // then normalize repeated forward slashes\n .replace(/\\\\/g, \"/\").replace(/\\/\\/+/g, \"/\") + (urlParts[1] ? \"?\".concat(urlParts.slice(1).join(\"?\")) : \"\");\n}\nfunction loadGetInitialProps(App, ctx) {\n return _loadGetInitialProps.apply(this, arguments);\n}\nfunction _loadGetInitialProps() {\n _loadGetInitialProps = _async_to_generator(function(App, ctx) {\n var ref, message, res, _tmp, props, message1;\n return _tsGenerator(this, function(_state) {\n switch(_state.label){\n case 0:\n if (true) {\n ;\n if ((ref = App.prototype) == null ? void 0 : ref.getInitialProps) {\n message = '\"'.concat(getDisplayName(App), '.getInitialProps()\" is defined as an instance method - visit https://nextjs.org/docs/messages/get-initial-props-as-an-instance-method for more information.');\n throw new Error(message);\n }\n }\n res = ctx.res || ctx.ctx && ctx.ctx.res;\n if (!!App.getInitialProps) return [\n 3,\n 3\n ];\n if (!(ctx.ctx && ctx.Component)) return [\n 3,\n 2\n ];\n _tmp = {};\n return [\n 4,\n loadGetInitialProps(ctx.Component, ctx.ctx)\n ];\n case 1:\n // @ts-ignore pageProps default\n return [\n 2,\n (_tmp.pageProps = _state.sent(), _tmp)\n ];\n case 2:\n return [\n 2,\n {}\n ];\n case 3:\n return [\n 4,\n App.getInitialProps(ctx)\n ];\n case 4:\n props = _state.sent();\n if (res && isResSent(res)) {\n return [\n 2,\n props\n ];\n }\n if (!props) {\n message1 = '\"'.concat(getDisplayName(App), '.getInitialProps()\" should resolve to an object. But found \"').concat(props, '\" instead.');\n throw new Error(message1);\n }\n if (true) {\n if (Object.keys(props).length === 0 && !ctx.ctx) {\n console.warn(\"\".concat(getDisplayName(App), \" returned an empty object from `getInitialProps`. This de-optimizes and prevents automatic static optimization. https://nextjs.org/docs/messages/empty-object-getInitialProps\"));\n }\n }\n return [\n 2,\n props\n ];\n }\n });\n });\n return _loadGetInitialProps.apply(this, arguments);\n}\nvar warnOnce = function(_) {};\nif (true) {\n var warnings = new Set();\n exports.warnOnce = warnOnce = function(msg) {\n if (!warnings.has(msg)) {\n console.warn(msg);\n }\n warnings.add(msg);\n };\n}\nvar SP = typeof performance !== \"undefined\";\nexports.SP = SP;\nvar ST = SP && [\n \"mark\",\n \"measure\",\n \"getEntriesByName\"\n].every(function(method) {\n return typeof performance[method] === \"function\";\n});\nexports.ST = ST;\nvar DecodeError = /*#__PURE__*/ function(Error1) {\n _inherits(DecodeError, Error1);\n var _super = _createSuper(DecodeError);\n function DecodeError() {\n _classCallCheck(this, DecodeError);\n return _super.apply(this, arguments);\n }\n return DecodeError;\n}(_wrapNativeSuper(Error));\nexports.DecodeError = DecodeError;\nvar NormalizeError = /*#__PURE__*/ function(Error1) {\n _inherits(NormalizeError, Error1);\n var _super = _createSuper(NormalizeError);\n function NormalizeError() {\n _classCallCheck(this, NormalizeError);\n return _super.apply(this, arguments);\n }\n return NormalizeError;\n}(_wrapNativeSuper(Error));\nexports.NormalizeError = NormalizeError;\nvar PageNotFoundError = /*#__PURE__*/ function(Error1) {\n _inherits(PageNotFoundError, Error1);\n var _super = _createSuper(PageNotFoundError);\n function PageNotFoundError(page) {\n _classCallCheck(this, PageNotFoundError);\n var _this;\n _this = _super.call(this);\n _this.code = \"ENOENT\";\n _this.message = \"Cannot find module for page: \".concat(page);\n return _this;\n }\n return PageNotFoundError;\n}(_wrapNativeSuper(Error));\nexports.PageNotFoundError = PageNotFoundError;\nvar MissingStaticPage = /*#__PURE__*/ function(Error1) {\n _inherits(MissingStaticPage, Error1);\n var _super = _createSuper(MissingStaticPage);\n function MissingStaticPage(page, message) {\n _classCallCheck(this, MissingStaticPage);\n var _this;\n _this = _super.call(this);\n _this.message = \"Failed to load static file for page: \".concat(page, \" \").concat(message);\n return _this;\n }\n return MissingStaticPage;\n}(_wrapNativeSuper(Error));\nexports.MissingStaticPage = MissingStaticPage;\nvar MiddlewareNotFoundError = /*#__PURE__*/ function(Error1) {\n _inherits(MiddlewareNotFoundError, Error1);\n var _super = _createSuper(MiddlewareNotFoundError);\n function MiddlewareNotFoundError() {\n _classCallCheck(this, MiddlewareNotFoundError);\n var _this;\n _this = _super.call(this);\n _this.code = \"ENOENT\";\n _this.message = \"Cannot find the middleware module\";\n return _this;\n }\n return MiddlewareNotFoundError;\n}(_wrapNativeSuper(Error));\nexports.MiddlewareNotFoundError = MiddlewareNotFoundError;\nexports.warnOnce = warnOnce; //# sourceMappingURL=utils.js.map\n\n\n;\n // Wrapped in an IIFE to avoid polluting the global scope\n ;\n (function () {\n var _a, _b;\n // Legacy CSS implementations will `eval` browser code in a Node.js context\n // to extract CSS. For backwards compatibility, we need to check we're in a\n // browser context before continuing.\n if (typeof self !== 'undefined' &&\n // AMP / No-JS mode does not inject these helpers:\n '$RefreshHelpers$' in self) {\n // @ts-ignore __webpack_module__ is global\n var currentExports = module.exports;\n // @ts-ignore __webpack_module__ is global\n var prevExports = (_b = (_a = module.hot.data) === null || _a === void 0 ? void 0 : _a.prevExports) !== null && _b !== void 0 ? _b : null;\n // This cannot happen in MainTemplate because the exports mismatch between\n // templating and execution.\n self.$RefreshHelpers$.registerExportsForReactRefresh(currentExports, module.id);\n // A module can be accepted automatically based on its exports, e.g. when\n // it is a Refresh Boundary.\n if (self.$RefreshHelpers$.isReactRefreshBoundary(currentExports)) {\n // Save the previous exports on update so we can compare the boundary\n // signatures.\n module.hot.dispose(function (data) {\n data.prevExports = currentExports;\n });\n // Unconditionally accept an update to this module, we'll check if it's\n // still a Refresh Boundary later.\n // @ts-ignore importMeta is replaced in the loader\n module.hot.accept();\n // This field is set when the previous version of this module was a\n // Refresh Boundary, letting us know we need to check for invalidation or\n // enqueue an update.\n if (prevExports !== null) {\n // A boundary can become ineligible if its exports are incompatible\n // with the previous exports.\n //\n // For example, if you add/remove/change exports, we'll want to\n // re-execute the importing modules, and force those components to\n // re-render. Similarly, if you convert a class component to a\n // function, we want to invalidate the boundary.\n if (self.$RefreshHelpers$.shouldInvalidateReactRefreshBoundary(prevExports, currentExports)) {\n module.hot.invalidate();\n }\n else {\n self.$RefreshHelpers$.scheduleUpdate();\n }\n }\n }\n else {\n // Since we just executed the code for the module, it's possible that the\n // new exports made it ineligible for being a boundary.\n // We only care about the case when we were _previously_ a boundary,\n // because we already accepted this update (accidental side effect).\n var isNoLongerABoundary = prevExports !== null;\n if (isNoLongerABoundary) {\n module.hot.invalidate();\n }\n }\n }\n })();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L3NoYXJlZC9saWIvdXRpbHMuanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7Ozs7Ozs7Ozs7QUFDYkEsOENBQTZDO0lBQ3pDRyxLQUFLLEVBQUUsSUFBSTtDQUNkLEVBQUMsQ0FBQztBQUNIRCxnQkFBZ0IsR0FBR0UsUUFBUSxDQUFDO0FBQzVCRix5QkFBeUIsR0FBR0csaUJBQWlCLENBQUM7QUFDOUNILGNBQWMsR0FBR0ksTUFBTSxDQUFDO0FBQ3hCSixzQkFBc0IsR0FBR0ssY0FBYyxDQUFDO0FBQ3hDTCxpQkFBaUIsR0FBR00sU0FBUyxDQUFDO0FBQzlCTixnQ0FBZ0MsR0FBR08sd0JBQXdCLENB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ourceURL=webpack-internal:///./node_modules/next/dist/shared/lib/utils.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/compiled/react-is/cjs/react-is.development.js": +/*!******************************************************************************!*\ + !*** ./node_modules/next/dist/compiled/react-is/cjs/react-is.development.js ***! + \******************************************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("/** @license React v17.0.2\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\n\nif (true) {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar REACT_ELEMENT_TYPE = 0xeac7;\nvar REACT_PORTAL_TYPE = 0xeaca;\nvar REACT_FRAGMENT_TYPE = 0xeacb;\nvar REACT_STRICT_MODE_TYPE = 0xeacc;\nvar REACT_PROFILER_TYPE = 0xead2;\nvar REACT_PROVIDER_TYPE = 0xeacd;\nvar REACT_CONTEXT_TYPE = 0xeace;\nvar REACT_FORWARD_REF_TYPE = 0xead0;\nvar REACT_SUSPENSE_TYPE = 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = 0xead8;\nvar REACT_MEMO_TYPE = 0xead3;\nvar REACT_LAZY_TYPE = 0xead4;\nvar REACT_BLOCK_TYPE = 0xead9;\nvar REACT_SERVER_BLOCK_TYPE = 0xeada;\nvar REACT_FUNDAMENTAL_TYPE = 0xead5;\nvar REACT_SCOPE_TYPE = 0xead7;\nvar REACT_OPAQUE_ID_TYPE = 0xeae0;\nvar REACT_DEBUG_TRACING_MODE_TYPE = 0xeae1;\nvar REACT_OFFSCREEN_TYPE = 0xeae2;\nvar REACT_LEGACY_HIDDEN_TYPE = 0xeae3;\n\nif (typeof Symbol === 'function' && Symbol.for) {\n var symbolFor = Symbol.for;\n REACT_ELEMENT_TYPE = symbolFor('react.element');\n REACT_PORTAL_TYPE = symbolFor('react.portal');\n REACT_FRAGMENT_TYPE = symbolFor('react.fragment');\n REACT_STRICT_MODE_TYPE = symbolFor('react.strict_mode');\n REACT_PROFILER_TYPE = symbolFor('react.profiler');\n REACT_PROVIDER_TYPE = symbolFor('react.provider');\n REACT_CONTEXT_TYPE = symbolFor('react.context');\n REACT_FORWARD_REF_TYPE = symbolFor('react.forward_ref');\n REACT_SUSPENSE_TYPE = symbolFor('react.suspense');\n REACT_SUSPENSE_LIST_TYPE = symbolFor('react.suspense_list');\n REACT_MEMO_TYPE = symbolFor('react.memo');\n REACT_LAZY_TYPE = symbolFor('react.lazy');\n REACT_BLOCK_TYPE = symbolFor('react.block');\n REACT_SERVER_BLOCK_TYPE = symbolFor('react.server.block');\n REACT_FUNDAMENTAL_TYPE = symbolFor('react.fundamental');\n REACT_SCOPE_TYPE = symbolFor('react.scope');\n REACT_OPAQUE_ID_TYPE = symbolFor('react.opaque.id');\n REACT_DEBUG_TRACING_MODE_TYPE = symbolFor('react.debug_trace_mode');\n REACT_OFFSCREEN_TYPE = symbolFor('react.offscreen');\n REACT_LEGACY_HIDDEN_TYPE = symbolFor('react.legacy_hidden');\n}\n\n// Filter certain DOM attributes (e.g. src, href) if their values are empty strings.\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || type === REACT_DEBUG_TRACING_MODE_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || type === REACT_LEGACY_HIDDEN_TYPE || enableScopeAPI ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_BLOCK_TYPE || type[0] === REACT_SERVER_BLOCK_TYPE) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NvbXBpbGVkL3JlYWN0LWlzL2Nqcy9yZWFjdC1pcy5kZXZlbG9wbWVudC5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVhOztBQUViLElBQUksSUFBcUM7QUFDekM7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBOztBQUVBLDRCQUE0Qjs7QUFFNUI7QUFDQTtBQUNBO0FBQ0EsSUFBSTs7O0FBR0o7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTt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dist/compiled/react-is/cjs/react-is.development.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/compiled/react-is/index.js": +/*!***********************************************************!*\ + !*** ./node_modules/next/dist/compiled/react-is/index.js ***! + \***********************************************************/ +/***/ (function(module, __unused_webpack_exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\n\nif (false) {} else {\n module.exports = __webpack_require__(/*! ./cjs/react-is.development.js */ \"./node_modules/next/dist/compiled/react-is/cjs/react-is.development.js\");\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2NvbXBpbGVkL3JlYWN0LWlzL2luZGV4LmpzLmpzIiwibWFwcGluZ3MiOiJBQUFhOztBQUViLElBQUksS0FBcUMsRUFBRSxFQUUxQyxDQUFDO0FBQ0YsRUFBRSxtSkFBeUQ7QUFDM0QiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly9fTl9FLy4vbm9kZV9tb2R1bGVzL25leHQvZGlzdC9jb21waWxlZC9yZWFjdC1pcy9pbmRleC5qcz80MjNkIl0sInNvdXJjZXNDb250ZW50IjpbIid1c2Ugc3RyaWN0JztcblxuaWYgKHByb2Nlc3MuZW52Lk5PREVfRU5WID09PSAncHJvZHVjdGlvbicpIHtcbiAgbW9kdWxlLmV4cG9ydHMgPSByZXF1aXJlKCcuL2Nqcy9yZWFjdC1pcy5wcm9kdWN0aW9uLm1pbi5qcycpO1xufSBlbHNlIHtcbiAgbW9kdWxlLmV4cG9ydHMgPSByZXF1aXJlKCcuL2Nqcy9yZWFjdC1pcy5kZXZlbG9wbWVudC5qcycpO1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/dist/compiled/react-is/index.js\n")); + +/***/ }), + +/***/ "./node_modules/next/dist/lib/is-error.js": +/*!************************************************!*\ + !*** ./node_modules/next/dist/lib/is-error.js ***! + \************************************************/ +/***/ (function(__unused_webpack_module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\nObject.defineProperty(exports, \"__esModule\", ({\n value: true\n}));\nexports[\"default\"] = isError;\nexports.getProperError = getProperError;\nvar _isPlainObject = __webpack_require__(/*! ../shared/lib/is-plain-object */ \"./node_modules/next/dist/shared/lib/is-plain-object.js\");\nfunction isError(err) {\n return typeof err === \"object\" && err !== null && \"name\" in err && \"message\" in err;\n}\nfunction getProperError(err) {\n if (isError(err)) {\n return err;\n }\n if (true) {\n // provide better error for case where `throw undefined`\n // is called in development\n if (typeof err === \"undefined\") {\n return new Error(\"An undefined error was thrown, \" + \"see here for more info: https://nextjs.org/docs/messages/threw-undefined\");\n }\n if (err === null) {\n return new Error(\"A null error was thrown, \" + \"see here for more info: https://nextjs.org/docs/messages/threw-undefined\");\n }\n }\n return new Error((0, _isPlainObject).isPlainObject(err) ? JSON.stringify(err) : err + \"\");\n}\n\n//# sourceMappingURL=is-error.js.map//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2xpYi9pcy1lcnJvci5qcy5qcyIsIm1hcHBpbmdzIjoiQUFBYTtBQUNiLDhDQUE2QztBQUM3QztBQUNBLENBQUMsRUFBQztBQUNGLGtCQUFlO0FBQ2Ysc0JBQXNCO0FBQ3RCLHFCQUFxQixtQkFBTyxDQUFDLDZGQUErQjtBQUM1RDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLFFBQVEsSUFBc0M7QUFDOUM7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQSIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvbmV4dC9kaXN0L2xpYi9pcy1lc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AgICAgICB9XG4gICAgICAgIGlmIChlcnIgPT09IG51bGwpIHtcbiAgICAgICAgICAgIHJldHVybiBuZXcgRXJyb3IoXCJBIG51bGwgZXJyb3Igd2FzIHRocm93biwgXCIgKyBcInNlZSBoZXJlIGZvciBtb3JlIGluZm86IGh0dHBzOi8vbmV4dGpzLm9yZy9kb2NzL21lc3NhZ2VzL3RocmV3LXVuZGVmaW5lZFwiKTtcbiAgICAgICAgfVxuICAgIH1cbiAgICByZXR1cm4gbmV3IEVycm9yKCgwLCBfaXNQbGFpbk9iamVjdCkuaXNQbGFpbk9iamVjdChlcnIpID8gSlNPTi5zdHJpbmdpZnkoZXJyKSA6IGVyciArIFwiXCIpO1xufVxuXG4vLyMgc291cmNlTWFwcGluZ1VSTD1pcy1lcnJvci5qcy5tYXAiXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///./node_modules/next/dist/lib/is-error.js\n")); + +/***/ }), + +/***/ "./node_modules/next/router.js": +/*!*************************************!*\ + !*** ./node_modules/next/router.js ***! + \*************************************/ +/***/ (function(module, __unused_webpack_exports, __webpack_require__) { + +eval(__webpack_require__.ts("module.exports = __webpack_require__(/*! ./dist/client/router */ \"./node_modules/next/dist/client/router.js\")\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvbmV4dC9yb3V0ZXIuanMuanMiLCJtYXBwaW5ncyI6IkFBQUEsNkdBQWdEIiwic291cmNlcyI6WyJ3ZWJwYWNrOi8vX05fRS8uL25vZGVfbW9kdWxlcy9uZXh0L3JvdXRlci5qcz8xYmI2Il0sInNvdXJjZXNDb250ZW50IjpbIm1vZHVsZS5leHBvcnRzID0gcmVxdWlyZSgnLi9kaXN0L2NsaWVudC9yb3V0ZXInKVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/next/router.js\n")); + +/***/ }), + +/***/ "./node_modules/react/cjs/react.development.js": +/*!*****************************************************!*\ + !*** ./node_modules/react/cjs/react.development.js ***! + \*****************************************************/ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("/* module decorator */ module = __webpack_require__.nmd(module);\n/**\n * @license React\n * react.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\n\nif (true) {\n (function() {\n\n 'use strict';\n\n/* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\nif (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' &&\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart ===\n 'function'\n) {\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());\n}\n var ReactVersion = '18.2.0';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\nvar MAYBE_ITERATOR_SYMBOL = Symbol.iterator;\nvar FAUX_ITERATOR_SYMBOL = '@@iterator';\nfunction getIteratorFn(maybeIterable) {\n if (maybeIterable === null || typeof maybeIterable !== 'object') {\n return null;\n }\n\n var maybeIterator = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL];\n\n if (typeof maybeIterator === 'function') {\n return maybeIterator;\n }\n\n return null;\n}\n\n/**\n * Keeps track of the current dispatcher.\n */\nvar ReactCurrentDispatcher = {\n /**\n * @internal\n * @type {ReactComponent}\n */\n current: null\n};\n\n/**\n * Keeps track of the current batch's configuration such as how long an update\n * should suspend for if it needs to.\n */\nvar ReactCurrentBatchConfig = {\n transition: null\n};\n\nvar ReactCurrentActQueue = {\n current: null,\n // Used to reproduce behavior of `batchedUpdates` in legacy mode.\n isBatchingLegacy: false,\n didScheduleLegacyUpdate: false\n};\n\n/**\n * Keeps track of the current owner.\n *\n * The current owner is the component who should own any components that are\n * currently being constructed.\n */\nvar ReactCurrentOwner = {\n /**\n * @internal\n * @type {ReactComponent}\n */\n current: null\n};\n\nvar ReactDebugCurrentFrame = {};\nvar currentExtraStackFrame = null;\nfunction setExtraStackFrame(stack) {\n {\n currentExtraStackFrame = stack;\n }\n}\n\n{\n ReactDebugCurrentFrame.setExtraStackFrame = function (stack) {\n {\n currentExtraStackFrame = stack;\n }\n }; // Stack implementation injected by the current renderer.\n\n\n ReactDebugCurrentFrame.getCurrentStack = null;\n\n ReactDebugCurrentFrame.getStackAddendum = function () {\n var stack = ''; // Add an extra top frame while an element is being validated\n\n if (currentExtraStackFrame) {\n stack += currentExtraStackFrame;\n } // Delegate to the injected renderer-specific implementation\n\n\n var impl = ReactDebugCurrentFrame.getCurrentStack;\n\n if (impl) {\n stack += impl() || '';\n }\n\n return stack;\n };\n}\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar ReactSharedInternals = {\n ReactCurrentDispatcher: ReactCurrentDispatcher,\n ReactCurrentBatchConfig: ReactCurrentBatchConfig,\n ReactCurrentOwner: ReactCurrentOwner\n};\n\n{\n ReactSharedInternals.ReactDebugCurrentFrame = ReactDebugCurrentFrame;\n ReactSharedInternals.ReactCurrentActQueue = ReactCurrentActQueue;\n}\n\n// by calls to these methods by a Babel plugin.\n//\n// In PROD (or in packages without access to React internals),\n// they are left as they are instead.\n\nfunction warn(format) {\n {\n {\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n printWarning('warn', format, args);\n }\n }\n}\nfunction error(format) {\n {\n {\n for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n args[_key2 - 1] = arguments[_key2];\n }\n\n printWarning('error', format, args);\n }\n }\n}\n\nfunction printWarning(level, format, args) {\n // When changing this logic, you might want to also\n // update consoleWithStackDev.www.js as well.\n {\n var ReactDebugCurrentFrame = ReactSharedInternals.ReactDebugCurrentFrame;\n var stack = ReactDebugCurrentFrame.getStackAddendum();\n\n if (stack !== '') {\n format += '%s';\n args = args.concat([stack]);\n } // eslint-disable-next-line react-internal/safe-string-coercion\n\n\n var argsWithFormat = args.map(function (item) {\n return String(item);\n }); // Careful: RN currently depends on this prefix\n\n argsWithFormat.unshift('Warning: ' + format); // We intentionally don't use spread (or .apply) directly because it\n // breaks IE9: https://github.com/facebook/react/issues/13610\n // eslint-disable-next-line react-internal/no-production-logging\n\n Function.prototype.apply.call(console[level], console, argsWithFormat);\n }\n}\n\nvar didWarnStateUpdateForUnmountedComponent = {};\n\nfunction warnNoop(publicInstance, callerName) {\n {\n var _constructor = publicInstance.constructor;\n var componentName = _constructor && (_constructor.displayName || _constructor.name) || 'ReactClass';\n var warningKey = componentName + \".\" + callerName;\n\n if (didWarnStateUpdateForUnmountedComponent[warningKey]) {\n return;\n }\n\n error(\"Can't call %s on a component that is not yet mounted. \" + 'This is a no-op, but it might indicate a bug in your application. ' + 'Instead, assign to `this.state` directly or define a `state = {};` ' + 'class property with the desired state in the %s component.', callerName, componentName);\n\n didWarnStateUpdateForUnmountedComponent[warningKey] = true;\n }\n}\n/**\n * This is the abstract API for an update queue.\n */\n\n\nvar ReactNoopUpdateQueue = {\n /**\n * Checks whether or not this composite component is mounted.\n * @param {ReactClass} publicInstance The instance we want to test.\n * @return {boolean} True if mounted, false otherwise.\n * @protected\n * @final\n */\n isMounted: function (publicInstance) {\n return false;\n },\n\n /**\n * Forces an update. This should only be invoked when it is known with\n * certainty that we are **not** in a DOM transaction.\n *\n * You may want to call this when you know that some deeper aspect of the\n * component's state has changed but `setState` was not called.\n *\n * This will not invoke `shouldComponentUpdate`, but it will invoke\n * `componentWillUpdate` and `componentDidUpdate`.\n *\n * @param {ReactClass} publicInstance The instance that should rerender.\n * @param {?function} callback Called after component is updated.\n * @param {?string} callerName name of the calling function in the public API.\n * @internal\n */\n enqueueForceUpdate: function (publicInstance, callback, callerName) {\n warnNoop(publicInstance, 'forceUpdate');\n },\n\n /**\n * Replaces all of the state. Always use this or `setState` to mutate state.\n * You should treat `this.state` as immutable.\n *\n * There is no guarantee that `this.state` will be immediately updated, so\n * accessing `this.state` after calling this method may return the old value.\n *\n * @param {ReactClass} publicInstance The instance that should rerender.\n * @param {object} completeState Next state.\n * @param {?function} callback Called after component is updated.\n * @param {?string} callerName name of the calling function in the public API.\n * @internal\n */\n enqueueReplaceState: function (publicInstance, completeState, callback, callerName) {\n warnNoop(publicInstance, 'replaceState');\n },\n\n /**\n * Sets a subset of the state. This only exists because _pendingState is\n * internal. This provides a merging strategy that is not available to deep\n * properties which is confusing. TODO: Expose pendingState or don't use it\n * during the merge.\n *\n * @param {ReactClass} publicInstance The instance that should rerender.\n * @param {object} partialState Next partial state to be merged with state.\n * @param {?function} callback Called after component is updated.\n * @param {?string} Name of the calling function in the public API.\n * @internal\n */\n enqueueSetState: function (publicInstance, partialState, callback, callerName) {\n warnNoop(publicInstance, 'setState');\n }\n};\n\nvar assign = Object.assign;\n\nvar emptyObject = {};\n\n{\n Object.freeze(emptyObject);\n}\n/**\n * Base class helpers for the updating state of a component.\n */\n\n\nfunction Component(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject; // We initialize the default updater but the real one gets injected by the\n // renderer.\n\n this.updater = updater || ReactNoopUpdateQueue;\n}\n\nComponent.prototype.isReactComponent = {};\n/**\n * Sets a subset of the state. Always use this to mutate\n * state. You should treat `this.state` as immutable.\n *\n * There is no guarantee that `this.state` will be immediately updated, so\n * accessing `this.state` after calling this method may return the old value.\n *\n * There is no guarantee that calls to `setState` will run synchronously,\n * as they may eventually be batched together. You can provide an optional\n * callback that will be executed when the call to setState is actually\n * completed.\n *\n * When a function is provided to setState, it will be called at some point in\n * the future (not synchronously). It will be called with the up to date\n * component arguments (state, props, context). These values can be different\n * from this.* because your function may be called after receiveProps but before\n * shouldComponentUpdate, and this new state, props, and context will not yet be\n * assigned to this.\n *\n * @param {object|function} partialState Next partial state or function to\n * produce next partial state to be merged with current state.\n * @param {?function} callback Called after state is updated.\n * @final\n * @protected\n */\n\nComponent.prototype.setState = function (partialState, callback) {\n if (typeof partialState !== 'object' && typeof partialState !== 'function' && partialState != null) {\n throw new Error('setState(...): takes an object of state variables to update or a ' + 'function which returns an object of state variables.');\n }\n\n this.updater.enqueueSetState(this, partialState, callback, 'setState');\n};\n/**\n * Forces an update. This should only be invoked when it is known with\n * certainty that we are **not** in a DOM transaction.\n *\n * You may want to call this when you know that some deeper aspect of the\n * component's state has changed but `setState` was not called.\n *\n * This will not invoke `shouldComponentUpdate`, but it will invoke\n * `componentWillUpdate` and `componentDidUpdate`.\n *\n * @param {?function} callback Called after update is complete.\n * @final\n * @protected\n */\n\n\nComponent.prototype.forceUpdate = function (callback) {\n this.updater.enqueueForceUpdate(this, callback, 'forceUpdate');\n};\n/**\n * Deprecated APIs. These APIs used to exist on classic React classes but since\n * we would like to deprecate them, we're not going to move them over to this\n * modern base class. Instead, we define a getter that warns if it's accessed.\n */\n\n\n{\n var deprecatedAPIs = {\n isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'],\n replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).']\n };\n\n var defineDeprecationWarning = function (methodName, info) {\n Object.defineProperty(Component.prototype, methodName, {\n get: function () {\n warn('%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]);\n\n return undefined;\n }\n });\n };\n\n for (var fnName in deprecatedAPIs) {\n if (deprecatedAPIs.hasOwnProperty(fnName)) {\n defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);\n }\n }\n}\n\nfunction ComponentDummy() {}\n\nComponentDummy.prototype = Component.prototype;\n/**\n * Convenience component with default shallow equality check for sCU.\n */\n\nfunction PureComponent(props, context, updater) {\n this.props = props;\n this.context = context; // If a component has string refs, we will assign a different object later.\n\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n}\n\nvar pureComponentPrototype = PureComponent.prototype = new ComponentDummy();\npureComponentPrototype.constructor = PureComponent; // Avoid an extra prototype jump for these methods.\n\nassign(pureComponentPrototype, Component.prototype);\npureComponentPrototype.isPureReactComponent = true;\n\n// an immutable object with a single mutable value\nfunction createRef() {\n var refObject = {\n current: null\n };\n\n {\n Object.seal(refObject);\n }\n\n return refObject;\n}\n\nvar isArrayImpl = Array.isArray; // eslint-disable-next-line no-redeclare\n\nfunction isArray(a) {\n return isArrayImpl(a);\n}\n\n/*\n * The `'' + value` pattern (used in in perf-sensitive code) throws for Symbol\n * and Temporal.* types. See https://github.com/facebook/react/pull/22064.\n *\n * The functions in this module will throw an easier-to-understand,\n * easier-to-debug exception with a clear errors message message explaining the\n * problem. (Instead of a confusing exception thrown inside the implementation\n * of the `value` object).\n */\n// $FlowFixMe only called in DEV, so void return is not possible.\nfunction typeName(value) {\n {\n // toStringTag is needed for namespaced types like Temporal.Instant\n var hasToStringTag = typeof Symbol === 'function' && Symbol.toStringTag;\n var type = hasToStringTag && value[Symbol.toStringTag] || value.constructor.name || 'Object';\n return type;\n }\n} // $FlowFixMe only called in DEV, so void return is not possible.\n\n\nfunction willCoercionThrow(value) {\n {\n try {\n testStringCoercion(value);\n return false;\n } catch (e) {\n return true;\n }\n }\n}\n\nfunction testStringCoercion(value) {\n // If you ended up here by following an exception call stack, here's what's\n // happened: you supplied an object or symbol value to React (as a prop, key,\n // DOM attribute, CSS property, string ref, etc.) and when React tried to\n // coerce it to a string using `'' + value`, an exception was thrown.\n //\n // The most common types that will cause this exception are `Symbol` instances\n // and Temporal objects like `Temporal.Instant`. But any object that has a\n // `valueOf` or `[Symbol.toPrimitive]` method that throws will also cause this\n // exception. (Library authors do this to prevent users from using built-in\n // numeric operators like `+` or comparison operators like `>=` because custom\n // methods are needed to perform accurate arithmetic or comparison.)\n //\n // To fix the problem, coerce this object or symbol value to a string before\n // passing it to React. The most reliable way is usually `String(value)`.\n //\n // To find which value is throwing, check the browser or debugger console.\n // Before this exception was thrown, there should be `console.error` output\n // that shows the type (Symbol, Temporal.PlainDate, etc.) that caused the\n // problem and how that type was used: key, atrribute, input value prop, etc.\n // In most cases, this console output also shows the component and its\n // ancestor components where the exception happened.\n //\n // eslint-disable-next-line react-internal/safe-string-coercion\n return '' + value;\n}\nfunction checkKeyStringCoercion(value) {\n {\n if (willCoercionThrow(value)) {\n error('The provided key is an unsupported type %s.' + ' This value must be coerced to a string before before using it here.', typeName(value));\n\n return testStringCoercion(value); // throw (to help callers find troubleshooting comments)\n }\n }\n}\n\nfunction getWrappedName(outerType, innerType, wrapperName) {\n var displayName = outerType.displayName;\n\n if (displayName) {\n return displayName;\n }\n\n var functionName = innerType.displayName || innerType.name || '';\n return functionName !== '' ? wrapperName + \"(\" + functionName + \")\" : wrapperName;\n} // Keep in sync with react-reconciler/getComponentNameFromFiber\n\n\nfunction getContextName(type) {\n return type.displayName || 'Context';\n} // Note that the reconciler package should generally prefer to use getComponentNameFromFiber() instead.\n\n\nfunction getComponentNameFromType(type) {\n if (type == null) {\n // Host root, text node or just invalid type.\n return null;\n }\n\n {\n if (typeof type.tag === 'number') {\n error('Received an unexpected object in getComponentNameFromType(). ' + 'This is likely a bug in React. Please file an issue.');\n }\n }\n\n if (typeof type === 'function') {\n return type.displayName || type.name || null;\n }\n\n if (typeof type === 'string') {\n return type;\n }\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return 'Fragment';\n\n case REACT_PORTAL_TYPE:\n return 'Portal';\n\n case REACT_PROFILER_TYPE:\n return 'Profiler';\n\n case REACT_STRICT_MODE_TYPE:\n return 'StrictMode';\n\n case REACT_SUSPENSE_TYPE:\n return 'Suspense';\n\n case REACT_SUSPENSE_LIST_TYPE:\n return 'SuspenseList';\n\n }\n\n if (typeof type === 'object') {\n switch (type.$$typeof) {\n case REACT_CONTEXT_TYPE:\n var context = type;\n return getContextName(context) + '.Consumer';\n\n case REACT_PROVIDER_TYPE:\n var provider = type;\n return getContextName(provider._context) + '.Provider';\n\n case REACT_FORWARD_REF_TYPE:\n return getWrappedName(type, type.render, 'ForwardRef');\n\n case REACT_MEMO_TYPE:\n var outerName = type.displayName || null;\n\n if (outerName !== null) {\n return outerName;\n }\n\n return getComponentNameFromType(type.type) || 'Memo';\n\n case REACT_LAZY_TYPE:\n {\n var lazyComponent = type;\n var payload = lazyComponent._payload;\n var init = lazyComponent._init;\n\n try {\n return getComponentNameFromType(init(payload));\n } catch (x) {\n return null;\n }\n }\n\n // eslint-disable-next-line no-fallthrough\n }\n }\n\n return null;\n}\n\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\n\nvar RESERVED_PROPS = {\n key: true,\n ref: true,\n __self: true,\n __source: true\n};\nvar specialPropKeyWarningShown, specialPropRefWarningShown, didWarnAboutStringRefs;\n\n{\n didWarnAboutStringRefs = {};\n}\n\nfunction hasValidRef(config) {\n {\n if (hasOwnProperty.call(config, 'ref')) {\n var getter = Object.getOwnPropertyDescriptor(config, 'ref').get;\n\n if (getter && getter.isReactWarning) {\n return false;\n }\n }\n }\n\n return config.ref !== undefined;\n}\n\nfunction hasValidKey(config) {\n {\n if (hasOwnProperty.call(config, 'key')) {\n var getter = Object.getOwnPropertyDescriptor(config, 'key').get;\n\n if (getter && getter.isReactWarning) {\n return false;\n }\n }\n }\n\n return config.key !== undefined;\n}\n\nfunction defineKeyPropWarningGetter(props, displayName) {\n var warnAboutAccessingKey = function () {\n {\n if (!specialPropKeyWarningShown) {\n specialPropKeyWarningShown = true;\n\n error('%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://reactjs.org/link/special-props)', displayName);\n }\n }\n };\n\n warnAboutAccessingKey.isReactWarning = true;\n Object.defineProperty(props, 'key', {\n get: warnAboutAccessingKey,\n configurable: true\n });\n}\n\nfunction defineRefPropWarningGetter(props, displayName) {\n var warnAboutAccessingRef = function () {\n {\n if (!specialPropRefWarningShown) {\n specialPropRefWarningShown = true;\n\n error('%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://reactjs.org/link/special-props)', displayName);\n }\n }\n };\n\n warnAboutAccessingRef.isReactWarning = true;\n Object.defineProperty(props, 'ref', {\n get: warnAboutAccessingRef,\n configurable: true\n });\n}\n\nfunction warnIfStringRefCannotBeAutoConverted(config) {\n {\n if (typeof config.ref === 'string' && ReactCurrentOwner.current && config.__self && ReactCurrentOwner.current.stateNode !== config.__self) {\n var componentName = getComponentNameFromType(ReactCurrentOwner.current.type);\n\n if (!didWarnAboutStringRefs[componentName]) {\n error('Component \"%s\" contains the string ref \"%s\". ' + 'Support for string refs will be removed in a future major release. ' + 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + 'https://reactjs.org/link/strict-mode-string-ref', componentName, config.ref);\n\n didWarnAboutStringRefs[componentName] = true;\n }\n }\n }\n}\n/**\n * Factory method to create a new React element. This no longer adheres to\n * the class pattern, so do not use new to call it. Also, instanceof check\n * will not work. Instead test $$typeof field against Symbol.for('react.element') to check\n * if something is a React Element.\n *\n * @param {*} type\n * @param {*} props\n * @param {*} key\n * @param {string|object} ref\n * @param {*} owner\n * @param {*} self A *temporary* helper to detect places where `this` is\n * different from the `owner` when React.createElement is called, so that we\n * can warn. We want to get rid of owner and replace string `ref`s with arrow\n * functions, and as long as `this` and owner are the same, there will be no\n * change in behavior.\n * @param {*} source An annotation object (added by a transpiler or otherwise)\n * indicating filename, line number, and/or other information.\n * @internal\n */\n\n\nvar ReactElement = function (type, key, ref, self, source, owner, props) {\n var element = {\n // This tag allows us to uniquely identify this as a React Element\n $$typeof: REACT_ELEMENT_TYPE,\n // Built-in properties that belong on the element\n type: type,\n key: key,\n ref: ref,\n props: props,\n // Record the component responsible for creating this element.\n _owner: owner\n };\n\n {\n // The validation flag is currently mutative. We put it on\n // an external backing store so that we can freeze the whole object.\n // This can be replaced with a WeakMap once they are implemented in\n // commonly used development environments.\n element._store = {}; // To make comparing ReactElements easier for testing purposes, we make\n // the validation flag non-enumerable (where possible, which should\n // include every environment we run tests in), so the test framework\n // ignores it.\n\n Object.defineProperty(element._store, 'validated', {\n configurable: false,\n enumerable: false,\n writable: true,\n value: false\n }); // self and source are DEV only properties.\n\n Object.defineProperty(element, '_self', {\n configurable: false,\n enumerable: false,\n writable: false,\n value: self\n }); // Two elements created in two different places should be considered\n // equal for testing purposes and therefore we hide it from enumeration.\n\n Object.defineProperty(element, '_source', {\n configurable: false,\n enumerable: false,\n writable: false,\n value: source\n });\n\n if (Object.freeze) {\n Object.freeze(element.props);\n Object.freeze(element);\n }\n }\n\n return element;\n};\n/**\n * Create and return a new ReactElement of the given type.\n * See https://reactjs.org/docs/react-api.html#createelement\n */\n\nfunction createElement(type, config, children) {\n var propName; // Reserved names are extracted\n\n var props = {};\n var key = null;\n var ref = null;\n var self = null;\n var source = null;\n\n if (config != null) {\n if (hasValidRef(config)) {\n ref = config.ref;\n\n {\n warnIfStringRefCannotBeAutoConverted(config);\n }\n }\n\n if (hasValidKey(config)) {\n {\n checkKeyStringCoercion(config.key);\n }\n\n key = '' + config.key;\n }\n\n self = config.__self === undefined ? null : config.__self;\n source = config.__source === undefined ? null : config.__source; // Remaining properties are added to a new props object\n\n for (propName in config) {\n if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) {\n props[propName] = config[propName];\n }\n }\n } // Children can be more than one argument, and those are transferred onto\n // the newly allocated props object.\n\n\n var childrenLength = arguments.length - 2;\n\n if (childrenLength === 1) {\n props.children = children;\n } else if (childrenLength > 1) {\n var childArray = Array(childrenLength);\n\n for (var i = 0; i < childrenLength; i++) {\n childArray[i] = arguments[i + 2];\n }\n\n {\n if (Object.freeze) {\n Object.freeze(childArray);\n }\n }\n\n props.children = childArray;\n } // Resolve default props\n\n\n if (type && type.defaultProps) {\n var defaultProps = type.defaultProps;\n\n for (propName in defaultProps) {\n if (props[propName] === undefined) {\n props[propName] = defaultProps[propName];\n }\n }\n }\n\n {\n if (key || ref) {\n var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type;\n\n if (key) {\n defineKeyPropWarningGetter(props, displayName);\n }\n\n if (ref) {\n defineRefPropWarningGetter(props, displayName);\n }\n }\n }\n\n return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props);\n}\nfunction cloneAndReplaceKey(oldElement, newKey) {\n var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props);\n return newElement;\n}\n/**\n * Clone and return a new ReactElement using element as the starting point.\n * See https://reactjs.org/docs/react-api.html#cloneelement\n */\n\nfunction cloneElement(element, config, children) {\n if (element === null || element === undefined) {\n throw new Error(\"React.cloneElement(...): The argument must be a React element, but you passed \" + element + \".\");\n }\n\n var propName; // Original props are copied\n\n var props = assign({}, element.props); // Reserved names are extracted\n\n var key = element.key;\n var ref = element.ref; // Self is preserved since the owner is preserved.\n\n var self = element._self; // Source is preserved since cloneElement is unlikely to be targeted by a\n // transpiler, and the original source is probably a better indicator of the\n // true owner.\n\n var source = element._source; // Owner will be preserved, unless ref is overridden\n\n var owner = element._owner;\n\n if (config != null) {\n if (hasValidRef(config)) {\n // Silently steal the ref from the parent.\n ref = config.ref;\n owner = ReactCurrentOwner.current;\n }\n\n if (hasValidKey(config)) {\n {\n checkKeyStringCoercion(config.key);\n }\n\n key = '' + config.key;\n } // Remaining properties override existing props\n\n\n var defaultProps;\n\n if (element.type && element.type.defaultProps) {\n defaultProps = element.type.defaultProps;\n }\n\n for (propName in config) {\n if (hasOwnProperty.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) {\n if (config[propName] === undefined && defaultProps !== undefined) {\n // Resolve default props\n props[propName] = defaultProps[propName];\n } else {\n props[propName] = config[propName];\n }\n }\n }\n } // Children can be more than one argument, and those are transferred onto\n // the newly allocated props object.\n\n\n var childrenLength = arguments.length - 2;\n\n if (childrenLength === 1) {\n props.children = children;\n } else if (childrenLength > 1) {\n var childArray = Array(childrenLength);\n\n for (var i = 0; i < childrenLength; i++) {\n childArray[i] = arguments[i + 2];\n }\n\n props.children = childArray;\n }\n\n return ReactElement(element.type, key, ref, self, source, owner, props);\n}\n/**\n * Verifies the object is a ReactElement.\n * See https://reactjs.org/docs/react-api.html#isvalidelement\n * @param {?object} object\n * @return {boolean} True if `object` is a ReactElement.\n * @final\n */\n\nfunction isValidElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\n\nvar SEPARATOR = '.';\nvar SUBSEPARATOR = ':';\n/**\n * Escape and wrap key so it is safe to use as a reactid\n *\n * @param {string} key to be escaped.\n * @return {string} the escaped key.\n */\n\nfunction escape(key) {\n var escapeRegex = /[=:]/g;\n var escaperLookup = {\n '=': '=0',\n ':': '=2'\n };\n var escapedString = key.replace(escapeRegex, function (match) {\n return escaperLookup[match];\n });\n return '$' + escapedString;\n}\n/**\n * TODO: Test that a single child and an array with one item have the same key\n * pattern.\n */\n\n\nvar didWarnAboutMaps = false;\nvar userProvidedKeyEscapeRegex = /\\/+/g;\n\nfunction escapeUserProvidedKey(text) {\n return text.replace(userProvidedKeyEscapeRegex, '$&/');\n}\n/**\n * Generate a key string that identifies a element within a set.\n *\n * @param {*} element A element that could contain a manual key.\n * @param {number} index Index that is used if a manual key is not provided.\n * @return {string}\n */\n\n\nfunction getElementKey(element, index) {\n // Do some typechecking here since we call this blindly. We want to ensure\n // that we don't block potential future ES APIs.\n if (typeof element === 'object' && element !== null && element.key != null) {\n // Explicit key\n {\n checkKeyStringCoercion(element.key);\n }\n\n return escape('' + element.key);\n } // Implicit key determined by the index in the set\n\n\n return index.toString(36);\n}\n\nfunction mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {\n var type = typeof children;\n\n if (type === 'undefined' || type === 'boolean') {\n // All of the above are perceived as null.\n children = null;\n }\n\n var invokeCallback = false;\n\n if (children === null) {\n invokeCallback = true;\n } else {\n switch (type) {\n case 'string':\n case 'number':\n invokeCallback = true;\n break;\n\n case 'object':\n switch (children.$$typeof) {\n case REACT_ELEMENT_TYPE:\n case REACT_PORTAL_TYPE:\n invokeCallback = true;\n }\n\n }\n }\n\n if (invokeCallback) {\n var _child = children;\n var mappedChild = callback(_child); // If it's the only child, treat the name as if it was wrapped in an array\n // so that it's consistent if the number of children grows:\n\n var childKey = nameSoFar === '' ? SEPARATOR + getElementKey(_child, 0) : nameSoFar;\n\n if (isArray(mappedChild)) {\n var escapedChildKey = '';\n\n if (childKey != null) {\n escapedChildKey = escapeUserProvidedKey(childKey) + '/';\n }\n\n mapIntoArray(mappedChild, array, escapedChildKey, '', function (c) {\n return c;\n });\n } else if (mappedChild != null) {\n if (isValidElement(mappedChild)) {\n {\n // The `if` statement here prevents auto-disabling of the safe\n // coercion ESLint rule, so we must manually disable it below.\n // $FlowFixMe Flow incorrectly thinks React.Portal doesn't have a key\n if (mappedChild.key && (!_child || _child.key !== mappedChild.key)) {\n checkKeyStringCoercion(mappedChild.key);\n }\n }\n\n mappedChild = cloneAndReplaceKey(mappedChild, // Keep both the (mapped) and old keys if they differ, just as\n // traverseAllChildren used to do for objects as children\n escapedPrefix + ( // $FlowFixMe Flow incorrectly thinks React.Portal doesn't have a key\n mappedChild.key && (!_child || _child.key !== mappedChild.key) ? // $FlowFixMe Flow incorrectly thinks existing element's key can be a number\n // eslint-disable-next-line react-internal/safe-string-coercion\n escapeUserProvidedKey('' + mappedChild.key) + '/' : '') + childKey);\n }\n\n array.push(mappedChild);\n }\n\n return 1;\n }\n\n var child;\n var nextName;\n var subtreeCount = 0; // Count of children found in the current subtree.\n\n var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR;\n\n if (isArray(children)) {\n for (var i = 0; i < children.length; i++) {\n child = children[i];\n nextName = nextNamePrefix + getElementKey(child, i);\n subtreeCount += mapIntoArray(child, array, escapedPrefix, nextName, callback);\n }\n } else {\n var iteratorFn = getIteratorFn(children);\n\n if (typeof iteratorFn === 'function') {\n var iterableChildren = children;\n\n {\n // Warn about using Maps as children\n if (iteratorFn === iterableChildren.entries) {\n if (!didWarnAboutMaps) {\n warn('Using Maps as children is not supported. ' + 'Use an array of keyed ReactElements instead.');\n }\n\n didWarnAboutMaps = true;\n }\n }\n\n var iterator = iteratorFn.call(iterableChildren);\n var step;\n var ii = 0;\n\n while (!(step = iterator.next()).done) {\n child = step.value;\n nextName = nextNamePrefix + getElementKey(child, ii++);\n subtreeCount += mapIntoArray(child, array, escapedPrefix, nextName, callback);\n }\n } else if (type === 'object') {\n // eslint-disable-next-line react-internal/safe-string-coercion\n var childrenString = String(children);\n throw new Error(\"Objects are not valid as a React child (found: \" + (childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString) + \"). \" + 'If you meant to render a collection of children, use an array ' + 'instead.');\n }\n }\n\n return subtreeCount;\n}\n\n/**\n * Maps children that are typically specified as `props.children`.\n *\n * See https://reactjs.org/docs/react-api.html#reactchildrenmap\n *\n * The provided mapFunction(child, index) will be called for each\n * leaf child.\n *\n * @param {?*} children Children tree container.\n * @param {function(*, int)} func The map function.\n * @param {*} context Context for mapFunction.\n * @return {object} Object containing the ordered map of results.\n */\nfunction mapChildren(children, func, context) {\n if (children == null) {\n return children;\n }\n\n var result = [];\n var count = 0;\n mapIntoArray(children, result, '', '', function (child) {\n return func.call(context, child, count++);\n });\n return result;\n}\n/**\n * Count the number of children that are typically specified as\n * `props.children`.\n *\n * See https://reactjs.org/docs/react-api.html#reactchildrencount\n *\n * @param {?*} children Children tree container.\n * @return {number} The number of children.\n */\n\n\nfunction countChildren(children) {\n var n = 0;\n mapChildren(children, function () {\n n++; // Don't return anything\n });\n return n;\n}\n\n/**\n * Iterates through children that are typically specified as `props.children`.\n *\n * See https://reactjs.org/docs/react-api.html#reactchildrenforeach\n *\n * The provided forEachFunc(child, index) will be called for each\n * leaf child.\n *\n * @param {?*} children Children tree container.\n * @param {function(*, int)} forEachFunc\n * @param {*} forEachContext Context for forEachContext.\n */\nfunction forEachChildren(children, forEachFunc, forEachContext) {\n mapChildren(children, function () {\n forEachFunc.apply(this, arguments); // Don't return anything.\n }, forEachContext);\n}\n/**\n * Flatten a children object (typically specified as `props.children`) and\n * return an array with appropriately re-keyed children.\n *\n * See https://reactjs.org/docs/react-api.html#reactchildrentoarray\n */\n\n\nfunction toArray(children) {\n return mapChildren(children, function (child) {\n return child;\n }) || [];\n}\n/**\n * Returns the first child in a collection of children and verifies that there\n * is only one child in the collection.\n *\n * See https://reactjs.org/docs/react-api.html#reactchildrenonly\n *\n * The current implementation of this function assumes that a single child gets\n * passed without a wrapper, but the purpose of this helper function is to\n * abstract away the particular structure of children.\n *\n * @param {?object} children Child collection structure.\n * @return {ReactElement} The first and only `ReactElement` contained in the\n * structure.\n */\n\n\nfunction onlyChild(children) {\n if (!isValidElement(children)) {\n throw new Error('React.Children.only expected to receive a single React element child.');\n }\n\n return children;\n}\n\nfunction createContext(defaultValue) {\n // TODO: Second argument used to be an optional `calculateChangedBits`\n // function. Warn to reserve for future use?\n var context = {\n $$typeof: REACT_CONTEXT_TYPE,\n // As a workaround to support multiple concurrent renderers, we categorize\n // some renderers as primary and others as secondary. We only expect\n // there to be two concurrent renderers at most: React Native (primary) and\n // Fabric (secondary); React DOM (primary) and React ART (secondary).\n // Secondary renderers store their context values on separate fields.\n _currentValue: defaultValue,\n _currentValue2: defaultValue,\n // Used to track how many concurrent renderers this context currently\n // supports within in a single renderer. Such as parallel server rendering.\n _threadCount: 0,\n // These are circular\n Provider: null,\n Consumer: null,\n // Add these to use same hidden class in VM as ServerContext\n _defaultValue: null,\n _globalName: null\n };\n context.Provider = {\n $$typeof: REACT_PROVIDER_TYPE,\n _context: context\n };\n var hasWarnedAboutUsingNestedContextConsumers = false;\n var hasWarnedAboutUsingConsumerProvider = false;\n var hasWarnedAboutDisplayNameOnConsumer = false;\n\n {\n // A separate object, but proxies back to the original context object for\n // backwards compatibility. It has a different $$typeof, so we can properly\n // warn for the incorrect usage of Context as a Consumer.\n var Consumer = {\n $$typeof: REACT_CONTEXT_TYPE,\n _context: context\n }; // $FlowFixMe: Flow complains about not setting a value, which is intentional here\n\n Object.defineProperties(Consumer, {\n Provider: {\n get: function () {\n if (!hasWarnedAboutUsingConsumerProvider) {\n hasWarnedAboutUsingConsumerProvider = true;\n\n error('Rendering is not supported and will be removed in ' + 'a future major release. Did you mean to render instead?');\n }\n\n return context.Provider;\n },\n set: function (_Provider) {\n context.Provider = _Provider;\n }\n },\n _currentValue: {\n get: function () {\n return context._currentValue;\n },\n set: function (_currentValue) {\n context._currentValue = _currentValue;\n }\n },\n _currentValue2: {\n get: function () {\n return context._currentValue2;\n },\n set: function (_currentValue2) {\n context._currentValue2 = _currentValue2;\n }\n },\n _threadCount: {\n get: function () {\n return context._threadCount;\n },\n set: function (_threadCount) {\n context._threadCount = _threadCount;\n }\n },\n Consumer: {\n get: function () {\n if (!hasWarnedAboutUsingNestedContextConsumers) {\n hasWarnedAboutUsingNestedContextConsumers = true;\n\n error('Rendering is not supported and will be removed in ' + 'a future major release. Did you mean to render instead?');\n }\n\n return context.Consumer;\n }\n },\n displayName: {\n get: function () {\n return context.displayName;\n },\n set: function (displayName) {\n if (!hasWarnedAboutDisplayNameOnConsumer) {\n warn('Setting `displayName` on Context.Consumer has no effect. ' + \"You should set it directly on the context with Context.displayName = '%s'.\", displayName);\n\n hasWarnedAboutDisplayNameOnConsumer = true;\n }\n }\n }\n }); // $FlowFixMe: Flow complains about missing properties because it doesn't understand defineProperty\n\n context.Consumer = Consumer;\n }\n\n {\n context._currentRenderer = null;\n context._currentRenderer2 = null;\n }\n\n return context;\n}\n\nvar Uninitialized = -1;\nvar Pending = 0;\nvar Resolved = 1;\nvar Rejected = 2;\n\nfunction lazyInitializer(payload) {\n if (payload._status === Uninitialized) {\n var ctor = payload._result;\n var thenable = ctor(); // Transition to the next state.\n // This might throw either because it's missing or throws. If so, we treat it\n // as still uninitialized and try again next time. Which is the same as what\n // happens if the ctor or any wrappers processing the ctor throws. This might\n // end up fixing it if the resolution was a concurrency bug.\n\n thenable.then(function (moduleObject) {\n if (payload._status === Pending || payload._status === Uninitialized) {\n // Transition to the next state.\n var resolved = payload;\n resolved._status = Resolved;\n resolved._result = moduleObject;\n }\n }, function (error) {\n if (payload._status === Pending || payload._status === Uninitialized) {\n // Transition to the next state.\n var rejected = payload;\n rejected._status = Rejected;\n rejected._result = error;\n }\n });\n\n if (payload._status === Uninitialized) {\n // In case, we're still uninitialized, then we're waiting for the thenable\n // to resolve. Set it as pending in the meantime.\n var pending = payload;\n pending._status = Pending;\n pending._result = thenable;\n }\n }\n\n if (payload._status === Resolved) {\n var moduleObject = payload._result;\n\n {\n if (moduleObject === undefined) {\n error('lazy: Expected the result of a dynamic imp' + 'ort() call. ' + 'Instead received: %s\\n\\nYour code should look like: \\n ' + // Break up imports to avoid accidentally parsing them as dependencies.\n 'const MyComponent = lazy(() => imp' + \"ort('./MyComponent'))\\n\\n\" + 'Did you accidentally put curly braces around the import?', moduleObject);\n }\n }\n\n {\n if (!('default' in moduleObject)) {\n error('lazy: Expected the result of a dynamic imp' + 'ort() call. ' + 'Instead received: %s\\n\\nYour code should look like: \\n ' + // Break up imports to avoid accidentally parsing them as dependencies.\n 'const MyComponent = lazy(() => imp' + \"ort('./MyComponent'))\", moduleObject);\n }\n }\n\n return moduleObject.default;\n } else {\n throw payload._result;\n }\n}\n\nfunction lazy(ctor) {\n var payload = {\n // We use these fields to store the result.\n _status: Uninitialized,\n _result: ctor\n };\n var lazyType = {\n $$typeof: REACT_LAZY_TYPE,\n _payload: payload,\n _init: lazyInitializer\n };\n\n {\n // In production, this would just set it on the object.\n var defaultProps;\n var propTypes; // $FlowFixMe\n\n Object.defineProperties(lazyType, {\n defaultProps: {\n configurable: true,\n get: function () {\n return defaultProps;\n },\n set: function (newDefaultProps) {\n error('React.lazy(...): It is not supported to assign `defaultProps` to ' + 'a lazy component import. Either specify them where the component ' + 'is defined, or create a wrapping component around it.');\n\n defaultProps = newDefaultProps; // Match production behavior more closely:\n // $FlowFixMe\n\n Object.defineProperty(lazyType, 'defaultProps', {\n enumerable: true\n });\n }\n },\n propTypes: {\n configurable: true,\n get: function () {\n return propTypes;\n },\n set: function (newPropTypes) {\n error('React.lazy(...): It is not supported to assign `propTypes` to ' + 'a lazy component import. Either specify them where the component ' + 'is defined, or create a wrapping component around it.');\n\n propTypes = newPropTypes; // Match production behavior more closely:\n // $FlowFixMe\n\n Object.defineProperty(lazyType, 'propTypes', {\n enumerable: true\n });\n }\n }\n });\n }\n\n return lazyType;\n}\n\nfunction forwardRef(render) {\n {\n if (render != null && render.$$typeof === REACT_MEMO_TYPE) {\n error('forwardRef requires a render function but received a `memo` ' + 'component. Instead of forwardRef(memo(...)), use ' + 'memo(forwardRef(...)).');\n } else if (typeof render !== 'function') {\n error('forwardRef requires a render function but was given %s.', render === null ? 'null' : typeof render);\n } else {\n if (render.length !== 0 && render.length !== 2) {\n error('forwardRef render functions accept exactly two parameters: props and ref. %s', render.length === 1 ? 'Did you forget to use the ref parameter?' : 'Any additional parameter will be undefined.');\n }\n }\n\n if (render != null) {\n if (render.defaultProps != null || render.propTypes != null) {\n error('forwardRef render functions do not support propTypes or defaultProps. ' + 'Did you accidentally pass a React component?');\n }\n }\n }\n\n var elementType = {\n $$typeof: REACT_FORWARD_REF_TYPE,\n render: render\n };\n\n {\n var ownName;\n Object.defineProperty(elementType, 'displayName', {\n enumerable: false,\n configurable: true,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name; // The inner component shouldn't inherit this display name in most cases,\n // because the component may be used elsewhere.\n // But it's nice for anonymous functions to inherit the name,\n // so that our component-stack generation logic will display their frames.\n // An anonymous function generally suggests a pattern like:\n // React.forwardRef((props, ref) => {...});\n // This kind of inner function is not used elsewhere so the side effect is okay.\n\n if (!render.name && !render.displayName) {\n render.displayName = name;\n }\n }\n });\n }\n\n return elementType;\n}\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction memo(type, compare) {\n {\n if (!isValidElementType(type)) {\n error('memo: The first argument must be a component. Instead ' + 'received: %s', type === null ? 'null' : typeof type);\n }\n }\n\n var elementType = {\n $$typeof: REACT_MEMO_TYPE,\n type: type,\n compare: compare === undefined ? null : compare\n };\n\n {\n var ownName;\n Object.defineProperty(elementType, 'displayName', {\n enumerable: false,\n configurable: true,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name; // The inner component shouldn't inherit this display name in most cases,\n // because the component may be used elsewhere.\n // But it's nice for anonymous functions to inherit the name,\n // so that our component-stack generation logic will display their frames.\n // An anonymous function generally suggests a pattern like:\n // React.memo((props) => {...});\n // This kind of inner function is not used elsewhere so the side effect is okay.\n\n if (!type.name && !type.displayName) {\n type.displayName = name;\n }\n }\n });\n }\n\n return elementType;\n}\n\nfunction resolveDispatcher() {\n var dispatcher = ReactCurrentDispatcher.current;\n\n {\n if (dispatcher === null) {\n error('Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for' + ' one of the following reasons:\\n' + '1. You might have mismatching versions of React and the renderer (such as React DOM)\\n' + '2. You might be breaking the Rules of Hooks\\n' + '3. You might have more than one copy of React in the same app\\n' + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.');\n }\n } // Will result in a null access error if accessed outside render phase. We\n // intentionally don't throw our own error because this is in a hot path.\n // Also helps ensure this is inlined.\n\n\n return dispatcher;\n}\nfunction useContext(Context) {\n var dispatcher = resolveDispatcher();\n\n {\n // TODO: add a more generic warning for invalid values.\n if (Context._context !== undefined) {\n var realContext = Context._context; // Don't deduplicate because this legitimately causes bugs\n // and nobody should be using this in existing code.\n\n if (realContext.Consumer === Context) {\n error('Calling useContext(Context.Consumer) is not supported, may cause bugs, and will be ' + 'removed in a future major release. Did you mean to call useContext(Context) instead?');\n } else if (realContext.Provider === Context) {\n error('Calling useContext(Context.Provider) is not supported. ' + 'Did you mean to call useContext(Context) instead?');\n }\n }\n }\n\n return dispatcher.useContext(Context);\n}\nfunction useState(initialState) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useState(initialState);\n}\nfunction useReducer(reducer, initialArg, init) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useReducer(reducer, initialArg, init);\n}\nfunction useRef(initialValue) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useRef(initialValue);\n}\nfunction useEffect(create, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useEffect(create, deps);\n}\nfunction useInsertionEffect(create, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useInsertionEffect(create, deps);\n}\nfunction useLayoutEffect(create, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useLayoutEffect(create, deps);\n}\nfunction useCallback(callback, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useCallback(callback, deps);\n}\nfunction useMemo(create, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useMemo(create, deps);\n}\nfunction useImperativeHandle(ref, create, deps) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useImperativeHandle(ref, create, deps);\n}\nfunction useDebugValue(value, formatterFn) {\n {\n var dispatcher = resolveDispatcher();\n return dispatcher.useDebugValue(value, formatterFn);\n }\n}\nfunction useTransition() {\n var dispatcher = resolveDispatcher();\n return dispatcher.useTransition();\n}\nfunction useDeferredValue(value) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useDeferredValue(value);\n}\nfunction useId() {\n var dispatcher = resolveDispatcher();\n return dispatcher.useId();\n}\nfunction useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot) {\n var dispatcher = resolveDispatcher();\n return dispatcher.useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);\n}\n\n// Helpers to patch console.logs to avoid logging during side-effect free\n// replaying on render function. This currently only patches the object\n// lazily which won't cover if the log function was extracted eagerly.\n// We could also eagerly patch the method.\nvar disabledDepth = 0;\nvar prevLog;\nvar prevInfo;\nvar prevWarn;\nvar prevError;\nvar prevGroup;\nvar prevGroupCollapsed;\nvar prevGroupEnd;\n\nfunction disabledLog() {}\n\ndisabledLog.__reactDisabledLog = true;\nfunction disableLogs() {\n {\n if (disabledDepth === 0) {\n /* eslint-disable react-internal/no-production-logging */\n prevLog = console.log;\n prevInfo = console.info;\n prevWarn = console.warn;\n prevError = console.error;\n prevGroup = console.group;\n prevGroupCollapsed = console.groupCollapsed;\n prevGroupEnd = console.groupEnd; // https://github.com/facebook/react/issues/19099\n\n var props = {\n configurable: true,\n enumerable: true,\n value: disabledLog,\n writable: true\n }; // $FlowFixMe Flow thinks console is immutable.\n\n Object.defineProperties(console, {\n info: props,\n log: props,\n warn: props,\n error: props,\n group: props,\n groupCollapsed: props,\n groupEnd: props\n });\n /* eslint-enable react-internal/no-production-logging */\n }\n\n disabledDepth++;\n }\n}\nfunction reenableLogs() {\n {\n disabledDepth--;\n\n if (disabledDepth === 0) {\n /* eslint-disable react-internal/no-production-logging */\n var props = {\n configurable: true,\n enumerable: true,\n writable: true\n }; // $FlowFixMe Flow thinks console is immutable.\n\n Object.defineProperties(console, {\n log: assign({}, props, {\n value: prevLog\n }),\n info: assign({}, props, {\n value: prevInfo\n }),\n warn: assign({}, props, {\n value: prevWarn\n }),\n error: assign({}, props, {\n value: prevError\n }),\n group: assign({}, props, {\n value: prevGroup\n }),\n groupCollapsed: assign({}, props, {\n value: prevGroupCollapsed\n }),\n groupEnd: assign({}, props, {\n value: prevGroupEnd\n })\n });\n /* eslint-enable react-internal/no-production-logging */\n }\n\n if (disabledDepth < 0) {\n error('disabledDepth fell below zero. ' + 'This is a bug in React. Please file an issue.');\n }\n }\n}\n\nvar ReactCurrentDispatcher$1 = ReactSharedInternals.ReactCurrentDispatcher;\nvar prefix;\nfunction describeBuiltInComponentFrame(name, source, ownerFn) {\n {\n if (prefix === undefined) {\n // Extract the VM specific prefix used by each line.\n try {\n throw Error();\n } catch (x) {\n var match = x.stack.trim().match(/\\n( *(at )?)/);\n prefix = match && match[1] || '';\n }\n } // We use the prefix to ensure our stacks line up with native stack frames.\n\n\n return '\\n' + prefix + name;\n }\n}\nvar reentry = false;\nvar componentFrameCache;\n\n{\n var PossiblyWeakMap = typeof WeakMap === 'function' ? WeakMap : Map;\n componentFrameCache = new PossiblyWeakMap();\n}\n\nfunction describeNativeComponentFrame(fn, construct) {\n // If something asked for a stack inside a fake render, it should get ignored.\n if ( !fn || reentry) {\n return '';\n }\n\n {\n var frame = componentFrameCache.get(fn);\n\n if (frame !== undefined) {\n return frame;\n }\n }\n\n var control;\n reentry = true;\n var previousPrepareStackTrace = Error.prepareStackTrace; // $FlowFixMe It does accept undefined.\n\n Error.prepareStackTrace = undefined;\n var previousDispatcher;\n\n {\n previousDispatcher = ReactCurrentDispatcher$1.current; // Set the dispatcher in DEV because this might be call in the render function\n // for warnings.\n\n ReactCurrentDispatcher$1.current = null;\n disableLogs();\n }\n\n try {\n // This should throw.\n if (construct) {\n // Something should be setting the props in the constructor.\n var Fake = function () {\n throw Error();\n }; // $FlowFixMe\n\n\n Object.defineProperty(Fake.prototype, 'props', {\n set: function () {\n // We use a throwing setter instead of frozen or non-writable props\n // because that won't throw in a non-strict mode function.\n throw Error();\n }\n });\n\n if (typeof Reflect === 'object' && Reflect.construct) {\n // We construct a different control for this case to include any extra\n // frames added by the construct call.\n try {\n Reflect.construct(Fake, []);\n } catch (x) {\n control = x;\n }\n\n Reflect.construct(fn, [], Fake);\n } else {\n try {\n Fake.call();\n } catch (x) {\n control = x;\n }\n\n fn.call(Fake.prototype);\n }\n } else {\n try {\n throw Error();\n } catch (x) {\n control = x;\n }\n\n fn();\n }\n } catch (sample) {\n // This is inlined manually because closure doesn't do it for us.\n if (sample && control && typeof sample.stack === 'string') {\n // This extracts the first frame from the sample that isn't also in the control.\n // Skipping one frame that we assume is the frame that calls the two.\n var sampleLines = sample.stack.split('\\n');\n var controlLines = control.stack.split('\\n');\n var s = sampleLines.length - 1;\n var c = controlLines.length - 1;\n\n while (s >= 1 && c >= 0 && sampleLines[s] !== controlLines[c]) {\n // We expect at least one stack frame to be shared.\n // Typically this will be the root most one. However, stack frames may be\n // cut off due to maximum stack limits. In this case, one maybe cut off\n // earlier than the other. We assume that the sample is longer or the same\n // and there for cut off earlier. So we should find the root most frame in\n // the sample somewhere in the control.\n c--;\n }\n\n for (; s >= 1 && c >= 0; s--, c--) {\n // Next we find the first one that isn't the same which should be the\n // frame that called our sample function and the control.\n if (sampleLines[s] !== controlLines[c]) {\n // In V8, the first line is describing the message but other VMs don't.\n // If we're about to return the first line, and the control is also on the same\n // line, that's a pretty good indicator that our sample threw at same line as\n // the control. I.e. before we entered the sample frame. So we ignore this result.\n // This can happen if you passed a class to function component, or non-function.\n if (s !== 1 || c !== 1) {\n do {\n s--;\n c--; // We may still have similar intermediate frames from the construct call.\n // The next one that isn't the same should be our match though.\n\n if (c < 0 || sampleLines[s] !== controlLines[c]) {\n // V8 adds a \"new\" prefix for native classes. Let's remove it to make it prettier.\n var _frame = '\\n' + sampleLines[s].replace(' at new ', ' at '); // If our component frame is labeled \"\"\n // but we have a user-provided \"displayName\"\n // splice it in to make the stack more readable.\n\n\n if (fn.displayName && _frame.includes('')) {\n _frame = _frame.replace('', fn.displayName);\n }\n\n {\n if (typeof fn === 'function') {\n componentFrameCache.set(fn, _frame);\n }\n } // Return the line we found.\n\n\n return _frame;\n }\n } while (s >= 1 && c >= 0);\n }\n\n break;\n }\n }\n }\n } finally {\n reentry = false;\n\n {\n ReactCurrentDispatcher$1.current = previousDispatcher;\n reenableLogs();\n }\n\n Error.prepareStackTrace = previousPrepareStackTrace;\n } // Fallback to just using the name if we couldn't make it throw.\n\n\n var name = fn ? fn.displayName || fn.name : '';\n var syntheticFrame = name ? describeBuiltInComponentFrame(name) : '';\n\n {\n if (typeof fn === 'function') {\n componentFrameCache.set(fn, syntheticFrame);\n }\n }\n\n return syntheticFrame;\n}\nfunction describeFunctionComponentFrame(fn, source, ownerFn) {\n {\n return describeNativeComponentFrame(fn, false);\n }\n}\n\nfunction shouldConstruct(Component) {\n var prototype = Component.prototype;\n return !!(prototype && prototype.isReactComponent);\n}\n\nfunction describeUnknownElementTypeFrameInDEV(type, source, ownerFn) {\n\n if (type == null) {\n return '';\n }\n\n if (typeof type === 'function') {\n {\n return describeNativeComponentFrame(type, shouldConstruct(type));\n }\n }\n\n if (typeof type === 'string') {\n return describeBuiltInComponentFrame(type);\n }\n\n switch (type) {\n case REACT_SUSPENSE_TYPE:\n return describeBuiltInComponentFrame('Suspense');\n\n case REACT_SUSPENSE_LIST_TYPE:\n return describeBuiltInComponentFrame('SuspenseList');\n }\n\n if (typeof type === 'object') {\n switch (type.$$typeof) {\n case REACT_FORWARD_REF_TYPE:\n return describeFunctionComponentFrame(type.render);\n\n case REACT_MEMO_TYPE:\n // Memo may contain any component type so we recursively resolve it.\n return describeUnknownElementTypeFrameInDEV(type.type, source, ownerFn);\n\n case REACT_LAZY_TYPE:\n {\n var lazyComponent = type;\n var payload = lazyComponent._payload;\n var init = lazyComponent._init;\n\n try {\n // Lazy may contain any component type so we recursively resolve it.\n return describeUnknownElementTypeFrameInDEV(init(payload), source, ownerFn);\n } catch (x) {}\n }\n }\n }\n\n return '';\n}\n\nvar loggedTypeFailures = {};\nvar ReactDebugCurrentFrame$1 = ReactSharedInternals.ReactDebugCurrentFrame;\n\nfunction setCurrentlyValidatingElement(element) {\n {\n if (element) {\n var owner = element._owner;\n var stack = describeUnknownElementTypeFrameInDEV(element.type, element._source, owner ? owner.type : null);\n ReactDebugCurrentFrame$1.setExtraStackFrame(stack);\n } else {\n ReactDebugCurrentFrame$1.setExtraStackFrame(null);\n }\n }\n}\n\nfunction checkPropTypes(typeSpecs, values, location, componentName, element) {\n {\n // $FlowFixMe This is okay but Flow doesn't know it.\n var has = Function.call.bind(hasOwnProperty);\n\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error$1 = void 0; // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n // eslint-disable-next-line react-internal/prod-error-codes\n var err = Error((componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' + 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.');\n err.name = 'Invariant Violation';\n throw err;\n }\n\n error$1 = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED');\n } catch (ex) {\n error$1 = ex;\n }\n\n if (error$1 && !(error$1 instanceof Error)) {\n setCurrentlyValidatingElement(element);\n\n error('%s: type specification of %s' + ' `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error$1);\n\n setCurrentlyValidatingElement(null);\n }\n\n if (error$1 instanceof Error && !(error$1.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error$1.message] = true;\n setCurrentlyValidatingElement(element);\n\n error('Failed %s type: %s', location, error$1.message);\n\n setCurrentlyValidatingElement(null);\n }\n }\n }\n }\n}\n\nfunction setCurrentlyValidatingElement$1(element) {\n {\n if (element) {\n var owner = element._owner;\n var stack = describeUnknownElementTypeFrameInDEV(element.type, element._source, owner ? owner.type : null);\n setExtraStackFrame(stack);\n } else {\n setExtraStackFrame(null);\n }\n }\n}\n\nvar propTypesMisspellWarningShown;\n\n{\n propTypesMisspellWarningShown = false;\n}\n\nfunction getDeclarationErrorAddendum() {\n if (ReactCurrentOwner.current) {\n var name = getComponentNameFromType(ReactCurrentOwner.current.type);\n\n if (name) {\n return '\\n\\nCheck the render method of `' + name + '`.';\n }\n }\n\n return '';\n}\n\nfunction getSourceInfoErrorAddendum(source) {\n if (source !== undefined) {\n var fileName = source.fileName.replace(/^.*[\\\\\\/]/, '');\n var lineNumber = source.lineNumber;\n return '\\n\\nCheck your code at ' + fileName + ':' + lineNumber + '.';\n }\n\n return '';\n}\n\nfunction getSourceInfoErrorAddendumForProps(elementProps) {\n if (elementProps !== null && elementProps !== undefined) {\n return getSourceInfoErrorAddendum(elementProps.__source);\n }\n\n return '';\n}\n/**\n * Warn if there's no key explicitly set on dynamic arrays of children or\n * object keys are not valid. This allows us to keep track of children between\n * updates.\n */\n\n\nvar ownerHasKeyUseWarning = {};\n\nfunction getCurrentComponentErrorInfo(parentType) {\n var info = getDeclarationErrorAddendum();\n\n if (!info) {\n var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name;\n\n if (parentName) {\n info = \"\\n\\nCheck the top-level render call using <\" + parentName + \">.\";\n }\n }\n\n return info;\n}\n/**\n * Warn if the element doesn't have an explicit key assigned to it.\n * This element is in an array. The array could grow and shrink or be\n * reordered. All children that haven't already been validated are required to\n * have a \"key\" property assigned to it. Error statuses are cached so a warning\n * will only be shown once.\n *\n * @internal\n * @param {ReactElement} element Element that requires a key.\n * @param {*} parentType element's parent's type.\n */\n\n\nfunction validateExplicitKey(element, parentType) {\n if (!element._store || element._store.validated || element.key != null) {\n return;\n }\n\n element._store.validated = true;\n var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType);\n\n if (ownerHasKeyUseWarning[currentComponentErrorInfo]) {\n return;\n }\n\n ownerHasKeyUseWarning[currentComponentErrorInfo] = true; // Usually the current owner is the offender, but if it accepts children as a\n // property, it may be the creator of the child that's responsible for\n // assigning it a key.\n\n var childOwner = '';\n\n if (element && element._owner && element._owner !== ReactCurrentOwner.current) {\n // Give the component that originally created this child.\n childOwner = \" It was passed a child from \" + getComponentNameFromType(element._owner.type) + \".\";\n }\n\n {\n setCurrentlyValidatingElement$1(element);\n\n error('Each child in a list should have a unique \"key\" prop.' + '%s%s See https://reactjs.org/link/warning-keys for more information.', currentComponentErrorInfo, childOwner);\n\n setCurrentlyValidatingElement$1(null);\n }\n}\n/**\n * Ensure that every element either is passed in a static location, in an\n * array with an explicit keys property defined, or in an object literal\n * with valid key property.\n *\n * @internal\n * @param {ReactNode} node Statically passed child of any type.\n * @param {*} parentType node's parent's type.\n */\n\n\nfunction validateChildKeys(node, parentType) {\n if (typeof node !== 'object') {\n return;\n }\n\n if (isArray(node)) {\n for (var i = 0; i < node.length; i++) {\n var child = node[i];\n\n if (isValidElement(child)) {\n validateExplicitKey(child, parentType);\n }\n }\n } else if (isValidElement(node)) {\n // This element was passed in a valid location.\n if (node._store) {\n node._store.validated = true;\n }\n } else if (node) {\n var iteratorFn = getIteratorFn(node);\n\n if (typeof iteratorFn === 'function') {\n // Entry iterators used to provide implicit keys,\n // but now we print a separate warning for them later.\n if (iteratorFn !== node.entries) {\n var iterator = iteratorFn.call(node);\n var step;\n\n while (!(step = iterator.next()).done) {\n if (isValidElement(step.value)) {\n validateExplicitKey(step.value, parentType);\n }\n }\n }\n }\n }\n}\n/**\n * Given an element, validate that its props follow the propTypes definition,\n * provided by the type.\n *\n * @param {ReactElement} element\n */\n\n\nfunction validatePropTypes(element) {\n {\n var type = element.type;\n\n if (type === null || type === undefined || typeof type === 'string') {\n return;\n }\n\n var propTypes;\n\n if (typeof type === 'function') {\n propTypes = type.propTypes;\n } else if (typeof type === 'object' && (type.$$typeof === REACT_FORWARD_REF_TYPE || // Note: Memo only checks outer props here.\n // Inner props are checked in the reconciler.\n type.$$typeof === REACT_MEMO_TYPE)) {\n propTypes = type.propTypes;\n } else {\n return;\n }\n\n if (propTypes) {\n // Intentionally inside to avoid triggering lazy initializers:\n var name = getComponentNameFromType(type);\n checkPropTypes(propTypes, element.props, 'prop', name, element);\n } else if (type.PropTypes !== undefined && !propTypesMisspellWarningShown) {\n propTypesMisspellWarningShown = true; // Intentionally inside to avoid triggering lazy initializers:\n\n var _name = getComponentNameFromType(type);\n\n error('Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?', _name || 'Unknown');\n }\n\n if (typeof type.getDefaultProps === 'function' && !type.getDefaultProps.isReactClassApproved) {\n error('getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.');\n }\n }\n}\n/**\n * Given a fragment, validate that it can only be provided with fragment props\n * @param {ReactElement} fragment\n */\n\n\nfunction validateFragmentProps(fragment) {\n {\n var keys = Object.keys(fragment.props);\n\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n\n if (key !== 'children' && key !== 'key') {\n setCurrentlyValidatingElement$1(fragment);\n\n error('Invalid prop `%s` supplied to `React.Fragment`. ' + 'React.Fragment can only have `key` and `children` props.', key);\n\n setCurrentlyValidatingElement$1(null);\n break;\n }\n }\n\n if (fragment.ref !== null) {\n setCurrentlyValidatingElement$1(fragment);\n\n error('Invalid attribute `ref` supplied to `React.Fragment`.');\n\n setCurrentlyValidatingElement$1(null);\n }\n }\n}\nfunction createElementWithValidation(type, props, children) {\n var validType = isValidElementType(type); // We warn in this case but don't throw. We expect the element creation to\n // succeed and there will likely be errors in render.\n\n if (!validType) {\n var info = '';\n\n if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) {\n info += ' You likely forgot to export your component from the file ' + \"it's defined in, or you might have mixed up default and named imports.\";\n }\n\n var sourceInfo = getSourceInfoErrorAddendumForProps(props);\n\n if (sourceInfo) {\n info += sourceInfo;\n } else {\n info += getDeclarationErrorAddendum();\n }\n\n var typeString;\n\n if (type === null) {\n typeString = 'null';\n } else if (isArray(type)) {\n typeString = 'array';\n } else if (type !== undefined && type.$$typeof === REACT_ELEMENT_TYPE) {\n typeString = \"<\" + (getComponentNameFromType(type.type) || 'Unknown') + \" />\";\n info = ' Did you accidentally export a JSX literal instead of a component?';\n } else {\n typeString = typeof type;\n }\n\n {\n error('React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', typeString, info);\n }\n }\n\n var element = createElement.apply(this, arguments); // The result can be nullish if a mock or a custom function is used.\n // TODO: Drop this when these are no longer allowed as the type argument.\n\n if (element == null) {\n return element;\n } // Skip key warning if the type isn't valid since our key validation logic\n // doesn't expect a non-string/function type and can throw confusing errors.\n // We don't want exception behavior to differ between dev and prod.\n // (Rendering will throw with a helpful message and as soon as the type is\n // fixed, the key warnings will appear.)\n\n\n if (validType) {\n for (var i = 2; i < arguments.length; i++) {\n validateChildKeys(arguments[i], type);\n }\n }\n\n if (type === REACT_FRAGMENT_TYPE) {\n validateFragmentProps(element);\n } else {\n validatePropTypes(element);\n }\n\n return element;\n}\nvar didWarnAboutDeprecatedCreateFactory = false;\nfunction createFactoryWithValidation(type) {\n var validatedFactory = createElementWithValidation.bind(null, type);\n validatedFactory.type = type;\n\n {\n if (!didWarnAboutDeprecatedCreateFactory) {\n didWarnAboutDeprecatedCreateFactory = true;\n\n warn('React.createFactory() is deprecated and will be removed in ' + 'a future major release. Consider using JSX ' + 'or use React.createElement() directly instead.');\n } // Legacy hook: remove it\n\n\n Object.defineProperty(validatedFactory, 'type', {\n enumerable: false,\n get: function () {\n warn('Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.');\n\n Object.defineProperty(this, 'type', {\n value: type\n });\n return type;\n }\n });\n }\n\n return validatedFactory;\n}\nfunction cloneElementWithValidation(element, props, children) {\n var newElement = cloneElement.apply(this, arguments);\n\n for (var i = 2; i < arguments.length; i++) {\n validateChildKeys(arguments[i], newElement.type);\n }\n\n validatePropTypes(newElement);\n return newElement;\n}\n\nfunction startTransition(scope, options) {\n var prevTransition = ReactCurrentBatchConfig.transition;\n ReactCurrentBatchConfig.transition = {};\n var currentTransition = ReactCurrentBatchConfig.transition;\n\n {\n ReactCurrentBatchConfig.transition._updatedFibers = new Set();\n }\n\n try {\n scope();\n } finally {\n ReactCurrentBatchConfig.transition = prevTransition;\n\n {\n if (prevTransition === null && currentTransition._updatedFibers) {\n var updatedFibersCount = currentTransition._updatedFibers.size;\n\n if (updatedFibersCount > 10) {\n warn('Detected a large number of updates inside startTransition. ' + 'If this is due to a subscription please re-write it to use React provided hooks. ' + 'Otherwise concurrent mode guarantees are off the table.');\n }\n\n currentTransition._updatedFibers.clear();\n }\n }\n }\n}\n\nvar didWarnAboutMessageChannel = false;\nvar enqueueTaskImpl = null;\nfunction enqueueTask(task) {\n if (enqueueTaskImpl === null) {\n try {\n // read require off the module object to get around the bundlers.\n // we don't want them to detect a require and bundle a Node polyfill.\n var requireString = ('require' + Math.random()).slice(0, 7);\n var nodeRequire = module && module[requireString]; // assuming we're in node, let's try to get node's\n // version of setImmediate, bypassing fake timers if any.\n\n enqueueTaskImpl = nodeRequire.call(module, 'timers').setImmediate;\n } catch (_err) {\n // we're in a browser\n // we can't use regular timers because they may still be faked\n // so we try MessageChannel+postMessage instead\n enqueueTaskImpl = function (callback) {\n {\n if (didWarnAboutMessageChannel === false) {\n didWarnAboutMessageChannel = true;\n\n if (typeof MessageChannel === 'undefined') {\n error('This browser does not have a MessageChannel implementation, ' + 'so enqueuing tasks via await act(async () => ...) will fail. ' + 'Please file an issue at https://github.com/facebook/react/issues ' + 'if you encounter this warning.');\n }\n }\n }\n\n var channel = new MessageChannel();\n channel.port1.onmessage = callback;\n channel.port2.postMessage(undefined);\n };\n }\n }\n\n return enqueueTaskImpl(task);\n}\n\nvar actScopeDepth = 0;\nvar didWarnNoAwaitAct = false;\nfunction act(callback) {\n {\n // `act` calls can be nested, so we track the depth. This represents the\n // number of `act` scopes on the stack.\n var prevActScopeDepth = actScopeDepth;\n actScopeDepth++;\n\n if (ReactCurrentActQueue.current === null) {\n // This is the outermost `act` scope. Initialize the queue. The reconciler\n // will detect the queue and use it instead of Scheduler.\n ReactCurrentActQueue.current = [];\n }\n\n var prevIsBatchingLegacy = ReactCurrentActQueue.isBatchingLegacy;\n var result;\n\n try {\n // Used to reproduce behavior of `batchedUpdates` in legacy mode. Only\n // set to `true` while the given callback is executed, not for updates\n // triggered during an async event, because this is how the legacy\n // implementation of `act` behaved.\n ReactCurrentActQueue.isBatchingLegacy = true;\n result = callback(); // Replicate behavior of original `act` implementation in legacy mode,\n // which flushed updates immediately after the scope function exits, even\n // if it's an async function.\n\n if (!prevIsBatchingLegacy && ReactCurrentActQueue.didScheduleLegacyUpdate) {\n var queue = ReactCurrentActQueue.current;\n\n if (queue !== null) {\n ReactCurrentActQueue.didScheduleLegacyUpdate = false;\n flushActQueue(queue);\n }\n }\n } catch (error) {\n popActScope(prevActScopeDepth);\n throw error;\n } finally {\n ReactCurrentActQueue.isBatchingLegacy = prevIsBatchingLegacy;\n }\n\n if (result !== null && typeof result === 'object' && typeof result.then === 'function') {\n var thenableResult = result; // The callback is an async function (i.e. returned a promise). Wait\n // for it to resolve before exiting the current scope.\n\n var wasAwaited = false;\n var thenable = {\n then: function (resolve, reject) {\n wasAwaited = true;\n thenableResult.then(function (returnValue) {\n popActScope(prevActScopeDepth);\n\n if (actScopeDepth === 0) {\n // We've exited the outermost act scope. Recursively flush the\n // queue until there's no remaining work.\n recursivelyFlushAsyncActWork(returnValue, resolve, reject);\n } else {\n resolve(returnValue);\n }\n }, function (error) {\n // The callback threw an error.\n popActScope(prevActScopeDepth);\n reject(error);\n });\n }\n };\n\n {\n if (!didWarnNoAwaitAct && typeof Promise !== 'undefined') {\n // eslint-disable-next-line no-undef\n Promise.resolve().then(function () {}).then(function () {\n if (!wasAwaited) {\n didWarnNoAwaitAct = true;\n\n error('You called act(async () => ...) without await. ' + 'This could lead to unexpected testing behaviour, ' + 'interleaving multiple act calls and mixing their ' + 'scopes. ' + 'You should - await act(async () => ...);');\n }\n });\n }\n }\n\n return thenable;\n } else {\n var returnValue = result; // The callback is not an async function. Exit the current scope\n // immediately, without awaiting.\n\n popActScope(prevActScopeDepth);\n\n if (actScopeDepth === 0) {\n // Exiting the outermost act scope. Flush the queue.\n var _queue = ReactCurrentActQueue.current;\n\n if (_queue !== null) {\n flushActQueue(_queue);\n ReactCurrentActQueue.current = null;\n } // Return a thenable. If the user awaits it, we'll flush again in\n // case additional work was scheduled by a microtask.\n\n\n var _thenable = {\n then: function (resolve, reject) {\n // Confirm we haven't re-entered another `act` scope, in case\n // the user does something weird like await the thenable\n // multiple times.\n if (ReactCurrentActQueue.current === null) {\n // Recursively flush the queue until there's no remaining work.\n ReactCurrentActQueue.current = [];\n recursivelyFlushAsyncActWork(returnValue, resolve, reject);\n } else {\n resolve(returnValue);\n }\n }\n };\n return _thenable;\n } else {\n // Since we're inside a nested `act` scope, the returned thenable\n // immediately resolves. The outer scope will flush the queue.\n var _thenable2 = {\n then: function (resolve, reject) {\n resolve(returnValue);\n }\n };\n return _thenable2;\n }\n }\n }\n}\n\nfunction popActScope(prevActScopeDepth) {\n {\n if (prevActScopeDepth !== actScopeDepth - 1) {\n error('You seem to have overlapping act() calls, this is not supported. ' + 'Be sure to await previous act() calls before making a new one. ');\n }\n\n actScopeDepth = prevActScopeDepth;\n }\n}\n\nfunction recursivelyFlushAsyncActWork(returnValue, resolve, reject) {\n {\n var queue = ReactCurrentActQueue.current;\n\n if (queue !== null) {\n try {\n flushActQueue(queue);\n enqueueTask(function () {\n if (queue.length === 0) {\n // No additional work was scheduled. Finish.\n ReactCurrentActQueue.current = null;\n resolve(returnValue);\n } else {\n // Keep flushing work until there's none left.\n recursivelyFlushAsyncActWork(returnValue, resolve, reject);\n }\n });\n } catch (error) {\n reject(error);\n }\n } else {\n resolve(returnValue);\n }\n }\n}\n\nvar isFlushing = false;\n\nfunction flushActQueue(queue) {\n {\n if (!isFlushing) {\n // Prevent re-entrance.\n isFlushing = true;\n var i = 0;\n\n try {\n for (; i < queue.length; i++) {\n var callback = queue[i];\n\n do {\n callback = callback(true);\n } while (callback !== null);\n }\n\n queue.length = 0;\n } catch (error) {\n // If something throws, leave the remaining callbacks on the queue.\n queue = queue.slice(i + 1);\n throw error;\n } finally {\n isFlushing = false;\n }\n }\n }\n}\n\nvar createElement$1 = createElementWithValidation ;\nvar cloneElement$1 = cloneElementWithValidation ;\nvar createFactory = createFactoryWithValidation ;\nvar Children = {\n map: mapChildren,\n forEach: forEachChildren,\n count: countChildren,\n toArray: toArray,\n only: onlyChild\n};\n\nexports.Children = Children;\nexports.Component = Component;\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.Profiler = REACT_PROFILER_TYPE;\nexports.PureComponent = PureComponent;\nexports.StrictMode = REACT_STRICT_MODE_TYPE;\nexports.Suspense = REACT_SUSPENSE_TYPE;\nexports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = ReactSharedInternals;\nexports.cloneElement = cloneElement$1;\nexports.createContext = createContext;\nexports.createElement = createElement$1;\nexports.createFactory = createFactory;\nexports.createRef = createRef;\nexports.forwardRef = forwardRef;\nexports.isValidElement = isValidElement;\nexports.lazy = lazy;\nexports.memo = memo;\nexports.startTransition = startTransition;\nexports.unstable_act = act;\nexports.useCallback = useCallback;\nexports.useContext = useContext;\nexports.useDebugValue = useDebugValue;\nexports.useDeferredValue = useDeferredValue;\nexports.useEffect = useEffect;\nexports.useId = useId;\nexports.useImperativeHandle = useImperativeHandle;\nexports.useInsertionEffect = useInsertionEffect;\nexports.useLayoutEffect = useLayoutEffect;\nexports.useMemo = useMemo;\nexports.useReducer = useReducer;\nexports.useRef = useRef;\nexports.useState = useState;\nexports.useSyncExternalStore = useSyncExternalStore;\nexports.useTransition = useTransition;\nexports.version = ReactVersion;\n /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\nif (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' &&\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop ===\n 'function'\n) {\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error());\n}\n \n })();\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvcmVhY3QvY2pzL3JlYWN0LmRldmVsb3BtZW50LmpzLmpzIiwibWFwcGluZ3MiOiI7QUFBQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRWE7O0FBRWIsSUFBSSxJQUFxQztBQUN6Qzs7QUFFQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFZO0FBQ1o7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFZO0FBQ1o7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQ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UHJvdmlkZXInO1xuXG4gICAgICBjYXNlIFJFQUNUX0ZPUldBUkRfUkVGX1RZUEU6XG4gICAgICAgIHJldHVybiBnZXRXcmFwcGVkTmFtZSh0eXBlLCB0eXBlLnJlbmRlciwgJ0ZvcndhcmRSZWYnKTtcblxuICAgICAgY2FzZSBSRUFDVF9NRU1PX1RZUEU6XG4gICAgICAgIHZhciBvdXRlck5hbWUgPSB0eXBlLmRpc3BsYXlOYW1lIHx8IG51bGw7XG5cbiAgICAgICAgaWYgKG91dGVyTmFtZSAhPT0gbnVsbCkge1xuICAgICAgICAgIHJldHVybiBvdXRlck5hbWU7XG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZ2V0Q29tcG9uZW50TmFtZUZyb21UeXBlKHR5cGUudHlwZSkgfHwgJ01lbW8nO1xuXG4gICAgICBjYXNlIFJFQUNUX0xBWllfVFlQRTpcbiAgICAgICAge1xuICAgICAgICAgIHZhciBsYXp5Q29tcG9uZW50ID0gdHlwZTtcbiAgICAgICAgICB2YXIgcGF5bG9hZCA9IGxhenlDb21wb25lbnQuX3BheWxvYWQ7XG4gICAgICAgICAgdmFyIGluaXQgPSBsYXp5Q29tcG9uZW50Ll9pbml0O1xuXG4gICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgIHJldHVybiBnZXRDb21wb25lbnROYW1lRnJvbVR5cGUoaW5pdChwYXlsb2FkKSk7XG4gICAgICAgICAgfSBjYXRjaCAoeCkge1xuICAgICAgICAgICAgcmV0dXJuIG51bGw7XG4gICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgIC8vIGVzbGludC1kaXNhYmxlLW5leHQtbGluZSBuby1mYWxsdGhyb3VnaFxuICAgIH1cbiAgfVxuXG4gIHJldHVybiBudWxsO1xufVxuXG52YXIgaGFzT3duUHJvcGVydHkgPSBPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5O1xuXG52YXIgUkVTRVJWRURfUFJPUFMgPSB7XG4gIGtleTogdHJ1ZSxcb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ZvciBpdCB0byByZXNvbHZlIGJlZm9yZSBleGl0aW5nIHRoZSBjdXJyZW50IHNjb3BlLlxuXG4gICAgICB2YXIgd2FzQXdhaXRlZCA9IGZhbHNlO1xuICAgICAgdmFyIHRoZW5hYmxlID0ge1xuICAgICAgICB0aGVuOiBmdW5jdGlvbiAocmVzb2x2ZSwgcmVqZWN0KSB7XG4gICAgICAgICAgd2FzQXdhaXRlZCA9IHRydWU7XG4gICAgICAgICAgdGhlbmFibGVSZXN1bHQudGhlbihmdW5jdGlvbiAocmV0dXJuVmFsdWUpIHtcbiAgICAgICAgICAgIHBvcEFjdFNjb3BlKHByZXZBY3RTY29wZURlcHRoKTtcblxuICAgICAgICAgICAgaWYgKGFjdFNjb3BlRGVwdGggPT09IDApIHtcbiAgICAgICAgICAgICAgLy8gV2UndmUgZXhpdGVkIHRoZSBvdXRlcm1vc3QgYWN0IHNjb3BlLiBSZWN1cnNpdmVseSBmbHVzaCB0aGVcbiAgICAgICAgICAgICAgLy8gcXVldWUgdW50aWwgdGhlcmUncyBubyByZW1haW5pbmcgd29yay5cbiAgICAgICAgICAgICAgcmVjdXJzaXZlbHlGbHVzaEFzeW5jQWN0V29yayhyZXR1cm5WYWx1ZSwgcmVzb2x2ZSwgcmVqZWN0KTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgIHJlc29sdmUocmV0dXJuVmFsdWUpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgIH0sIGZ1bmN0aW9uIChlcnJvcikge1xuICAgICAgICAgICAgLy8gVGhlIGNhbGxiYWNrIHRocmV3IGFuIGVycm9yLlxuICAgICAgICAgICAgcG9wQWN0U2NvcGUocHJldkFjdFNjb3BlRGVwdGgpO1xuICAgICAgICAgICAgcmVqZWN0KGVycm9yKTtcbiAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgICAgfTtcblxuICAgICAge1xuICAgICAgICBpZiAoIWRpZFdhcm5Ob0F3YWl0QWN0ICYmIHR5cGVvZi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SgpO1xufVxuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/react/cjs/react.development.js\n")); + +/***/ }), + +/***/ "./node_modules/react/index.js": +/*!*************************************!*\ + !*** ./node_modules/react/index.js ***! + \*************************************/ +/***/ (function(module, __unused_webpack_exports, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("\n\nif (false) {} else {\n module.exports = __webpack_require__(/*! ./cjs/react.development.js */ \"./node_modules/react/cjs/react.development.js\");\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvcmVhY3QvaW5kZXguanMuanMiLCJtYXBwaW5ncyI6IkFBQWE7O0FBRWIsSUFBSSxLQUFxQyxFQUFFLEVBRTFDLENBQUM7QUFDRixFQUFFLHVIQUFzRDtBQUN4RCIsInNvdXJjZXMiOlsid2VicGFjazovL19OX0UvLi9ub2RlX21vZHVsZXMvcmVhY3QvaW5kZXguanM/MWZiMiJdLCJzb3VyY2VzQ29udGVudCI6WyIndXNlIHN0cmljdCc7XG5cbmlmIChwcm9jZXNzLmVudi5OT0RFX0VOViA9PT0gJ3Byb2R1Y3Rpb24nKSB7XG4gIG1vZHVsZS5leHBvcnRzID0gcmVxdWlyZSgnLi9janMvcmVhY3QucHJvZHVjdGlvbi5taW4uanMnKTtcbn0gZWxzZSB7XG4gIG1vZHVsZS5leHBvcnRzID0gcmVxdWlyZSgnLi9janMvcmVhY3QuZGV2ZWxvcG1lbnQuanMnKTtcbn1cbiJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///./node_modules/react/index.js\n")); + +/***/ }), + +/***/ "?506d": +/*!******************************************!*\ + !*** ./utils/resolve-rewrites (ignored) ***! + \******************************************/ +/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) { + +/* (ignored) */ + +/***/ }), + +/***/ "./node_modules/tslib/tslib.es6.mjs": +/*!******************************************!*\ + !*** ./node_modules/tslib/tslib.es6.mjs ***! + \******************************************/ +/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) { + +"use strict"; +eval(__webpack_require__.ts("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"__addDisposableResource\": function() { return /* binding */ __addDisposableResource; },\n/* harmony export */ \"__assign\": function() { return /* binding */ __assign; },\n/* harmony export */ \"__asyncDelegator\": function() { return /* binding */ __asyncDelegator; },\n/* harmony export */ \"__asyncGenerator\": function() { return /* binding */ __asyncGenerator; },\n/* harmony export */ \"__asyncValues\": function() { return /* binding */ __asyncValues; },\n/* harmony export */ \"__await\": function() { return /* binding */ __await; },\n/* harmony export */ \"__awaiter\": function() { return /* binding */ __awaiter; },\n/* harmony export */ \"__classPrivateFieldGet\": function() { return /* binding */ __classPrivateFieldGet; },\n/* harmony export */ \"__classPrivateFieldIn\": function() { return /* binding */ __classPrivateFieldIn; },\n/* harmony export */ \"__classPrivateFieldSet\": function() { return /* binding */ __classPrivateFieldSet; },\n/* harmony export */ \"__createBinding\": function() { return /* binding */ __createBinding; },\n/* harmony export */ \"__decorate\": function() { return /* binding */ __decorate; },\n/* harmony export */ \"__disposeResources\": function() { return /* binding */ __disposeResources; },\n/* harmony export */ \"__esDecorate\": function() { return /* binding */ __esDecorate; },\n/* harmony export */ \"__exportStar\": function() { return /* binding */ __exportStar; },\n/* harmony export */ \"__extends\": function() { return /* binding */ __extends; },\n/* harmony export */ \"__generator\": function() { return /* binding */ __generator; },\n/* harmony export */ \"__importDefault\": function() { return /* binding */ __importDefault; },\n/* harmony export */ \"__importStar\": function() { return /* binding */ __importStar; },\n/* harmony export */ \"__makeTemplateObject\": function() { return /* binding */ __makeTemplateObject; },\n/* harmony export */ \"__metadata\": function() { return /* binding */ __metadata; },\n/* harmony export */ \"__param\": function() { return /* binding */ __param; },\n/* harmony export */ \"__propKey\": function() { return /* binding */ __propKey; },\n/* harmony export */ \"__read\": function() { return /* binding */ __read; },\n/* harmony export */ \"__rest\": function() { return /* binding */ __rest; },\n/* harmony export */ \"__runInitializers\": function() { return /* binding */ __runInitializers; },\n/* harmony export */ \"__setFunctionName\": function() { return /* binding */ __setFunctionName; },\n/* harmony export */ \"__spread\": function() { return /* binding */ __spread; },\n/* harmony export */ \"__spreadArray\": function() { return /* binding */ __spreadArray; },\n/* harmony export */ \"__spreadArrays\": function() { return /* binding */ __spreadArrays; },\n/* harmony export */ \"__values\": function() { return /* binding */ __values; }\n/* harmony export */ });\n/******************************************************************************\nCopyright (c) Microsoft Corporation.\n\nPermission to use, copy, modify, and/or distribute this software for any\npurpose with or without fee is hereby granted.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\nPERFORMANCE OF THIS SOFTWARE.\n***************************************************************************** */\n/* global Reflect, Promise, SuppressedError, Symbol */\n\nvar extendStatics = function(d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n};\n\nfunction __extends(d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n}\n\nvar __assign = function() {\n __assign = Object.assign || function __assign(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\n }\n return t;\n }\n return __assign.apply(this, arguments);\n}\n\nfunction __rest(s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\n t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\n t[p[i]] = s[p[i]];\n }\n return t;\n}\n\nfunction __decorate(decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n}\n\nfunction __param(paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n}\n\nfunction __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {\n function accept(f) { if (f !== void 0 && typeof f !== \"function\") throw new TypeError(\"Function expected\"); return f; }\n var kind = contextIn.kind, key = kind === \"getter\" ? \"get\" : kind === \"setter\" ? \"set\" : \"value\";\n var target = !descriptorIn && ctor ? contextIn[\"static\"] ? ctor : ctor.prototype : null;\n var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});\n var _, done = false;\n for (var i = decorators.length - 1; i >= 0; i--) {\n var context = {};\n for (var p in contextIn) context[p] = p === \"access\" ? {} : contextIn[p];\n for (var p in contextIn.access) context.access[p] = contextIn.access[p];\n context.addInitializer = function (f) { if (done) throw new TypeError(\"Cannot add initializers after decoration has completed\"); extraInitializers.push(accept(f || null)); };\n var result = (0, decorators[i])(kind === \"accessor\" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);\n if (kind === \"accessor\") {\n if (result === void 0) continue;\n if (result === null || typeof result !== \"object\") throw new TypeError(\"Object expected\");\n if (_ = accept(result.get)) descriptor.get = _;\n if (_ = accept(result.set)) descriptor.set = _;\n if (_ = accept(result.init)) initializers.unshift(_);\n }\n else if (_ = accept(result)) {\n if (kind === \"field\") initializers.unshift(_);\n else descriptor[key] = _;\n }\n }\n if (target) Object.defineProperty(target, contextIn.name, descriptor);\n done = true;\n};\n\nfunction __runInitializers(thisArg, initializers, value) {\n var useValue = arguments.length > 2;\n for (var i = 0; i < initializers.length; i++) {\n value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);\n }\n return useValue ? value : void 0;\n};\n\nfunction __propKey(x) {\n return typeof x === \"symbol\" ? x : \"\".concat(x);\n};\n\nfunction __setFunctionName(f, name, prefix) {\n if (typeof name === \"symbol\") name = name.description ? \"[\".concat(name.description, \"]\") : \"\";\n return Object.defineProperty(f, \"name\", { configurable: true, value: prefix ? \"\".concat(prefix, \" \", name) : name });\n};\n\nfunction __metadata(metadataKey, metadataValue) {\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\n}\n\nfunction __awaiter(thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n}\n\nfunction __generator(thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (g && (g = 0, op[0] && (_ = 0)), _) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n}\n\nvar __createBinding = Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n});\n\nfunction __exportStar(m, o) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\n}\n\nfunction __values(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n}\n\nfunction __read(o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n}\n\n/** @deprecated */\nfunction __spread() {\n for (var ar = [], i = 0; i < arguments.length; i++)\n ar = ar.concat(__read(arguments[i]));\n return ar;\n}\n\n/** @deprecated */\nfunction __spreadArrays() {\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n r[k] = a[j];\n return r;\n}\n\nfunction __spreadArray(to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n}\n\nfunction __await(v) {\n return this instanceof __await ? (this.v = v, this) : new __await(v);\n}\n\nfunction __asyncGenerator(thisArg, _arguments, generator) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\n function fulfill(value) { resume(\"next\", value); }\n function reject(value) { resume(\"throw\", value); }\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\n}\n\nfunction __asyncDelegator(o) {\n var i, p;\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v; } : f; }\n}\n\nfunction __asyncValues(o) {\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n var m = o[Symbol.asyncIterator], i;\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\n}\n\nfunction __makeTemplateObject(cooked, raw) {\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\n return cooked;\n};\n\nvar __setModuleDefault = Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n};\n\nfunction __importStar(mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n}\n\nfunction __importDefault(mod) {\n return (mod && mod.__esModule) ? mod : { default: mod };\n}\n\nfunction __classPrivateFieldGet(receiver, state, kind, f) {\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\n}\n\nfunction __classPrivateFieldSet(receiver, state, value, kind, f) {\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\n}\n\nfunction __classPrivateFieldIn(state, receiver) {\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\n}\n\nfunction __addDisposableResource(env, value, async) {\n if (value !== null && value !== void 0) {\n if (typeof value !== \"object\" && typeof value !== \"function\") throw new TypeError(\"Object expected.\");\n var dispose;\n if (async) {\n if (!Symbol.asyncDispose) throw new TypeError(\"Symbol.asyncDispose is not defined.\");\n dispose = value[Symbol.asyncDispose];\n }\n if (dispose === void 0) {\n if (!Symbol.dispose) throw new TypeError(\"Symbol.dispose is not defined.\");\n dispose = value[Symbol.dispose];\n }\n if (typeof dispose !== \"function\") throw new TypeError(\"Object not disposable.\");\n env.stack.push({ value: value, dispose: dispose, async: async });\n }\n else if (async) {\n env.stack.push({ async: true });\n }\n return value;\n}\n\nvar _SuppressedError = typeof SuppressedError === \"function\" ? SuppressedError : function (error, suppressed, message) {\n var e = new Error(message);\n return e.name = \"SuppressedError\", e.error = error, e.suppressed = suppressed, e;\n};\n\nfunction __disposeResources(env) {\n function fail(e) {\n env.error = env.hasError ? new _SuppressedError(e, env.error, \"An error was suppressed during disposal.\") : e;\n env.hasError = true;\n }\n function next() {\n while (env.stack.length) {\n var rec = env.stack.pop();\n try {\n var result = rec.dispose && rec.dispose.call(rec.value);\n if (rec.async) return Promise.resolve(result).then(next, function(e) { fail(e); return next(); });\n }\n catch (e) {\n fail(e);\n }\n }\n if (env.hasError) throw env.error;\n }\n return next();\n}\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n __extends,\n __assign,\n __rest,\n __decorate,\n __param,\n __metadata,\n __awaiter,\n __generator,\n __createBinding,\n __exportStar,\n __values,\n __read,\n __spread,\n __spreadArrays,\n __spreadArray,\n __await,\n __asyncGenerator,\n __asyncDelegator,\n __asyncValues,\n __makeTemplateObject,\n __importStar,\n __importDefault,\n __classPrivateFieldGet,\n __classPrivateFieldSet,\n __classPrivateFieldIn,\n __addDisposableResource,\n __disposeResources,\n});\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiLi9ub2RlX21vZHVsZXMvdHNsaWIvdHNsaWIuZXM2Lm1qcy5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7O0FBQUE7QUFDQTs7QUFFQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0EsU0FBUyxnQkFBZ0Isc0NBQXNDLGtCQUFrQjtBQUNqRix3QkFBd0I7QUFDeEI7QUFDQTs7QUFFTztBQUNQO0FBQ0E7QUFDQTtBQUNBLGtCQUFrQjtBQUNsQjtBQUNBOztBQUVPO0FBQ1A7QUFDQSwrQ0FBK0MsT0FBTztBQUN0RDtBQ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NvdXJjZXMsXG59O1xuIl0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./node_modules/tslib/tslib.es6.mjs\n")); + +/***/ }) + +}, +/******/ function(__webpack_require__) { // webpackRuntimeModules +/******/ var __webpack_exec__ = function(moduleId) { return __webpack_require__(__webpack_require__.s = moduleId); } +/******/ var __webpack_exports__ = (__webpack_exec__("./node_modules/next/dist/client/dev/amp-dev.js")); +/******/ _N_E = __webpack_exports__; +/******/ } +]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/ed150ef9-713e0b995a8779c6.js b/dsql-app/.local_dist/static/chunks/ed150ef9-713e0b995a8779c6.js new file mode 100644 index 0000000..77f6a2c --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/ed150ef9-713e0b995a8779c6.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6142],{12320:function(e){var t;self,t=()=>(()=>{"use strict";var e={4567:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.AccessibilityManager=void 0;const n=i(9042),o=i(6114),a=i(9924),h=i(844),c=i(5596),l=i(4725),d=i(3656);let _=t.AccessibilityManager=class extends h.Disposable{constructor(e,t){super(),this._terminal=e,this._renderService=t,this._liveRegionLineCount=0,this._charsToConsume=[],this._charsToAnnounce="",this._accessibilityContainer=document.createElement("div"),this._accessibilityContainer.classList.add("xterm-accessibility"),this._rowContainer=document.createElement("div"),this._rowContainer.setAttribute("role","list"),this._rowContainer.classList.add("xterm-accessibility-tree"),this._rowElements=[];for(let i=0;ithis._handleBoundaryFocus(e,0),this._bottomBoundaryFocusListener=e=>this._handleBoundaryFocus(e,1),this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions(),this._accessibilityContainer.appendChild(this._rowContainer),this._liveRegion=document.createElement("div"),this._liveRegion.classList.add("live-region"),this._liveRegion.setAttribute("aria-live","assertive"),this._accessibilityContainer.appendChild(this._liveRegion),this._liveRegionDebouncer=this.register(new a.TimeBasedDebouncer(this._renderRows.bind(this))),!this._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");this._terminal.element.insertAdjacentElement("afterbegin",this._accessibilityContainer),this.register(this._terminal.onResize((e=>this._handleResize(e.rows)))),this.register(this._terminal.onRender((e=>this._refreshRows(e.start,e.end)))),this.register(this._terminal.onScroll((()=>this._refreshRows()))),this.register(this._terminal.onA11yChar((e=>this._handleChar(e)))),this.register(this._terminal.onLineFeed((()=>this._handleChar("\n")))),this.register(this._terminal.onA11yTab((e=>this._handleTab(e)))),this.register(this._terminal.onKey((e=>this._handleKey(e.key)))),this.register(this._terminal.onBlur((()=>this._clearLiveRegion()))),this.register(this._renderService.onDimensionsChange((()=>this._refreshRowsDimensions()))),this._screenDprMonitor=new c.ScreenDprMonitor(window),this.register(this._screenDprMonitor),this._screenDprMonitor.setListener((()=>this._refreshRowsDimensions())),this.register((0,d.addDisposableDomListener)(window,"resize",(()=>this._refreshRowsDimensions()))),this._refreshRows(),this.register((0,h.toDisposable)((()=>{this._accessibilityContainer.remove(),this._rowElements.length=0})))}_handleTab(e){for(let t=0;t0?this._charsToConsume.shift()!==e&&(this._charsToAnnounce+=e):this._charsToAnnounce+=e,"\n"===e&&(this._liveRegionLineCount++,21===this._liveRegionLineCount&&(this._liveRegion.textContent+=n.tooMuchOutput)),o.isMac&&this._liveRegion.textContent&&this._liveRegion.textContent.length>0&&!this._liveRegion.parentNode&&setTimeout((()=>{this._accessibilityContainer.appendChild(this._liveRegion)}),0))}_clearLiveRegion(){this._liveRegion.textContent="",this._liveRegionLineCount=0,o.isMac&&this._liveRegion.remove()}_handleKey(e){this._clearLiveRegion(),/\p{Control}/u.test(e)||this._charsToConsume.push(e)}_refreshRows(e,t){this._liveRegionDebouncer.refresh(e,t,this._terminal.rows)}_renderRows(e,t){const i=this._terminal.buffer,s=i.lines.length.toString();for(let r=e;r<=t;r++){const e=i.translateBufferLineToString(i.ydisp+r,!0),t=(i.ydisp+r+1).toString(),n=this._rowElements[r];n&&(0===e.length?n.innerText="\xa0":n.textContent=e,n.setAttribute("aria-posinset",t),n.setAttribute("aria-setsize",s))}this._announceCharacters()}_announceCharacters(){0!==this._charsToAnnounce.length&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")}_handleBoundaryFocus(e,t){const i=e.target,s=this._rowElements[0===t?1:this._rowElements.length-2];if(i.getAttribute("aria-posinset")===(0===t?"1":`${this._terminal.buffer.lines.length}`))return;if(e.relatedTarget!==s)return;let r,n;if(0===t?(r=i,n=this._rowElements.pop(),this._rowContainer.removeChild(n)):(r=this._rowElements.shift(),n=i,this._rowContainer.removeChild(r)),r.removeEventListener("focus",this._topBoundaryFocusListener),n.removeEventListener("focus",this._bottomBoundaryFocusListener),0===t){const e=this._createAccessibilityTreeNode();this._rowElements.unshift(e),this._rowContainer.insertAdjacentElement("afterbegin",e)}else{const e=this._createAccessibilityTreeNode();this._rowElements.push(e),this._rowContainer.appendChild(e)}this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._terminal.scrollLines(0===t?-1:1),this._rowElements[0===t?1:this._rowElements.length-2].focus(),e.preventDefault(),e.stopImmediatePropagation()}_handleResize(e){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(let t=this._rowContainer.children.length;te;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()}_createAccessibilityTreeNode(){const e=document.createElement("div");return e.setAttribute("role","listitem"),e.tabIndex=-1,this._refreshRowDimensions(e),e}_refreshRowsDimensions(){if(this._renderService.dimensions.css.cell.height){this._accessibilityContainer.style.width=`${this._renderService.dimensions.css.canvas.width}px`,this._rowElements.length!==this._terminal.rows&&this._handleResize(this._terminal.rows);for(let e=0;e{function i(e){return e.replace(/\r?\n/g,"\r")}function s(e,t){return t?"\x1b[200~"+e+"\x1b[201~":e}function r(e,t,r,n){e=s(e=i(e),r.decPrivateModes.bracketedPasteMode&&!0!==n.rawOptions.ignoreBracketedPasteMode),r.triggerDataEvent(e,!0),t.value=""}function n(e,t,i){const s=i.getBoundingClientRect(),r=e.clientX-s.left-10,n=e.clientY-s.top-10;t.style.width="20px",t.style.height="20px",t.style.left=`${r}px`,t.style.top=`${n}px`,t.style.zIndex="1000",t.focus()}Object.defineProperty(t,"__esModule",{value:!0}),t.rightClickHandler=t.moveTextAreaUnderMouseCursor=t.paste=t.handlePasteEvent=t.copyHandler=t.bracketTextForPaste=t.prepareTextForTerminal=void 0,t.prepareTextForTerminal=i,t.bracketTextForPaste=s,t.copyHandler=function(e,t){e.clipboardData&&e.clipboardData.setData("text/plain",t.selectionText),e.preventDefault()},t.handlePasteEvent=function(e,t,i,s){e.stopPropagation(),e.clipboardData&&r(e.clipboardData.getData("text/plain"),t,i,s)},t.paste=r,t.moveTextAreaUnderMouseCursor=n,t.rightClickHandler=function(e,t,i,s,r){n(e,t,i),r&&s.rightClickSelect(e),t.value=s.selectionText,t.select()}},7239:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ColorContrastCache=void 0;const s=i(1505);t.ColorContrastCache=class{constructor(){this._color=new s.TwoKeyMap,this._css=new s.TwoKeyMap}setCss(e,t,i){this._css.set(e,t,i)}getCss(e,t){return this._css.get(e,t)}setColor(e,t,i){this._color.set(e,t,i)}getColor(e,t){return this._color.get(e,t)}clear(){this._color.clear(),this._css.clear()}}},3656:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.addDisposableDomListener=void 0,t.addDisposableDomListener=function(e,t,i,s){e.addEventListener(t,i,s);let r=!1;return{dispose:()=>{r||(r=!0,e.removeEventListener(t,i,s))}}}},6465:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Linkifier2=void 0;const n=i(3656),o=i(8460),a=i(844),h=i(2585);let c=t.Linkifier2=class extends a.Disposable{get currentLink(){return this._currentLink}constructor(e){super(),this._bufferService=e,this._linkProviders=[],this._linkCacheDisposables=[],this._isMouseOut=!0,this._wasResized=!1,this._activeLine=-1,this._onShowLinkUnderline=this.register(new o.EventEmitter),this.onShowLinkUnderline=this._onShowLinkUnderline.event,this._onHideLinkUnderline=this.register(new o.EventEmitter),this.onHideLinkUnderline=this._onHideLinkUnderline.event,this.register((0,a.getDisposeArrayDisposable)(this._linkCacheDisposables)),this.register((0,a.toDisposable)((()=>{this._lastMouseEvent=void 0}))),this.register(this._bufferService.onResize((()=>{this._clearCurrentLink(),this._wasResized=!0})))}registerLinkProvider(e){return this._linkProviders.push(e),{dispose:()=>{const t=this._linkProviders.indexOf(e);-1!==t&&this._linkProviders.splice(t,1)}}}attachToDom(e,t,i){this._element=e,this._mouseService=t,this._renderService=i,this.register((0,n.addDisposableDomListener)(this._element,"mouseleave",(()=>{this._isMouseOut=!0,this._clearCurrentLink()}))),this.register((0,n.addDisposableDomListener)(this._element,"mousemove",this._handleMouseMove.bind(this))),this.register((0,n.addDisposableDomListener)(this._element,"mousedown",this._handleMouseDown.bind(this))),this.register((0,n.addDisposableDomListener)(this._element,"mouseup",this._handleMouseUp.bind(this)))}_handleMouseMove(e){if(this._lastMouseEvent=e,!this._element||!this._mouseService)return;const t=this._positionFromMouseEvent(e,this._element,this._mouseService);if(!t)return;this._isMouseOut=!1;const i=e.composedPath();for(let s=0;s{null==e||e.forEach((e=>{e.link.dispose&&e.link.dispose()}))})),this._activeProviderReplies=new Map,this._activeLine=e.y);let r=!1;for(const[n,o]of this._linkProviders.entries())t?(null===(s=this._activeProviderReplies)||void 0===s?void 0:s.get(n))&&(r=this._checkLinkProviderResult(n,e,r)):o.provideLinks(e.y,(t=>{var i,s;if(this._isMouseOut)return;const o=null==t?void 0:t.map((e=>({link:e})));null===(i=this._activeProviderReplies)||void 0===i||i.set(n,o),r=this._checkLinkProviderResult(n,e,r),(null===(s=this._activeProviderReplies)||void 0===s?void 0:s.size)===this._linkProviders.length&&this._removeIntersectingLinks(e.y,this._activeProviderReplies)}))}_removeIntersectingLinks(e,t){const i=new Set;for(let s=0;se?this._bufferService.cols:s.link.range.end.x;for(let e=n;e<=o;e++){if(i.has(e)){r.splice(t--,1);break}i.add(e)}}}}_checkLinkProviderResult(e,t,i){var s;if(!this._activeProviderReplies)return i;const r=this._activeProviderReplies.get(e);let n=!1;for(let o=0;othis._linkAtPosition(e.link,t)));e&&(i=!0,this._handleNewLink(e))}if(this._activeProviderReplies.size===this._linkProviders.length&&!i)for(let o=0;othis._linkAtPosition(e.link,t)));if(e){i=!0,this._handleNewLink(e);break}}return i}_handleMouseDown(){this._mouseDownLink=this._currentLink}_handleMouseUp(e){if(!this._element||!this._mouseService||!this._currentLink)return;const t=this._positionFromMouseEvent(e,this._element,this._mouseService);t&&this._mouseDownLink===this._currentLink&&this._linkAtPosition(this._currentLink.link,t)&&this._currentLink.link.activate(e,this._currentLink.link.text)}_clearCurrentLink(e,t){this._element&&this._currentLink&&this._lastMouseEvent&&(!e||!t||this._currentLink.link.range.start.y>=e&&this._currentLink.link.range.end.y<=t)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,(0,a.disposeArray)(this._linkCacheDisposables))}_handleNewLink(e){if(!this._element||!this._lastMouseEvent||!this._mouseService)return;const t=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);t&&this._linkAtPosition(e.link,t)&&(this._currentLink=e,this._currentLink.state={decorations:{underline:void 0===e.link.decorations||e.link.decorations.underline,pointerCursor:void 0===e.link.decorations||e.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,e.link,this._lastMouseEvent),e.link.decorations={},Object.defineProperties(e.link.decorations,{pointerCursor:{get:()=>{var e,t;return null===(t=null===(e=this._currentLink)||void 0===e?void 0:e.state)||void 0===t?void 0:t.decorations.pointerCursor},set:e=>{var t,i;(null===(t=this._currentLink)||void 0===t?void 0:t.state)&&this._currentLink.state.decorations.pointerCursor!==e&&(this._currentLink.state.decorations.pointerCursor=e,this._currentLink.state.isHovered&&(null===(i=this._element)||void 0===i||i.classList.toggle("xterm-cursor-pointer",e)))}},underline:{get:()=>{var e,t;return null===(t=null===(e=this._currentLink)||void 0===e?void 0:e.state)||void 0===t?void 0:t.decorations.underline},set:t=>{var i,s,r;(null===(i=this._currentLink)||void 0===i?void 0:i.state)&&(null===(r=null===(s=this._currentLink)||void 0===s?void 0:s.state)||void 0===r?void 0:r.decorations.underline)!==t&&(this._currentLink.state.decorations.underline=t,this._currentLink.state.isHovered&&this._fireUnderlineEvent(e.link,t))}}}),this._renderService&&this._linkCacheDisposables.push(this._renderService.onRenderedViewportChange((e=>{if(!this._currentLink)return;const t=0===e.start?0:e.start+1+this._bufferService.buffer.ydisp,i=this._bufferService.buffer.ydisp+1+e.end;if(this._currentLink.link.range.start.y>=t&&this._currentLink.link.range.end.y<=i&&(this._clearCurrentLink(t,i),this._lastMouseEvent&&this._element)){const e=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);e&&this._askForLink(e,!1)}}))))}_linkHover(e,t,i){var s;(null===(s=this._currentLink)||void 0===s?void 0:s.state)&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!0),this._currentLink.state.decorations.pointerCursor&&e.classList.add("xterm-cursor-pointer")),t.hover&&t.hover(i,t.text)}_fireUnderlineEvent(e,t){const i=e.range,s=this._bufferService.buffer.ydisp,r=this._createLinkUnderlineEvent(i.start.x-1,i.start.y-s-1,i.end.x,i.end.y-s-1,void 0);(t?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(r)}_linkLeave(e,t,i){var s;(null===(s=this._currentLink)||void 0===s?void 0:s.state)&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!1),this._currentLink.state.decorations.pointerCursor&&e.classList.remove("xterm-cursor-pointer")),t.leave&&t.leave(i,t.text)}_linkAtPosition(e,t){const i=e.range.start.y*this._bufferService.cols+e.range.start.x,s=e.range.end.y*this._bufferService.cols+e.range.end.x,r=t.y*this._bufferService.cols+t.x;return i<=r&&r<=s}_positionFromMouseEvent(e,t,i){const s=i.getCoords(e,t,this._bufferService.cols,this._bufferService.rows);if(s)return{x:s[0],y:s[1]+this._bufferService.buffer.ydisp}}_createLinkUnderlineEvent(e,t,i,s,r){return{x1:e,y1:t,x2:i,y2:s,cols:this._bufferService.cols,fg:r}}};t.Linkifier2=c=s([r(0,h.IBufferService)],c)},9042:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.tooMuchOutput=t.promptLabel=void 0,t.promptLabel="Terminal input",t.tooMuchOutput="Too much output to announce, navigate to rows manually to read"},3730:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OscLinkProvider=void 0;const n=i(511),o=i(2585);let a=t.OscLinkProvider=class{constructor(e,t,i){this._bufferService=e,this._optionsService=t,this._oscLinkService=i}provideLinks(e,t){var i;const s=this._bufferService.buffer.lines.get(e-1);if(!s)return void t(void 0);const r=[],o=this._optionsService.rawOptions.linkHandler,a=new n.CellData,c=s.getTrimmedLength();let l=-1,d=-1,_=!1;for(let n=0;no?o.activate(e,t,i):h(0,t),hover:(e,t)=>{var s;return null===(s=null==o?void 0:o.hover)||void 0===s?void 0:s.call(o,e,t,i)},leave:(e,t)=>{var s;return null===(s=null==o?void 0:o.leave)||void 0===s?void 0:s.call(o,e,t,i)}})}_=!1,a.hasExtendedAttrs()&&a.extended.urlId?(d=n,l=a.extended.urlId):(d=-1,l=-1)}}t(r)}};function h(e,t){if(confirm(`Do you want to navigate to ${t}?\n\nWARNING: This link could potentially be dangerous`)){const i=window.open();if(i){try{i.opener=null}catch(e){}i.location.href=t}else console.warn("Opening link blocked as opener could not be cleared")}}t.OscLinkProvider=a=s([r(0,o.IBufferService),r(1,o.IOptionsService),r(2,o.IOscLinkService)],a)},6193:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RenderDebouncer=void 0,t.RenderDebouncer=class{constructor(e,t){this._parentWindow=e,this._renderCallback=t,this._refreshCallbacks=[]}dispose(){this._animationFrame&&(this._parentWindow.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}addRefreshCallback(e){return this._refreshCallbacks.push(e),this._animationFrame||(this._animationFrame=this._parentWindow.requestAnimationFrame((()=>this._innerRefresh()))),this._animationFrame}refresh(e,t,i){this._rowCount=i,e=void 0!==e?e:0,t=void 0!==t?t:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,e):e,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,t):t,this._animationFrame||(this._animationFrame=this._parentWindow.requestAnimationFrame((()=>this._innerRefresh())))}_innerRefresh(){if(this._animationFrame=void 0,void 0===this._rowStart||void 0===this._rowEnd||void 0===this._rowCount)return void this._runRefreshCallbacks();const e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t),this._runRefreshCallbacks()}_runRefreshCallbacks(){for(const e of this._refreshCallbacks)e(0);this._refreshCallbacks=[]}}},5596:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ScreenDprMonitor=void 0;const s=i(844);class r extends s.Disposable{constructor(e){super(),this._parentWindow=e,this._currentDevicePixelRatio=this._parentWindow.devicePixelRatio,this.register((0,s.toDisposable)((()=>{this.clearListener()})))}setListener(e){this._listener&&this.clearListener(),this._listener=e,this._outerListener=()=>{this._listener&&(this._listener(this._parentWindow.devicePixelRatio,this._currentDevicePixelRatio),this._updateDpr())},this._updateDpr()}_updateDpr(){var e;this._outerListener&&(null===(e=this._resolutionMediaMatchList)||void 0===e||e.removeListener(this._outerListener),this._currentDevicePixelRatio=this._parentWindow.devicePixelRatio,this._resolutionMediaMatchList=this._parentWindow.matchMedia(`screen and (resolution: ${this._parentWindow.devicePixelRatio}dppx)`),this._resolutionMediaMatchList.addListener(this._outerListener))}clearListener(){this._resolutionMediaMatchList&&this._listener&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._listener=void 0,this._outerListener=void 0)}}t.ScreenDprMonitor=r},3236:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Terminal=void 0;const s=i(3614),r=i(3656),n=i(6465),o=i(9042),a=i(3730),h=i(1680),c=i(3107),l=i(5744),d=i(2950),_=i(1296),u=i(428),f=i(4269),v=i(5114),p=i(8934),g=i(3230),m=i(9312),S=i(4725),C=i(6731),b=i(8055),y=i(8969),w=i(8460),E=i(844),k=i(6114),L=i(8437),D=i(2584),R=i(7399),x=i(5941),A=i(9074),B=i(2585),T=i(5435),M=i(4567),O="undefined"!=typeof window?window.document:null;class P extends y.CoreTerminal{get onFocus(){return this._onFocus.event}get onBlur(){return this._onBlur.event}get onA11yChar(){return this._onA11yCharEmitter.event}get onA11yTab(){return this._onA11yTabEmitter.event}get onWillOpen(){return this._onWillOpen.event}constructor(e={}){super(e),this.browser=k,this._keyDownHandled=!1,this._keyDownSeen=!1,this._keyPressHandled=!1,this._unprocessedDeadKey=!1,this._accessibilityManager=this.register(new E.MutableDisposable),this._onCursorMove=this.register(new w.EventEmitter),this.onCursorMove=this._onCursorMove.event,this._onKey=this.register(new w.EventEmitter),this.onKey=this._onKey.event,this._onRender=this.register(new w.EventEmitter),this.onRender=this._onRender.event,this._onSelectionChange=this.register(new w.EventEmitter),this.onSelectionChange=this._onSelectionChange.event,this._onTitleChange=this.register(new w.EventEmitter),this.onTitleChange=this._onTitleChange.event,this._onBell=this.register(new w.EventEmitter),this.onBell=this._onBell.event,this._onFocus=this.register(new w.EventEmitter),this._onBlur=this.register(new w.EventEmitter),this._onA11yCharEmitter=this.register(new w.EventEmitter),this._onA11yTabEmitter=this.register(new w.EventEmitter),this._onWillOpen=this.register(new w.EventEmitter),this._setup(),this.linkifier2=this.register(this._instantiationService.createInstance(n.Linkifier2)),this.linkifier2.registerLinkProvider(this._instantiationService.createInstance(a.OscLinkProvider)),this._decorationService=this._instantiationService.createInstance(A.DecorationService),this._instantiationService.setService(B.IDecorationService,this._decorationService),this.register(this._inputHandler.onRequestBell((()=>this._onBell.fire()))),this.register(this._inputHandler.onRequestRefreshRows(((e,t)=>this.refresh(e,t)))),this.register(this._inputHandler.onRequestSendFocus((()=>this._reportFocus()))),this.register(this._inputHandler.onRequestReset((()=>this.reset()))),this.register(this._inputHandler.onRequestWindowsOptionsReport((e=>this._reportWindowsOptions(e)))),this.register(this._inputHandler.onColor((e=>this._handleColorEvent(e)))),this.register((0,w.forwardEvent)(this._inputHandler.onCursorMove,this._onCursorMove)),this.register((0,w.forwardEvent)(this._inputHandler.onTitleChange,this._onTitleChange)),this.register((0,w.forwardEvent)(this._inputHandler.onA11yChar,this._onA11yCharEmitter)),this.register((0,w.forwardEvent)(this._inputHandler.onA11yTab,this._onA11yTabEmitter)),this.register(this._bufferService.onResize((e=>this._afterResize(e.cols,e.rows)))),this.register((0,E.toDisposable)((()=>{var e,t;this._customKeyEventHandler=void 0,null===(t=null===(e=this.element)||void 0===e?void 0:e.parentNode)||void 0===t||t.removeChild(this.element)})))}_handleColorEvent(e){if(this._themeService)for(const t of e){let e,i="";switch(t.index){case 256:e="foreground",i="10";break;case 257:e="background",i="11";break;case 258:e="cursor",i="12";break;default:e="ansi",i="4;"+t.index}switch(t.type){case 0:const s=b.color.toColorRGB("ansi"===e?this._themeService.colors.ansi[t.index]:this._themeService.colors[e]);this.coreService.triggerDataEvent(`${D.C0.ESC}]${i};${(0,x.toRgbString)(s)}${D.C1_ESCAPED.ST}`);break;case 1:if("ansi"===e)this._themeService.modifyColors((e=>e.ansi[t.index]=b.rgba.toColor(...t.color)));else{const i=e;this._themeService.modifyColors((e=>e[i]=b.rgba.toColor(...t.color)))}break;case 2:this._themeService.restoreColor(t.index)}}}_setup(){super._setup(),this._customKeyEventHandler=void 0}get buffer(){return this.buffers.active}focus(){this.textarea&&this.textarea.focus({preventScroll:!0})}_handleScreenReaderModeOptionChange(e){e?!this._accessibilityManager.value&&this._renderService&&(this._accessibilityManager.value=this._instantiationService.createInstance(M.AccessibilityManager,this)):this._accessibilityManager.clear()}_handleTextAreaFocus(e){this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(D.C0.ESC+"[I"),this.updateCursorStyle(e),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()}blur(){var e;return null===(e=this.textarea)||void 0===e?void 0:e.blur()}_handleTextAreaBlur(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(D.C0.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()}_syncTextArea(){if(!this.textarea||!this.buffer.isCursorInViewport||this._compositionHelper.isComposing||!this._renderService)return;const e=this.buffer.ybase+this.buffer.y,t=this.buffer.lines.get(e);if(!t)return;const i=Math.min(this.buffer.x,this.cols-1),s=this._renderService.dimensions.css.cell.height,r=t.getWidth(i),n=this._renderService.dimensions.css.cell.width*r,o=this.buffer.y*this._renderService.dimensions.css.cell.height,a=i*this._renderService.dimensions.css.cell.width;this.textarea.style.left=a+"px",this.textarea.style.top=o+"px",this.textarea.style.width=n+"px",this.textarea.style.height=s+"px",this.textarea.style.lineHeight=s+"px",this.textarea.style.zIndex="-5"}_initGlobal(){this._bindKeys(),this.register((0,r.addDisposableDomListener)(this.element,"copy",(e=>{this.hasSelection()&&(0,s.copyHandler)(e,this._selectionService)})));const e=e=>(0,s.handlePasteEvent)(e,this.textarea,this.coreService,this.optionsService);this.register((0,r.addDisposableDomListener)(this.textarea,"paste",e)),this.register((0,r.addDisposableDomListener)(this.element,"paste",e)),k.isFirefox?this.register((0,r.addDisposableDomListener)(this.element,"mousedown",(e=>{2===e.button&&(0,s.rightClickHandler)(e,this.textarea,this.screenElement,this._selectionService,this.options.rightClickSelectsWord)}))):this.register((0,r.addDisposableDomListener)(this.element,"contextmenu",(e=>{(0,s.rightClickHandler)(e,this.textarea,this.screenElement,this._selectionService,this.options.rightClickSelectsWord)}))),k.isLinux&&this.register((0,r.addDisposableDomListener)(this.element,"auxclick",(e=>{1===e.button&&(0,s.moveTextAreaUnderMouseCursor)(e,this.textarea,this.screenElement)})))}_bindKeys(){this.register((0,r.addDisposableDomListener)(this.textarea,"keyup",(e=>this._keyUp(e)),!0)),this.register((0,r.addDisposableDomListener)(this.textarea,"keydown",(e=>this._keyDown(e)),!0)),this.register((0,r.addDisposableDomListener)(this.textarea,"keypress",(e=>this._keyPress(e)),!0)),this.register((0,r.addDisposableDomListener)(this.textarea,"compositionstart",(()=>this._compositionHelper.compositionstart()))),this.register((0,r.addDisposableDomListener)(this.textarea,"compositionupdate",(e=>this._compositionHelper.compositionupdate(e)))),this.register((0,r.addDisposableDomListener)(this.textarea,"compositionend",(()=>this._compositionHelper.compositionend()))),this.register((0,r.addDisposableDomListener)(this.textarea,"input",(e=>this._inputEvent(e)),!0)),this.register(this.onRender((()=>this._compositionHelper.updateCompositionElements())))}open(e){var t;if(!e)throw new Error("Terminal requires a parent element.");e.isConnected||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),this._document=e.ownerDocument,this.element=this._document.createElement("div"),this.element.dir="ltr",this.element.classList.add("terminal"),this.element.classList.add("xterm"),e.appendChild(this.element);const i=O.createDocumentFragment();this._viewportElement=O.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),i.appendChild(this._viewportElement),this._viewportScrollArea=O.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=O.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=O.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),i.appendChild(this.screenElement),this.textarea=O.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",o.promptLabel),k.isChromeOS||this.textarea.setAttribute("aria-multiline","false"),this.textarea.setAttribute("autocorrect","off"),this.textarea.setAttribute("autocapitalize","off"),this.textarea.setAttribute("spellcheck","false"),this.textarea.tabIndex=0,this._coreBrowserService=this._instantiationService.createInstance(v.CoreBrowserService,this.textarea,null!==(t=this._document.defaultView)&&void 0!==t?t:window),this._instantiationService.setService(S.ICoreBrowserService,this._coreBrowserService),this.register((0,r.addDisposableDomListener)(this.textarea,"focus",(e=>this._handleTextAreaFocus(e)))),this.register((0,r.addDisposableDomListener)(this.textarea,"blur",(()=>this._handleTextAreaBlur()))),this._helperContainer.appendChild(this.textarea),this._charSizeService=this._instantiationService.createInstance(u.CharSizeService,this._document,this._helperContainer),this._instantiationService.setService(S.ICharSizeService,this._charSizeService),this._themeService=this._instantiationService.createInstance(C.ThemeService),this._instantiationService.setService(S.IThemeService,this._themeService),this._characterJoinerService=this._instantiationService.createInstance(f.CharacterJoinerService),this._instantiationService.setService(S.ICharacterJoinerService,this._characterJoinerService),this._renderService=this.register(this._instantiationService.createInstance(g.RenderService,this.rows,this.screenElement)),this._instantiationService.setService(S.IRenderService,this._renderService),this.register(this._renderService.onRenderedViewportChange((e=>this._onRender.fire(e)))),this.onResize((e=>this._renderService.resize(e.cols,e.rows))),this._compositionView=O.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(d.CompositionHelper,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this.element.appendChild(i);try{this._onWillOpen.fire(this.element)}catch(e){}this._renderService.hasRenderer()||this._renderService.setRenderer(this._createRenderer()),this._mouseService=this._instantiationService.createInstance(p.MouseService),this._instantiationService.setService(S.IMouseService,this._mouseService),this.viewport=this._instantiationService.createInstance(h.Viewport,this._viewportElement,this._viewportScrollArea),this.viewport.onRequestScrollLines((e=>this.scrollLines(e.amount,e.suppressScrollEvent,1))),this.register(this._inputHandler.onRequestSyncScrollBar((()=>this.viewport.syncScrollArea()))),this.register(this.viewport),this.register(this.onCursorMove((()=>{this._renderService.handleCursorMove(),this._syncTextArea()}))),this.register(this.onResize((()=>this._renderService.handleResize(this.cols,this.rows)))),this.register(this.onBlur((()=>this._renderService.handleBlur()))),this.register(this.onFocus((()=>this._renderService.handleFocus()))),this.register(this._renderService.onDimensionsChange((()=>this.viewport.syncScrollArea()))),this._selectionService=this.register(this._instantiationService.createInstance(m.SelectionService,this.element,this.screenElement,this.linkifier2)),this._instantiationService.setService(S.ISelectionService,this._selectionService),this.register(this._selectionService.onRequestScrollLines((e=>this.scrollLines(e.amount,e.suppressScrollEvent)))),this.register(this._selectionService.onSelectionChange((()=>this._onSelectionChange.fire()))),this.register(this._selectionService.onRequestRedraw((e=>this._renderService.handleSelectionChanged(e.start,e.end,e.columnSelectMode)))),this.register(this._selectionService.onLinuxMouseSelection((e=>{this.textarea.value=e,this.textarea.focus(),this.textarea.select()}))),this.register(this._onScroll.event((e=>{this.viewport.syncScrollArea(),this._selectionService.refresh()}))),this.register((0,r.addDisposableDomListener)(this._viewportElement,"scroll",(()=>this._selectionService.refresh()))),this.linkifier2.attachToDom(this.screenElement,this._mouseService,this._renderService),this.register(this._instantiationService.createInstance(c.BufferDecorationRenderer,this.screenElement)),this.register((0,r.addDisposableDomListener)(this.element,"mousedown",(e=>this._selectionService.handleMouseDown(e)))),this.coreMouseService.areMouseEventsActive?(this._selectionService.disable(),this.element.classList.add("enable-mouse-events")):this._selectionService.enable(),this.options.screenReaderMode&&(this._accessibilityManager.value=this._instantiationService.createInstance(M.AccessibilityManager,this)),this.register(this.optionsService.onSpecificOptionChange("screenReaderMode",(e=>this._handleScreenReaderModeOptionChange(e)))),this.options.overviewRulerWidth&&(this._overviewRulerRenderer=this.register(this._instantiationService.createInstance(l.OverviewRulerRenderer,this._viewportElement,this.screenElement))),this.optionsService.onSpecificOptionChange("overviewRulerWidth",(e=>{!this._overviewRulerRenderer&&e&&this._viewportElement&&this.screenElement&&(this._overviewRulerRenderer=this.register(this._instantiationService.createInstance(l.OverviewRulerRenderer,this._viewportElement,this.screenElement)))})),this._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()}_createRenderer(){return this._instantiationService.createInstance(_.DomRenderer,this.element,this.screenElement,this._viewportElement,this.linkifier2)}bindMouse(){const e=this,t=this.element;function i(t){const i=e._mouseService.getMouseReportCoords(t,e.screenElement);if(!i)return!1;let s,r;switch(t.overrideType||t.type){case"mousemove":r=32,void 0===t.buttons?(s=3,void 0!==t.button&&(s=t.button<3?t.button:3)):s=1&t.buttons?0:4&t.buttons?1:2&t.buttons?2:3;break;case"mouseup":r=0,s=t.button<3?t.button:3;break;case"mousedown":r=1,s=t.button<3?t.button:3;break;case"wheel":if(0===e.viewport.getLinesScrolled(t))return!1;r=t.deltaY<0?0:1,s=4;break;default:return!1}return!(void 0===r||void 0===s||s>4)&&e.coreMouseService.triggerMouseEvent({col:i.col,row:i.row,x:i.x,y:i.y,button:s,action:r,ctrl:t.ctrlKey,alt:t.altKey,shift:t.shiftKey})}const s={mouseup:null,wheel:null,mousedrag:null,mousemove:null},n={mouseup:e=>(i(e),e.buttons||(this._document.removeEventListener("mouseup",s.mouseup),s.mousedrag&&this._document.removeEventListener("mousemove",s.mousedrag)),this.cancel(e)),wheel:e=>(i(e),this.cancel(e,!0)),mousedrag:e=>{e.buttons&&i(e)},mousemove:e=>{e.buttons||i(e)}};this.register(this.coreMouseService.onProtocolChange((e=>{e?("debug"===this.optionsService.rawOptions.logLevel&&this._logService.debug("Binding to mouse events:",this.coreMouseService.explainEvents(e)),this.element.classList.add("enable-mouse-events"),this._selectionService.disable()):(this._logService.debug("Unbinding from mouse events."),this.element.classList.remove("enable-mouse-events"),this._selectionService.enable()),8&e?s.mousemove||(t.addEventListener("mousemove",n.mousemove),s.mousemove=n.mousemove):(t.removeEventListener("mousemove",s.mousemove),s.mousemove=null),16&e?s.wheel||(t.addEventListener("wheel",n.wheel,{passive:!1}),s.wheel=n.wheel):(t.removeEventListener("wheel",s.wheel),s.wheel=null),2&e?s.mouseup||(t.addEventListener("mouseup",n.mouseup),s.mouseup=n.mouseup):(this._document.removeEventListener("mouseup",s.mouseup),t.removeEventListener("mouseup",s.mouseup),s.mouseup=null),4&e?s.mousedrag||(s.mousedrag=n.mousedrag):(this._document.removeEventListener("mousemove",s.mousedrag),s.mousedrag=null)}))),this.coreMouseService.activeProtocol=this.coreMouseService.activeProtocol,this.register((0,r.addDisposableDomListener)(t,"mousedown",(e=>{if(e.preventDefault(),this.focus(),this.coreMouseService.areMouseEventsActive&&!this._selectionService.shouldForceSelection(e))return i(e),s.mouseup&&this._document.addEventListener("mouseup",s.mouseup),s.mousedrag&&this._document.addEventListener("mousemove",s.mousedrag),this.cancel(e)}))),this.register((0,r.addDisposableDomListener)(t,"wheel",(e=>{if(!s.wheel){if(!this.buffer.hasScrollback){const t=this.viewport.getLinesScrolled(e);if(0===t)return;const i=D.C0.ESC+(this.coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(e.deltaY<0?"A":"B");let s="";for(let e=0;e{if(!this.coreMouseService.areMouseEventsActive)return this.viewport.handleTouchStart(e),this.cancel(e)}),{passive:!0})),this.register((0,r.addDisposableDomListener)(t,"touchmove",(e=>{if(!this.coreMouseService.areMouseEventsActive)return this.viewport.handleTouchMove(e)?void 0:this.cancel(e)}),{passive:!1}))}refresh(e,t){var i;null===(i=this._renderService)||void 0===i||i.refreshRows(e,t)}updateCursorStyle(e){var t;(null===(t=this._selectionService)||void 0===t?void 0:t.shouldColumnSelect(e))?this.element.classList.add("column-select"):this.element.classList.remove("column-select")}_showCursor(){this.coreService.isCursorInitialized||(this.coreService.isCursorInitialized=!0,this.refresh(this.buffer.y,this.buffer.y))}scrollLines(e,t,i=0){var s;1===i?(super.scrollLines(e,t,i),this.refresh(0,this.rows-1)):null===(s=this.viewport)||void 0===s||s.scrollLines(e)}paste(e){(0,s.paste)(e,this.textarea,this.coreService,this.optionsService)}attachCustomKeyEventHandler(e){this._customKeyEventHandler=e}registerLinkProvider(e){return this.linkifier2.registerLinkProvider(e)}registerCharacterJoiner(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");const t=this._characterJoinerService.register(e);return this.refresh(0,this.rows-1),t}deregisterCharacterJoiner(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");this._characterJoinerService.deregister(e)&&this.refresh(0,this.rows-1)}get markers(){return this.buffer.markers}registerMarker(e){return this.buffer.addMarker(this.buffer.ybase+this.buffer.y+e)}registerDecoration(e){return this._decorationService.registerDecoration(e)}hasSelection(){return!!this._selectionService&&this._selectionService.hasSelection}select(e,t,i){this._selectionService.setSelection(e,t,i)}getSelection(){return this._selectionService?this._selectionService.selectionText:""}getSelectionPosition(){if(this._selectionService&&this._selectionService.hasSelection)return{start:{x:this._selectionService.selectionStart[0],y:this._selectionService.selectionStart[1]},end:{x:this._selectionService.selectionEnd[0],y:this._selectionService.selectionEnd[1]}}}clearSelection(){var e;null===(e=this._selectionService)||void 0===e||e.clearSelection()}selectAll(){var e;null===(e=this._selectionService)||void 0===e||e.selectAll()}selectLines(e,t){var i;null===(i=this._selectionService)||void 0===i||i.selectLines(e,t)}_keyDown(e){if(this._keyDownHandled=!1,this._keyDownSeen=!0,this._customKeyEventHandler&&!1===this._customKeyEventHandler(e))return!1;const t=this.browser.isMac&&this.options.macOptionIsMeta&&e.altKey;if(!t&&!this._compositionHelper.keydown(e))return this.options.scrollOnUserInput&&this.buffer.ybase!==this.buffer.ydisp&&this.scrollToBottom(),!1;t||"Dead"!==e.key&&"AltGraph"!==e.key||(this._unprocessedDeadKey=!0);const i=(0,R.evaluateKeyboardEvent)(e,this.coreService.decPrivateModes.applicationCursorKeys,this.browser.isMac,this.options.macOptionIsMeta);if(this.updateCursorStyle(e),3===i.type||2===i.type){const t=this.rows-1;return this.scrollLines(2===i.type?-t:t),this.cancel(e,!0)}return 1===i.type&&this.selectAll(),!!this._isThirdLevelShift(this.browser,e)||(i.cancel&&this.cancel(e,!0),!i.key||!!(e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&1===e.key.length&&e.key.charCodeAt(0)>=65&&e.key.charCodeAt(0)<=90)||(this._unprocessedDeadKey?(this._unprocessedDeadKey=!1,!0):(i.key!==D.C0.ETX&&i.key!==D.C0.CR||(this.textarea.value=""),this._onKey.fire({key:i.key,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(i.key,!0),!this.optionsService.rawOptions.screenReaderMode||e.altKey||e.ctrlKey?this.cancel(e,!0):void(this._keyDownHandled=!0))))}_isThirdLevelShift(e,t){const i=e.isMac&&!this.options.macOptionIsMeta&&t.altKey&&!t.ctrlKey&&!t.metaKey||e.isWindows&&t.altKey&&t.ctrlKey&&!t.metaKey||e.isWindows&&t.getModifierState("AltGraph");return"keypress"===t.type?i:i&&(!t.keyCode||t.keyCode>47)}_keyUp(e){this._keyDownSeen=!1,this._customKeyEventHandler&&!1===this._customKeyEventHandler(e)||(function(e){return 16===e.keyCode||17===e.keyCode||18===e.keyCode}(e)||this.focus(),this.updateCursorStyle(e),this._keyPressHandled=!1)}_keyPress(e){let t;if(this._keyPressHandled=!1,this._keyDownHandled)return!1;if(this._customKeyEventHandler&&!1===this._customKeyEventHandler(e))return!1;if(this.cancel(e),e.charCode)t=e.charCode;else if(null===e.which||void 0===e.which)t=e.keyCode;else{if(0===e.which||0===e.charCode)return!1;t=e.which}return!(!t||(e.altKey||e.ctrlKey||e.metaKey)&&!this._isThirdLevelShift(this.browser,e)||(t=String.fromCharCode(t),this._onKey.fire({key:t,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(t,!0),this._keyPressHandled=!0,this._unprocessedDeadKey=!1,0))}_inputEvent(e){if(e.data&&"insertText"===e.inputType&&(!e.composed||!this._keyDownSeen)&&!this.optionsService.rawOptions.screenReaderMode){if(this._keyPressHandled)return!1;this._unprocessedDeadKey=!1;const t=e.data;return this.coreService.triggerDataEvent(t,!0),this.cancel(e),!0}return!1}resize(e,t){e!==this.cols||t!==this.rows?super.resize(e,t):this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure()}_afterResize(e,t){var i,s;null===(i=this._charSizeService)||void 0===i||i.measure(),null===(s=this.viewport)||void 0===s||s.syncScrollArea(!0)}clear(){var e;if(0!==this.buffer.ybase||0!==this.buffer.y){this.buffer.clearAllMarkers(),this.buffer.lines.set(0,this.buffer.lines.get(this.buffer.ybase+this.buffer.y)),this.buffer.lines.length=1,this.buffer.ydisp=0,this.buffer.ybase=0,this.buffer.y=0;for(let e=1;e{Object.defineProperty(t,"__esModule",{value:!0}),t.TimeBasedDebouncer=void 0,t.TimeBasedDebouncer=class{constructor(e,t=1e3){this._renderCallback=e,this._debounceThresholdMS=t,this._lastRefreshMs=0,this._additionalRefreshRequested=!1}dispose(){this._refreshTimeoutID&&clearTimeout(this._refreshTimeoutID)}refresh(e,t,i){this._rowCount=i,e=void 0!==e?e:0,t=void 0!==t?t:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,e):e,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,t):t;const s=Date.now();if(s-this._lastRefreshMs>=this._debounceThresholdMS)this._lastRefreshMs=s,this._innerRefresh();else if(!this._additionalRefreshRequested){const e=s-this._lastRefreshMs,t=this._debounceThresholdMS-e;this._additionalRefreshRequested=!0,this._refreshTimeoutID=window.setTimeout((()=>{this._lastRefreshMs=Date.now(),this._innerRefresh(),this._additionalRefreshRequested=!1,this._refreshTimeoutID=void 0}),t)}}_innerRefresh(){if(void 0===this._rowStart||void 0===this._rowEnd||void 0===this._rowCount)return;const e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t)}}},1680:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Viewport=void 0;const n=i(3656),o=i(4725),a=i(8460),h=i(844),c=i(2585);let l=t.Viewport=class extends h.Disposable{constructor(e,t,i,s,r,o,h,c){super(),this._viewportElement=e,this._scrollArea=t,this._bufferService=i,this._optionsService=s,this._charSizeService=r,this._renderService=o,this._coreBrowserService=h,this.scrollBarWidth=0,this._currentRowHeight=0,this._currentDeviceCellHeight=0,this._lastRecordedBufferLength=0,this._lastRecordedViewportHeight=0,this._lastRecordedBufferHeight=0,this._lastTouchY=0,this._lastScrollTop=0,this._wheelPartialScroll=0,this._refreshAnimationFrame=null,this._ignoreNextScrollEvent=!1,this._smoothScrollState={startTime:0,origin:-1,target:-1},this._onRequestScrollLines=this.register(new a.EventEmitter),this.onRequestScrollLines=this._onRequestScrollLines.event,this.scrollBarWidth=this._viewportElement.offsetWidth-this._scrollArea.offsetWidth||15,this.register((0,n.addDisposableDomListener)(this._viewportElement,"scroll",this._handleScroll.bind(this))),this._activeBuffer=this._bufferService.buffer,this.register(this._bufferService.buffers.onBufferActivate((e=>this._activeBuffer=e.activeBuffer))),this._renderDimensions=this._renderService.dimensions,this.register(this._renderService.onDimensionsChange((e=>this._renderDimensions=e))),this._handleThemeChange(c.colors),this.register(c.onChangeColors((e=>this._handleThemeChange(e)))),this.register(this._optionsService.onSpecificOptionChange("scrollback",(()=>this.syncScrollArea()))),setTimeout((()=>this.syncScrollArea()))}_handleThemeChange(e){this._viewportElement.style.backgroundColor=e.background.css}reset(){this._currentRowHeight=0,this._currentDeviceCellHeight=0,this._lastRecordedBufferLength=0,this._lastRecordedViewportHeight=0,this._lastRecordedBufferHeight=0,this._lastTouchY=0,this._lastScrollTop=0,this._coreBrowserService.window.requestAnimationFrame((()=>this.syncScrollArea()))}_refresh(e){if(e)return this._innerRefresh(),void(null!==this._refreshAnimationFrame&&this._coreBrowserService.window.cancelAnimationFrame(this._refreshAnimationFrame));null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=this._coreBrowserService.window.requestAnimationFrame((()=>this._innerRefresh())))}_innerRefresh(){if(this._charSizeService.height>0){this._currentRowHeight=this._renderService.dimensions.device.cell.height/this._coreBrowserService.dpr,this._currentDeviceCellHeight=this._renderService.dimensions.device.cell.height,this._lastRecordedViewportHeight=this._viewportElement.offsetHeight;const e=Math.round(this._currentRowHeight*this._lastRecordedBufferLength)+(this._lastRecordedViewportHeight-this._renderService.dimensions.css.canvas.height);this._lastRecordedBufferHeight!==e&&(this._lastRecordedBufferHeight=e,this._scrollArea.style.height=this._lastRecordedBufferHeight+"px")}const e=this._bufferService.buffer.ydisp*this._currentRowHeight;this._viewportElement.scrollTop!==e&&(this._ignoreNextScrollEvent=!0,this._viewportElement.scrollTop=e),this._refreshAnimationFrame=null}syncScrollArea(e=!1){if(this._lastRecordedBufferLength!==this._bufferService.buffer.lines.length)return this._lastRecordedBufferLength=this._bufferService.buffer.lines.length,void this._refresh(e);this._lastRecordedViewportHeight===this._renderService.dimensions.css.canvas.height&&this._lastScrollTop===this._activeBuffer.ydisp*this._currentRowHeight&&this._renderDimensions.device.cell.height===this._currentDeviceCellHeight||this._refresh(e)}_handleScroll(e){if(this._lastScrollTop=this._viewportElement.scrollTop,!this._viewportElement.offsetParent)return;if(this._ignoreNextScrollEvent)return this._ignoreNextScrollEvent=!1,void this._onRequestScrollLines.fire({amount:0,suppressScrollEvent:!0});const t=Math.round(this._lastScrollTop/this._currentRowHeight)-this._bufferService.buffer.ydisp;this._onRequestScrollLines.fire({amount:t,suppressScrollEvent:!0})}_smoothScroll(){if(this._isDisposed||-1===this._smoothScrollState.origin||-1===this._smoothScrollState.target)return;const e=this._smoothScrollPercent();this._viewportElement.scrollTop=this._smoothScrollState.origin+Math.round(e*(this._smoothScrollState.target-this._smoothScrollState.origin)),e<1?this._coreBrowserService.window.requestAnimationFrame((()=>this._smoothScroll())):this._clearSmoothScrollState()}_smoothScrollPercent(){return this._optionsService.rawOptions.smoothScrollDuration&&this._smoothScrollState.startTime?Math.max(Math.min((Date.now()-this._smoothScrollState.startTime)/this._optionsService.rawOptions.smoothScrollDuration,1),0):1}_clearSmoothScrollState(){this._smoothScrollState.startTime=0,this._smoothScrollState.origin=-1,this._smoothScrollState.target=-1}_bubbleScroll(e,t){const i=this._viewportElement.scrollTop+this._lastRecordedViewportHeight;return!(t<0&&0!==this._viewportElement.scrollTop||t>0&&i0&&(s=e),r=""}}return{bufferElements:n,cursorElement:s}}getLinesScrolled(e){if(0===e.deltaY||e.shiftKey)return 0;let t=this._applyScrollModifier(e.deltaY,e);return e.deltaMode===WheelEvent.DOM_DELTA_PIXEL?(t/=this._currentRowHeight+0,this._wheelPartialScroll+=t,t=Math.floor(Math.abs(this._wheelPartialScroll))*(this._wheelPartialScroll>0?1:-1),this._wheelPartialScroll%=1):e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._bufferService.rows),t}_applyScrollModifier(e,t){const i=this._optionsService.rawOptions.fastScrollModifier;return"alt"===i&&t.altKey||"ctrl"===i&&t.ctrlKey||"shift"===i&&t.shiftKey?e*this._optionsService.rawOptions.fastScrollSensitivity*this._optionsService.rawOptions.scrollSensitivity:e*this._optionsService.rawOptions.scrollSensitivity}handleTouchStart(e){this._lastTouchY=e.touches[0].pageY}handleTouchMove(e){const t=this._lastTouchY-e.touches[0].pageY;return this._lastTouchY=e.touches[0].pageY,0!==t&&(this._viewportElement.scrollTop+=t,this._bubbleScroll(e,t))}};t.Viewport=l=s([r(2,c.IBufferService),r(3,c.IOptionsService),r(4,o.ICharSizeService),r(5,o.IRenderService),r(6,o.ICoreBrowserService),r(7,o.IThemeService)],l)},3107:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.BufferDecorationRenderer=void 0;const n=i(3656),o=i(4725),a=i(844),h=i(2585);let c=t.BufferDecorationRenderer=class extends a.Disposable{constructor(e,t,i,s){super(),this._screenElement=e,this._bufferService=t,this._decorationService=i,this._renderService=s,this._decorationElements=new Map,this._altBufferIsActive=!1,this._dimensionsChanged=!1,this._container=document.createElement("div"),this._container.classList.add("xterm-decoration-container"),this._screenElement.appendChild(this._container),this.register(this._renderService.onRenderedViewportChange((()=>this._doRefreshDecorations()))),this.register(this._renderService.onDimensionsChange((()=>{this._dimensionsChanged=!0,this._queueRefresh()}))),this.register((0,n.addDisposableDomListener)(window,"resize",(()=>this._queueRefresh()))),this.register(this._bufferService.buffers.onBufferActivate((()=>{this._altBufferIsActive=this._bufferService.buffer===this._bufferService.buffers.alt}))),this.register(this._decorationService.onDecorationRegistered((()=>this._queueRefresh()))),this.register(this._decorationService.onDecorationRemoved((e=>this._removeDecoration(e)))),this.register((0,a.toDisposable)((()=>{this._container.remove(),this._decorationElements.clear()})))}_queueRefresh(){void 0===this._animationFrame&&(this._animationFrame=this._renderService.addRefreshCallback((()=>{this._doRefreshDecorations(),this._animationFrame=void 0})))}_doRefreshDecorations(){for(const e of this._decorationService.decorations)this._renderDecoration(e);this._dimensionsChanged=!1}_renderDecoration(e){this._refreshStyle(e),this._dimensionsChanged&&this._refreshXPosition(e)}_createElement(e){var t,i;const s=document.createElement("div");s.classList.add("xterm-decoration"),s.classList.toggle("xterm-decoration-top-layer","top"===(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.layer)),s.style.width=`${Math.round((e.options.width||1)*this._renderService.dimensions.css.cell.width)}px`,s.style.height=(e.options.height||1)*this._renderService.dimensions.css.cell.height+"px",s.style.top=(e.marker.line-this._bufferService.buffers.active.ydisp)*this._renderService.dimensions.css.cell.height+"px",s.style.lineHeight=`${this._renderService.dimensions.css.cell.height}px`;const r=null!==(i=e.options.x)&&void 0!==i?i:0;return r&&r>this._bufferService.cols&&(s.style.display="none"),this._refreshXPosition(e,s),s}_refreshStyle(e){const t=e.marker.line-this._bufferService.buffers.active.ydisp;if(t<0||t>=this._bufferService.rows)e.element&&(e.element.style.display="none",e.onRenderEmitter.fire(e.element));else{let i=this._decorationElements.get(e);i||(i=this._createElement(e),e.element=i,this._decorationElements.set(e,i),this._container.appendChild(i),e.onDispose((()=>{this._decorationElements.delete(e),i.remove()}))),i.style.top=t*this._renderService.dimensions.css.cell.height+"px",i.style.display=this._altBufferIsActive?"none":"block",e.onRenderEmitter.fire(i)}}_refreshXPosition(e,t=e.element){var i;if(!t)return;const s=null!==(i=e.options.x)&&void 0!==i?i:0;"right"===(e.options.anchor||"left")?t.style.right=s?s*this._renderService.dimensions.css.cell.width+"px":"":t.style.left=s?s*this._renderService.dimensions.css.cell.width+"px":""}_removeDecoration(e){var t;null===(t=this._decorationElements.get(e))||void 0===t||t.remove(),this._decorationElements.delete(e),e.dispose()}};t.BufferDecorationRenderer=c=s([r(1,h.IBufferService),r(2,h.IDecorationService),r(3,o.IRenderService)],c)},5871:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ColorZoneStore=void 0,t.ColorZoneStore=class{constructor(){this._zones=[],this._zonePool=[],this._zonePoolIndex=0,this._linePadding={full:0,left:0,center:0,right:0}}get zones(){return this._zonePool.length=Math.min(this._zonePool.length,this._zones.length),this._zones}clear(){this._zones.length=0,this._zonePoolIndex=0}addDecoration(e){if(e.options.overviewRulerOptions){for(const t of this._zones)if(t.color===e.options.overviewRulerOptions.color&&t.position===e.options.overviewRulerOptions.position){if(this._lineIntersectsZone(t,e.marker.line))return;if(this._lineAdjacentToZone(t,e.marker.line,e.options.overviewRulerOptions.position))return void this._addLineToZone(t,e.marker.line)}if(this._zonePoolIndex=e.startBufferLine&&t<=e.endBufferLine}_lineAdjacentToZone(e,t,i){return t>=e.startBufferLine-this._linePadding[i||"full"]&&t<=e.endBufferLine+this._linePadding[i||"full"]}_addLineToZone(e,t){e.startBufferLine=Math.min(e.startBufferLine,t),e.endBufferLine=Math.max(e.endBufferLine,t)}}},5744:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OverviewRulerRenderer=void 0;const n=i(5871),o=i(3656),a=i(4725),h=i(844),c=i(2585),l={full:0,left:0,center:0,right:0},d={full:0,left:0,center:0,right:0},_={full:0,left:0,center:0,right:0};let u=t.OverviewRulerRenderer=class extends h.Disposable{get _width(){return this._optionsService.options.overviewRulerWidth||0}constructor(e,t,i,s,r,o,a){var c;super(),this._viewportElement=e,this._screenElement=t,this._bufferService=i,this._decorationService=s,this._renderService=r,this._optionsService=o,this._coreBrowseService=a,this._colorZoneStore=new n.ColorZoneStore,this._shouldUpdateDimensions=!0,this._shouldUpdateAnchor=!0,this._lastKnownBufferLength=0,this._canvas=document.createElement("canvas"),this._canvas.classList.add("xterm-decoration-overview-ruler"),this._refreshCanvasDimensions(),null===(c=this._viewportElement.parentElement)||void 0===c||c.insertBefore(this._canvas,this._viewportElement);const l=this._canvas.getContext("2d");if(!l)throw new Error("Ctx cannot be null");this._ctx=l,this._registerDecorationListeners(),this._registerBufferChangeListeners(),this._registerDimensionChangeListeners(),this.register((0,h.toDisposable)((()=>{var e;null===(e=this._canvas)||void 0===e||e.remove()})))}_registerDecorationListeners(){this.register(this._decorationService.onDecorationRegistered((()=>this._queueRefresh(void 0,!0)))),this.register(this._decorationService.onDecorationRemoved((()=>this._queueRefresh(void 0,!0))))}_registerBufferChangeListeners(){this.register(this._renderService.onRenderedViewportChange((()=>this._queueRefresh()))),this.register(this._bufferService.buffers.onBufferActivate((()=>{this._canvas.style.display=this._bufferService.buffer===this._bufferService.buffers.alt?"none":"block"}))),this.register(this._bufferService.onScroll((()=>{this._lastKnownBufferLength!==this._bufferService.buffers.normal.lines.length&&(this._refreshDrawHeightConstants(),this._refreshColorZonePadding())})))}_registerDimensionChangeListeners(){this.register(this._renderService.onRender((()=>{this._containerHeight&&this._containerHeight===this._screenElement.clientHeight||(this._queueRefresh(!0),this._containerHeight=this._screenElement.clientHeight)}))),this.register(this._optionsService.onSpecificOptionChange("overviewRulerWidth",(()=>this._queueRefresh(!0)))),this.register((0,o.addDisposableDomListener)(this._coreBrowseService.window,"resize",(()=>this._queueRefresh(!0)))),this._queueRefresh(!0)}_refreshDrawConstants(){const e=Math.floor(this._canvas.width/3),t=Math.ceil(this._canvas.width/3);d.full=this._canvas.width,d.left=e,d.center=t,d.right=e,this._refreshDrawHeightConstants(),_.full=0,_.left=0,_.center=d.left,_.right=d.left+d.center}_refreshDrawHeightConstants(){l.full=Math.round(2*this._coreBrowseService.dpr);const e=this._canvas.height/this._bufferService.buffer.lines.length,t=Math.round(Math.max(Math.min(e,12),6)*this._coreBrowseService.dpr);l.left=t,l.center=t,l.right=t}_refreshColorZonePadding(){this._colorZoneStore.setPadding({full:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*l.full),left:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*l.left),center:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*l.center),right:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*l.right)}),this._lastKnownBufferLength=this._bufferService.buffers.normal.lines.length}_refreshCanvasDimensions(){this._canvas.style.width=`${this._width}px`,this._canvas.width=Math.round(this._width*this._coreBrowseService.dpr),this._canvas.style.height=`${this._screenElement.clientHeight}px`,this._canvas.height=Math.round(this._screenElement.clientHeight*this._coreBrowseService.dpr),this._refreshDrawConstants(),this._refreshColorZonePadding()}_refreshDecorations(){this._shouldUpdateDimensions&&this._refreshCanvasDimensions(),this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height),this._colorZoneStore.clear();for(const t of this._decorationService.decorations)this._colorZoneStore.addDecoration(t);this._ctx.lineWidth=1;const e=this._colorZoneStore.zones;for(const t of e)"full"!==t.position&&this._renderColorZone(t);for(const t of e)"full"===t.position&&this._renderColorZone(t);this._shouldUpdateDimensions=!1,this._shouldUpdateAnchor=!1}_renderColorZone(e){this._ctx.fillStyle=e.color,this._ctx.fillRect(_[e.position||"full"],Math.round((this._canvas.height-1)*(e.startBufferLine/this._bufferService.buffers.active.lines.length)-l[e.position||"full"]/2),d[e.position||"full"],Math.round((this._canvas.height-1)*((e.endBufferLine-e.startBufferLine)/this._bufferService.buffers.active.lines.length)+l[e.position||"full"]))}_queueRefresh(e,t){this._shouldUpdateDimensions=e||this._shouldUpdateDimensions,this._shouldUpdateAnchor=t||this._shouldUpdateAnchor,void 0===this._animationFrame&&(this._animationFrame=this._coreBrowseService.window.requestAnimationFrame((()=>{this._refreshDecorations(),this._animationFrame=void 0})))}};t.OverviewRulerRenderer=u=s([r(2,c.IBufferService),r(3,c.IDecorationService),r(4,a.IRenderService),r(5,c.IOptionsService),r(6,a.ICoreBrowserService)],u)},2950:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CompositionHelper=void 0;const n=i(4725),o=i(2585),a=i(2584);let h=t.CompositionHelper=class{get isComposing(){return this._isComposing}constructor(e,t,i,s,r,n){this._textarea=e,this._compositionView=t,this._bufferService=i,this._optionsService=s,this._coreService=r,this._renderService=n,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0},this._dataAlreadySent=""}compositionstart(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._dataAlreadySent="",this._compositionView.classList.add("active")}compositionupdate(e){this._compositionView.textContent=e.data,this.updateCompositionElements(),setTimeout((()=>{this._compositionPosition.end=this._textarea.value.length}),0)}compositionend(){this._finalizeComposition(!0)}keydown(e){if(this._isComposing||this._isSendingComposition){if(229===e.keyCode)return!1;if(16===e.keyCode||17===e.keyCode||18===e.keyCode)return!1;this._finalizeComposition(!1)}return 229!==e.keyCode||(this._handleAnyTextareaChanges(),!1)}_finalizeComposition(e){if(this._compositionView.classList.remove("active"),this._isComposing=!1,e){const e={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout((()=>{if(this._isSendingComposition){let t;this._isSendingComposition=!1,e.start+=this._dataAlreadySent.length,t=this._isComposing?this._textarea.value.substring(e.start,e.end):this._textarea.value.substring(e.start),t.length>0&&this._coreService.triggerDataEvent(t,!0)}}),0)}else{this._isSendingComposition=!1;const e=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(e,!0)}}_handleAnyTextareaChanges(){const e=this._textarea.value;setTimeout((()=>{if(!this._isComposing){const t=this._textarea.value,i=t.replace(e,"");this._dataAlreadySent=i,t.length>e.length?this._coreService.triggerDataEvent(i,!0):t.lengththis.updateCompositionElements(!0)),0)}}};t.CompositionHelper=h=s([r(2,o.IBufferService),r(3,o.IOptionsService),r(4,o.ICoreService),r(5,n.IRenderService)],h)},9806:(e,t)=>{function i(e,t,i){const s=i.getBoundingClientRect(),r=e.getComputedStyle(i),n=parseInt(r.getPropertyValue("padding-left")),o=parseInt(r.getPropertyValue("padding-top"));return[t.clientX-s.left-n,t.clientY-s.top-o]}Object.defineProperty(t,"__esModule",{value:!0}),t.getCoords=t.getCoordsRelativeToElement=void 0,t.getCoordsRelativeToElement=i,t.getCoords=function(e,t,s,r,n,o,a,h,c){if(!o)return;const l=i(e,t,s);return l?(l[0]=Math.ceil((l[0]+(c?a/2:0))/a),l[1]=Math.ceil(l[1]/h),l[0]=Math.min(Math.max(l[0],1),r+(c?1:0)),l[1]=Math.min(Math.max(l[1],1),n),l):void 0}},9504:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.moveToCellSequence=void 0;const s=i(2584);function r(e,t,i,s){const r=e-n(e,i),a=t-n(t,i),l=Math.abs(r-a)-function(e,t,i){let s=0;const r=e-n(e,i),a=t-n(t,i);for(let n=0;n=0&&et?"A":"B"}function a(e,t,i,s,r,n){let o=e,a=t,h="";for(;o!==i||a!==s;)o+=r?1:-1,r&&o>n.cols-1?(h+=n.buffer.translateBufferLineToString(a,!1,e,o),o=0,e=0,a++):!r&&o<0&&(h+=n.buffer.translateBufferLineToString(a,!1,0,e+1),o=n.cols-1,e=o,a--);return h+n.buffer.translateBufferLineToString(a,!1,e,o)}function h(e,t){const i=t?"O":"[";return s.C0.ESC+i+e}function c(e,t){e=Math.floor(e);let i="";for(let s=0;s0?s-n(s,o):t;const _=s,u=function(e,t,i,s,o,a){let h;return h=r(i,s,o,a).length>0?s-n(s,o):t,e=i&&he?"D":"C",c(Math.abs(o-e),h(d,s));d=l>t?"D":"C";const _=Math.abs(l-t);return c(function(e,t){return t.cols-e}(l>t?e:o,i)+(_-1)*i.cols+1+((l>t?o:e)-1),h(d,s))}},1296:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DomRenderer=void 0;const n=i(3787),o=i(2550),a=i(2223),h=i(6171),c=i(4725),l=i(8055),d=i(8460),_=i(844),u=i(2585),f="xterm-dom-renderer-owner-",v="xterm-rows",p="xterm-fg-",g="xterm-bg-",m="xterm-focus",S="xterm-selection";let C=1,b=t.DomRenderer=class extends _.Disposable{constructor(e,t,i,s,r,a,c,l,u,p){super(),this._element=e,this._screenElement=t,this._viewportElement=i,this._linkifier2=s,this._charSizeService=a,this._optionsService=c,this._bufferService=l,this._coreBrowserService=u,this._themeService=p,this._terminalClass=C++,this._rowElements=[],this.onRequestRedraw=this.register(new d.EventEmitter).event,this._rowContainer=document.createElement("div"),this._rowContainer.classList.add(v),this._rowContainer.style.lineHeight="normal",this._rowContainer.setAttribute("aria-hidden","true"),this._refreshRowElements(this._bufferService.cols,this._bufferService.rows),this._selectionContainer=document.createElement("div"),this._selectionContainer.classList.add(S),this._selectionContainer.setAttribute("aria-hidden","true"),this.dimensions=(0,h.createRenderDimensions)(),this._updateDimensions(),this.register(this._optionsService.onOptionChange((()=>this._handleOptionsChanged()))),this.register(this._themeService.onChangeColors((e=>this._injectCss(e)))),this._injectCss(this._themeService.colors),this._rowFactory=r.createInstance(n.DomRendererRowFactory,document),this._element.classList.add(f+this._terminalClass),this._screenElement.appendChild(this._rowContainer),this._screenElement.appendChild(this._selectionContainer),this.register(this._linkifier2.onShowLinkUnderline((e=>this._handleLinkHover(e)))),this.register(this._linkifier2.onHideLinkUnderline((e=>this._handleLinkLeave(e)))),this.register((0,_.toDisposable)((()=>{this._element.classList.remove(f+this._terminalClass),this._rowContainer.remove(),this._selectionContainer.remove(),this._widthCache.dispose(),this._themeStyleElement.remove(),this._dimensionsStyleElement.remove()}))),this._widthCache=new o.WidthCache(document),this._widthCache.setFont(this._optionsService.rawOptions.fontFamily,this._optionsService.rawOptions.fontSize,this._optionsService.rawOptions.fontWeight,this._optionsService.rawOptions.fontWeightBold),this._setDefaultSpacing()}_updateDimensions(){const e=this._coreBrowserService.dpr;this.dimensions.device.char.width=this._charSizeService.width*e,this.dimensions.device.char.height=Math.ceil(this._charSizeService.height*e),this.dimensions.device.cell.width=this.dimensions.device.char.width+Math.round(this._optionsService.rawOptions.letterSpacing),this.dimensions.device.cell.height=Math.floor(this.dimensions.device.char.height*this._optionsService.rawOptions.lineHeight),this.dimensions.device.char.left=0,this.dimensions.device.char.top=0,this.dimensions.device.canvas.width=this.dimensions.device.cell.width*this._bufferService.cols,this.dimensions.device.canvas.height=this.dimensions.device.cell.height*this._bufferService.rows,this.dimensions.css.canvas.width=Math.round(this.dimensions.device.canvas.width/e),this.dimensions.css.canvas.height=Math.round(this.dimensions.device.canvas.height/e),this.dimensions.css.cell.width=this.dimensions.css.canvas.width/this._bufferService.cols,this.dimensions.css.cell.height=this.dimensions.css.canvas.height/this._bufferService.rows;for(const i of this._rowElements)i.style.width=`${this.dimensions.css.canvas.width}px`,i.style.height=`${this.dimensions.css.cell.height}px`,i.style.lineHeight=`${this.dimensions.css.cell.height}px`,i.style.overflow="hidden";this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._screenElement.appendChild(this._dimensionsStyleElement));const t=`${this._terminalSelector} .${v} span { display: inline-block; height: 100%; vertical-align: top;}`;this._dimensionsStyleElement.textContent=t,this._selectionContainer.style.height=this._viewportElement.style.height,this._screenElement.style.width=`${this.dimensions.css.canvas.width}px`,this._screenElement.style.height=`${this.dimensions.css.canvas.height}px`}_injectCss(e){this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._screenElement.appendChild(this._themeStyleElement));let t=`${this._terminalSelector} .${v} { color: ${e.foreground.css}; font-family: ${this._optionsService.rawOptions.fontFamily}; font-size: ${this._optionsService.rawOptions.fontSize}px; font-kerning: none; white-space: pre}`;t+=`${this._terminalSelector} .${v} .xterm-dim { color: ${l.color.multiplyOpacity(e.foreground,.5).css};}`,t+=`${this._terminalSelector} span:not(.xterm-bold) { font-weight: ${this._optionsService.rawOptions.fontWeight};}${this._terminalSelector} span.xterm-bold { font-weight: ${this._optionsService.rawOptions.fontWeightBold};}${this._terminalSelector} span.xterm-italic { font-style: italic;}`,t+="@keyframes blink_box_shadow_"+this._terminalClass+" { 50% { border-bottom-style: hidden; }}",t+="@keyframes blink_block_"+this._terminalClass+" { 0% {"+` background-color: ${e.cursor.css};`+` color: ${e.cursorAccent.css}; } 50% { background-color: inherit;`+` color: ${e.cursor.css}; }}`,t+=`${this._terminalSelector} .${v}.${m} .xterm-cursor.xterm-cursor-blink:not(.xterm-cursor-block) { animation: blink_box_shadow_`+this._terminalClass+" 1s step-end infinite;}"+`${this._terminalSelector} .${v}.${m} .xterm-cursor.xterm-cursor-blink.xterm-cursor-block { animation: blink_block_`+this._terminalClass+" 1s step-end infinite;}"+`${this._terminalSelector} .${v} .xterm-cursor.xterm-cursor-block {`+` background-color: ${e.cursor.css};`+` color: ${e.cursorAccent.css};}`+`${this._terminalSelector} .${v} .xterm-cursor.xterm-cursor-outline {`+` outline: 1px solid ${e.cursor.css}; outline-offset: -1px;}`+`${this._terminalSelector} .${v} .xterm-cursor.xterm-cursor-bar {`+` box-shadow: ${this._optionsService.rawOptions.cursorWidth}px 0 0 ${e.cursor.css} inset;}`+`${this._terminalSelector} .${v} .xterm-cursor.xterm-cursor-underline {`+` border-bottom: 1px ${e.cursor.css}; border-bottom-style: solid; height: calc(100% - 1px);}`,t+=`${this._terminalSelector} .${S} { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}${this._terminalSelector}.focus .${S} div { position: absolute; background-color: ${e.selectionBackgroundOpaque.css};}${this._terminalSelector} .${S} div { position: absolute; background-color: ${e.selectionInactiveBackgroundOpaque.css};}`;for(const[i,s]of e.ansi.entries())t+=`${this._terminalSelector} .${p}${i} { color: ${s.css}; }${this._terminalSelector} .${p}${i}.xterm-dim { color: ${l.color.multiplyOpacity(s,.5).css}; }${this._terminalSelector} .${g}${i} { background-color: ${s.css}; }`;t+=`${this._terminalSelector} .${p}${a.INVERTED_DEFAULT_COLOR} { color: ${l.color.opaque(e.background).css}; }${this._terminalSelector} .${p}${a.INVERTED_DEFAULT_COLOR}.xterm-dim { color: ${l.color.multiplyOpacity(l.color.opaque(e.background),.5).css}; }${this._terminalSelector} .${g}${a.INVERTED_DEFAULT_COLOR} { background-color: ${e.foreground.css}; }`,this._themeStyleElement.textContent=t}_setDefaultSpacing(){const e=this.dimensions.css.cell.width-this._widthCache.get("W",!1,!1);this._rowContainer.style.letterSpacing=`${e}px`,this._rowFactory.defaultSpacing=e}handleDevicePixelRatioChange(){this._updateDimensions(),this._widthCache.clear(),this._setDefaultSpacing()}_refreshRowElements(e,t){for(let i=this._rowElements.length;i<=t;i++){const e=document.createElement("div");this._rowContainer.appendChild(e),this._rowElements.push(e)}for(;this._rowElements.length>t;)this._rowContainer.removeChild(this._rowElements.pop())}handleResize(e,t){this._refreshRowElements(e,t),this._updateDimensions()}handleCharSizeChanged(){this._updateDimensions(),this._widthCache.clear(),this._setDefaultSpacing()}handleBlur(){this._rowContainer.classList.remove(m)}handleFocus(){this._rowContainer.classList.add(m),this.renderRows(this._bufferService.buffer.y,this._bufferService.buffer.y)}handleSelectionChanged(e,t,i){if(this._selectionContainer.replaceChildren(),this._rowFactory.handleSelectionChanged(e,t,i),this.renderRows(0,this._bufferService.rows-1),!e||!t)return;const s=e[1]-this._bufferService.buffer.ydisp,r=t[1]-this._bufferService.buffer.ydisp,n=Math.max(s,0),o=Math.min(r,this._bufferService.rows-1);if(n>=this._bufferService.rows||o<0)return;const a=document.createDocumentFragment();if(i){const i=e[0]>t[0];a.appendChild(this._createSelectionElement(n,i?t[0]:e[0],i?e[0]:t[0],o-n+1))}else{const i=s===n?e[0]:0,h=n===r?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(n,i,h));const c=o-n-1;if(a.appendChild(this._createSelectionElement(n+1,0,this._bufferService.cols,c)),n!==o){const e=r===o?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(o,0,e))}}this._selectionContainer.appendChild(a)}_createSelectionElement(e,t,i,s=1){const r=document.createElement("div");return r.style.height=s*this.dimensions.css.cell.height+"px",r.style.top=e*this.dimensions.css.cell.height+"px",r.style.left=t*this.dimensions.css.cell.width+"px",r.style.width=this.dimensions.css.cell.width*(i-t)+"px",r}handleCursorMove(){}_handleOptionsChanged(){this._updateDimensions(),this._injectCss(this._themeService.colors),this._widthCache.setFont(this._optionsService.rawOptions.fontFamily,this._optionsService.rawOptions.fontSize,this._optionsService.rawOptions.fontWeight,this._optionsService.rawOptions.fontWeightBold),this._setDefaultSpacing()}clear(){for(const e of this._rowElements)e.replaceChildren()}renderRows(e,t){const i=this._bufferService.buffer,s=i.ybase+i.y,r=Math.min(i.x,this._bufferService.cols-1),n=this._optionsService.rawOptions.cursorBlink,o=this._optionsService.rawOptions.cursorStyle,a=this._optionsService.rawOptions.cursorInactiveStyle;for(let h=e;h<=t;h++){const e=h+i.ydisp,t=this._rowElements[h],c=i.lines.get(e);if(!t||!c)break;t.replaceChildren(...this._rowFactory.createRow(c,e,e===s,o,a,r,n,this.dimensions.css.cell.width,this._widthCache,-1,-1))}}get _terminalSelector(){return`.${f}${this._terminalClass}`}_handleLinkHover(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!0)}_handleLinkLeave(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!1)}_setCellUnderline(e,t,i,s,r,n){i<0&&(e=0),s<0&&(t=0);const o=this._bufferService.rows-1;i=Math.max(Math.min(i,o),0),s=Math.max(Math.min(s,o),0),r=Math.min(r,this._bufferService.cols);const a=this._bufferService.buffer,h=a.ybase+a.y,c=Math.min(a.x,r-1),l=this._optionsService.rawOptions.cursorBlink,d=this._optionsService.rawOptions.cursorStyle,_=this._optionsService.rawOptions.cursorInactiveStyle;for(let u=i;u<=s;++u){const o=u+a.ydisp,f=this._rowElements[u],v=a.lines.get(o);if(!f||!v)break;f.replaceChildren(...this._rowFactory.createRow(v,o,o===h,d,_,c,l,this.dimensions.css.cell.width,this._widthCache,n?u===i?e:0:-1,n?(u===s?t:r)-1:-1))}}};t.DomRenderer=b=s([r(4,u.IInstantiationService),r(5,c.ICharSizeService),r(6,u.IOptionsService),r(7,u.IBufferService),r(8,c.ICoreBrowserService),r(9,c.IThemeService)],b)},3787:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DomRendererRowFactory=void 0;const n=i(2223),o=i(643),a=i(511),h=i(2585),c=i(8055),l=i(4725),d=i(4269),_=i(6171),u=i(3734);let f=t.DomRendererRowFactory=class{constructor(e,t,i,s,r,n,o){this._document=e,this._characterJoinerService=t,this._optionsService=i,this._coreBrowserService=s,this._coreService=r,this._decorationService=n,this._themeService=o,this._workCell=new a.CellData,this._columnSelectMode=!1,this.defaultSpacing=0}handleSelectionChanged(e,t,i){this._selectionStart=e,this._selectionEnd=t,this._columnSelectMode=i}createRow(e,t,i,s,r,a,h,l,_,f,p){const g=[],m=this._characterJoinerService.getJoinedCharacters(t),S=this._themeService.colors;let C,b=e.getNoBgTrimmedLength();i&&b0&&M===m[0][0]){O=!0;const t=m.shift();I=new d.JoinedCellData(this._workCell,e.translateToString(!0,t[0],t[1]),t[1]-t[0]),P=t[1]-1,b=I.getWidth()}const H=this._isCellInSelection(M,t),F=i&&M===a,W=T&&M>=f&&M<=p;let U=!1;this._decorationService.forEachDecorationAtCell(M,t,void 0,(e=>{U=!0}));let N=I.getChars()||o.WHITESPACE_CELL_CHAR;if(" "===N&&(I.isUnderline()||I.isOverline())&&(N="\xa0"),A=b*l-_.get(N,I.isBold(),I.isItalic()),C){if(y&&(H&&x||!H&&!x&&I.bg===E)&&(H&&x&&S.selectionForeground||I.fg===k)&&I.extended.ext===L&&W===D&&A===R&&!F&&!O&&!U){w+=N,y++;continue}y&&(C.textContent=w),C=this._document.createElement("span"),y=0,w=""}else C=this._document.createElement("span");if(E=I.bg,k=I.fg,L=I.extended.ext,D=W,R=A,x=H,O&&a>=M&&a<=P&&(a=M),!this._coreService.isCursorHidden&&F)if(B.push("xterm-cursor"),this._coreBrowserService.isFocused)h&&B.push("xterm-cursor-blink"),B.push("bar"===s?"xterm-cursor-bar":"underline"===s?"xterm-cursor-underline":"xterm-cursor-block");else if(r)switch(r){case"outline":B.push("xterm-cursor-outline");break;case"block":B.push("xterm-cursor-block");break;case"bar":B.push("xterm-cursor-bar");break;case"underline":B.push("xterm-cursor-underline")}if(I.isBold()&&B.push("xterm-bold"),I.isItalic()&&B.push("xterm-italic"),I.isDim()&&B.push("xterm-dim"),w=I.isInvisible()?o.WHITESPACE_CELL_CHAR:I.getChars()||o.WHITESPACE_CELL_CHAR,I.isUnderline()&&(B.push(`xterm-underline-${I.extended.underlineStyle}`)," "===w&&(w="\xa0"),!I.isUnderlineColorDefault()))if(I.isUnderlineColorRGB())C.style.textDecorationColor=`rgb(${u.AttributeData.toColorRGB(I.getUnderlineColor()).join(",")})`;else{let e=I.getUnderlineColor();this._optionsService.rawOptions.drawBoldTextInBrightColors&&I.isBold()&&e<8&&(e+=8),C.style.textDecorationColor=S.ansi[e].css}I.isOverline()&&(B.push("xterm-overline")," "===w&&(w="\xa0")),I.isStrikethrough()&&B.push("xterm-strikethrough"),W&&(C.style.textDecoration="underline");let $=I.getFgColor(),j=I.getFgColorMode(),z=I.getBgColor(),K=I.getBgColorMode();const q=!!I.isInverse();if(q){const e=$;$=z,z=e;const t=j;j=K,K=t}let V,G,X,J=!1;switch(this._decorationService.forEachDecorationAtCell(M,t,void 0,(e=>{"top"!==e.options.layer&&J||(e.backgroundColorRGB&&(K=50331648,z=e.backgroundColorRGB.rgba>>8&16777215,V=e.backgroundColorRGB),e.foregroundColorRGB&&(j=50331648,$=e.foregroundColorRGB.rgba>>8&16777215,G=e.foregroundColorRGB),J="top"===e.options.layer)})),!J&&H&&(V=this._coreBrowserService.isFocused?S.selectionBackgroundOpaque:S.selectionInactiveBackgroundOpaque,z=V.rgba>>8&16777215,K=50331648,J=!0,S.selectionForeground&&(j=50331648,$=S.selectionForeground.rgba>>8&16777215,G=S.selectionForeground)),J&&B.push("xterm-decoration-top"),K){case 16777216:case 33554432:X=S.ansi[z],B.push(`xterm-bg-${z}`);break;case 50331648:X=c.rgba.toColor(z>>16,z>>8&255,255&z),this._addStyle(C,`background-color:#${v((z>>>0).toString(16),"0",6)}`);break;default:q?(X=S.foreground,B.push(`xterm-bg-${n.INVERTED_DEFAULT_COLOR}`)):X=S.background}switch(V||I.isDim()&&(V=c.color.multiplyOpacity(X,.5)),j){case 16777216:case 33554432:I.isBold()&&$<8&&this._optionsService.rawOptions.drawBoldTextInBrightColors&&($+=8),this._applyMinimumContrast(C,X,S.ansi[$],I,V,void 0)||B.push(`xterm-fg-${$}`);break;case 50331648:const e=c.rgba.toColor($>>16&255,$>>8&255,255&$);this._applyMinimumContrast(C,X,e,I,V,G)||this._addStyle(C,`color:#${v($.toString(16),"0",6)}`);break;default:this._applyMinimumContrast(C,X,S.foreground,I,V,void 0)||q&&B.push(`xterm-fg-${n.INVERTED_DEFAULT_COLOR}`)}B.length&&(C.className=B.join(" "),B.length=0),F||O||U?C.textContent=w:y++,A!==this.defaultSpacing&&(C.style.letterSpacing=`${A}px`),g.push(C),M=P}return C&&y&&(C.textContent=w),g}_applyMinimumContrast(e,t,i,s,r,n){if(1===this._optionsService.rawOptions.minimumContrastRatio||(0,_.excludeFromContrastRatioDemands)(s.getCode()))return!1;const o=this._getContrastCache(s);let a;if(r||n||(a=o.getColor(t.rgba,i.rgba)),void 0===a){const e=this._optionsService.rawOptions.minimumContrastRatio/(s.isDim()?2:1);a=c.color.ensureContrastRatio(r||t,n||i,e),o.setColor((r||t).rgba,(n||i).rgba,null!=a?a:null)}return!!a&&(this._addStyle(e,`color:${a.css}`),!0)}_getContrastCache(e){return e.isDim()?this._themeService.colors.halfContrastCache:this._themeService.colors.contrastCache}_addStyle(e,t){e.setAttribute("style",`${e.getAttribute("style")||""}${t};`)}_isCellInSelection(e,t){const i=this._selectionStart,s=this._selectionEnd;return!(!i||!s)&&(this._columnSelectMode?i[0]<=s[0]?e>=i[0]&&t>=i[1]&&e=i[1]&&e>=s[0]&&t<=s[1]:t>i[1]&&t=i[0]&&e=i[0])}};function v(e,t,i){for(;e.length{Object.defineProperty(t,"__esModule",{value:!0}),t.WidthCache=void 0,t.WidthCache=class{constructor(e){this._flat=new Float32Array(256),this._font="",this._fontSize=0,this._weight="normal",this._weightBold="bold",this._measureElements=[],this._container=e.createElement("div"),this._container.style.position="absolute",this._container.style.top="-50000px",this._container.style.width="50000px",this._container.style.whiteSpace="pre",this._container.style.fontKerning="none";const t=e.createElement("span"),i=e.createElement("span");i.style.fontWeight="bold";const s=e.createElement("span");s.style.fontStyle="italic";const r=e.createElement("span");r.style.fontWeight="bold",r.style.fontStyle="italic",this._measureElements=[t,i,s,r],this._container.appendChild(t),this._container.appendChild(i),this._container.appendChild(s),this._container.appendChild(r),e.body.appendChild(this._container),this.clear()}dispose(){this._container.remove(),this._measureElements.length=0,this._holey=void 0}clear(){this._flat.fill(-9999),this._holey=new Map}setFont(e,t,i,s){e===this._font&&t===this._fontSize&&i===this._weight&&s===this._weightBold||(this._font=e,this._fontSize=t,this._weight=i,this._weightBold=s,this._container.style.fontFamily=this._font,this._container.style.fontSize=`${this._fontSize}px`,this._measureElements[0].style.fontWeight=`${i}`,this._measureElements[1].style.fontWeight=`${s}`,this._measureElements[2].style.fontWeight=`${i}`,this._measureElements[3].style.fontWeight=`${s}`,this.clear())}get(e,t,i){let s=0;if(!t&&!i&&1===e.length&&(s=e.charCodeAt(0))<256)return-9999!==this._flat[s]?this._flat[s]:this._flat[s]=this._measure(e,0);let r=e;t&&(r+="B"),i&&(r+="I");let n=this._holey.get(r);if(void 0===n){let s=0;t&&(s|=1),i&&(s|=2),n=this._measure(e,s),this._holey.set(r,n)}return n}_measure(e,t){const i=this._measureElements[t];return i.textContent=e.repeat(32),i.offsetWidth/32}}},2223:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TEXT_BASELINE=t.DIM_OPACITY=t.INVERTED_DEFAULT_COLOR=void 0;const s=i(6114);t.INVERTED_DEFAULT_COLOR=257,t.DIM_OPACITY=.5,t.TEXT_BASELINE=s.isFirefox||s.isLegacyEdge?"bottom":"ideographic"},6171:(e,t)=>{function i(e){return 57508<=e&&e<=57558}Object.defineProperty(t,"__esModule",{value:!0}),t.createRenderDimensions=t.excludeFromContrastRatioDemands=t.isRestrictedPowerlineGlyph=t.isPowerlineGlyph=t.throwIfFalsy=void 0,t.throwIfFalsy=function(e){if(!e)throw new Error("value must not be falsy");return e},t.isPowerlineGlyph=i,t.isRestrictedPowerlineGlyph=function(e){return 57520<=e&&e<=57527},t.excludeFromContrastRatioDemands=function(e){return i(e)||function(e){return 9472<=e&&e<=9631}(e)},t.createRenderDimensions=function(){return{css:{canvas:{width:0,height:0},cell:{width:0,height:0}},device:{canvas:{width:0,height:0},cell:{width:0,height:0},char:{width:0,height:0,left:0,top:0}}}}},456:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionModel=void 0,t.SelectionModel=class{constructor(e){this._bufferService=e,this.isSelectAllActive=!1,this.selectionStartLength=0}clearSelection(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0}get finalSelectionStart(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart}get finalSelectionEnd(){if(this.isSelectAllActive)return[this._bufferService.cols,this._bufferService.buffer.ybase+this._bufferService.rows-1];if(this.selectionStart){if(!this.selectionEnd||this.areSelectionValuesReversed()){const e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?e%this._bufferService.cols==0?[this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)-1]:[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[e,this.selectionStart[1]]}if(this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]){const e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[Math.max(e,this.selectionEnd[0]),this.selectionEnd[1]]}return this.selectionEnd}}areSelectionValuesReversed(){const e=this.selectionStart,t=this.selectionEnd;return!(!e||!t)&&(e[1]>t[1]||e[1]===t[1]&&e[0]>t[0])}handleTrim(e){return this.selectionStart&&(this.selectionStart[1]-=e),this.selectionEnd&&(this.selectionEnd[1]-=e),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)}}},428:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharSizeService=void 0;const n=i(2585),o=i(8460),a=i(844);let h=t.CharSizeService=class extends a.Disposable{get hasValidSize(){return this.width>0&&this.height>0}constructor(e,t,i){super(),this._optionsService=i,this.width=0,this.height=0,this._onCharSizeChange=this.register(new o.EventEmitter),this.onCharSizeChange=this._onCharSizeChange.event,this._measureStrategy=new c(e,t,this._optionsService),this.register(this._optionsService.onMultipleOptionChange(["fontFamily","fontSize"],(()=>this.measure())))}measure(){const e=this._measureStrategy.measure();e.width===this.width&&e.height===this.height||(this.width=e.width,this.height=e.height,this._onCharSizeChange.fire())}};t.CharSizeService=h=s([r(2,n.IOptionsService)],h);class c{constructor(e,t,i){this._document=e,this._parentElement=t,this._optionsService=i,this._result={width:0,height:0},this._measureElement=this._document.createElement("span"),this._measureElement.classList.add("xterm-char-measure-element"),this._measureElement.textContent="W".repeat(32),this._measureElement.setAttribute("aria-hidden","true"),this._measureElement.style.whiteSpace="pre",this._measureElement.style.fontKerning="none",this._parentElement.appendChild(this._measureElement)}measure(){this._measureElement.style.fontFamily=this._optionsService.rawOptions.fontFamily,this._measureElement.style.fontSize=`${this._optionsService.rawOptions.fontSize}px`;const e={height:Number(this._measureElement.offsetHeight),width:Number(this._measureElement.offsetWidth)};return 0!==e.width&&0!==e.height&&(this._result.width=e.width/32,this._result.height=Math.ceil(e.height)),this._result}}},4269:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharacterJoinerService=t.JoinedCellData=void 0;const n=i(3734),o=i(643),a=i(511),h=i(2585);class c extends n.AttributeData{constructor(e,t,i){super(),this.content=0,this.combinedData="",this.fg=e.fg,this.bg=e.bg,this.combinedData=t,this._width=i}isCombined(){return 2097152}getWidth(){return this._width}getChars(){return this.combinedData}getCode(){return 2097151}setFromCharData(e){throw new Error("not implemented")}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}t.JoinedCellData=c;let l=t.CharacterJoinerService=class e{constructor(e){this._bufferService=e,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new a.CellData}register(e){const t={id:this._nextCharacterJoinerId++,handler:e};return this._characterJoiners.push(t),t.id}deregister(e){for(let t=0;t1){const e=this._getJoinedRanges(s,a,n,t,r);for(let t=0;t1){const e=this._getJoinedRanges(s,a,n,t,r);for(let t=0;t{Object.defineProperty(t,"__esModule",{value:!0}),t.CoreBrowserService=void 0,t.CoreBrowserService=class{constructor(e,t){this._textarea=e,this.window=t,this._isFocused=!1,this._cachedIsFocused=void 0,this._textarea.addEventListener("focus",(()=>this._isFocused=!0)),this._textarea.addEventListener("blur",(()=>this._isFocused=!1))}get dpr(){return this.window.devicePixelRatio}get isFocused(){return void 0===this._cachedIsFocused&&(this._cachedIsFocused=this._isFocused&&this._textarea.ownerDocument.hasFocus(),queueMicrotask((()=>this._cachedIsFocused=void 0))),this._cachedIsFocused}}},8934:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MouseService=void 0;const n=i(4725),o=i(9806);let a=t.MouseService=class{constructor(e,t){this._renderService=e,this._charSizeService=t}getCoords(e,t,i,s,r){return(0,o.getCoords)(window,e,t,i,s,this._charSizeService.hasValidSize,this._renderService.dimensions.css.cell.width,this._renderService.dimensions.css.cell.height,r)}getMouseReportCoords(e,t){const i=(0,o.getCoordsRelativeToElement)(window,e,t);if(this._charSizeService.hasValidSize)return i[0]=Math.min(Math.max(i[0],0),this._renderService.dimensions.css.canvas.width-1),i[1]=Math.min(Math.max(i[1],0),this._renderService.dimensions.css.canvas.height-1),{col:Math.floor(i[0]/this._renderService.dimensions.css.cell.width),row:Math.floor(i[1]/this._renderService.dimensions.css.cell.height),x:Math.floor(i[0]),y:Math.floor(i[1])}}};t.MouseService=a=s([r(0,n.IRenderService),r(1,n.ICharSizeService)],a)},3230:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.RenderService=void 0;const n=i(3656),o=i(6193),a=i(5596),h=i(4725),c=i(8460),l=i(844),d=i(7226),_=i(2585);let u=t.RenderService=class extends l.Disposable{get dimensions(){return this._renderer.value.dimensions}constructor(e,t,i,s,r,h,_,u){if(super(),this._rowCount=e,this._charSizeService=s,this._renderer=this.register(new l.MutableDisposable),this._pausedResizeTask=new d.DebouncedIdleTask,this._isPaused=!1,this._needsFullRefresh=!1,this._isNextRenderRedrawOnly=!0,this._needsSelectionRefresh=!1,this._canvasWidth=0,this._canvasHeight=0,this._selectionState={start:void 0,end:void 0,columnSelectMode:!1},this._onDimensionsChange=this.register(new c.EventEmitter),this.onDimensionsChange=this._onDimensionsChange.event,this._onRenderedViewportChange=this.register(new c.EventEmitter),this.onRenderedViewportChange=this._onRenderedViewportChange.event,this._onRender=this.register(new c.EventEmitter),this.onRender=this._onRender.event,this._onRefreshRequest=this.register(new c.EventEmitter),this.onRefreshRequest=this._onRefreshRequest.event,this._renderDebouncer=new o.RenderDebouncer(_.window,((e,t)=>this._renderRows(e,t))),this.register(this._renderDebouncer),this._screenDprMonitor=new a.ScreenDprMonitor(_.window),this._screenDprMonitor.setListener((()=>this.handleDevicePixelRatioChange())),this.register(this._screenDprMonitor),this.register(h.onResize((()=>this._fullRefresh()))),this.register(h.buffers.onBufferActivate((()=>{var e;return null===(e=this._renderer.value)||void 0===e?void 0:e.clear()}))),this.register(i.onOptionChange((()=>this._handleOptionsChanged()))),this.register(this._charSizeService.onCharSizeChange((()=>this.handleCharSizeChanged()))),this.register(r.onDecorationRegistered((()=>this._fullRefresh()))),this.register(r.onDecorationRemoved((()=>this._fullRefresh()))),this.register(i.onMultipleOptionChange(["customGlyphs","drawBoldTextInBrightColors","letterSpacing","lineHeight","fontFamily","fontSize","fontWeight","fontWeightBold","minimumContrastRatio"],(()=>{this.clear(),this.handleResize(h.cols,h.rows),this._fullRefresh()}))),this.register(i.onMultipleOptionChange(["cursorBlink","cursorStyle"],(()=>this.refreshRows(h.buffer.y,h.buffer.y,!0)))),this.register((0,n.addDisposableDomListener)(_.window,"resize",(()=>this.handleDevicePixelRatioChange()))),this.register(u.onChangeColors((()=>this._fullRefresh()))),"IntersectionObserver"in _.window){const e=new _.window.IntersectionObserver((e=>this._handleIntersectionChange(e[e.length-1])),{threshold:0});e.observe(t),this.register({dispose:()=>e.disconnect()})}}_handleIntersectionChange(e){this._isPaused=void 0===e.isIntersecting?0===e.intersectionRatio:!e.isIntersecting,this._isPaused||this._charSizeService.hasValidSize||this._charSizeService.measure(),!this._isPaused&&this._needsFullRefresh&&(this._pausedResizeTask.flush(),this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)}refreshRows(e,t,i=!1){this._isPaused?this._needsFullRefresh=!0:(i||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(e,t,this._rowCount))}_renderRows(e,t){this._renderer.value&&(e=Math.min(e,this._rowCount-1),t=Math.min(t,this._rowCount-1),this._renderer.value.renderRows(e,t),this._needsSelectionRefresh&&(this._renderer.value.handleSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRenderedViewportChange.fire({start:e,end:t}),this._onRender.fire({start:e,end:t}),this._isNextRenderRedrawOnly=!0)}resize(e,t){this._rowCount=t,this._fireOnCanvasResize()}_handleOptionsChanged(){this._renderer.value&&(this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize())}_fireOnCanvasResize(){this._renderer.value&&(this._renderer.value.dimensions.css.canvas.width===this._canvasWidth&&this._renderer.value.dimensions.css.canvas.height===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.value.dimensions))}hasRenderer(){return!!this._renderer.value}setRenderer(e){this._renderer.value=e,this._renderer.value.onRequestRedraw((e=>this.refreshRows(e.start,e.end,!0))),this._needsSelectionRefresh=!0,this._fullRefresh()}addRefreshCallback(e){return this._renderDebouncer.addRefreshCallback(e)}_fullRefresh(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)}clearTextureAtlas(){var e,t;this._renderer.value&&(null===(t=(e=this._renderer.value).clearTextureAtlas)||void 0===t||t.call(e),this._fullRefresh())}handleDevicePixelRatioChange(){this._charSizeService.measure(),this._renderer.value&&(this._renderer.value.handleDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1))}handleResize(e,t){this._renderer.value&&(this._isPaused?this._pausedResizeTask.set((()=>this._renderer.value.handleResize(e,t))):this._renderer.value.handleResize(e,t),this._fullRefresh())}handleCharSizeChanged(){var e;null===(e=this._renderer.value)||void 0===e||e.handleCharSizeChanged()}handleBlur(){var e;null===(e=this._renderer.value)||void 0===e||e.handleBlur()}handleFocus(){var e;null===(e=this._renderer.value)||void 0===e||e.handleFocus()}handleSelectionChanged(e,t,i){var s;this._selectionState.start=e,this._selectionState.end=t,this._selectionState.columnSelectMode=i,null===(s=this._renderer.value)||void 0===s||s.handleSelectionChanged(e,t,i)}handleCursorMove(){var e;null===(e=this._renderer.value)||void 0===e||e.handleCursorMove()}clear(){var e;null===(e=this._renderer.value)||void 0===e||e.clear()}};t.RenderService=u=s([r(2,_.IOptionsService),r(3,h.ICharSizeService),r(4,_.IDecorationService),r(5,_.IBufferService),r(6,h.ICoreBrowserService),r(7,h.IThemeService)],u)},9312:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionService=void 0;const n=i(9806),o=i(9504),a=i(456),h=i(4725),c=i(8460),l=i(844),d=i(6114),_=i(4841),u=i(511),f=i(2585),v=String.fromCharCode(160),p=new RegExp(v,"g");let g=t.SelectionService=class extends l.Disposable{constructor(e,t,i,s,r,n,o,h,d){super(),this._element=e,this._screenElement=t,this._linkifier=i,this._bufferService=s,this._coreService=r,this._mouseService=n,this._optionsService=o,this._renderService=h,this._coreBrowserService=d,this._dragScrollAmount=0,this._enabled=!0,this._workCell=new u.CellData,this._mouseDownTimeStamp=0,this._oldHasSelection=!1,this._oldSelectionStart=void 0,this._oldSelectionEnd=void 0,this._onLinuxMouseSelection=this.register(new c.EventEmitter),this.onLinuxMouseSelection=this._onLinuxMouseSelection.event,this._onRedrawRequest=this.register(new c.EventEmitter),this.onRequestRedraw=this._onRedrawRequest.event,this._onSelectionChange=this.register(new c.EventEmitter),this.onSelectionChange=this._onSelectionChange.event,this._onRequestScrollLines=this.register(new c.EventEmitter),this.onRequestScrollLines=this._onRequestScrollLines.event,this._mouseMoveListener=e=>this._handleMouseMove(e),this._mouseUpListener=e=>this._handleMouseUp(e),this._coreService.onUserInput((()=>{this.hasSelection&&this.clearSelection()})),this._trimListener=this._bufferService.buffer.lines.onTrim((e=>this._handleTrim(e))),this.register(this._bufferService.buffers.onBufferActivate((e=>this._handleBufferActivate(e)))),this.enable(),this._model=new a.SelectionModel(this._bufferService),this._activeSelectionMode=0,this.register((0,l.toDisposable)((()=>{this._removeMouseDownListeners()})))}reset(){this.clearSelection()}disable(){this.clearSelection(),this._enabled=!1}enable(){this._enabled=!0}get selectionStart(){return this._model.finalSelectionStart}get selectionEnd(){return this._model.finalSelectionEnd}get hasSelection(){const e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;return!(!e||!t||e[0]===t[0]&&e[1]===t[1])}get selectionText(){const e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;if(!e||!t)return"";const i=this._bufferService.buffer,s=[];if(3===this._activeSelectionMode){if(e[0]===t[0])return"";const r=e[0]e.replace(p," "))).join(d.isWindows?"\r\n":"\n")}clearSelection(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()}refresh(e){this._refreshAnimationFrame||(this._refreshAnimationFrame=this._coreBrowserService.window.requestAnimationFrame((()=>this._refresh()))),d.isLinux&&e&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)}_refresh(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:3===this._activeSelectionMode})}_isClickInSelection(e){const t=this._getMouseBufferCoords(e),i=this._model.finalSelectionStart,s=this._model.finalSelectionEnd;return!!(i&&s&&t)&&this._areCoordsInSelection(t,i,s)}isCellInSelection(e,t){const i=this._model.finalSelectionStart,s=this._model.finalSelectionEnd;return!(!i||!s)&&this._areCoordsInSelection([e,t],i,s)}_areCoordsInSelection(e,t,i){return e[1]>t[1]&&e[1]=t[0]&&e[0]=t[0]}_selectWordAtCursor(e,t){var i,s;const r=null===(s=null===(i=this._linkifier.currentLink)||void 0===i?void 0:i.link)||void 0===s?void 0:s.range;if(r)return this._model.selectionStart=[r.start.x-1,r.start.y-1],this._model.selectionStartLength=(0,_.getRangeLength)(r,this._bufferService.cols),this._model.selectionEnd=void 0,!0;const n=this._getMouseBufferCoords(e);return!!n&&(this._selectWordAt(n,t),this._model.selectionEnd=void 0,!0)}selectAll(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()}selectLines(e,t){this._model.clearSelection(),e=Math.max(e,0),t=Math.min(t,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,e],this._model.selectionEnd=[this._bufferService.cols,t],this.refresh(),this._onSelectionChange.fire()}_handleTrim(e){this._model.handleTrim(e)&&this.refresh()}_getMouseBufferCoords(e){const t=this._mouseService.getCoords(e,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(t)return t[0]--,t[1]--,t[1]+=this._bufferService.buffer.ydisp,t}_getMouseEventScrollAmount(e){let t=(0,n.getCoordsRelativeToElement)(this._coreBrowserService.window,e,this._screenElement)[1];const i=this._renderService.dimensions.css.canvas.height;return t>=0&&t<=i?0:(t>i&&(t-=i),t=Math.min(Math.max(t,-50),50),t/=50,t/Math.abs(t)+Math.round(14*t))}shouldForceSelection(e){return d.isMac?e.altKey&&this._optionsService.rawOptions.macOptionClickForcesSelection:e.shiftKey}handleMouseDown(e){if(this._mouseDownTimeStamp=e.timeStamp,(2!==e.button||!this.hasSelection)&&0===e.button){if(!this._enabled){if(!this.shouldForceSelection(e))return;e.stopPropagation()}e.preventDefault(),this._dragScrollAmount=0,this._enabled&&e.shiftKey?this._handleIncrementalClick(e):1===e.detail?this._handleSingleClick(e):2===e.detail?this._handleDoubleClick(e):3===e.detail&&this._handleTripleClick(e),this._addMouseDownListeners(),this.refresh(!0)}}_addMouseDownListeners(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=this._coreBrowserService.window.setInterval((()=>this._dragScroll()),50)}_removeMouseDownListeners(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.removeEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.removeEventListener("mouseup",this._mouseUpListener)),this._coreBrowserService.window.clearInterval(this._dragScrollIntervalTimer),this._dragScrollIntervalTimer=void 0}_handleIncrementalClick(e){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(e))}_handleSingleClick(e){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(e)?3:0,this._model.selectionStart=this._getMouseBufferCoords(e),!this._model.selectionStart)return;this._model.selectionEnd=void 0;const t=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);t&&t.length!==this._model.selectionStart[0]&&0===t.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++}_handleDoubleClick(e){this._selectWordAtCursor(e,!0)&&(this._activeSelectionMode=1)}_handleTripleClick(e){const t=this._getMouseBufferCoords(e);t&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))}shouldColumnSelect(e){return e.altKey&&!(d.isMac&&this._optionsService.rawOptions.macOptionClickForcesSelection)}_handleMouseMove(e){if(e.stopImmediatePropagation(),!this._model.selectionStart)return;const t=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(e),!this._model.selectionEnd)return void this.refresh(!0);2===this._activeSelectionMode?this._model.selectionEnd[1]0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));const i=this._bufferService.buffer;if(this._model.selectionEnd[1]0?(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(e.ydisp+this._bufferService.rows,e.lines.length-1)):(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=e.ydisp),this.refresh()}}_handleMouseUp(e){const t=e.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&t<500&&e.altKey&&this._optionsService.rawOptions.altClickMovesCursor){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){const t=this._mouseService.getCoords(e,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(t&&void 0!==t[0]&&void 0!==t[1]){const e=(0,o.moveToCellSequence)(t[0]-1,t[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(e,!0)}}}else this._fireEventIfSelectionChanged()}_fireEventIfSelectionChanged(){const e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd,i=!(!e||!t||e[0]===t[0]&&e[1]===t[1]);i?e&&t&&(this._oldSelectionStart&&this._oldSelectionEnd&&e[0]===this._oldSelectionStart[0]&&e[1]===this._oldSelectionStart[1]&&t[0]===this._oldSelectionEnd[0]&&t[1]===this._oldSelectionEnd[1]||this._fireOnSelectionChange(e,t,i)):this._oldHasSelection&&this._fireOnSelectionChange(e,t,i)}_fireOnSelectionChange(e,t,i){this._oldSelectionStart=e,this._oldSelectionEnd=t,this._oldHasSelection=i,this._onSelectionChange.fire()}_handleBufferActivate(e){this.clearSelection(),this._trimListener.dispose(),this._trimListener=e.activeBuffer.lines.onTrim((e=>this._handleTrim(e)))}_convertViewportColToCharacterIndex(e,t){let i=t;for(let s=0;t>=s;s++){const r=e.loadCell(s,this._workCell).getChars().length;0===this._workCell.getWidth()?i--:r>1&&t!==s&&(i+=r-1)}return i}setSelection(e,t,i){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[e,t],this._model.selectionStartLength=i,this.refresh(),this._fireEventIfSelectionChanged()}rightClickSelect(e){this._isClickInSelection(e)||(this._selectWordAtCursor(e,!1)&&this.refresh(!0),this._fireEventIfSelectionChanged())}_getWordAt(e,t,i=!0,s=!0){if(e[0]>=this._bufferService.cols)return;const r=this._bufferService.buffer,n=r.lines.get(e[1]);if(!n)return;const o=r.translateBufferLineToString(e[1],!1);let a=this._convertViewportColToCharacterIndex(n,e[0]),h=a;const c=e[0]-a;let l=0,d=0,_=0,u=0;if(" "===o.charAt(a)){for(;a>0&&" "===o.charAt(a-1);)a--;for(;h1&&(u+=s-1,h+=s-1);t>0&&a>0&&!this._isCharWordSeparator(n.loadCell(t-1,this._workCell));){n.loadCell(t-1,this._workCell);const e=this._workCell.getChars().length;0===this._workCell.getWidth()?(l++,t--):e>1&&(_+=e-1,a-=e-1),a--,t--}for(;i1&&(u+=e-1,h+=e-1),h++,i++}}h++;let f=a+c-l+_,v=Math.min(this._bufferService.cols,h-a+l+d-_-u);if(t||""!==o.slice(a,h).trim()){if(i&&0===f&&32!==n.getCodePoint(0)){const t=r.lines.get(e[1]-1);if(t&&n.isWrapped&&32!==t.getCodePoint(this._bufferService.cols-1)){const t=this._getWordAt([this._bufferService.cols-1,e[1]-1],!1,!0,!1);if(t){const e=this._bufferService.cols-t.start;f-=e,v+=e}}}if(s&&f+v===this._bufferService.cols&&32!==n.getCodePoint(this._bufferService.cols-1)){const t=r.lines.get(e[1]+1);if((null==t?void 0:t.isWrapped)&&32!==t.getCodePoint(0)){const t=this._getWordAt([0,e[1]+1],!1,!1,!0);t&&(v+=t.length)}}return{start:f,length:v}}}_selectWordAt(e,t){const i=this._getWordAt(e,t);if(i){for(;i.start<0;)i.start+=this._bufferService.cols,e[1]--;this._model.selectionStart=[i.start,e[1]],this._model.selectionStartLength=i.length}}_selectToWordAt(e){const t=this._getWordAt(e,!0);if(t){let i=e[1];for(;t.start<0;)t.start+=this._bufferService.cols,i--;if(!this._model.areSelectionValuesReversed())for(;t.start+t.length>this._bufferService.cols;)t.length-=this._bufferService.cols,i++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?t.start:t.start+t.length,i]}}_isCharWordSeparator(e){return 0!==e.getWidth()&&this._optionsService.rawOptions.wordSeparator.indexOf(e.getChars())>=0}_selectLineAt(e){const t=this._bufferService.buffer.getWrappedRangeForLine(e),i={start:{x:0,y:t.first},end:{x:this._bufferService.cols-1,y:t.last}};this._model.selectionStart=[0,t.first],this._model.selectionEnd=void 0,this._model.selectionStartLength=(0,_.getRangeLength)(i,this._bufferService.cols)}};t.SelectionService=g=s([r(3,f.IBufferService),r(4,f.ICoreService),r(5,h.IMouseService),r(6,f.IOptionsService),r(7,h.IRenderService),r(8,h.ICoreBrowserService)],g)},4725:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.IThemeService=t.ICharacterJoinerService=t.ISelectionService=t.IRenderService=t.IMouseService=t.ICoreBrowserService=t.ICharSizeService=void 0;const s=i(8343);t.ICharSizeService=(0,s.createDecorator)("CharSizeService"),t.ICoreBrowserService=(0,s.createDecorator)("CoreBrowserService"),t.IMouseService=(0,s.createDecorator)("MouseService"),t.IRenderService=(0,s.createDecorator)("RenderService"),t.ISelectionService=(0,s.createDecorator)("SelectionService"),t.ICharacterJoinerService=(0,s.createDecorator)("CharacterJoinerService"),t.IThemeService=(0,s.createDecorator)("ThemeService")},6731:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.ThemeService=t.DEFAULT_ANSI_COLORS=void 0;const n=i(7239),o=i(8055),a=i(8460),h=i(844),c=i(2585),l=o.css.toColor("#ffffff"),d=o.css.toColor("#000000"),_=o.css.toColor("#ffffff"),u=o.css.toColor("#000000"),f={css:"rgba(255, 255, 255, 0.3)",rgba:4294967117};t.DEFAULT_ANSI_COLORS=Object.freeze((()=>{const e=[o.css.toColor("#2e3436"),o.css.toColor("#cc0000"),o.css.toColor("#4e9a06"),o.css.toColor("#c4a000"),o.css.toColor("#3465a4"),o.css.toColor("#75507b"),o.css.toColor("#06989a"),o.css.toColor("#d3d7cf"),o.css.toColor("#555753"),o.css.toColor("#ef2929"),o.css.toColor("#8ae234"),o.css.toColor("#fce94f"),o.css.toColor("#729fcf"),o.css.toColor("#ad7fa8"),o.css.toColor("#34e2e2"),o.css.toColor("#eeeeec")],t=[0,95,135,175,215,255];for(let i=0;i<216;i++){const s=t[i/36%6|0],r=t[i/6%6|0],n=t[i%6];e.push({css:o.channels.toCss(s,r,n),rgba:o.channels.toRgba(s,r,n)})}for(let i=0;i<24;i++){const t=8+10*i;e.push({css:o.channels.toCss(t,t,t),rgba:o.channels.toRgba(t,t,t)})}return e})());let v=t.ThemeService=class extends h.Disposable{get colors(){return this._colors}constructor(e){super(),this._optionsService=e,this._contrastCache=new n.ColorContrastCache,this._halfContrastCache=new n.ColorContrastCache,this._onChangeColors=this.register(new a.EventEmitter),this.onChangeColors=this._onChangeColors.event,this._colors={foreground:l,background:d,cursor:_,cursorAccent:u,selectionForeground:void 0,selectionBackgroundTransparent:f,selectionBackgroundOpaque:o.color.blend(d,f),selectionInactiveBackgroundTransparent:f,selectionInactiveBackgroundOpaque:o.color.blend(d,f),ansi:t.DEFAULT_ANSI_COLORS.slice(),contrastCache:this._contrastCache,halfContrastCache:this._halfContrastCache},this._updateRestoreColors(),this._setTheme(this._optionsService.rawOptions.theme),this.register(this._optionsService.onSpecificOptionChange("minimumContrastRatio",(()=>this._contrastCache.clear()))),this.register(this._optionsService.onSpecificOptionChange("theme",(()=>this._setTheme(this._optionsService.rawOptions.theme))))}_setTheme(e={}){const i=this._colors;if(i.foreground=p(e.foreground,l),i.background=p(e.background,d),i.cursor=p(e.cursor,_),i.cursorAccent=p(e.cursorAccent,u),i.selectionBackgroundTransparent=p(e.selectionBackground,f),i.selectionBackgroundOpaque=o.color.blend(i.background,i.selectionBackgroundTransparent),i.selectionInactiveBackgroundTransparent=p(e.selectionInactiveBackground,i.selectionBackgroundTransparent),i.selectionInactiveBackgroundOpaque=o.color.blend(i.background,i.selectionInactiveBackgroundTransparent),i.selectionForeground=e.selectionForeground?p(e.selectionForeground,o.NULL_COLOR):void 0,i.selectionForeground===o.NULL_COLOR&&(i.selectionForeground=void 0),o.color.isOpaque(i.selectionBackgroundTransparent)){const e=.3;i.selectionBackgroundTransparent=o.color.opacity(i.selectionBackgroundTransparent,e)}if(o.color.isOpaque(i.selectionInactiveBackgroundTransparent)){const e=.3;i.selectionInactiveBackgroundTransparent=o.color.opacity(i.selectionInactiveBackgroundTransparent,e)}if(i.ansi=t.DEFAULT_ANSI_COLORS.slice(),i.ansi[0]=p(e.black,t.DEFAULT_ANSI_COLORS[0]),i.ansi[1]=p(e.red,t.DEFAULT_ANSI_COLORS[1]),i.ansi[2]=p(e.green,t.DEFAULT_ANSI_COLORS[2]),i.ansi[3]=p(e.yellow,t.DEFAULT_ANSI_COLORS[3]),i.ansi[4]=p(e.blue,t.DEFAULT_ANSI_COLORS[4]),i.ansi[5]=p(e.magenta,t.DEFAULT_ANSI_COLORS[5]),i.ansi[6]=p(e.cyan,t.DEFAULT_ANSI_COLORS[6]),i.ansi[7]=p(e.white,t.DEFAULT_ANSI_COLORS[7]),i.ansi[8]=p(e.brightBlack,t.DEFAULT_ANSI_COLORS[8]),i.ansi[9]=p(e.brightRed,t.DEFAULT_ANSI_COLORS[9]),i.ansi[10]=p(e.brightGreen,t.DEFAULT_ANSI_COLORS[10]),i.ansi[11]=p(e.brightYellow,t.DEFAULT_ANSI_COLORS[11]),i.ansi[12]=p(e.brightBlue,t.DEFAULT_ANSI_COLORS[12]),i.ansi[13]=p(e.brightMagenta,t.DEFAULT_ANSI_COLORS[13]),i.ansi[14]=p(e.brightCyan,t.DEFAULT_ANSI_COLORS[14]),i.ansi[15]=p(e.brightWhite,t.DEFAULT_ANSI_COLORS[15]),e.extendedAnsi){const s=Math.min(i.ansi.length-16,e.extendedAnsi.length);for(let r=0;r{Object.defineProperty(t,"__esModule",{value:!0}),t.CircularList=void 0;const s=i(8460),r=i(844);class n extends r.Disposable{constructor(e){super(),this._maxLength=e,this.onDeleteEmitter=this.register(new s.EventEmitter),this.onDelete=this.onDeleteEmitter.event,this.onInsertEmitter=this.register(new s.EventEmitter),this.onInsert=this.onInsertEmitter.event,this.onTrimEmitter=this.register(new s.EventEmitter),this.onTrim=this.onTrimEmitter.event,this._array=new Array(this._maxLength),this._startIndex=0,this._length=0}get maxLength(){return this._maxLength}set maxLength(e){if(this._maxLength===e)return;const t=new Array(e);for(let i=0;ithis._length)for(let t=this._length;t=e;s--)this._array[this._getCyclicIndex(s+i.length)]=this._array[this._getCyclicIndex(s)];for(let s=0;sthis._maxLength){const e=this._length+i.length-this._maxLength;this._startIndex+=e,this._length=this._maxLength,this.onTrimEmitter.fire(e)}else this._length+=i.length}trimStart(e){e>this._length&&(e=this._length),this._startIndex+=e,this._length-=e,this.onTrimEmitter.fire(e)}shiftElements(e,t,i){if(!(t<=0)){if(e<0||e>=this._length)throw new Error("start argument out of range");if(e+i<0)throw new Error("Cannot shift elements in list beyond index 0");if(i>0){for(let r=t-1;r>=0;r--)this.set(e+r+i,this.get(e+r));const s=e+t+i-this._length;if(s>0)for(this._length+=s;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(let s=0;s{Object.defineProperty(t,"__esModule",{value:!0}),t.clone=void 0,t.clone=function e(t,i=5){if("object"!=typeof t)return t;const s=Array.isArray(t)?[]:{};for(const r in t)s[r]=i<=1?t[r]:t[r]&&e(t[r],i-1);return s}},8055:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.contrastRatio=t.toPaddedHex=t.rgba=t.rgb=t.css=t.color=t.channels=t.NULL_COLOR=void 0;const s=i(6114);let r=0,n=0,o=0,a=0;var h,c,l,d,_;function u(e){const t=e.toString(16);return t.length<2?"0"+t:t}function f(e,t){return e>>0}}(h||(t.channels=h={})),function(e){function t(e,t){return a=Math.round(255*t),[r,n,o]=_.toChannels(e.rgba),{css:h.toCss(r,n,o,a),rgba:h.toRgba(r,n,o,a)}}e.blend=function(e,t){if(a=(255&t.rgba)/255,1===a)return{css:t.css,rgba:t.rgba};const i=t.rgba>>24&255,s=t.rgba>>16&255,c=t.rgba>>8&255,l=e.rgba>>24&255,d=e.rgba>>16&255,_=e.rgba>>8&255;return r=l+Math.round((i-l)*a),n=d+Math.round((s-d)*a),o=_+Math.round((c-_)*a),{css:h.toCss(r,n,o),rgba:h.toRgba(r,n,o)}},e.isOpaque=function(e){return 255==(255&e.rgba)},e.ensureContrastRatio=function(e,t,i){const s=_.ensureContrastRatio(e.rgba,t.rgba,i);if(s)return _.toColor(s>>24&255,s>>16&255,s>>8&255)},e.opaque=function(e){const t=(255|e.rgba)>>>0;return[r,n,o]=_.toChannels(t),{css:h.toCss(r,n,o),rgba:t}},e.opacity=t,e.multiplyOpacity=function(e,i){return a=255&e.rgba,t(e,a*i/255)},e.toColorRGB=function(e){return[e.rgba>>24&255,e.rgba>>16&255,e.rgba>>8&255]}}(c||(t.color=c={})),function(e){let t,i;if(!s.isNode){const e=document.createElement("canvas");e.width=1,e.height=1;const s=e.getContext("2d",{willReadFrequently:!0});s&&(t=s,t.globalCompositeOperation="copy",i=t.createLinearGradient(0,0,1,1))}e.toColor=function(e){if(e.match(/#[\da-f]{3,8}/i))switch(e.length){case 4:return r=parseInt(e.slice(1,2).repeat(2),16),n=parseInt(e.slice(2,3).repeat(2),16),o=parseInt(e.slice(3,4).repeat(2),16),_.toColor(r,n,o);case 5:return r=parseInt(e.slice(1,2).repeat(2),16),n=parseInt(e.slice(2,3).repeat(2),16),o=parseInt(e.slice(3,4).repeat(2),16),a=parseInt(e.slice(4,5).repeat(2),16),_.toColor(r,n,o,a);case 7:return{css:e,rgba:(parseInt(e.slice(1),16)<<8|255)>>>0};case 9:return{css:e,rgba:parseInt(e.slice(1),16)>>>0}}const s=e.match(/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(0|1|\d?\.(\d+))\s*)?\)/);if(s)return r=parseInt(s[1]),n=parseInt(s[2]),o=parseInt(s[3]),a=Math.round(255*(void 0===s[5]?1:parseFloat(s[5]))),_.toColor(r,n,o,a);if(!t||!i)throw new Error("css.toColor: Unsupported css format");if(t.fillStyle=i,t.fillStyle=e,"string"!=typeof t.fillStyle)throw new Error("css.toColor: Unsupported css format");if(t.fillRect(0,0,1,1),[r,n,o,a]=t.getImageData(0,0,1,1).data,255!==a)throw new Error("css.toColor: Unsupported css format");return{rgba:h.toRgba(r,n,o,a),css:e}}}(l||(t.css=l={})),function(e){function t(e,t,i){const s=e/255,r=t/255,n=i/255;return.2126*(s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4))+.7152*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4))}e.relativeLuminance=function(e){return t(e>>16&255,e>>8&255,255&e)},e.relativeLuminance2=t}(d||(t.rgb=d={})),function(e){function t(e,t,i){const s=e>>24&255,r=e>>16&255,n=e>>8&255;let o=t>>24&255,a=t>>16&255,h=t>>8&255,c=f(d.relativeLuminance2(o,a,h),d.relativeLuminance2(s,r,n));for(;c0||a>0||h>0);)o-=Math.max(0,Math.ceil(.1*o)),a-=Math.max(0,Math.ceil(.1*a)),h-=Math.max(0,Math.ceil(.1*h)),c=f(d.relativeLuminance2(o,a,h),d.relativeLuminance2(s,r,n));return(o<<24|a<<16|h<<8|255)>>>0}function i(e,t,i){const s=e>>24&255,r=e>>16&255,n=e>>8&255;let o=t>>24&255,a=t>>16&255,h=t>>8&255,c=f(d.relativeLuminance2(o,a,h),d.relativeLuminance2(s,r,n));for(;c>>0}e.ensureContrastRatio=function(e,s,r){const n=d.relativeLuminance(e>>8),o=d.relativeLuminance(s>>8);if(f(n,o)>8));if(af(n,d.relativeLuminance(t>>8))?o:t}return o}const a=i(e,s,r),h=f(n,d.relativeLuminance(a>>8));if(hf(n,d.relativeLuminance(i>>8))?a:i}return a}},e.reduceLuminance=t,e.increaseLuminance=i,e.toChannels=function(e){return[e>>24&255,e>>16&255,e>>8&255,255&e]},e.toColor=function(e,t,i,s){return{css:h.toCss(e,t,i,s),rgba:h.toRgba(e,t,i,s)}}}(_||(t.rgba=_={})),t.toPaddedHex=u,t.contrastRatio=f},8969:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CoreTerminal=void 0;const s=i(844),r=i(2585),n=i(4348),o=i(7866),a=i(744),h=i(7302),c=i(6975),l=i(8460),d=i(1753),_=i(1480),u=i(7994),f=i(9282),v=i(5435),p=i(5981),g=i(2660);let m=!1;class S extends s.Disposable{get onScroll(){return this._onScrollApi||(this._onScrollApi=this.register(new l.EventEmitter),this._onScroll.event((e=>{var t;null===(t=this._onScrollApi)||void 0===t||t.fire(e.position)}))),this._onScrollApi.event}get cols(){return this._bufferService.cols}get rows(){return this._bufferService.rows}get buffers(){return this._bufferService.buffers}get options(){return this.optionsService.options}set options(e){for(const t in e)this.optionsService.options[t]=e[t]}constructor(e){super(),this._windowsWrappingHeuristics=this.register(new s.MutableDisposable),this._onBinary=this.register(new l.EventEmitter),this.onBinary=this._onBinary.event,this._onData=this.register(new l.EventEmitter),this.onData=this._onData.event,this._onLineFeed=this.register(new l.EventEmitter),this.onLineFeed=this._onLineFeed.event,this._onResize=this.register(new l.EventEmitter),this.onResize=this._onResize.event,this._onWriteParsed=this.register(new l.EventEmitter),this.onWriteParsed=this._onWriteParsed.event,this._onScroll=this.register(new l.EventEmitter),this._instantiationService=new n.InstantiationService,this.optionsService=this.register(new h.OptionsService(e)),this._instantiationService.setService(r.IOptionsService,this.optionsService),this._bufferService=this.register(this._instantiationService.createInstance(a.BufferService)),this._instantiationService.setService(r.IBufferService,this._bufferService),this._logService=this.register(this._instantiationService.createInstance(o.LogService)),this._instantiationService.setService(r.ILogService,this._logService),this.coreService=this.register(this._instantiationService.createInstance(c.CoreService)),this._instantiationService.setService(r.ICoreService,this.coreService),this.coreMouseService=this.register(this._instantiationService.createInstance(d.CoreMouseService)),this._instantiationService.setService(r.ICoreMouseService,this.coreMouseService),this.unicodeService=this.register(this._instantiationService.createInstance(_.UnicodeService)),this._instantiationService.setService(r.IUnicodeService,this.unicodeService),this._charsetService=this._instantiationService.createInstance(u.CharsetService),this._instantiationService.setService(r.ICharsetService,this._charsetService),this._oscLinkService=this._instantiationService.createInstance(g.OscLinkService),this._instantiationService.setService(r.IOscLinkService,this._oscLinkService),this._inputHandler=this.register(new v.InputHandler(this._bufferService,this._charsetService,this.coreService,this._logService,this.optionsService,this._oscLinkService,this.coreMouseService,this.unicodeService)),this.register((0,l.forwardEvent)(this._inputHandler.onLineFeed,this._onLineFeed)),this.register(this._inputHandler),this.register((0,l.forwardEvent)(this._bufferService.onResize,this._onResize)),this.register((0,l.forwardEvent)(this.coreService.onData,this._onData)),this.register((0,l.forwardEvent)(this.coreService.onBinary,this._onBinary)),this.register(this.coreService.onRequestScrollToBottom((()=>this.scrollToBottom()))),this.register(this.coreService.onUserInput((()=>this._writeBuffer.handleUserInput()))),this.register(this.optionsService.onMultipleOptionChange(["windowsMode","windowsPty"],(()=>this._handleWindowsPtyOptionChange()))),this.register(this._bufferService.onScroll((e=>{this._onScroll.fire({position:this._bufferService.buffer.ydisp,source:0}),this._inputHandler.markRangeDirty(this._bufferService.buffer.scrollTop,this._bufferService.buffer.scrollBottom)}))),this.register(this._inputHandler.onScroll((e=>{this._onScroll.fire({position:this._bufferService.buffer.ydisp,source:0}),this._inputHandler.markRangeDirty(this._bufferService.buffer.scrollTop,this._bufferService.buffer.scrollBottom)}))),this._writeBuffer=this.register(new p.WriteBuffer(((e,t)=>this._inputHandler.parse(e,t)))),this.register((0,l.forwardEvent)(this._writeBuffer.onWriteParsed,this._onWriteParsed))}write(e,t){this._writeBuffer.write(e,t)}writeSync(e,t){this._logService.logLevel<=r.LogLevelEnum.WARN&&!m&&(this._logService.warn("writeSync is unreliable and will be removed soon."),m=!0),this._writeBuffer.writeSync(e,t)}resize(e,t){isNaN(e)||isNaN(t)||(e=Math.max(e,a.MINIMUM_COLS),t=Math.max(t,a.MINIMUM_ROWS),this._bufferService.resize(e,t))}scroll(e,t=!1){this._bufferService.scroll(e,t)}scrollLines(e,t,i){this._bufferService.scrollLines(e,t,i)}scrollPages(e){this.scrollLines(e*(this.rows-1))}scrollToTop(){this.scrollLines(-this._bufferService.buffer.ydisp)}scrollToBottom(){this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)}scrollToLine(e){const t=e-this._bufferService.buffer.ydisp;0!==t&&this.scrollLines(t)}registerEscHandler(e,t){return this._inputHandler.registerEscHandler(e,t)}registerDcsHandler(e,t){return this._inputHandler.registerDcsHandler(e,t)}registerCsiHandler(e,t){return this._inputHandler.registerCsiHandler(e,t)}registerOscHandler(e,t){return this._inputHandler.registerOscHandler(e,t)}_setup(){this._handleWindowsPtyOptionChange()}reset(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this.coreService.reset(),this.coreMouseService.reset()}_handleWindowsPtyOptionChange(){let e=!1;const t=this.optionsService.rawOptions.windowsPty;t&&void 0!==t.buildNumber&&void 0!==t.buildNumber?e=!!("conpty"===t.backend&&t.buildNumber<21376):this.optionsService.rawOptions.windowsMode&&(e=!0),e?this._enableWindowsWrappingHeuristics():this._windowsWrappingHeuristics.clear()}_enableWindowsWrappingHeuristics(){if(!this._windowsWrappingHeuristics.value){const e=[];e.push(this.onLineFeed(f.updateWindowsModeWrappedState.bind(null,this._bufferService))),e.push(this.registerCsiHandler({final:"H"},(()=>((0,f.updateWindowsModeWrappedState)(this._bufferService),!1)))),this._windowsWrappingHeuristics.value=(0,s.toDisposable)((()=>{for(const t of e)t.dispose()}))}}}t.CoreTerminal=S},8460:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.forwardEvent=t.EventEmitter=void 0,t.EventEmitter=class{constructor(){this._listeners=[],this._disposed=!1}get event(){return this._event||(this._event=e=>(this._listeners.push(e),{dispose:()=>{if(!this._disposed)for(let t=0;tt.fire(e)))}},5435:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.InputHandler=t.WindowsOptionsReportType=void 0;const n=i(2584),o=i(7116),a=i(2015),h=i(844),c=i(482),l=i(8437),d=i(8460),_=i(643),u=i(511),f=i(3734),v=i(2585),p=i(6242),g=i(6351),m=i(5941),S={"(":0,")":1,"*":2,"+":3,"-":1,".":2},C=131072;function b(e,t){if(e>24)return t.setWinLines||!1;switch(e){case 1:return!!t.restoreWin;case 2:return!!t.minimizeWin;case 3:return!!t.setWinPosition;case 4:return!!t.setWinSizePixels;case 5:return!!t.raiseWin;case 6:return!!t.lowerWin;case 7:return!!t.refreshWin;case 8:return!!t.setWinSizeChars;case 9:return!!t.maximizeWin;case 10:return!!t.fullscreenWin;case 11:return!!t.getWinState;case 13:return!!t.getWinPosition;case 14:return!!t.getWinSizePixels;case 15:return!!t.getScreenSizePixels;case 16:return!!t.getCellSizePixels;case 18:return!!t.getWinSizeChars;case 19:return!!t.getScreenSizeChars;case 20:return!!t.getIconTitle;case 21:return!!t.getWinTitle;case 22:return!!t.pushTitle;case 23:return!!t.popTitle;case 24:return!!t.setWinLines}return!1}var y;!function(e){e[e.GET_WIN_SIZE_PIXELS=0]="GET_WIN_SIZE_PIXELS",e[e.GET_CELL_SIZE_PIXELS=1]="GET_CELL_SIZE_PIXELS"}(y||(t.WindowsOptionsReportType=y={}));let w=0;class E extends h.Disposable{getAttrData(){return this._curAttrData}constructor(e,t,i,s,r,h,_,f,v=new a.EscapeSequenceParser){super(),this._bufferService=e,this._charsetService=t,this._coreService=i,this._logService=s,this._optionsService=r,this._oscLinkService=h,this._coreMouseService=_,this._unicodeService=f,this._parser=v,this._parseBuffer=new Uint32Array(4096),this._stringDecoder=new c.StringToUtf32,this._utf8Decoder=new c.Utf8ToUtf32,this._workCell=new u.CellData,this._windowTitle="",this._iconName="",this._windowTitleStack=[],this._iconNameStack=[],this._curAttrData=l.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=l.DEFAULT_ATTR_DATA.clone(),this._onRequestBell=this.register(new d.EventEmitter),this.onRequestBell=this._onRequestBell.event,this._onRequestRefreshRows=this.register(new d.EventEmitter),this.onRequestRefreshRows=this._onRequestRefreshRows.event,this._onRequestReset=this.register(new d.EventEmitter),this.onRequestReset=this._onRequestReset.event,this._onRequestSendFocus=this.register(new d.EventEmitter),this.onRequestSendFocus=this._onRequestSendFocus.event,this._onRequestSyncScrollBar=this.register(new d.EventEmitter),this.onRequestSyncScrollBar=this._onRequestSyncScrollBar.event,this._onRequestWindowsOptionsReport=this.register(new d.EventEmitter),this.onRequestWindowsOptionsReport=this._onRequestWindowsOptionsReport.event,this._onA11yChar=this.register(new d.EventEmitter),this.onA11yChar=this._onA11yChar.event,this._onA11yTab=this.register(new d.EventEmitter),this.onA11yTab=this._onA11yTab.event,this._onCursorMove=this.register(new d.EventEmitter),this.onCursorMove=this._onCursorMove.event,this._onLineFeed=this.register(new d.EventEmitter),this.onLineFeed=this._onLineFeed.event,this._onScroll=this.register(new d.EventEmitter),this.onScroll=this._onScroll.event,this._onTitleChange=this.register(new d.EventEmitter),this.onTitleChange=this._onTitleChange.event,this._onColor=this.register(new d.EventEmitter),this.onColor=this._onColor.event,this._parseStack={paused:!1,cursorStartX:0,cursorStartY:0,decodedLength:0,position:0},this._specialColors=[256,257,258],this.register(this._parser),this._dirtyRowTracker=new k(this._bufferService),this._activeBuffer=this._bufferService.buffer,this.register(this._bufferService.buffers.onBufferActivate((e=>this._activeBuffer=e.activeBuffer))),this._parser.setCsiHandlerFallback(((e,t)=>{this._logService.debug("Unknown CSI code: ",{identifier:this._parser.identToString(e),params:t.toArray()})})),this._parser.setEscHandlerFallback((e=>{this._logService.debug("Unknown ESC code: ",{identifier:this._parser.identToString(e)})})),this._parser.setExecuteHandlerFallback((e=>{this._logService.debug("Unknown EXECUTE code: ",{code:e})})),this._parser.setOscHandlerFallback(((e,t,i)=>{this._logService.debug("Unknown OSC code: ",{identifier:e,action:t,data:i})})),this._parser.setDcsHandlerFallback(((e,t,i)=>{"HOOK"===t&&(i=i.toArray()),this._logService.debug("Unknown DCS code: ",{identifier:this._parser.identToString(e),action:t,payload:i})})),this._parser.setPrintHandler(((e,t,i)=>this.print(e,t,i))),this._parser.registerCsiHandler({final:"@"},(e=>this.insertChars(e))),this._parser.registerCsiHandler({intermediates:" ",final:"@"},(e=>this.scrollLeft(e))),this._parser.registerCsiHandler({final:"A"},(e=>this.cursorUp(e))),this._parser.registerCsiHandler({intermediates:" ",final:"A"},(e=>this.scrollRight(e))),this._parser.registerCsiHandler({final:"B"},(e=>this.cursorDown(e))),this._parser.registerCsiHandler({final:"C"},(e=>this.cursorForward(e))),this._parser.registerCsiHandler({final:"D"},(e=>this.cursorBackward(e))),this._parser.registerCsiHandler({final:"E"},(e=>this.cursorNextLine(e))),this._parser.registerCsiHandler({final:"F"},(e=>this.cursorPrecedingLine(e))),this._parser.registerCsiHandler({final:"G"},(e=>this.cursorCharAbsolute(e))),this._parser.registerCsiHandler({final:"H"},(e=>this.cursorPosition(e))),this._parser.registerCsiHandler({final:"I"},(e=>this.cursorForwardTab(e))),this._parser.registerCsiHandler({final:"J"},(e=>this.eraseInDisplay(e,!1))),this._parser.registerCsiHandler({prefix:"?",final:"J"},(e=>this.eraseInDisplay(e,!0))),this._parser.registerCsiHandler({final:"K"},(e=>this.eraseInLine(e,!1))),this._parser.registerCsiHandler({prefix:"?",final:"K"},(e=>this.eraseInLine(e,!0))),this._parser.registerCsiHandler({final:"L"},(e=>this.insertLines(e))),this._parser.registerCsiHandler({final:"M"},(e=>this.deleteLines(e))),this._parser.registerCsiHandler({final:"P"},(e=>this.deleteChars(e))),this._parser.registerCsiHandler({final:"S"},(e=>this.scrollUp(e))),this._parser.registerCsiHandler({final:"T"},(e=>this.scrollDown(e))),this._parser.registerCsiHandler({final:"X"},(e=>this.eraseChars(e))),this._parser.registerCsiHandler({final:"Z"},(e=>this.cursorBackwardTab(e))),this._parser.registerCsiHandler({final:"`"},(e=>this.charPosAbsolute(e))),this._parser.registerCsiHandler({final:"a"},(e=>this.hPositionRelative(e))),this._parser.registerCsiHandler({final:"b"},(e=>this.repeatPrecedingCharacter(e))),this._parser.registerCsiHandler({final:"c"},(e=>this.sendDeviceAttributesPrimary(e))),this._parser.registerCsiHandler({prefix:">",final:"c"},(e=>this.sendDeviceAttributesSecondary(e))),this._parser.registerCsiHandler({final:"d"},(e=>this.linePosAbsolute(e))),this._parser.registerCsiHandler({final:"e"},(e=>this.vPositionRelative(e))),this._parser.registerCsiHandler({final:"f"},(e=>this.hVPosition(e))),this._parser.registerCsiHandler({final:"g"},(e=>this.tabClear(e))),this._parser.registerCsiHandler({final:"h"},(e=>this.setMode(e))),this._parser.registerCsiHandler({prefix:"?",final:"h"},(e=>this.setModePrivate(e))),this._parser.registerCsiHandler({final:"l"},(e=>this.resetMode(e))),this._parser.registerCsiHandler({prefix:"?",final:"l"},(e=>this.resetModePrivate(e))),this._parser.registerCsiHandler({final:"m"},(e=>this.charAttributes(e))),this._parser.registerCsiHandler({final:"n"},(e=>this.deviceStatus(e))),this._parser.registerCsiHandler({prefix:"?",final:"n"},(e=>this.deviceStatusPrivate(e))),this._parser.registerCsiHandler({intermediates:"!",final:"p"},(e=>this.softReset(e))),this._parser.registerCsiHandler({intermediates:" ",final:"q"},(e=>this.setCursorStyle(e))),this._parser.registerCsiHandler({final:"r"},(e=>this.setScrollRegion(e))),this._parser.registerCsiHandler({final:"s"},(e=>this.saveCursor(e))),this._parser.registerCsiHandler({final:"t"},(e=>this.windowOptions(e))),this._parser.registerCsiHandler({final:"u"},(e=>this.restoreCursor(e))),this._parser.registerCsiHandler({intermediates:"'",final:"}"},(e=>this.insertColumns(e))),this._parser.registerCsiHandler({intermediates:"'",final:"~"},(e=>this.deleteColumns(e))),this._parser.registerCsiHandler({intermediates:'"',final:"q"},(e=>this.selectProtected(e))),this._parser.registerCsiHandler({intermediates:"$",final:"p"},(e=>this.requestMode(e,!0))),this._parser.registerCsiHandler({prefix:"?",intermediates:"$",final:"p"},(e=>this.requestMode(e,!1))),this._parser.setExecuteHandler(n.C0.BEL,(()=>this.bell())),this._parser.setExecuteHandler(n.C0.LF,(()=>this.lineFeed())),this._parser.setExecuteHandler(n.C0.VT,(()=>this.lineFeed())),this._parser.setExecuteHandler(n.C0.FF,(()=>this.lineFeed())),this._parser.setExecuteHandler(n.C0.CR,(()=>this.carriageReturn())),this._parser.setExecuteHandler(n.C0.BS,(()=>this.backspace())),this._parser.setExecuteHandler(n.C0.HT,(()=>this.tab())),this._parser.setExecuteHandler(n.C0.SO,(()=>this.shiftOut())),this._parser.setExecuteHandler(n.C0.SI,(()=>this.shiftIn())),this._parser.setExecuteHandler(n.C1.IND,(()=>this.index())),this._parser.setExecuteHandler(n.C1.NEL,(()=>this.nextLine())),this._parser.setExecuteHandler(n.C1.HTS,(()=>this.tabSet())),this._parser.registerOscHandler(0,new p.OscHandler((e=>(this.setTitle(e),this.setIconName(e),!0)))),this._parser.registerOscHandler(1,new p.OscHandler((e=>this.setIconName(e)))),this._parser.registerOscHandler(2,new p.OscHandler((e=>this.setTitle(e)))),this._parser.registerOscHandler(4,new p.OscHandler((e=>this.setOrReportIndexedColor(e)))),this._parser.registerOscHandler(8,new p.OscHandler((e=>this.setHyperlink(e)))),this._parser.registerOscHandler(10,new p.OscHandler((e=>this.setOrReportFgColor(e)))),this._parser.registerOscHandler(11,new p.OscHandler((e=>this.setOrReportBgColor(e)))),this._parser.registerOscHandler(12,new p.OscHandler((e=>this.setOrReportCursorColor(e)))),this._parser.registerOscHandler(104,new p.OscHandler((e=>this.restoreIndexedColor(e)))),this._parser.registerOscHandler(110,new p.OscHandler((e=>this.restoreFgColor(e)))),this._parser.registerOscHandler(111,new p.OscHandler((e=>this.restoreBgColor(e)))),this._parser.registerOscHandler(112,new p.OscHandler((e=>this.restoreCursorColor(e)))),this._parser.registerEscHandler({final:"7"},(()=>this.saveCursor())),this._parser.registerEscHandler({final:"8"},(()=>this.restoreCursor())),this._parser.registerEscHandler({final:"D"},(()=>this.index())),this._parser.registerEscHandler({final:"E"},(()=>this.nextLine())),this._parser.registerEscHandler({final:"H"},(()=>this.tabSet())),this._parser.registerEscHandler({final:"M"},(()=>this.reverseIndex())),this._parser.registerEscHandler({final:"="},(()=>this.keypadApplicationMode())),this._parser.registerEscHandler({final:">"},(()=>this.keypadNumericMode())),this._parser.registerEscHandler({final:"c"},(()=>this.fullReset())),this._parser.registerEscHandler({final:"n"},(()=>this.setgLevel(2))),this._parser.registerEscHandler({final:"o"},(()=>this.setgLevel(3))),this._parser.registerEscHandler({final:"|"},(()=>this.setgLevel(3))),this._parser.registerEscHandler({final:"}"},(()=>this.setgLevel(2))),this._parser.registerEscHandler({final:"~"},(()=>this.setgLevel(1))),this._parser.registerEscHandler({intermediates:"%",final:"@"},(()=>this.selectDefaultCharset())),this._parser.registerEscHandler({intermediates:"%",final:"G"},(()=>this.selectDefaultCharset()));for(const n in o.CHARSETS)this._parser.registerEscHandler({intermediates:"(",final:n},(()=>this.selectCharset("("+n))),this._parser.registerEscHandler({intermediates:")",final:n},(()=>this.selectCharset(")"+n))),this._parser.registerEscHandler({intermediates:"*",final:n},(()=>this.selectCharset("*"+n))),this._parser.registerEscHandler({intermediates:"+",final:n},(()=>this.selectCharset("+"+n))),this._parser.registerEscHandler({intermediates:"-",final:n},(()=>this.selectCharset("-"+n))),this._parser.registerEscHandler({intermediates:".",final:n},(()=>this.selectCharset("."+n))),this._parser.registerEscHandler({intermediates:"/",final:n},(()=>this.selectCharset("/"+n)));this._parser.registerEscHandler({intermediates:"#",final:"8"},(()=>this.screenAlignmentPattern())),this._parser.setErrorHandler((e=>(this._logService.error("Parsing error: ",e),e))),this._parser.registerDcsHandler({intermediates:"$",final:"q"},new g.DcsHandler(((e,t)=>this.requestStatusString(e,t))))}_preserveStack(e,t,i,s){this._parseStack.paused=!0,this._parseStack.cursorStartX=e,this._parseStack.cursorStartY=t,this._parseStack.decodedLength=i,this._parseStack.position=s}_logSlowResolvingAsync(e){this._logService.logLevel<=v.LogLevelEnum.WARN&&Promise.race([e,new Promise(((e,t)=>setTimeout((()=>t("#SLOW_TIMEOUT")),5e3)))]).catch((e=>{if("#SLOW_TIMEOUT"!==e)throw e;console.warn("async parser handler taking longer than 5000 ms")}))}_getCurrentLinkId(){return this._curAttrData.extended.urlId}parse(e,t){let i,s=this._activeBuffer.x,r=this._activeBuffer.y,n=0;const o=this._parseStack.paused;if(o){if(i=this._parser.parse(this._parseBuffer,this._parseStack.decodedLength,t))return this._logSlowResolvingAsync(i),i;s=this._parseStack.cursorStartX,r=this._parseStack.cursorStartY,this._parseStack.paused=!1,e.length>C&&(n=this._parseStack.position+C)}if(this._logService.logLevel<=v.LogLevelEnum.DEBUG&&this._logService.debug("parsing data"+("string"==typeof e?` "${e}"`:` "${Array.prototype.map.call(e,(e=>String.fromCharCode(e))).join("")}"`),"string"==typeof e?e.split("").map((e=>e.charCodeAt(0))):e),this._parseBuffer.lengthC)for(let a=n;a0&&2===u.getWidth(this._activeBuffer.x-1)&&u.setCellFromCodePoint(this._activeBuffer.x-1,0,1,d.fg,d.bg,d.extended);for(let f=t;f=a)if(h){for(;this._activeBuffer.x=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!0),u=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y)}else if(this._activeBuffer.x=a-1,2===r)continue;if(l&&(u.insertCells(this._activeBuffer.x,r,this._activeBuffer.getNullCell(d),d),2===u.getWidth(a-1)&&u.setCellFromCodePoint(a-1,_.NULL_CELL_CODE,_.NULL_CELL_WIDTH,d.fg,d.bg,d.extended)),u.setCellFromCodePoint(this._activeBuffer.x++,s,r,d.fg,d.bg,d.extended),r>0)for(;--r;)u.setCellFromCodePoint(this._activeBuffer.x++,0,0,d.fg,d.bg,d.extended)}else u.getWidth(this._activeBuffer.x-1)?u.addCodepointToCell(this._activeBuffer.x-1,s):u.addCodepointToCell(this._activeBuffer.x-2,s)}i-t>0&&(u.loadCell(this._activeBuffer.x-1,this._workCell),2===this._workCell.getWidth()||this._workCell.getCode()>65535?this._parser.precedingCodepoint=0:this._workCell.isCombined()?this._parser.precedingCodepoint=this._workCell.getChars().charCodeAt(0):this._parser.precedingCodepoint=this._workCell.content),this._activeBuffer.x0&&0===u.getWidth(this._activeBuffer.x)&&!u.hasContent(this._activeBuffer.x)&&u.setCellFromCodePoint(this._activeBuffer.x,0,1,d.fg,d.bg,d.extended),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}registerCsiHandler(e,t){return"t"!==e.final||e.prefix||e.intermediates?this._parser.registerCsiHandler(e,t):this._parser.registerCsiHandler(e,(e=>!b(e.params[0],this._optionsService.rawOptions.windowOptions)||t(e)))}registerDcsHandler(e,t){return this._parser.registerDcsHandler(e,new g.DcsHandler(t))}registerEscHandler(e,t){return this._parser.registerEscHandler(e,t)}registerOscHandler(e,t){return this._parser.registerOscHandler(e,new p.OscHandler(t))}bell(){return this._onRequestBell.fire(),!0}lineFeed(){return this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._optionsService.rawOptions.convertEol&&(this._activeBuffer.x=0),this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData())):this._activeBuffer.y>=this._bufferService.rows?this._activeBuffer.y=this._bufferService.rows-1:this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!1,this._activeBuffer.x>=this._bufferService.cols&&this._activeBuffer.x--,this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._onLineFeed.fire(),!0}carriageReturn(){return this._activeBuffer.x=0,!0}backspace(){var e;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),this._activeBuffer.x>0&&this._activeBuffer.x--,!0;if(this._restrictCursor(this._bufferService.cols),this._activeBuffer.x>0)this._activeBuffer.x--;else if(0===this._activeBuffer.x&&this._activeBuffer.y>this._activeBuffer.scrollTop&&this._activeBuffer.y<=this._activeBuffer.scrollBottom&&(null===(e=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y))||void 0===e?void 0:e.isWrapped)){this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!1,this._activeBuffer.y--,this._activeBuffer.x=this._bufferService.cols-1;const e=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);e.hasWidth(this._activeBuffer.x)&&!e.hasContent(this._activeBuffer.x)&&this._activeBuffer.x--}return this._restrictCursor(),!0}tab(){if(this._activeBuffer.x>=this._bufferService.cols)return!0;const e=this._activeBuffer.x;return this._activeBuffer.x=this._activeBuffer.nextStop(),this._optionsService.rawOptions.screenReaderMode&&this._onA11yTab.fire(this._activeBuffer.x-e),!0}shiftOut(){return this._charsetService.setgLevel(1),!0}shiftIn(){return this._charsetService.setgLevel(0),!0}_restrictCursor(e=this._bufferService.cols-1){this._activeBuffer.x=Math.min(e,Math.max(0,this._activeBuffer.x)),this._activeBuffer.y=this._coreService.decPrivateModes.origin?Math.min(this._activeBuffer.scrollBottom,Math.max(this._activeBuffer.scrollTop,this._activeBuffer.y)):Math.min(this._bufferService.rows-1,Math.max(0,this._activeBuffer.y)),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}_setCursor(e,t){this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._coreService.decPrivateModes.origin?(this._activeBuffer.x=e,this._activeBuffer.y=this._activeBuffer.scrollTop+t):(this._activeBuffer.x=e,this._activeBuffer.y=t),this._restrictCursor(),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}_moveCursor(e,t){this._restrictCursor(),this._setCursor(this._activeBuffer.x+e,this._activeBuffer.y+t)}cursorUp(e){const t=this._activeBuffer.y-this._activeBuffer.scrollTop;return t>=0?this._moveCursor(0,-Math.min(t,e.params[0]||1)):this._moveCursor(0,-(e.params[0]||1)),!0}cursorDown(e){const t=this._activeBuffer.scrollBottom-this._activeBuffer.y;return t>=0?this._moveCursor(0,Math.min(t,e.params[0]||1)):this._moveCursor(0,e.params[0]||1),!0}cursorForward(e){return this._moveCursor(e.params[0]||1,0),!0}cursorBackward(e){return this._moveCursor(-(e.params[0]||1),0),!0}cursorNextLine(e){return this.cursorDown(e),this._activeBuffer.x=0,!0}cursorPrecedingLine(e){return this.cursorUp(e),this._activeBuffer.x=0,!0}cursorCharAbsolute(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}cursorPosition(e){return this._setCursor(e.length>=2?(e.params[1]||1)-1:0,(e.params[0]||1)-1),!0}charPosAbsolute(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}hPositionRelative(e){return this._moveCursor(e.params[0]||1,0),!0}linePosAbsolute(e){return this._setCursor(this._activeBuffer.x,(e.params[0]||1)-1),!0}vPositionRelative(e){return this._moveCursor(0,e.params[0]||1),!0}hVPosition(e){return this.cursorPosition(e),!0}tabClear(e){const t=e.params[0];return 0===t?delete this._activeBuffer.tabs[this._activeBuffer.x]:3===t&&(this._activeBuffer.tabs={}),!0}cursorForwardTab(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;let t=e.params[0]||1;for(;t--;)this._activeBuffer.x=this._activeBuffer.nextStop();return!0}cursorBackwardTab(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;let t=e.params[0]||1;for(;t--;)this._activeBuffer.x=this._activeBuffer.prevStop();return!0}selectProtected(e){const t=e.params[0];return 1===t&&(this._curAttrData.bg|=536870912),2!==t&&0!==t||(this._curAttrData.bg&=-536870913),!0}_eraseInBufferLine(e,t,i,s=!1,r=!1){const n=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);n.replaceCells(t,i,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData(),r),s&&(n.isWrapped=!1)}_resetBufferLine(e,t=!1){const i=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);i&&(i.fill(this._activeBuffer.getNullCell(this._eraseAttrData()),t),this._bufferService.buffer.clearMarkers(this._activeBuffer.ybase+e),i.isWrapped=!1)}eraseInDisplay(e,t=!1){let i;switch(this._restrictCursor(this._bufferService.cols),e.params[0]){case 0:for(i=this._activeBuffer.y,this._dirtyRowTracker.markDirty(i),this._eraseInBufferLine(i++,this._activeBuffer.x,this._bufferService.cols,0===this._activeBuffer.x,t);i=this._bufferService.cols&&(this._activeBuffer.lines.get(i+1).isWrapped=!1);i--;)this._resetBufferLine(i,t);this._dirtyRowTracker.markDirty(0);break;case 2:for(i=this._bufferService.rows,this._dirtyRowTracker.markDirty(i-1);i--;)this._resetBufferLine(i,t);this._dirtyRowTracker.markDirty(0);break;case 3:const e=this._activeBuffer.lines.length-this._bufferService.rows;e>0&&(this._activeBuffer.lines.trimStart(e),this._activeBuffer.ybase=Math.max(this._activeBuffer.ybase-e,0),this._activeBuffer.ydisp=Math.max(this._activeBuffer.ydisp-e,0),this._onScroll.fire(0))}return!0}eraseInLine(e,t=!1){switch(this._restrictCursor(this._bufferService.cols),e.params[0]){case 0:this._eraseInBufferLine(this._activeBuffer.y,this._activeBuffer.x,this._bufferService.cols,0===this._activeBuffer.x,t);break;case 1:this._eraseInBufferLine(this._activeBuffer.y,0,this._activeBuffer.x+1,!1,t);break;case 2:this._eraseInBufferLine(this._activeBuffer.y,0,this._bufferService.cols,!0,t)}return this._dirtyRowTracker.markDirty(this._activeBuffer.y),!0}insertLines(e){this._restrictCursor();let t=e.params[0]||1;if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.ythis._activeBuffer.scrollBottom||this._activeBuffer.ythis._activeBuffer.scrollBottom||this._activeBuffer.ythis._activeBuffer.scrollBottom||this._activeBuffer.ythis._activeBuffer.scrollBottom||this._activeBuffer.ythis._activeBuffer.scrollBottom||this._activeBuffer.y0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(n.C0.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(n.C0.ESC+"[?6c")),!0}sendDeviceAttributesSecondary(e){return e.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(n.C0.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(n.C0.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(e.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(n.C0.ESC+"[>83;40003;0c")),!0}_is(e){return 0===(this._optionsService.rawOptions.termName+"").indexOf(e)}setMode(e){for(let t=0;te?1:2,u=e.params[0];return f=u,v=t?2===u?4:4===u?_(o.modes.insertMode):12===u?3:20===u?_(d.convertEol):0:1===u?_(i.applicationCursorKeys):3===u?d.windowOptions.setWinLines?80===h?2:132===h?1:0:0:6===u?_(i.origin):7===u?_(i.wraparound):8===u?3:9===u?_("X10"===s):12===u?_(d.cursorBlink):25===u?_(!o.isCursorHidden):45===u?_(i.reverseWraparound):66===u?_(i.applicationKeypad):67===u?4:1e3===u?_("VT200"===s):1002===u?_("DRAG"===s):1003===u?_("ANY"===s):1004===u?_(i.sendFocus):1005===u?4:1006===u?_("SGR"===r):1015===u?4:1016===u?_("SGR_PIXELS"===r):1048===u?1:47===u||1047===u||1049===u?_(c===l):2004===u?_(i.bracketedPasteMode):0,o.triggerDataEvent(`${n.C0.ESC}[${t?"":"?"}${f};${v}$y`),!0;var f,v}_updateAttrColor(e,t,i,s,r){return 2===t?(e|=50331648,e&=-16777216,e|=f.AttributeData.fromColorRGB([i,s,r])):5===t&&(e&=-50331904,e|=33554432|255&i),e}_extractColor(e,t,i){const s=[0,0,-1,0,0,0];let r=0,n=0;do{if(s[n+r]=e.params[t+n],e.hasSubParams(t+n)){const i=e.getSubParams(t+n);let o=0;do{5===s[1]&&(r=1),s[n+o+1+r]=i[o]}while(++o=2||2===s[1]&&n+r>=5)break;s[1]&&(r=1)}while(++n+t5)&&(e=1),t.extended.underlineStyle=e,t.fg|=268435456,0===e&&(t.fg&=-268435457),t.updateExtended()}_processSGR0(e){e.fg=l.DEFAULT_ATTR_DATA.fg,e.bg=l.DEFAULT_ATTR_DATA.bg,e.extended=e.extended.clone(),e.extended.underlineStyle=0,e.extended.underlineColor&=-67108864,e.updateExtended()}charAttributes(e){if(1===e.length&&0===e.params[0])return this._processSGR0(this._curAttrData),!0;const t=e.length;let i;const s=this._curAttrData;for(let r=0;r=30&&i<=37?(s.fg&=-50331904,s.fg|=16777216|i-30):i>=40&&i<=47?(s.bg&=-50331904,s.bg|=16777216|i-40):i>=90&&i<=97?(s.fg&=-50331904,s.fg|=16777224|i-90):i>=100&&i<=107?(s.bg&=-50331904,s.bg|=16777224|i-100):0===i?this._processSGR0(s):1===i?s.fg|=134217728:3===i?s.bg|=67108864:4===i?(s.fg|=268435456,this._processUnderline(e.hasSubParams(r)?e.getSubParams(r)[0]:1,s)):5===i?s.fg|=536870912:7===i?s.fg|=67108864:8===i?s.fg|=1073741824:9===i?s.fg|=2147483648:2===i?s.bg|=134217728:21===i?this._processUnderline(2,s):22===i?(s.fg&=-134217729,s.bg&=-134217729):23===i?s.bg&=-67108865:24===i?(s.fg&=-268435457,this._processUnderline(0,s)):25===i?s.fg&=-536870913:27===i?s.fg&=-67108865:28===i?s.fg&=-1073741825:29===i?s.fg&=2147483647:39===i?(s.fg&=-67108864,s.fg|=16777215&l.DEFAULT_ATTR_DATA.fg):49===i?(s.bg&=-67108864,s.bg|=16777215&l.DEFAULT_ATTR_DATA.bg):38===i||48===i||58===i?r+=this._extractColor(e,r,s):53===i?s.bg|=1073741824:55===i?s.bg&=-1073741825:59===i?(s.extended=s.extended.clone(),s.extended.underlineColor=-1,s.updateExtended()):100===i?(s.fg&=-67108864,s.fg|=16777215&l.DEFAULT_ATTR_DATA.fg,s.bg&=-67108864,s.bg|=16777215&l.DEFAULT_ATTR_DATA.bg):this._logService.debug("Unknown SGR attribute: %d.",i);return!0}deviceStatus(e){switch(e.params[0]){case 5:this._coreService.triggerDataEvent(`${n.C0.ESC}[0n`);break;case 6:const e=this._activeBuffer.y+1,t=this._activeBuffer.x+1;this._coreService.triggerDataEvent(`${n.C0.ESC}[${e};${t}R`)}return!0}deviceStatusPrivate(e){if(6===e.params[0]){const e=this._activeBuffer.y+1,t=this._activeBuffer.x+1;this._coreService.triggerDataEvent(`${n.C0.ESC}[?${e};${t}R`)}return!0}softReset(e){return this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._activeBuffer.scrollTop=0,this._activeBuffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=l.DEFAULT_ATTR_DATA.clone(),this._coreService.reset(),this._charsetService.reset(),this._activeBuffer.savedX=0,this._activeBuffer.savedY=this._activeBuffer.ybase,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,this._coreService.decPrivateModes.origin=!1,!0}setCursorStyle(e){const t=e.params[0]||1;switch(t){case 1:case 2:this._optionsService.options.cursorStyle="block";break;case 3:case 4:this._optionsService.options.cursorStyle="underline";break;case 5:case 6:this._optionsService.options.cursorStyle="bar"}const i=t%2==1;return this._optionsService.options.cursorBlink=i,!0}setScrollRegion(e){const t=e.params[0]||1;let i;return(e.length<2||(i=e.params[1])>this._bufferService.rows||0===i)&&(i=this._bufferService.rows),i>t&&(this._activeBuffer.scrollTop=t-1,this._activeBuffer.scrollBottom=i-1,this._setCursor(0,0)),!0}windowOptions(e){if(!b(e.params[0],this._optionsService.rawOptions.windowOptions))return!0;const t=e.length>1?e.params[1]:0;switch(e.params[0]){case 14:2!==t&&this._onRequestWindowsOptionsReport.fire(y.GET_WIN_SIZE_PIXELS);break;case 16:this._onRequestWindowsOptionsReport.fire(y.GET_CELL_SIZE_PIXELS);break;case 18:this._bufferService&&this._coreService.triggerDataEvent(`${n.C0.ESC}[8;${this._bufferService.rows};${this._bufferService.cols}t`);break;case 22:0!==t&&2!==t||(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>10&&this._windowTitleStack.shift()),0!==t&&1!==t||(this._iconNameStack.push(this._iconName),this._iconNameStack.length>10&&this._iconNameStack.shift());break;case 23:0!==t&&2!==t||this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),0!==t&&1!==t||this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop())}return!0}saveCursor(e){return this._activeBuffer.savedX=this._activeBuffer.x,this._activeBuffer.savedY=this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,!0}restoreCursor(e){return this._activeBuffer.x=this._activeBuffer.savedX||0,this._activeBuffer.y=Math.max(this._activeBuffer.savedY-this._activeBuffer.ybase,0),this._curAttrData.fg=this._activeBuffer.savedCurAttrData.fg,this._curAttrData.bg=this._activeBuffer.savedCurAttrData.bg,this._charsetService.charset=this._savedCharset,this._activeBuffer.savedCharset&&(this._charsetService.charset=this._activeBuffer.savedCharset),this._restrictCursor(),!0}setTitle(e){return this._windowTitle=e,this._onTitleChange.fire(e),!0}setIconName(e){return this._iconName=e,!0}setOrReportIndexedColor(e){const t=[],i=e.split(";");for(;i.length>1;){const e=i.shift(),s=i.shift();if(/^\d+$/.exec(e)){const i=parseInt(e);if(L(i))if("?"===s)t.push({type:0,index:i});else{const e=(0,m.parseColor)(s);e&&t.push({type:1,index:i,color:e})}}}return t.length&&this._onColor.fire(t),!0}setHyperlink(e){const t=e.split(";");return!(t.length<2)&&(t[1]?this._createHyperlink(t[0],t[1]):!t[0]&&this._finishHyperlink())}_createHyperlink(e,t){this._getCurrentLinkId()&&this._finishHyperlink();const i=e.split(":");let s;const r=i.findIndex((e=>e.startsWith("id=")));return-1!==r&&(s=i[r].slice(3)||void 0),this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=this._oscLinkService.registerLink({id:s,uri:t}),this._curAttrData.updateExtended(),!0}_finishHyperlink(){return this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=0,this._curAttrData.updateExtended(),!0}_setOrReportSpecialColor(e,t){const i=e.split(";");for(let s=0;s=this._specialColors.length);++s,++t)if("?"===i[s])this._onColor.fire([{type:0,index:this._specialColors[t]}]);else{const e=(0,m.parseColor)(i[s]);e&&this._onColor.fire([{type:1,index:this._specialColors[t],color:e}])}return!0}setOrReportFgColor(e){return this._setOrReportSpecialColor(e,0)}setOrReportBgColor(e){return this._setOrReportSpecialColor(e,1)}setOrReportCursorColor(e){return this._setOrReportSpecialColor(e,2)}restoreIndexedColor(e){if(!e)return this._onColor.fire([{type:2}]),!0;const t=[],i=e.split(";");for(let s=0;s=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._restrictCursor(),!0}tabSet(){return this._activeBuffer.tabs[this._activeBuffer.x]=!0,!0}reverseIndex(){if(this._restrictCursor(),this._activeBuffer.y===this._activeBuffer.scrollTop){const e=this._activeBuffer.scrollBottom-this._activeBuffer.scrollTop;this._activeBuffer.lines.shiftElements(this._activeBuffer.ybase+this._activeBuffer.y,e,1),this._activeBuffer.lines.set(this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.getBlankLine(this._eraseAttrData())),this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom)}else this._activeBuffer.y--,this._restrictCursor();return!0}fullReset(){return this._parser.reset(),this._onRequestReset.fire(),!0}reset(){this._curAttrData=l.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=l.DEFAULT_ATTR_DATA.clone()}_eraseAttrData(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=67108863&this._curAttrData.bg,this._eraseAttrDataInternal}setgLevel(e){return this._charsetService.setgLevel(e),!0}screenAlignmentPattern(){const e=new u.CellData;e.content=1<<22|"E".charCodeAt(0),e.fg=this._curAttrData.fg,e.bg=this._curAttrData.bg,this._setCursor(0,0);for(let t=0;t(this._coreService.triggerDataEvent(`${n.C0.ESC}${e}${n.C0.ESC}\\`),!0))('"q'===e?`P1$r${this._curAttrData.isProtected()?1:0}"q`:'"p'===e?'P1$r61;1"p':"r"===e?`P1$r${i.scrollTop+1};${i.scrollBottom+1}r`:"m"===e?"P1$r0m":" q"===e?`P1$r${{block:2,underline:4,bar:6}[s.cursorStyle]-(s.cursorBlink?1:0)} q`:"P0$r")}markRangeDirty(e,t){this._dirtyRowTracker.markRangeDirty(e,t)}}t.InputHandler=E;let k=class{constructor(e){this._bufferService=e,this.clearRange()}clearRange(){this.start=this._bufferService.buffer.y,this.end=this._bufferService.buffer.y}markDirty(e){ethis.end&&(this.end=e)}markRangeDirty(e,t){e>t&&(w=e,e=t,t=w),ethis.end&&(this.end=t)}markAllDirty(){this.markRangeDirty(0,this._bufferService.rows-1)}};function L(e){return 0<=e&&e<256}k=s([r(0,v.IBufferService)],k)},844:(e,t)=>{function i(e){for(const t of e)t.dispose();e.length=0}Object.defineProperty(t,"__esModule",{value:!0}),t.getDisposeArrayDisposable=t.disposeArray=t.toDisposable=t.MutableDisposable=t.Disposable=void 0,t.Disposable=class{constructor(){this._disposables=[],this._isDisposed=!1}dispose(){this._isDisposed=!0;for(const e of this._disposables)e.dispose();this._disposables.length=0}register(e){return this._disposables.push(e),e}unregister(e){const t=this._disposables.indexOf(e);-1!==t&&this._disposables.splice(t,1)}},t.MutableDisposable=class{constructor(){this._isDisposed=!1}get value(){return this._isDisposed?void 0:this._value}set value(e){var t;this._isDisposed||e===this._value||(null===(t=this._value)||void 0===t||t.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){var e;this._isDisposed=!0,null===(e=this._value)||void 0===e||e.dispose(),this._value=void 0}},t.toDisposable=function(e){return{dispose:e}},t.disposeArray=i,t.getDisposeArrayDisposable=function(e){return{dispose:()=>i(e)}}},1505:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.FourKeyMap=t.TwoKeyMap=void 0;class i{constructor(){this._data={}}set(e,t,i){this._data[e]||(this._data[e]={}),this._data[e][t]=i}get(e,t){return this._data[e]?this._data[e][t]:void 0}clear(){this._data={}}}t.TwoKeyMap=i,t.FourKeyMap=class{constructor(){this._data=new i}set(e,t,s,r,n){this._data.get(e,t)||this._data.set(e,t,new i),this._data.get(e,t).set(s,r,n)}get(e,t,i,s){var r;return null===(r=this._data.get(e,t))||void 0===r?void 0:r.get(i,s)}clear(){this._data.clear()}}},6114:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isChromeOS=t.isLinux=t.isWindows=t.isIphone=t.isIpad=t.isMac=t.getSafariVersion=t.isSafari=t.isLegacyEdge=t.isFirefox=t.isNode=void 0,t.isNode="undefined"==typeof navigator;const i=t.isNode?"node":navigator.userAgent,s=t.isNode?"node":navigator.platform;t.isFirefox=i.includes("Firefox"),t.isLegacyEdge=i.includes("Edge"),t.isSafari=/^((?!chrome|android).)*safari/i.test(i),t.getSafariVersion=function(){if(!t.isSafari)return 0;const e=i.match(/Version\/(\d+)/);return null===e||e.length<2?0:parseInt(e[1])},t.isMac=["Macintosh","MacIntel","MacPPC","Mac68K"].includes(s),t.isIpad="iPad"===s,t.isIphone="iPhone"===s,t.isWindows=["Windows","Win16","Win32","WinCE"].includes(s),t.isLinux=s.indexOf("Linux")>=0,t.isChromeOS=/\bCrOS\b/.test(i)},6106:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SortedList=void 0;let i=0;t.SortedList=class{constructor(e){this._getKey=e,this._array=[]}clear(){this._array.length=0}insert(e){0!==this._array.length?(i=this._search(this._getKey(e)),this._array.splice(i,0,e)):this._array.push(e)}delete(e){if(0===this._array.length)return!1;const t=this._getKey(e);if(void 0===t)return!1;if(i=this._search(t),-1===i)return!1;if(this._getKey(this._array[i])!==t)return!1;do{if(this._array[i]===e)return this._array.splice(i,1),!0}while(++i=this._array.length)&&this._getKey(this._array[i])===e))do{yield this._array[i]}while(++i=this._array.length)&&this._getKey(this._array[i])===e))do{t(this._array[i])}while(++i=t;){let s=t+i>>1;const r=this._getKey(this._array[s]);if(r>e)i=s-1;else{if(!(r0&&this._getKey(this._array[s-1])===e;)s--;return s}t=s+1}}return t}}},7226:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DebouncedIdleTask=t.IdleTaskQueue=t.PriorityTaskQueue=void 0;const s=i(6114);class r{constructor(){this._tasks=[],this._i=0}enqueue(e){this._tasks.push(e),this._start()}flush(){for(;this._ir)return s-t<-20&&console.warn(`task queue exceeded allotted deadline by ${Math.abs(Math.round(s-t))}ms`),void this._start();s=r}this.clear()}}class n extends r{_requestCallback(e){return setTimeout((()=>e(this._createDeadline(16))))}_cancelCallback(e){clearTimeout(e)}_createDeadline(e){const t=Date.now()+e;return{timeRemaining:()=>Math.max(0,t-Date.now())}}}t.PriorityTaskQueue=n,t.IdleTaskQueue=!s.isNode&&"requestIdleCallback"in window?class extends r{_requestCallback(e){return requestIdleCallback(e)}_cancelCallback(e){cancelIdleCallback(e)}}:n,t.DebouncedIdleTask=class{constructor(){this._queue=new t.IdleTaskQueue}set(e){this._queue.clear(),this._queue.enqueue(e)}flush(){this._queue.flush()}}},9282:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.updateWindowsModeWrappedState=void 0;const s=i(643);t.updateWindowsModeWrappedState=function(e){const t=e.buffer.lines.get(e.buffer.ybase+e.buffer.y-1),i=null==t?void 0:t.get(e.cols-1),r=e.buffer.lines.get(e.buffer.ybase+e.buffer.y);r&&i&&(r.isWrapped=i[s.CHAR_DATA_CODE_INDEX]!==s.NULL_CELL_CODE&&i[s.CHAR_DATA_CODE_INDEX]!==s.WHITESPACE_CELL_CODE)}},3734:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ExtendedAttrs=t.AttributeData=void 0;class i{constructor(){this.fg=0,this.bg=0,this.extended=new s}static toColorRGB(e){return[e>>>16&255,e>>>8&255,255&e]}static fromColorRGB(e){return(255&e[0])<<16|(255&e[1])<<8|255&e[2]}clone(){const e=new i;return e.fg=this.fg,e.bg=this.bg,e.extended=this.extended.clone(),e}isInverse(){return 67108864&this.fg}isBold(){return 134217728&this.fg}isUnderline(){return this.hasExtendedAttrs()&&0!==this.extended.underlineStyle?1:268435456&this.fg}isBlink(){return 536870912&this.fg}isInvisible(){return 1073741824&this.fg}isItalic(){return 67108864&this.bg}isDim(){return 134217728&this.bg}isStrikethrough(){return 2147483648&this.fg}isProtected(){return 536870912&this.bg}isOverline(){return 1073741824&this.bg}getFgColorMode(){return 50331648&this.fg}getBgColorMode(){return 50331648&this.bg}isFgRGB(){return 50331648==(50331648&this.fg)}isBgRGB(){return 50331648==(50331648&this.bg)}isFgPalette(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)}isBgPalette(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)}isFgDefault(){return 0==(50331648&this.fg)}isBgDefault(){return 0==(50331648&this.bg)}isAttributeDefault(){return 0===this.fg&&0===this.bg}getFgColor(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}}getBgColor(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}}hasExtendedAttrs(){return 268435456&this.bg}updateExtended(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456}getUnderlineColor(){if(268435456&this.bg&&~this.extended.underlineColor)switch(50331648&this.extended.underlineColor){case 16777216:case 33554432:return 255&this.extended.underlineColor;case 50331648:return 16777215&this.extended.underlineColor;default:return this.getFgColor()}return this.getFgColor()}getUnderlineColorMode(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()}isUnderlineColorRGB(){return 268435456&this.bg&&~this.extended.underlineColor?50331648==(50331648&this.extended.underlineColor):this.isFgRGB()}isUnderlineColorPalette(){return 268435456&this.bg&&~this.extended.underlineColor?16777216==(50331648&this.extended.underlineColor)||33554432==(50331648&this.extended.underlineColor):this.isFgPalette()}isUnderlineColorDefault(){return 268435456&this.bg&&~this.extended.underlineColor?0==(50331648&this.extended.underlineColor):this.isFgDefault()}getUnderlineStyle(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0}}t.AttributeData=i;class s{get ext(){return this._urlId?-469762049&this._ext|this.underlineStyle<<26:this._ext}set ext(e){this._ext=e}get underlineStyle(){return this._urlId?5:(469762048&this._ext)>>26}set underlineStyle(e){this._ext&=-469762049,this._ext|=e<<26&469762048}get underlineColor(){return 67108863&this._ext}set underlineColor(e){this._ext&=-67108864,this._ext|=67108863&e}get urlId(){return this._urlId}set urlId(e){this._urlId=e}constructor(e=0,t=0){this._ext=0,this._urlId=0,this._ext=e,this._urlId=t}clone(){return new s(this._ext,this._urlId)}isEmpty(){return 0===this.underlineStyle&&0===this._urlId}}t.ExtendedAttrs=s},9092:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Buffer=t.MAX_BUFFER_SIZE=void 0;const s=i(6349),r=i(7226),n=i(3734),o=i(8437),a=i(4634),h=i(511),c=i(643),l=i(4863),d=i(7116);t.MAX_BUFFER_SIZE=4294967295,t.Buffer=class{constructor(e,t,i){this._hasScrollback=e,this._optionsService=t,this._bufferService=i,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.tabs={},this.savedY=0,this.savedX=0,this.savedCurAttrData=o.DEFAULT_ATTR_DATA.clone(),this.savedCharset=d.DEFAULT_CHARSET,this.markers=[],this._nullCell=h.CellData.fromCharData([0,c.NULL_CELL_CHAR,c.NULL_CELL_WIDTH,c.NULL_CELL_CODE]),this._whitespaceCell=h.CellData.fromCharData([0,c.WHITESPACE_CELL_CHAR,c.WHITESPACE_CELL_WIDTH,c.WHITESPACE_CELL_CODE]),this._isClearing=!1,this._memoryCleanupQueue=new r.IdleTaskQueue,this._memoryCleanupPosition=0,this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new s.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}getNullCell(e){return e?(this._nullCell.fg=e.fg,this._nullCell.bg=e.bg,this._nullCell.extended=e.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new n.ExtendedAttrs),this._nullCell}getWhitespaceCell(e){return e?(this._whitespaceCell.fg=e.fg,this._whitespaceCell.bg=e.bg,this._whitespaceCell.extended=e.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new n.ExtendedAttrs),this._whitespaceCell}getBlankLine(e,t){return new o.BufferLine(this._bufferService.cols,this.getNullCell(e),t)}get hasScrollback(){return this._hasScrollback&&this.lines.maxLength>this._rows}get isCursorInViewport(){const e=this.ybase+this.y-this.ydisp;return e>=0&&et.MAX_BUFFER_SIZE?t.MAX_BUFFER_SIZE:i}fillViewportRows(e){if(0===this.lines.length){void 0===e&&(e=o.DEFAULT_ATTR_DATA);let t=this._rows;for(;t--;)this.lines.push(this.getBlankLine(e))}}clear(){this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.lines=new s.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}resize(e,t){const i=this.getNullCell(o.DEFAULT_ATTR_DATA);let s=0;const r=this._getCorrectBufferLength(t);if(r>this.lines.maxLength&&(this.lines.maxLength=r),this.lines.length>0){if(this._cols0&&this.lines.length<=this.ybase+this.y+n+1?(this.ybase--,n++,this.ydisp>0&&this.ydisp--):this.lines.push(new o.BufferLine(e,i)));else for(let e=this._rows;e>t;e--)this.lines.length>t+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(r0&&(this.lines.trimStart(e),this.ybase=Math.max(this.ybase-e,0),this.ydisp=Math.max(this.ydisp-e,0),this.savedY=Math.max(this.savedY-e,0)),this.lines.maxLength=r}this.x=Math.min(this.x,e-1),this.y=Math.min(this.y,t-1),n&&(this.y+=n),this.savedX=Math.min(this.savedX,e-1),this.scrollTop=0}if(this.scrollBottom=t-1,this._isReflowEnabled&&(this._reflow(e,t),this._cols>e))for(let n=0;n.1*this.lines.length&&(this._memoryCleanupPosition=0,this._memoryCleanupQueue.enqueue((()=>this._batchedMemoryCleanup())))}_batchedMemoryCleanup(){let e=!0;this._memoryCleanupPosition>=this.lines.length&&(this._memoryCleanupPosition=0,e=!1);let t=0;for(;this._memoryCleanupPosition100)return!0;return e}get _isReflowEnabled(){const e=this._optionsService.rawOptions.windowsPty;return e&&e.buildNumber?this._hasScrollback&&"conpty"===e.backend&&e.buildNumber>=21376:this._hasScrollback&&!this._optionsService.rawOptions.windowsMode}_reflow(e,t){this._cols!==e&&(e>this._cols?this._reflowLarger(e,t):this._reflowSmaller(e,t))}_reflowLarger(e,t){const i=(0,a.reflowLargerGetLinesToRemove)(this.lines,this._cols,e,this.ybase+this.y,this.getNullCell(o.DEFAULT_ATTR_DATA));if(i.length>0){const s=(0,a.reflowLargerCreateNewLayout)(this.lines,i);(0,a.reflowLargerApplyNewLayout)(this.lines,s.layout),this._reflowLargerAdjustViewport(e,t,s.countRemoved)}}_reflowLargerAdjustViewport(e,t,i){const s=this.getNullCell(o.DEFAULT_ATTR_DATA);let r=i;for(;r-- >0;)0===this.ybase?(this.y>0&&this.y--,this.lines.length=0;n--){let h=this.lines.get(n);if(!h||!h.isWrapped&&h.getTrimmedLength()<=e)continue;const c=[h];for(;h.isWrapped&&n>0;)h=this.lines.get(--n),c.unshift(h);const l=this.ybase+this.y;if(l>=n&&l0&&(s.push({start:n+c.length+r,newLines:v}),r+=v.length),c.push(...v);let p=_.length-1,g=_[p];0===g&&(p--,g=_[p]);let m=c.length-u-1,S=d;for(;m>=0;){const e=Math.min(S,g);if(void 0===c[p])break;if(c[p].copyCellsFrom(c[m],S-e,g-e,e,!0),g-=e,0===g&&(p--,g=_[p]),S-=e,0===S){m--;const e=Math.max(m,0);S=(0,a.getWrappedLineTrimmedLength)(c,e,this._cols)}}for(let t=0;t0;)0===this.ybase?this.y0){const e=[],t=[];for(let s=0;s=0;d--)if(a&&a.start>n+h){for(let e=a.newLines.length-1;e>=0;e--)this.lines.set(d--,a.newLines[e]);d++,e.push({index:n+1,amount:a.newLines.length}),h+=a.newLines.length,a=s[++o]}else this.lines.set(d,t[n--]);let c=0;for(let s=e.length-1;s>=0;s--)e[s].index+=c,this.lines.onInsertEmitter.fire(e[s]),c+=e[s].amount;const l=Math.max(0,i+r-this.lines.maxLength);l>0&&this.lines.onTrimEmitter.fire(l)}}translateBufferLineToString(e,t,i=0,s){const r=this.lines.get(e);return r?r.translateToString(t,i,s):""}getWrappedRangeForLine(e){let t=e,i=e;for(;t>0&&this.lines.get(t).isWrapped;)t--;for(;i+10;);return e>=this._cols?this._cols-1:e<0?0:e}nextStop(e){for(null==e&&(e=this.x);!this.tabs[++e]&&e=this._cols?this._cols-1:e<0?0:e}clearMarkers(e){this._isClearing=!0;for(let t=0;t{t.line-=e,t.line<0&&t.dispose()}))),t.register(this.lines.onInsert((e=>{t.line>=e.index&&(t.line+=e.amount)}))),t.register(this.lines.onDelete((e=>{t.line>=e.index&&t.linee.index&&(t.line-=e.amount)}))),t.register(t.onDispose((()=>this._removeMarker(t)))),t}_removeMarker(e){this._isClearing||this.markers.splice(this.markers.indexOf(e),1)}}},8437:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BufferLine=t.DEFAULT_ATTR_DATA=void 0;const s=i(3734),r=i(511),n=i(643),o=i(482);t.DEFAULT_ATTR_DATA=Object.freeze(new s.AttributeData);let a=0;class h{constructor(e,t,i=!1){this.isWrapped=i,this._combined={},this._extendedAttrs={},this._data=new Uint32Array(3*e);const s=t||r.CellData.fromCharData([0,n.NULL_CELL_CHAR,n.NULL_CELL_WIDTH,n.NULL_CELL_CODE]);for(let r=0;r>22,2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):i]}set(e,t){this._data[3*e+1]=t[n.CHAR_DATA_ATTR_INDEX],t[n.CHAR_DATA_CHAR_INDEX].length>1?(this._combined[e]=t[1],this._data[3*e+0]=2097152|e|t[n.CHAR_DATA_WIDTH_INDEX]<<22):this._data[3*e+0]=t[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|t[n.CHAR_DATA_WIDTH_INDEX]<<22}getWidth(e){return this._data[3*e+0]>>22}hasWidth(e){return 12582912&this._data[3*e+0]}getFg(e){return this._data[3*e+1]}getBg(e){return this._data[3*e+2]}hasContent(e){return 4194303&this._data[3*e+0]}getCodePoint(e){const t=this._data[3*e+0];return 2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):2097151&t}isCombined(e){return 2097152&this._data[3*e+0]}getString(e){const t=this._data[3*e+0];return 2097152&t?this._combined[e]:2097151&t?(0,o.stringFromCodePoint)(2097151&t):""}isProtected(e){return 536870912&this._data[3*e+2]}loadCell(e,t){return a=3*e,t.content=this._data[a+0],t.fg=this._data[a+1],t.bg=this._data[a+2],2097152&t.content&&(t.combinedData=this._combined[e]),268435456&t.bg&&(t.extended=this._extendedAttrs[e]),t}setCell(e,t){2097152&t.content&&(this._combined[e]=t.combinedData),268435456&t.bg&&(this._extendedAttrs[e]=t.extended),this._data[3*e+0]=t.content,this._data[3*e+1]=t.fg,this._data[3*e+2]=t.bg}setCellFromCodePoint(e,t,i,s,r,n){268435456&r&&(this._extendedAttrs[e]=n),this._data[3*e+0]=t|i<<22,this._data[3*e+1]=s,this._data[3*e+2]=r}addCodepointToCell(e,t){let i=this._data[3*e+0];2097152&i?this._combined[e]+=(0,o.stringFromCodePoint)(t):(2097151&i?(this._combined[e]=(0,o.stringFromCodePoint)(2097151&i)+(0,o.stringFromCodePoint)(t),i&=-2097152,i|=2097152):i=t|1<<22,this._data[3*e+0]=i)}insertCells(e,t,i,n){if((e%=this.length)&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==n?void 0:n.fg)||0,(null==n?void 0:n.bg)||0,(null==n?void 0:n.extended)||new s.ExtendedAttrs),t=0;--i)this.setCell(e+t+i,this.loadCell(e+i,s));for(let r=0;rthis.length){if(this._data.buffer.byteLength>=4*i)this._data=new Uint32Array(this._data.buffer,0,i);else{const e=new Uint32Array(i);e.set(this._data),this._data=e}for(let i=this.length;i=e&&delete this._combined[s]}const s=Object.keys(this._extendedAttrs);for(let i=0;i=e&&delete this._extendedAttrs[t]}}return this.length=e,4*i*2=0;--e)if(4194303&this._data[3*e+0])return e+(this._data[3*e+0]>>22);return 0}getNoBgTrimmedLength(){for(let e=this.length-1;e>=0;--e)if(4194303&this._data[3*e+0]||50331648&this._data[3*e+2])return e+(this._data[3*e+0]>>22);return 0}copyCellsFrom(e,t,i,s,r){const n=e._data;if(r)for(let a=s-1;a>=0;a--){for(let e=0;e<3;e++)this._data[3*(i+a)+e]=n[3*(t+a)+e];268435456&n[3*(t+a)+2]&&(this._extendedAttrs[i+a]=e._extendedAttrs[t+a])}else for(let a=0;a=t&&(this._combined[s-t+i]=e._combined[s])}}translateToString(e=!1,t=0,i=this.length){e&&(i=Math.min(i,this.getTrimmedLength()));let s="";for(;t>22||1}return s}}t.BufferLine=h},4841:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getRangeLength=void 0,t.getRangeLength=function(e,t){if(e.start.y>e.end.y)throw new Error(`Buffer range end (${e.end.x}, ${e.end.y}) cannot be before start (${e.start.x}, ${e.start.y})`);return t*(e.end.y-e.start.y)+(e.end.x-e.start.x+1)}},4634:(e,t)=>{function i(e,t,i){if(t===e.length-1)return e[t].getTrimmedLength();const s=!e[t].hasContent(i-1)&&1===e[t].getWidth(i-1),r=2===e[t+1].getWidth(0);return s&&r?i-1:i}Object.defineProperty(t,"__esModule",{value:!0}),t.getWrappedLineTrimmedLength=t.reflowSmallerGetNewLineLengths=t.reflowLargerApplyNewLayout=t.reflowLargerCreateNewLayout=t.reflowLargerGetLinesToRemove=void 0,t.reflowLargerGetLinesToRemove=function(e,t,s,r,n){const o=[];for(let a=0;a=a&&r0&&(e>d||0===l[e].getTrimmedLength());e--)v++;v>0&&(o.push(a+l.length-v),o.push(v)),a+=l.length-1}return o},t.reflowLargerCreateNewLayout=function(e,t){const i=[];let s=0,r=t[s],n=0;for(let o=0;oi(e,r,t))).reduce(((e,t)=>e+t));let o=0,a=0,h=0;for(;hc&&(o-=c,a++);const l=2===e[a].getWidth(o-1);l&&o--;const d=l?s-1:s;r.push(d),h+=d}return r},t.getWrappedLineTrimmedLength=i},5295:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BufferSet=void 0;const s=i(8460),r=i(844),n=i(9092);class o extends r.Disposable{constructor(e,t){super(),this._optionsService=e,this._bufferService=t,this._onBufferActivate=this.register(new s.EventEmitter),this.onBufferActivate=this._onBufferActivate.event,this.reset(),this.register(this._optionsService.onSpecificOptionChange("scrollback",(()=>this.resize(this._bufferService.cols,this._bufferService.rows)))),this.register(this._optionsService.onSpecificOptionChange("tabStopWidth",(()=>this.setupTabStops())))}reset(){this._normal=new n.Buffer(!0,this._optionsService,this._bufferService),this._normal.fillViewportRows(),this._alt=new n.Buffer(!1,this._optionsService,this._bufferService),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}),this.setupTabStops()}get alt(){return this._alt}get active(){return this._activeBuffer}get normal(){return this._normal}activateNormalBuffer(){this._activeBuffer!==this._normal&&(this._normal.x=this._alt.x,this._normal.y=this._alt.y,this._alt.clearAllMarkers(),this._alt.clear(),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}))}activateAltBuffer(e){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(e),this._alt.x=this._normal.x,this._alt.y=this._normal.y,this._activeBuffer=this._alt,this._onBufferActivate.fire({activeBuffer:this._alt,inactiveBuffer:this._normal}))}resize(e,t){this._normal.resize(e,t),this._alt.resize(e,t),this.setupTabStops(e)}setupTabStops(e){this._normal.setupTabStops(e),this._alt.setupTabStops(e)}}t.BufferSet=o},511:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CellData=void 0;const s=i(482),r=i(643),n=i(3734);class o extends n.AttributeData{constructor(){super(...arguments),this.content=0,this.fg=0,this.bg=0,this.extended=new n.ExtendedAttrs,this.combinedData=""}static fromCharData(e){const t=new o;return t.setFromCharData(e),t}isCombined(){return 2097152&this.content}getWidth(){return this.content>>22}getChars(){return 2097152&this.content?this.combinedData:2097151&this.content?(0,s.stringFromCodePoint)(2097151&this.content):""}getCode(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content}setFromCharData(e){this.fg=e[r.CHAR_DATA_ATTR_INDEX],this.bg=0;let t=!1;if(e[r.CHAR_DATA_CHAR_INDEX].length>2)t=!0;else if(2===e[r.CHAR_DATA_CHAR_INDEX].length){const i=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=i&&i<=56319){const s=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=s&&s<=57343?this.content=1024*(i-55296)+s-56320+65536|e[r.CHAR_DATA_WIDTH_INDEX]<<22:t=!0}else t=!0}else this.content=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[r.CHAR_DATA_WIDTH_INDEX]<<22;t&&(this.combinedData=e[r.CHAR_DATA_CHAR_INDEX],this.content=2097152|e[r.CHAR_DATA_WIDTH_INDEX]<<22)}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}t.CellData=o},643:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.WHITESPACE_CELL_CODE=t.WHITESPACE_CELL_WIDTH=t.WHITESPACE_CELL_CHAR=t.NULL_CELL_CODE=t.NULL_CELL_WIDTH=t.NULL_CELL_CHAR=t.CHAR_DATA_CODE_INDEX=t.CHAR_DATA_WIDTH_INDEX=t.CHAR_DATA_CHAR_INDEX=t.CHAR_DATA_ATTR_INDEX=t.DEFAULT_EXT=t.DEFAULT_ATTR=t.DEFAULT_COLOR=void 0,t.DEFAULT_COLOR=0,t.DEFAULT_ATTR=256|t.DEFAULT_COLOR<<9,t.DEFAULT_EXT=0,t.CHAR_DATA_ATTR_INDEX=0,t.CHAR_DATA_CHAR_INDEX=1,t.CHAR_DATA_WIDTH_INDEX=2,t.CHAR_DATA_CODE_INDEX=3,t.NULL_CELL_CHAR="",t.NULL_CELL_WIDTH=1,t.NULL_CELL_CODE=0,t.WHITESPACE_CELL_CHAR=" ",t.WHITESPACE_CELL_WIDTH=1,t.WHITESPACE_CELL_CODE=32},4863:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Marker=void 0;const s=i(8460),r=i(844);class n{get id(){return this._id}constructor(e){this.line=e,this.isDisposed=!1,this._disposables=[],this._id=n._nextId++,this._onDispose=this.register(new s.EventEmitter),this.onDispose=this._onDispose.event}dispose(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire(),(0,r.disposeArray)(this._disposables),this._disposables.length=0)}register(e){return this._disposables.push(e),e}}t.Marker=n,n._nextId=1},7116:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_CHARSET=t.CHARSETS=void 0,t.CHARSETS={},t.DEFAULT_CHARSET=t.CHARSETS.B,t.CHARSETS[0]={"`":"\u25c6",a:"\u2592",b:"\u2409",c:"\u240c",d:"\u240d",e:"\u240a",f:"\xb0",g:"\xb1",h:"\u2424",i:"\u240b",j:"\u2518",k:"\u2510",l:"\u250c",m:"\u2514",n:"\u253c",o:"\u23ba",p:"\u23bb",q:"\u2500",r:"\u23bc",s:"\u23bd",t:"\u251c",u:"\u2524",v:"\u2534",w:"\u252c",x:"\u2502",y:"\u2264",z:"\u2265","{":"\u03c0","|":"\u2260","}":"\xa3","~":"\xb7"},t.CHARSETS.A={"#":"\xa3"},t.CHARSETS.B=void 0,t.CHARSETS[4]={"#":"\xa3","@":"\xbe","[":"ij","\\":"\xbd","]":"|","{":"\xa8","|":"f","}":"\xbc","~":"\xb4"},t.CHARSETS.C=t.CHARSETS[5]={"[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},t.CHARSETS.R={"#":"\xa3","@":"\xe0","[":"\xb0","\\":"\xe7","]":"\xa7","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xa8"},t.CHARSETS.Q={"@":"\xe0","[":"\xe2","\\":"\xe7","]":"\xea","^":"\xee","`":"\xf4","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xfb"},t.CHARSETS.K={"@":"\xa7","[":"\xc4","\\":"\xd6","]":"\xdc","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xdf"},t.CHARSETS.Y={"#":"\xa3","@":"\xa7","[":"\xb0","\\":"\xe7","]":"\xe9","`":"\xf9","{":"\xe0","|":"\xf2","}":"\xe8","~":"\xec"},t.CHARSETS.E=t.CHARSETS[6]={"@":"\xc4","[":"\xc6","\\":"\xd8","]":"\xc5","^":"\xdc","`":"\xe4","{":"\xe6","|":"\xf8","}":"\xe5","~":"\xfc"},t.CHARSETS.Z={"#":"\xa3","@":"\xa7","[":"\xa1","\\":"\xd1","]":"\xbf","{":"\xb0","|":"\xf1","}":"\xe7"},t.CHARSETS.H=t.CHARSETS[7]={"@":"\xc9","[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},t.CHARSETS["="]={"#":"\xf9","@":"\xe0","[":"\xe9","\\":"\xe7","]":"\xea","^":"\xee",_:"\xe8","`":"\xf4","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xfb"}},2584:(e,t)=>{var i,s,r;Object.defineProperty(t,"__esModule",{value:!0}),t.C1_ESCAPED=t.C1=t.C0=void 0,function(e){e.NUL="\0",e.SOH="\x01",e.STX="\x02",e.ETX="\x03",e.EOT="\x04",e.ENQ="\x05",e.ACK="\x06",e.BEL="\x07",e.BS="\b",e.HT="\t",e.LF="\n",e.VT="\v",e.FF="\f",e.CR="\r",e.SO="\x0e",e.SI="\x0f",e.DLE="\x10",e.DC1="\x11",e.DC2="\x12",e.DC3="\x13",e.DC4="\x14",e.NAK="\x15",e.SYN="\x16",e.ETB="\x17",e.CAN="\x18",e.EM="\x19",e.SUB="\x1a",e.ESC="\x1b",e.FS="\x1c",e.GS="\x1d",e.RS="\x1e",e.US="\x1f",e.SP=" ",e.DEL="\x7f"}(i||(t.C0=i={})),function(e){e.PAD="\x80",e.HOP="\x81",e.BPH="\x82",e.NBH="\x83",e.IND="\x84",e.NEL="\x85",e.SSA="\x86",e.ESA="\x87",e.HTS="\x88",e.HTJ="\x89",e.VTS="\x8a",e.PLD="\x8b",e.PLU="\x8c",e.RI="\x8d",e.SS2="\x8e",e.SS3="\x8f",e.DCS="\x90",e.PU1="\x91",e.PU2="\x92",e.STS="\x93",e.CCH="\x94",e.MW="\x95",e.SPA="\x96",e.EPA="\x97",e.SOS="\x98",e.SGCI="\x99",e.SCI="\x9a",e.CSI="\x9b",e.ST="\x9c",e.OSC="\x9d",e.PM="\x9e",e.APC="\x9f"}(s||(t.C1=s={})),function(e){e.ST=`${i.ESC}\\`}(r||(t.C1_ESCAPED=r={}))},7399:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.evaluateKeyboardEvent=void 0;const s=i(2584),r={48:["0",")"],49:["1","!"],50:["2","@"],51:["3","#"],52:["4","$"],53:["5","%"],54:["6","^"],55:["7","&"],56:["8","*"],57:["9","("],186:[";",":"],187:["=","+"],188:[",","<"],189:["-","_"],190:[".",">"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};t.evaluateKeyboardEvent=function(e,t,i,n){const o={type:0,cancel:!1,key:void 0},a=(e.shiftKey?1:0)|(e.altKey?2:0)|(e.ctrlKey?4:0)|(e.metaKey?8:0);switch(e.keyCode){case 0:"UIKeyInputUpArrow"===e.key?o.key=t?s.C0.ESC+"OA":s.C0.ESC+"[A":"UIKeyInputLeftArrow"===e.key?o.key=t?s.C0.ESC+"OD":s.C0.ESC+"[D":"UIKeyInputRightArrow"===e.key?o.key=t?s.C0.ESC+"OC":s.C0.ESC+"[C":"UIKeyInputDownArrow"===e.key&&(o.key=t?s.C0.ESC+"OB":s.C0.ESC+"[B");break;case 8:if(e.altKey){o.key=s.C0.ESC+s.C0.DEL;break}o.key=s.C0.DEL;break;case 9:if(e.shiftKey){o.key=s.C0.ESC+"[Z";break}o.key=s.C0.HT,o.cancel=!0;break;case 13:o.key=e.altKey?s.C0.ESC+s.C0.CR:s.C0.CR,o.cancel=!0;break;case 27:o.key=s.C0.ESC,e.altKey&&(o.key=s.C0.ESC+s.C0.ESC),o.cancel=!0;break;case 37:if(e.metaKey)break;a?(o.key=s.C0.ESC+"[1;"+(a+1)+"D",o.key===s.C0.ESC+"[1;3D"&&(o.key=s.C0.ESC+(i?"b":"[1;5D"))):o.key=t?s.C0.ESC+"OD":s.C0.ESC+"[D";break;case 39:if(e.metaKey)break;a?(o.key=s.C0.ESC+"[1;"+(a+1)+"C",o.key===s.C0.ESC+"[1;3C"&&(o.key=s.C0.ESC+(i?"f":"[1;5C"))):o.key=t?s.C0.ESC+"OC":s.C0.ESC+"[C";break;case 38:if(e.metaKey)break;a?(o.key=s.C0.ESC+"[1;"+(a+1)+"A",i||o.key!==s.C0.ESC+"[1;3A"||(o.key=s.C0.ESC+"[1;5A")):o.key=t?s.C0.ESC+"OA":s.C0.ESC+"[A";break;case 40:if(e.metaKey)break;a?(o.key=s.C0.ESC+"[1;"+(a+1)+"B",i||o.key!==s.C0.ESC+"[1;3B"||(o.key=s.C0.ESC+"[1;5B")):o.key=t?s.C0.ESC+"OB":s.C0.ESC+"[B";break;case 45:e.shiftKey||e.ctrlKey||(o.key=s.C0.ESC+"[2~");break;case 46:o.key=a?s.C0.ESC+"[3;"+(a+1)+"~":s.C0.ESC+"[3~";break;case 36:o.key=a?s.C0.ESC+"[1;"+(a+1)+"H":t?s.C0.ESC+"OH":s.C0.ESC+"[H";break;case 35:o.key=a?s.C0.ESC+"[1;"+(a+1)+"F":t?s.C0.ESC+"OF":s.C0.ESC+"[F";break;case 33:e.shiftKey?o.type=2:e.ctrlKey?o.key=s.C0.ESC+"[5;"+(a+1)+"~":o.key=s.C0.ESC+"[5~";break;case 34:e.shiftKey?o.type=3:e.ctrlKey?o.key=s.C0.ESC+"[6;"+(a+1)+"~":o.key=s.C0.ESC+"[6~";break;case 112:o.key=a?s.C0.ESC+"[1;"+(a+1)+"P":s.C0.ESC+"OP";break;case 113:o.key=a?s.C0.ESC+"[1;"+(a+1)+"Q":s.C0.ESC+"OQ";break;case 114:o.key=a?s.C0.ESC+"[1;"+(a+1)+"R":s.C0.ESC+"OR";break;case 115:o.key=a?s.C0.ESC+"[1;"+(a+1)+"S":s.C0.ESC+"OS";break;case 116:o.key=a?s.C0.ESC+"[15;"+(a+1)+"~":s.C0.ESC+"[15~";break;case 117:o.key=a?s.C0.ESC+"[17;"+(a+1)+"~":s.C0.ESC+"[17~";break;case 118:o.key=a?s.C0.ESC+"[18;"+(a+1)+"~":s.C0.ESC+"[18~";break;case 119:o.key=a?s.C0.ESC+"[19;"+(a+1)+"~":s.C0.ESC+"[19~";break;case 120:o.key=a?s.C0.ESC+"[20;"+(a+1)+"~":s.C0.ESC+"[20~";break;case 121:o.key=a?s.C0.ESC+"[21;"+(a+1)+"~":s.C0.ESC+"[21~";break;case 122:o.key=a?s.C0.ESC+"[23;"+(a+1)+"~":s.C0.ESC+"[23~";break;case 123:o.key=a?s.C0.ESC+"[24;"+(a+1)+"~":s.C0.ESC+"[24~";break;default:if(!e.ctrlKey||e.shiftKey||e.altKey||e.metaKey)if(i&&!n||!e.altKey||e.metaKey)!i||e.altKey||e.ctrlKey||e.shiftKey||!e.metaKey?e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&e.keyCode>=48&&1===e.key.length?o.key=e.key:e.key&&e.ctrlKey&&("_"===e.key&&(o.key=s.C0.US),"@"===e.key&&(o.key=s.C0.NUL)):65===e.keyCode&&(o.type=1);else{const t=r[e.keyCode],i=null==t?void 0:t[e.shiftKey?1:0];if(i)o.key=s.C0.ESC+i;else if(e.keyCode>=65&&e.keyCode<=90){const t=e.ctrlKey?e.keyCode-64:e.keyCode+32;let i=String.fromCharCode(t);e.shiftKey&&(i=i.toUpperCase()),o.key=s.C0.ESC+i}else if(32===e.keyCode)o.key=s.C0.ESC+(e.ctrlKey?s.C0.NUL:" ");else if("Dead"===e.key&&e.code.startsWith("Key")){let t=e.code.slice(3,4);e.shiftKey||(t=t.toLowerCase()),o.key=s.C0.ESC+t,o.cancel=!0}}else e.keyCode>=65&&e.keyCode<=90?o.key=String.fromCharCode(e.keyCode-64):32===e.keyCode?o.key=s.C0.NUL:e.keyCode>=51&&e.keyCode<=55?o.key=String.fromCharCode(e.keyCode-51+27):56===e.keyCode?o.key=s.C0.DEL:219===e.keyCode?o.key=s.C0.ESC:220===e.keyCode?o.key=s.C0.FS:221===e.keyCode&&(o.key=s.C0.GS)}return o}},482:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ToUtf32=t.StringToUtf32=t.utf32ToString=t.stringFromCodePoint=void 0,t.stringFromCodePoint=function(e){return e>65535?(e-=65536,String.fromCharCode(55296+(e>>10))+String.fromCharCode(e%1024+56320)):String.fromCharCode(e)},t.utf32ToString=function(e,t=0,i=e.length){let s="";for(let r=t;r65535?(t-=65536,s+=String.fromCharCode(55296+(t>>10))+String.fromCharCode(t%1024+56320)):s+=String.fromCharCode(t)}return s},t.StringToUtf32=class{constructor(){this._interim=0}clear(){this._interim=0}decode(e,t){const i=e.length;if(!i)return 0;let s=0,r=0;if(this._interim){const i=e.charCodeAt(r++);56320<=i&&i<=57343?t[s++]=1024*(this._interim-55296)+i-56320+65536:(t[s++]=this._interim,t[s++]=i),this._interim=0}for(let n=r;n=i)return this._interim=r,s;const o=e.charCodeAt(n);56320<=o&&o<=57343?t[s++]=1024*(r-55296)+o-56320+65536:(t[s++]=r,t[s++]=o)}else 65279!==r&&(t[s++]=r)}return s}},t.Utf8ToUtf32=class{constructor(){this.interim=new Uint8Array(3)}clear(){this.interim.fill(0)}decode(e,t){const i=e.length;if(!i)return 0;let s,r,n,o,a=0,h=0,c=0;if(this.interim[0]){let s=!1,r=this.interim[0];r&=192==(224&r)?31:224==(240&r)?15:7;let n,o=0;for(;(n=63&this.interim[++o])&&o<4;)r<<=6,r|=n;const h=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,l=h-o;for(;c=i)return 0;if(n=e[c++],128!=(192&n)){c--,s=!0;break}this.interim[o++]=n,r<<=6,r|=63&n}s||(2===h?r<128?c--:t[a++]=r:3===h?r<2048||r>=55296&&r<=57343||65279===r||(t[a++]=r):r<65536||r>1114111||(t[a++]=r)),this.interim.fill(0)}const l=i-4;let d=c;for(;d=i)return this.interim[0]=s,a;if(r=e[d++],128!=(192&r)){d--;continue}if(h=(31&s)<<6|63&r,h<128){d--;continue}t[a++]=h}else if(224==(240&s)){if(d>=i)return this.interim[0]=s,a;if(r=e[d++],128!=(192&r)){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,a;if(n=e[d++],128!=(192&n)){d--;continue}if(h=(15&s)<<12|(63&r)<<6|63&n,h<2048||h>=55296&&h<=57343||65279===h)continue;t[a++]=h}else if(240==(248&s)){if(d>=i)return this.interim[0]=s,a;if(r=e[d++],128!=(192&r)){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,a;if(n=e[d++],128!=(192&n)){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,this.interim[2]=n,a;if(o=e[d++],128!=(192&o)){d--;continue}if(h=(7&s)<<18|(63&r)<<12|(63&n)<<6|63&o,h<65536||h>1114111)continue;t[a++]=h}}return a}}},225:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeV6=void 0;const i=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531]],s=[[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]];let r;t.UnicodeV6=class{constructor(){if(this.version="6",!r){r=new Uint8Array(65536),r.fill(1),r[0]=0,r.fill(0,1,32),r.fill(0,127,160),r.fill(2,4352,4448),r[9001]=2,r[9002]=2,r.fill(2,11904,42192),r[12351]=1,r.fill(2,44032,55204),r.fill(2,63744,64256),r.fill(2,65040,65050),r.fill(2,65072,65136),r.fill(2,65280,65377),r.fill(2,65504,65511);for(let e=0;et[r][1])return!1;for(;r>=s;)if(i=s+r>>1,e>t[i][1])s=i+1;else{if(!(e=131072&&e<=196605||e>=196608&&e<=262141?2:1}}},5981:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.WriteBuffer=void 0;const s=i(8460),r=i(844);class n extends r.Disposable{constructor(e){super(),this._action=e,this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0,this._isSyncWriting=!1,this._syncCalls=0,this._didUserInput=!1,this._onWriteParsed=this.register(new s.EventEmitter),this.onWriteParsed=this._onWriteParsed.event}handleUserInput(){this._didUserInput=!0}writeSync(e,t){if(void 0!==t&&this._syncCalls>t)return void(this._syncCalls=0);if(this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(void 0),this._syncCalls++,this._isSyncWriting)return;let i;for(this._isSyncWriting=!0;i=this._writeBuffer.shift();){this._action(i);const e=this._callbacks.shift();e&&e()}this._pendingData=0,this._bufferOffset=2147483647,this._isSyncWriting=!1,this._syncCalls=0}write(e,t){if(this._pendingData>5e7)throw new Error("write data discarded, use flow control to avoid losing data");if(!this._writeBuffer.length){if(this._bufferOffset=0,this._didUserInput)return this._didUserInput=!1,this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t),void this._innerWrite();setTimeout((()=>this._innerWrite()))}this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t)}_innerWrite(e=0,t=!0){const i=e||Date.now();for(;this._writeBuffer.length>this._bufferOffset;){const e=this._writeBuffer[this._bufferOffset],s=this._action(e,t);if(s){const e=e=>Date.now()-i>=12?setTimeout((()=>this._innerWrite(0,e))):this._innerWrite(i,e);return void s.catch((e=>(queueMicrotask((()=>{throw e})),Promise.resolve(!1)))).then(e)}const r=this._callbacks[this._bufferOffset];if(r&&r(),this._bufferOffset++,this._pendingData-=e.length,Date.now()-i>=12)break}this._writeBuffer.length>this._bufferOffset?(this._bufferOffset>50&&(this._writeBuffer=this._writeBuffer.slice(this._bufferOffset),this._callbacks=this._callbacks.slice(this._bufferOffset),this._bufferOffset=0),setTimeout((()=>this._innerWrite()))):(this._writeBuffer.length=0,this._callbacks.length=0,this._pendingData=0,this._bufferOffset=0),this._onWriteParsed.fire()}}t.WriteBuffer=n},5941:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.toRgbString=t.parseColor=void 0;const i=/^([\da-f])\/([\da-f])\/([\da-f])$|^([\da-f]{2})\/([\da-f]{2})\/([\da-f]{2})$|^([\da-f]{3})\/([\da-f]{3})\/([\da-f]{3})$|^([\da-f]{4})\/([\da-f]{4})\/([\da-f]{4})$/,s=/^[\da-f]+$/;function r(e,t){const i=e.toString(16),s=i.length<2?"0"+i:i;switch(t){case 4:return i[0];case 8:return s;case 12:return(s+s).slice(0,3);default:return s+s}}t.parseColor=function(e){if(!e)return;let t=e.toLowerCase();if(0===t.indexOf("rgb:")){t=t.slice(4);const e=i.exec(t);if(e){const t=e[1]?15:e[4]?255:e[7]?4095:65535;return[Math.round(parseInt(e[1]||e[4]||e[7]||e[10],16)/t*255),Math.round(parseInt(e[2]||e[5]||e[8]||e[11],16)/t*255),Math.round(parseInt(e[3]||e[6]||e[9]||e[12],16)/t*255)]}}else if(0===t.indexOf("#")&&(t=t.slice(1),s.exec(t)&&[3,6,9,12].includes(t.length))){const e=t.length/3,i=[0,0,0];for(let s=0;s<3;++s){const r=parseInt(t.slice(e*s,e*s+e),16);i[s]=1===e?r<<4:2===e?r:3===e?r>>4:r>>8}return i}},t.toRgbString=function(e,t=16){const[i,s,n]=e;return`rgb:${r(i,t)}/${r(s,t)}/${r(n,t)}`}},5770:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PAYLOAD_LIMIT=void 0,t.PAYLOAD_LIMIT=1e7},6351:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DcsHandler=t.DcsParser=void 0;const s=i(482),r=i(8742),n=i(5770),o=[];t.DcsParser=class{constructor(){this._handlers=Object.create(null),this._active=o,this._ident=0,this._handlerFb=()=>{},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}dispose(){this._handlers=Object.create(null),this._handlerFb=()=>{},this._active=o}registerHandler(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);const i=this._handlers[e];return i.push(t),{dispose:()=>{const e=i.indexOf(t);-1!==e&&i.splice(e,1)}}}clearHandler(e){this._handlers[e]&&delete this._handlers[e]}setHandlerFallback(e){this._handlerFb=e}reset(){if(this._active.length)for(let e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].unhook(!1);this._stack.paused=!1,this._active=o,this._ident=0}hook(e,t){if(this.reset(),this._ident=e,this._active=this._handlers[e]||o,this._active.length)for(let i=this._active.length-1;i>=0;i--)this._active[i].hook(t);else this._handlerFb(this._ident,"HOOK",t)}put(e,t,i){if(this._active.length)for(let s=this._active.length-1;s>=0;s--)this._active[s].put(e,t,i);else this._handlerFb(this._ident,"PUT",(0,s.utf32ToString)(e,t,i))}unhook(e,t=!0){if(this._active.length){let i=!1,s=this._active.length-1,r=!1;if(this._stack.paused&&(s=this._stack.loopPosition-1,i=t,r=this._stack.fallThrough,this._stack.paused=!1),!r&&!1===i){for(;s>=0&&(i=this._active[s].unhook(e),!0!==i);s--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=s,this._stack.fallThrough=!1,i;s--}for(;s>=0;s--)if(i=this._active[s].unhook(!1),i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=s,this._stack.fallThrough=!0,i}else this._handlerFb(this._ident,"UNHOOK",e);this._active=o,this._ident=0}};const a=new r.Params;a.addParam(0),t.DcsHandler=class{constructor(e){this._handler=e,this._data="",this._params=a,this._hitLimit=!1}hook(e){this._params=e.length>1||e.params[0]?e.clone():a,this._data="",this._hitLimit=!1}put(e,t,i){this._hitLimit||(this._data+=(0,s.utf32ToString)(e,t,i),this._data.length>n.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))}unhook(e){let t=!1;if(this._hitLimit)t=!1;else if(e&&(t=this._handler(this._data,this._params),t instanceof Promise))return t.then((e=>(this._params=a,this._data="",this._hitLimit=!1,e)));return this._params=a,this._data="",this._hitLimit=!1,t}}},2015:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.EscapeSequenceParser=t.VT500_TRANSITION_TABLE=t.TransitionTable=void 0;const s=i(844),r=i(8742),n=i(6242),o=i(6351);class a{constructor(e){this.table=new Uint8Array(e)}setDefault(e,t){this.table.fill(e<<4|t)}add(e,t,i,s){this.table[t<<8|e]=i<<4|s}addMany(e,t,i,s){for(let r=0;rt)),i=(e,i)=>t.slice(e,i),s=i(32,127),r=i(0,24);r.push(25),r.push.apply(r,i(28,32));const n=i(0,14);let o;for(o in e.setDefault(1,0),e.addMany(s,0,2,0),n)e.addMany([24,26,153,154],o,3,0),e.addMany(i(128,144),o,3,0),e.addMany(i(144,152),o,3,0),e.add(156,o,0,0),e.add(27,o,11,1),e.add(157,o,4,8),e.addMany([152,158,159],o,0,7),e.add(155,o,11,3),e.add(144,o,11,9);return e.addMany(r,0,3,0),e.addMany(r,1,3,1),e.add(127,1,0,1),e.addMany(r,8,0,8),e.addMany(r,3,3,3),e.add(127,3,0,3),e.addMany(r,4,3,4),e.add(127,4,0,4),e.addMany(r,6,3,6),e.addMany(r,5,3,5),e.add(127,5,0,5),e.addMany(r,2,3,2),e.add(127,2,0,2),e.add(93,1,4,8),e.addMany(s,8,5,8),e.add(127,8,5,8),e.addMany([156,27,24,26,7],8,6,0),e.addMany(i(28,32),8,0,8),e.addMany([88,94,95],1,0,7),e.addMany(s,7,0,7),e.addMany(r,7,0,7),e.add(156,7,0,0),e.add(127,7,0,7),e.add(91,1,11,3),e.addMany(i(64,127),3,7,0),e.addMany(i(48,60),3,8,4),e.addMany([60,61,62,63],3,9,4),e.addMany(i(48,60),4,8,4),e.addMany(i(64,127),4,7,0),e.addMany([60,61,62,63],4,0,6),e.addMany(i(32,64),6,0,6),e.add(127,6,0,6),e.addMany(i(64,127),6,0,0),e.addMany(i(32,48),3,9,5),e.addMany(i(32,48),5,9,5),e.addMany(i(48,64),5,0,6),e.addMany(i(64,127),5,7,0),e.addMany(i(32,48),4,9,5),e.addMany(i(32,48),1,9,2),e.addMany(i(32,48),2,9,2),e.addMany(i(48,127),2,10,0),e.addMany(i(48,80),1,10,0),e.addMany(i(81,88),1,10,0),e.addMany([89,90,92],1,10,0),e.addMany(i(96,127),1,10,0),e.add(80,1,11,9),e.addMany(r,9,0,9),e.add(127,9,0,9),e.addMany(i(28,32),9,0,9),e.addMany(i(32,48),9,9,12),e.addMany(i(48,60),9,8,10),e.addMany([60,61,62,63],9,9,10),e.addMany(r,11,0,11),e.addMany(i(32,128),11,0,11),e.addMany(i(28,32),11,0,11),e.addMany(r,10,0,10),e.add(127,10,0,10),e.addMany(i(28,32),10,0,10),e.addMany(i(48,60),10,8,10),e.addMany([60,61,62,63],10,0,11),e.addMany(i(32,48),10,9,12),e.addMany(r,12,0,12),e.add(127,12,0,12),e.addMany(i(28,32),12,0,12),e.addMany(i(32,48),12,9,12),e.addMany(i(48,64),12,0,11),e.addMany(i(64,127),12,12,13),e.addMany(i(64,127),10,12,13),e.addMany(i(64,127),9,12,13),e.addMany(r,13,13,13),e.addMany(s,13,13,13),e.add(127,13,0,13),e.addMany([27,156,24,26],13,14,0),e.add(h,0,2,0),e.add(h,8,5,8),e.add(h,6,0,6),e.add(h,11,0,11),e.add(h,13,13,13),e}();class c extends s.Disposable{constructor(e=t.VT500_TRANSITION_TABLE){super(),this._transitions=e,this._parseStack={state:0,handlers:[],handlerPos:0,transition:0,chunkPos:0},this.initialState=0,this.currentState=this.initialState,this._params=new r.Params,this._params.addParam(0),this._collect=0,this.precedingCodepoint=0,this._printHandlerFb=(e,t,i)=>{},this._executeHandlerFb=e=>{},this._csiHandlerFb=(e,t)=>{},this._escHandlerFb=e=>{},this._errorHandlerFb=e=>e,this._printHandler=this._printHandlerFb,this._executeHandlers=Object.create(null),this._csiHandlers=Object.create(null),this._escHandlers=Object.create(null),this.register((0,s.toDisposable)((()=>{this._csiHandlers=Object.create(null),this._executeHandlers=Object.create(null),this._escHandlers=Object.create(null)}))),this._oscParser=this.register(new n.OscParser),this._dcsParser=this.register(new o.DcsParser),this._errorHandler=this._errorHandlerFb,this.registerEscHandler({final:"\\"},(()=>!0))}_identifier(e,t=[64,126]){let i=0;if(e.prefix){if(e.prefix.length>1)throw new Error("only one byte as prefix supported");if(i=e.prefix.charCodeAt(0),i&&60>i||i>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(e.intermediates){if(e.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(let t=0;ts||s>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");i<<=8,i|=s}}if(1!==e.final.length)throw new Error("final must be a single byte");const s=e.final.charCodeAt(0);if(t[0]>s||s>t[1])throw new Error(`final must be in range ${t[0]} .. ${t[1]}`);return i<<=8,i|=s,i}identToString(e){const t=[];for(;e;)t.push(String.fromCharCode(255&e)),e>>=8;return t.reverse().join("")}setPrintHandler(e){this._printHandler=e}clearPrintHandler(){this._printHandler=this._printHandlerFb}registerEscHandler(e,t){const i=this._identifier(e,[48,126]);void 0===this._escHandlers[i]&&(this._escHandlers[i]=[]);const s=this._escHandlers[i];return s.push(t),{dispose:()=>{const e=s.indexOf(t);-1!==e&&s.splice(e,1)}}}clearEscHandler(e){this._escHandlers[this._identifier(e,[48,126])]&&delete this._escHandlers[this._identifier(e,[48,126])]}setEscHandlerFallback(e){this._escHandlerFb=e}setExecuteHandler(e,t){this._executeHandlers[e.charCodeAt(0)]=t}clearExecuteHandler(e){this._executeHandlers[e.charCodeAt(0)]&&delete this._executeHandlers[e.charCodeAt(0)]}setExecuteHandlerFallback(e){this._executeHandlerFb=e}registerCsiHandler(e,t){const i=this._identifier(e);void 0===this._csiHandlers[i]&&(this._csiHandlers[i]=[]);const s=this._csiHandlers[i];return s.push(t),{dispose:()=>{const e=s.indexOf(t);-1!==e&&s.splice(e,1)}}}clearCsiHandler(e){this._csiHandlers[this._identifier(e)]&&delete this._csiHandlers[this._identifier(e)]}setCsiHandlerFallback(e){this._csiHandlerFb=e}registerDcsHandler(e,t){return this._dcsParser.registerHandler(this._identifier(e),t)}clearDcsHandler(e){this._dcsParser.clearHandler(this._identifier(e))}setDcsHandlerFallback(e){this._dcsParser.setHandlerFallback(e)}registerOscHandler(e,t){return this._oscParser.registerHandler(e,t)}clearOscHandler(e){this._oscParser.clearHandler(e)}setOscHandlerFallback(e){this._oscParser.setHandlerFallback(e)}setErrorHandler(e){this._errorHandler=e}clearErrorHandler(){this._errorHandler=this._errorHandlerFb}reset(){this.currentState=this.initialState,this._oscParser.reset(),this._dcsParser.reset(),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0,0!==this._parseStack.state&&(this._parseStack.state=2,this._parseStack.handlers=[])}_preserveStack(e,t,i,s,r){this._parseStack.state=e,this._parseStack.handlers=t,this._parseStack.handlerPos=i,this._parseStack.transition=s,this._parseStack.chunkPos=r}parse(e,t,i){let s,r=0,n=0,o=0;if(this._parseStack.state)if(2===this._parseStack.state)this._parseStack.state=0,o=this._parseStack.chunkPos+1;else{if(void 0===i||1===this._parseStack.state)throw this._parseStack.state=1,new Error("improper continuation due to previous async handler, giving up parsing");const t=this._parseStack.handlers;let n=this._parseStack.handlerPos-1;switch(this._parseStack.state){case 3:if(!1===i&&n>-1)for(;n>=0&&(s=t[n](this._params),!0!==s);n--)if(s instanceof Promise)return this._parseStack.handlerPos=n,s;this._parseStack.handlers=[];break;case 4:if(!1===i&&n>-1)for(;n>=0&&(s=t[n](),!0!==s);n--)if(s instanceof Promise)return this._parseStack.handlerPos=n,s;this._parseStack.handlers=[];break;case 6:if(r=e[this._parseStack.chunkPos],s=this._dcsParser.unhook(24!==r&&26!==r,i),s)return s;27===r&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0;break;case 5:if(r=e[this._parseStack.chunkPos],s=this._oscParser.end(24!==r&&26!==r,i),s)return s;27===r&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0}this._parseStack.state=0,o=this._parseStack.chunkPos+1,this.precedingCodepoint=0,this.currentState=15&this._parseStack.transition}for(let a=o;a>4){case 2:for(let s=a+1;;++s){if(s>=t||(r=e[s])<32||r>126&&r=t||(r=e[s])<32||r>126&&r=t||(r=e[s])<32||r>126&&r=t||(r=e[s])<32||r>126&&r=0&&(s=i[o](this._params),!0!==s);o--)if(s instanceof Promise)return this._preserveStack(3,i,o,n,a),s;o<0&&this._csiHandlerFb(this._collect<<8|r,this._params),this.precedingCodepoint=0;break;case 8:do{switch(r){case 59:this._params.addParam(0);break;case 58:this._params.addSubParam(-1);break;default:this._params.addDigit(r-48)}}while(++a47&&r<60);a--;break;case 9:this._collect<<=8,this._collect|=r;break;case 10:const c=this._escHandlers[this._collect<<8|r];let l=c?c.length-1:-1;for(;l>=0&&(s=c[l](),!0!==s);l--)if(s instanceof Promise)return this._preserveStack(4,c,l,n,a),s;l<0&&this._escHandlerFb(this._collect<<8|r),this.precedingCodepoint=0;break;case 11:this._params.reset(),this._params.addParam(0),this._collect=0;break;case 12:this._dcsParser.hook(this._collect<<8|r,this._params);break;case 13:for(let s=a+1;;++s)if(s>=t||24===(r=e[s])||26===r||27===r||r>127&&r=t||(r=e[s])<32||r>127&&r{Object.defineProperty(t,"__esModule",{value:!0}),t.OscHandler=t.OscParser=void 0;const s=i(5770),r=i(482),n=[];t.OscParser=class{constructor(){this._state=0,this._active=n,this._id=-1,this._handlers=Object.create(null),this._handlerFb=()=>{},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}registerHandler(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);const i=this._handlers[e];return i.push(t),{dispose:()=>{const e=i.indexOf(t);-1!==e&&i.splice(e,1)}}}clearHandler(e){this._handlers[e]&&delete this._handlers[e]}setHandlerFallback(e){this._handlerFb=e}dispose(){this._handlers=Object.create(null),this._handlerFb=()=>{},this._active=n}reset(){if(2===this._state)for(let e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].end(!1);this._stack.paused=!1,this._active=n,this._id=-1,this._state=0}_start(){if(this._active=this._handlers[this._id]||n,this._active.length)for(let e=this._active.length-1;e>=0;e--)this._active[e].start();else this._handlerFb(this._id,"START")}_put(e,t,i){if(this._active.length)for(let s=this._active.length-1;s>=0;s--)this._active[s].put(e,t,i);else this._handlerFb(this._id,"PUT",(0,r.utf32ToString)(e,t,i))}start(){this.reset(),this._state=1}put(e,t,i){if(3!==this._state){if(1===this._state)for(;t0&&this._put(e,t,i)}}end(e,t=!0){if(0!==this._state){if(3!==this._state)if(1===this._state&&this._start(),this._active.length){let i=!1,s=this._active.length-1,r=!1;if(this._stack.paused&&(s=this._stack.loopPosition-1,i=t,r=this._stack.fallThrough,this._stack.paused=!1),!r&&!1===i){for(;s>=0&&(i=this._active[s].end(e),!0!==i);s--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=s,this._stack.fallThrough=!1,i;s--}for(;s>=0;s--)if(i=this._active[s].end(!1),i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=s,this._stack.fallThrough=!0,i}else this._handlerFb(this._id,"END",e);this._active=n,this._id=-1,this._state=0}}},t.OscHandler=class{constructor(e){this._handler=e,this._data="",this._hitLimit=!1}start(){this._data="",this._hitLimit=!1}put(e,t,i){this._hitLimit||(this._data+=(0,r.utf32ToString)(e,t,i),this._data.length>s.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))}end(e){let t=!1;if(this._hitLimit)t=!1;else if(e&&(t=this._handler(this._data),t instanceof Promise))return t.then((e=>(this._data="",this._hitLimit=!1,e)));return this._data="",this._hitLimit=!1,t}}},8742:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Params=void 0;const i=2147483647;class s{static fromArray(e){const t=new s;if(!e.length)return t;for(let i=Array.isArray(e[0])?1:0;i256)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(e),this.length=0,this._subParams=new Int32Array(t),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(e),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}clone(){const e=new s(this.maxLength,this.maxSubParamsLength);return e.params.set(this.params),e.length=this.length,e._subParams.set(this._subParams),e._subParamsLength=this._subParamsLength,e._subParamsIdx.set(this._subParamsIdx),e._rejectDigits=this._rejectDigits,e._rejectSubDigits=this._rejectSubDigits,e._digitIsSub=this._digitIsSub,e}toArray(){const e=[];for(let t=0;t>8,s=255&this._subParamsIdx[t];s-i>0&&e.push(Array.prototype.slice.call(this._subParams,i,s))}return e}reset(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}addParam(e){if(this._digitIsSub=!1,this.length>=this.maxLength)this._rejectDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=e>i?i:e}}addSubParam(e){if(this._digitIsSub=!0,this.length)if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength)this._rejectSubDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=e>i?i:e,this._subParamsIdx[this.length-1]++}}hasSubParams(e){return(255&this._subParamsIdx[e])-(this._subParamsIdx[e]>>8)>0}getSubParams(e){const t=this._subParamsIdx[e]>>8,i=255&this._subParamsIdx[e];return i-t>0?this._subParams.subarray(t,i):null}getSubParamsAll(){const e={};for(let t=0;t>8,s=255&this._subParamsIdx[t];s-i>0&&(e[t]=this._subParams.slice(i,s))}return e}addDigit(e){let t;if(this._rejectDigits||!(t=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)return;const s=this._digitIsSub?this._subParams:this.params,r=s[t-1];s[t-1]=~r?Math.min(10*r+e,i):e}}t.Params=s},5741:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AddonManager=void 0,t.AddonManager=class{constructor(){this._addons=[]}dispose(){for(let e=this._addons.length-1;e>=0;e--)this._addons[e].instance.dispose()}loadAddon(e,t){const i={instance:t,dispose:t.dispose,isDisposed:!1};this._addons.push(i),t.dispose=()=>this._wrappedAddonDispose(i),t.activate(e)}_wrappedAddonDispose(e){if(e.isDisposed)return;let t=-1;for(let i=0;i{Object.defineProperty(t,"__esModule",{value:!0}),t.BufferApiView=void 0;const s=i(3785),r=i(511);t.BufferApiView=class{constructor(e,t){this._buffer=e,this.type=t}init(e){return this._buffer=e,this}get cursorY(){return this._buffer.y}get cursorX(){return this._buffer.x}get viewportY(){return this._buffer.ydisp}get baseY(){return this._buffer.ybase}get length(){return this._buffer.lines.length}getLine(e){const t=this._buffer.lines.get(e);if(t)return new s.BufferLineApiView(t)}getNullCell(){return new r.CellData}}},3785:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BufferLineApiView=void 0;const s=i(511);t.BufferLineApiView=class{constructor(e){this._line=e}get isWrapped(){return this._line.isWrapped}get length(){return this._line.length}getCell(e,t){if(!(e<0||e>=this._line.length))return t?(this._line.loadCell(e,t),t):this._line.loadCell(e,new s.CellData)}translateToString(e,t,i){return this._line.translateToString(e,t,i)}}},8285:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BufferNamespaceApi=void 0;const s=i(8771),r=i(8460),n=i(844);class o extends n.Disposable{constructor(e){super(),this._core=e,this._onBufferChange=this.register(new r.EventEmitter),this.onBufferChange=this._onBufferChange.event,this._normal=new s.BufferApiView(this._core.buffers.normal,"normal"),this._alternate=new s.BufferApiView(this._core.buffers.alt,"alternate"),this._core.buffers.onBufferActivate((()=>this._onBufferChange.fire(this.active)))}get active(){if(this._core.buffers.active===this._core.buffers.normal)return this.normal;if(this._core.buffers.active===this._core.buffers.alt)return this.alternate;throw new Error("Active buffer is neither normal nor alternate")}get normal(){return this._normal.init(this._core.buffers.normal)}get alternate(){return this._alternate.init(this._core.buffers.alt)}}t.BufferNamespaceApi=o},7975:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ParserApi=void 0,t.ParserApi=class{constructor(e){this._core=e}registerCsiHandler(e,t){return this._core.registerCsiHandler(e,(e=>t(e.toArray())))}addCsiHandler(e,t){return this.registerCsiHandler(e,t)}registerDcsHandler(e,t){return this._core.registerDcsHandler(e,((e,i)=>t(e,i.toArray())))}addDcsHandler(e,t){return this.registerDcsHandler(e,t)}registerEscHandler(e,t){return this._core.registerEscHandler(e,t)}addEscHandler(e,t){return this.registerEscHandler(e,t)}registerOscHandler(e,t){return this._core.registerOscHandler(e,t)}addOscHandler(e,t){return this.registerOscHandler(e,t)}}},7090:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeApi=void 0,t.UnicodeApi=class{constructor(e){this._core=e}register(e){this._core.unicodeService.register(e)}get versions(){return this._core.unicodeService.versions}get activeVersion(){return this._core.unicodeService.activeVersion}set activeVersion(e){this._core.unicodeService.activeVersion=e}}},744:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.BufferService=t.MINIMUM_ROWS=t.MINIMUM_COLS=void 0;const n=i(8460),o=i(844),a=i(5295),h=i(2585);t.MINIMUM_COLS=2,t.MINIMUM_ROWS=1;let c=t.BufferService=class extends o.Disposable{get buffer(){return this.buffers.active}constructor(e){super(),this.isUserScrolling=!1,this._onResize=this.register(new n.EventEmitter),this.onResize=this._onResize.event,this._onScroll=this.register(new n.EventEmitter),this.onScroll=this._onScroll.event,this.cols=Math.max(e.rawOptions.cols||0,t.MINIMUM_COLS),this.rows=Math.max(e.rawOptions.rows||0,t.MINIMUM_ROWS),this.buffers=this.register(new a.BufferSet(e,this))}resize(e,t){this.cols=e,this.rows=t,this.buffers.resize(e,t),this._onResize.fire({cols:e,rows:t})}reset(){this.buffers.reset(),this.isUserScrolling=!1}scroll(e,t=!1){const i=this.buffer;let s;s=this._cachedBlankLine,s&&s.length===this.cols&&s.getFg(0)===e.fg&&s.getBg(0)===e.bg||(s=i.getBlankLine(e,t),this._cachedBlankLine=s),s.isWrapped=t;const r=i.ybase+i.scrollTop,n=i.ybase+i.scrollBottom;if(0===i.scrollTop){const e=i.lines.isFull;n===i.lines.length-1?e?i.lines.recycle().copyFrom(s):i.lines.push(s.clone()):i.lines.splice(n+1,0,s.clone()),e?this.isUserScrolling&&(i.ydisp=Math.max(i.ydisp-1,0)):(i.ybase++,this.isUserScrolling||i.ydisp++)}else{const e=n-r+1;i.lines.shiftElements(r+1,e-1,-1),i.lines.set(n,s.clone())}this.isUserScrolling||(i.ydisp=i.ybase),this._onScroll.fire(i.ydisp)}scrollLines(e,t,i){const s=this.buffer;if(e<0){if(0===s.ydisp)return;this.isUserScrolling=!0}else e+s.ydisp>=s.ybase&&(this.isUserScrolling=!1);const r=s.ydisp;s.ydisp=Math.max(Math.min(s.ydisp+e,s.ybase),0),r!==s.ydisp&&(t||this._onScroll.fire(s.ydisp))}};t.BufferService=c=s([r(0,h.IOptionsService)],c)},7994:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CharsetService=void 0,t.CharsetService=class{constructor(){this.glevel=0,this._charsets=[]}reset(){this.charset=void 0,this._charsets=[],this.glevel=0}setgLevel(e){this.glevel=e,this.charset=this._charsets[e]}setgCharset(e,t){this._charsets[e]=t,this.glevel===e&&(this.charset=t)}}},1753:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreMouseService=void 0;const n=i(2585),o=i(8460),a=i(844),h={NONE:{events:0,restrict:()=>!1},X10:{events:1,restrict:e=>4!==e.button&&1===e.action&&(e.ctrl=!1,e.alt=!1,e.shift=!1,!0)},VT200:{events:19,restrict:e=>32!==e.action},DRAG:{events:23,restrict:e=>32!==e.action||3!==e.button},ANY:{events:31,restrict:e=>!0}};function c(e,t){let i=(e.ctrl?16:0)|(e.shift?4:0)|(e.alt?8:0);return 4===e.button?(i|=64,i|=e.action):(i|=3&e.button,4&e.button&&(i|=64),8&e.button&&(i|=128),32===e.action?i|=32:0!==e.action||t||(i|=3)),i}const l=String.fromCharCode,d={DEFAULT:e=>{const t=[c(e,!1)+32,e.col+32,e.row+32];return t[0]>255||t[1]>255||t[2]>255?"":`\x1b[M${l(t[0])}${l(t[1])}${l(t[2])}`},SGR:e=>{const t=0===e.action&&4!==e.button?"m":"M";return`\x1b[<${c(e,!0)};${e.col};${e.row}${t}`},SGR_PIXELS:e=>{const t=0===e.action&&4!==e.button?"m":"M";return`\x1b[<${c(e,!0)};${e.x};${e.y}${t}`}};let _=t.CoreMouseService=class extends a.Disposable{constructor(e,t){super(),this._bufferService=e,this._coreService=t,this._protocols={},this._encodings={},this._activeProtocol="",this._activeEncoding="",this._lastEvent=null,this._onProtocolChange=this.register(new o.EventEmitter),this.onProtocolChange=this._onProtocolChange.event;for(const i of Object.keys(h))this.addProtocol(i,h[i]);for(const i of Object.keys(d))this.addEncoding(i,d[i]);this.reset()}addProtocol(e,t){this._protocols[e]=t}addEncoding(e,t){this._encodings[e]=t}get activeProtocol(){return this._activeProtocol}get areMouseEventsActive(){return 0!==this._protocols[this._activeProtocol].events}set activeProtocol(e){if(!this._protocols[e])throw new Error(`unknown protocol "${e}"`);this._activeProtocol=e,this._onProtocolChange.fire(this._protocols[e].events)}get activeEncoding(){return this._activeEncoding}set activeEncoding(e){if(!this._encodings[e])throw new Error(`unknown encoding "${e}"`);this._activeEncoding=e}reset(){this.activeProtocol="NONE",this.activeEncoding="DEFAULT",this._lastEvent=null}triggerMouseEvent(e){if(e.col<0||e.col>=this._bufferService.cols||e.row<0||e.row>=this._bufferService.rows)return!1;if(4===e.button&&32===e.action)return!1;if(3===e.button&&32!==e.action)return!1;if(4!==e.button&&(2===e.action||3===e.action))return!1;if(e.col++,e.row++,32===e.action&&this._lastEvent&&this._equalEvents(this._lastEvent,e,"SGR_PIXELS"===this._activeEncoding))return!1;if(!this._protocols[this._activeProtocol].restrict(e))return!1;const t=this._encodings[this._activeEncoding](e);return t&&("DEFAULT"===this._activeEncoding?this._coreService.triggerBinaryEvent(t):this._coreService.triggerDataEvent(t,!0)),this._lastEvent=e,!0}explainEvents(e){return{down:!!(1&e),up:!!(2&e),drag:!!(4&e),move:!!(8&e),wheel:!!(16&e)}}_equalEvents(e,t,i){if(i){if(e.x!==t.x)return!1;if(e.y!==t.y)return!1}else{if(e.col!==t.col)return!1;if(e.row!==t.row)return!1}return e.button===t.button&&e.action===t.action&&e.ctrl===t.ctrl&&e.alt===t.alt&&e.shift===t.shift}};t.CoreMouseService=_=s([r(0,n.IBufferService),r(1,n.ICoreService)],_)},6975:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreService=void 0;const n=i(1439),o=i(8460),a=i(844),h=i(2585),c=Object.freeze({insertMode:!1}),l=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,origin:!1,reverseWraparound:!1,sendFocus:!1,wraparound:!0});let d=t.CoreService=class extends a.Disposable{constructor(e,t,i){super(),this._bufferService=e,this._logService=t,this._optionsService=i,this.isCursorInitialized=!1,this.isCursorHidden=!1,this._onData=this.register(new o.EventEmitter),this.onData=this._onData.event,this._onUserInput=this.register(new o.EventEmitter),this.onUserInput=this._onUserInput.event,this._onBinary=this.register(new o.EventEmitter),this.onBinary=this._onBinary.event,this._onRequestScrollToBottom=this.register(new o.EventEmitter),this.onRequestScrollToBottom=this._onRequestScrollToBottom.event,this.modes=(0,n.clone)(c),this.decPrivateModes=(0,n.clone)(l)}reset(){this.modes=(0,n.clone)(c),this.decPrivateModes=(0,n.clone)(l)}triggerDataEvent(e,t=!1){if(this._optionsService.rawOptions.disableStdin)return;const i=this._bufferService.buffer;t&&this._optionsService.rawOptions.scrollOnUserInput&&i.ybase!==i.ydisp&&this._onRequestScrollToBottom.fire(),t&&this._onUserInput.fire(),this._logService.debug(`sending data "${e}"`,(()=>e.split("").map((e=>e.charCodeAt(0))))),this._onData.fire(e)}triggerBinaryEvent(e){this._optionsService.rawOptions.disableStdin||(this._logService.debug(`sending binary "${e}"`,(()=>e.split("").map((e=>e.charCodeAt(0))))),this._onBinary.fire(e))}};t.CoreService=d=s([r(0,h.IBufferService),r(1,h.ILogService),r(2,h.IOptionsService)],d)},9074:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DecorationService=void 0;const s=i(8055),r=i(8460),n=i(844),o=i(6106);let a=0,h=0;class c extends n.Disposable{get decorations(){return this._decorations.values()}constructor(){super(),this._decorations=new o.SortedList((e=>null==e?void 0:e.marker.line)),this._onDecorationRegistered=this.register(new r.EventEmitter),this.onDecorationRegistered=this._onDecorationRegistered.event,this._onDecorationRemoved=this.register(new r.EventEmitter),this.onDecorationRemoved=this._onDecorationRemoved.event,this.register((0,n.toDisposable)((()=>this.reset())))}registerDecoration(e){if(e.marker.isDisposed)return;const t=new l(e);if(t){const e=t.marker.onDispose((()=>t.dispose()));t.onDispose((()=>{t&&(this._decorations.delete(t)&&this._onDecorationRemoved.fire(t),e.dispose())})),this._decorations.insert(t),this._onDecorationRegistered.fire(t)}return t}reset(){for(const e of this._decorations.values())e.dispose();this._decorations.clear()}*getDecorationsAtCell(e,t,i){var s,r,n;let o=0,a=0;for(const h of this._decorations.getKeyIterator(t))o=null!==(s=h.options.x)&&void 0!==s?s:0,a=o+(null!==(r=h.options.width)&&void 0!==r?r:1),e>=o&&e{var r,n,o;a=null!==(r=t.options.x)&&void 0!==r?r:0,h=a+(null!==(n=t.options.width)&&void 0!==n?n:1),e>=a&&e{Object.defineProperty(t,"__esModule",{value:!0}),t.InstantiationService=t.ServiceCollection=void 0;const s=i(2585),r=i(8343);class n{constructor(...e){this._entries=new Map;for(const[t,i]of e)this.set(t,i)}set(e,t){const i=this._entries.get(e);return this._entries.set(e,t),i}forEach(e){for(const[t,i]of this._entries.entries())e(t,i)}has(e){return this._entries.has(e)}get(e){return this._entries.get(e)}}t.ServiceCollection=n,t.InstantiationService=class{constructor(){this._services=new n,this._services.set(s.IInstantiationService,this)}setService(e,t){this._services.set(e,t)}getService(e){return this._services.get(e)}createInstance(e,...t){const i=(0,r.getServiceDependencies)(e).sort(((e,t)=>e.index-t.index)),s=[];for(const r of i){const t=this._services.get(r.id);if(!t)throw new Error(`[createInstance] ${e.name} depends on UNKNOWN service ${r.id}.`);s.push(t)}const n=i.length>0?i[0].index:t.length;if(t.length!==n)throw new Error(`[createInstance] First service dependency of ${e.name} at position ${n+1} conflicts with ${t.length} static arguments`);return new e(...[...t,...s])}}},7866:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.traceCall=t.setTraceLogger=t.LogService=void 0;const n=i(844),o=i(2585),a={trace:o.LogLevelEnum.TRACE,debug:o.LogLevelEnum.DEBUG,info:o.LogLevelEnum.INFO,warn:o.LogLevelEnum.WARN,error:o.LogLevelEnum.ERROR,off:o.LogLevelEnum.OFF};let h,c=t.LogService=class extends n.Disposable{get logLevel(){return this._logLevel}constructor(e){super(),this._optionsService=e,this._logLevel=o.LogLevelEnum.OFF,this._updateLogLevel(),this.register(this._optionsService.onSpecificOptionChange("logLevel",(()=>this._updateLogLevel()))),h=this}_updateLogLevel(){this._logLevel=a[this._optionsService.rawOptions.logLevel]}_evalLazyOptionalParams(e){for(let t=0;tJSON.stringify(e))).join(", ")})`);const t=s.apply(this,e);return h.trace(`GlyphRenderer#${s.name} return`,t),t}}},7302:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.OptionsService=t.DEFAULT_OPTIONS=void 0;const s=i(8460),r=i(844),n=i(6114);t.DEFAULT_OPTIONS={cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,cursorInactiveStyle:"outline",customGlyphs:!0,drawBoldTextInBrightColors:!0,fastScrollModifier:"alt",fastScrollSensitivity:5,fontFamily:"courier-new, courier, monospace",fontSize:15,fontWeight:"normal",fontWeightBold:"bold",ignoreBracketedPasteMode:!1,lineHeight:1,letterSpacing:0,linkHandler:null,logLevel:"info",logger:null,scrollback:1e3,scrollOnUserInput:!0,scrollSensitivity:1,screenReaderMode:!1,smoothScrollDuration:0,macOptionIsMeta:!1,macOptionClickForcesSelection:!1,minimumContrastRatio:1,disableStdin:!1,allowProposedApi:!1,allowTransparency:!1,tabStopWidth:8,theme:{},rightClickSelectsWord:n.isMac,windowOptions:{},windowsMode:!1,windowsPty:{},wordSeparator:" ()[]{}',\"`",altClickMovesCursor:!0,convertEol:!1,termName:"xterm",cancelEvents:!1,overviewRulerWidth:0};const o=["normal","bold","100","200","300","400","500","600","700","800","900"];class a extends r.Disposable{constructor(e){super(),this._onOptionChange=this.register(new s.EventEmitter),this.onOptionChange=this._onOptionChange.event;const i=Object.assign({},t.DEFAULT_OPTIONS);for(const t in e)if(t in i)try{const s=e[t];i[t]=this._sanitizeAndValidateOption(t,s)}catch(e){console.error(e)}this.rawOptions=i,this.options=Object.assign({},i),this._setupOptions()}onSpecificOptionChange(e,t){return this.onOptionChange((i=>{i===e&&t(this.rawOptions[e])}))}onMultipleOptionChange(e,t){return this.onOptionChange((i=>{-1!==e.indexOf(i)&&t()}))}_setupOptions(){const e=e=>{if(!(e in t.DEFAULT_OPTIONS))throw new Error(`No option with key "${e}"`);return this.rawOptions[e]},i=(e,i)=>{if(!(e in t.DEFAULT_OPTIONS))throw new Error(`No option with key "${e}"`);i=this._sanitizeAndValidateOption(e,i),this.rawOptions[e]!==i&&(this.rawOptions[e]=i,this._onOptionChange.fire(e))};for(const t in this.rawOptions){const s={get:e.bind(this,t),set:i.bind(this,t)};Object.defineProperty(this.options,t,s)}}_sanitizeAndValidateOption(e,i){switch(e){case"cursorStyle":if(i||(i=t.DEFAULT_OPTIONS[e]),!function(e){return"block"===e||"underline"===e||"bar"===e}(i))throw new Error(`"${i}" is not a valid value for ${e}`);break;case"wordSeparator":i||(i=t.DEFAULT_OPTIONS[e]);break;case"fontWeight":case"fontWeightBold":if("number"==typeof i&&1<=i&&i<=1e3)break;i=o.includes(i)?i:t.DEFAULT_OPTIONS[e];break;case"cursorWidth":i=Math.floor(i);case"lineHeight":case"tabStopWidth":if(i<1)throw new Error(`${e} cannot be less than 1, value: ${i}`);break;case"minimumContrastRatio":i=Math.max(1,Math.min(21,Math.round(10*i)/10));break;case"scrollback":if((i=Math.min(i,4294967295))<0)throw new Error(`${e} cannot be less than 0, value: ${i}`);break;case"fastScrollSensitivity":case"scrollSensitivity":if(i<=0)throw new Error(`${e} cannot be less than or equal to 0, value: ${i}`);break;case"rows":case"cols":if(!i&&0!==i)throw new Error(`${e} must be numeric, value: ${i}`);break;case"windowsPty":i=null!=i?i:{}}return i}}t.OptionsService=a},2660:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,n=arguments.length,o=n<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(o=(n<3?r(o):n>3?r(t,i,o):r(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OscLinkService=void 0;const n=i(2585);let o=t.OscLinkService=class{constructor(e){this._bufferService=e,this._nextId=1,this._entriesWithId=new Map,this._dataByLinkId=new Map}registerLink(e){const t=this._bufferService.buffer;if(void 0===e.id){const i=t.addMarker(t.ybase+t.y),s={data:e,id:this._nextId++,lines:[i]};return i.onDispose((()=>this._removeMarkerFromLink(s,i))),this._dataByLinkId.set(s.id,s),s.id}const i=e,s=this._getEntryIdKey(i),r=this._entriesWithId.get(s);if(r)return this.addLineToLink(r.id,t.ybase+t.y),r.id;const n=t.addMarker(t.ybase+t.y),o={id:this._nextId++,key:this._getEntryIdKey(i),data:i,lines:[n]};return n.onDispose((()=>this._removeMarkerFromLink(o,n))),this._entriesWithId.set(o.key,o),this._dataByLinkId.set(o.id,o),o.id}addLineToLink(e,t){const i=this._dataByLinkId.get(e);if(i&&i.lines.every((e=>e.line!==t))){const e=this._bufferService.buffer.addMarker(t);i.lines.push(e),e.onDispose((()=>this._removeMarkerFromLink(i,e)))}}getLinkData(e){var t;return null===(t=this._dataByLinkId.get(e))||void 0===t?void 0:t.data}_getEntryIdKey(e){return`${e.id};;${e.uri}`}_removeMarkerFromLink(e,t){const i=e.lines.indexOf(t);-1!==i&&(e.lines.splice(i,1),0===e.lines.length&&(void 0!==e.data.id&&this._entriesWithId.delete(e.key),this._dataByLinkId.delete(e.id)))}};t.OscLinkService=o=s([r(0,n.IBufferService)],o)},8343:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.createDecorator=t.getServiceDependencies=t.serviceRegistry=void 0;const i="di$target",s="di$dependencies";t.serviceRegistry=new Map,t.getServiceDependencies=function(e){return e[s]||[]},t.createDecorator=function(e){if(t.serviceRegistry.has(e))return t.serviceRegistry.get(e);const r=function(e,t,n){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");!function(e,t,r){t[i]===t?t[s].push({id:e,index:r}):(t[s]=[{id:e,index:r}],t[i]=t)}(r,e,n)};return r.toString=()=>e,t.serviceRegistry.set(e,r),r}},2585:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.IDecorationService=t.IUnicodeService=t.IOscLinkService=t.IOptionsService=t.ILogService=t.LogLevelEnum=t.IInstantiationService=t.ICharsetService=t.ICoreService=t.ICoreMouseService=t.IBufferService=void 0;const s=i(8343);var r;t.IBufferService=(0,s.createDecorator)("BufferService"),t.ICoreMouseService=(0,s.createDecorator)("CoreMouseService"),t.ICoreService=(0,s.createDecorator)("CoreService"),t.ICharsetService=(0,s.createDecorator)("CharsetService"),t.IInstantiationService=(0,s.createDecorator)("InstantiationService"),function(e){e[e.TRACE=0]="TRACE",e[e.DEBUG=1]="DEBUG",e[e.INFO=2]="INFO",e[e.WARN=3]="WARN",e[e.ERROR=4]="ERROR",e[e.OFF=5]="OFF"}(r||(t.LogLevelEnum=r={})),t.ILogService=(0,s.createDecorator)("LogService"),t.IOptionsService=(0,s.createDecorator)("OptionsService"),t.IOscLinkService=(0,s.createDecorator)("OscLinkService"),t.IUnicodeService=(0,s.createDecorator)("UnicodeService"),t.IDecorationService=(0,s.createDecorator)("DecorationService")},1480:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeService=void 0;const s=i(8460),r=i(225);t.UnicodeService=class{constructor(){this._providers=Object.create(null),this._active="",this._onChange=new s.EventEmitter,this.onChange=this._onChange.event;const e=new r.UnicodeV6;this.register(e),this._active=e.version,this._activeProvider=e}dispose(){this._onChange.dispose()}get versions(){return Object.keys(this._providers)}get activeVersion(){return this._active}set activeVersion(e){if(!this._providers[e])throw new Error(`unknown Unicode version "${e}"`);this._active=e,this._activeProvider=this._providers[e],this._onChange.fire(e)}register(e){this._providers[e.version]=e}wcwidth(e){return this._activeProvider.wcwidth(e)}getStringCellWidth(e){let t=0;const i=e.length;for(let s=0;s=i)return t+this.wcwidth(r);const n=e.charCodeAt(s);56320<=n&&n<=57343?r=1024*(r-55296)+n-56320+65536:t+=this.wcwidth(n)}t+=this.wcwidth(r)}return t}}}},t={};function i(s){var r=t[s];if(void 0!==r)return r.exports;var n=t[s]={exports:{}};return e[s].call(n.exports,n,n.exports,i),n.exports}var s={};return(()=>{var e=s;Object.defineProperty(e,"__esModule",{value:!0}),e.Terminal=void 0;const t=i(9042),r=i(3236),n=i(844),o=i(5741),a=i(8285),h=i(7975),c=i(7090),l=["cols","rows"];class d extends n.Disposable{constructor(e){super(),this._core=this.register(new r.Terminal(e)),this._addonManager=this.register(new o.AddonManager),this._publicOptions=Object.assign({},this._core.options);const t=e=>this._core.options[e],i=(e,t)=>{this._checkReadonlyOptions(e),this._core.options[e]=t};for(const s in this._core.options){const e={get:t.bind(this,s),set:i.bind(this,s)};Object.defineProperty(this._publicOptions,s,e)}}_checkReadonlyOptions(e){if(l.includes(e))throw new Error(`Option "${e}" can only be set in the constructor`)}_checkProposedApi(){if(!this._core.optionsService.rawOptions.allowProposedApi)throw new Error("You must set the allowProposedApi option to true to use proposed API")}get onBell(){return this._core.onBell}get onBinary(){return this._core.onBinary}get onCursorMove(){return this._core.onCursorMove}get onData(){return this._core.onData}get onKey(){return this._core.onKey}get onLineFeed(){return this._core.onLineFeed}get onRender(){return this._core.onRender}get onResize(){return this._core.onResize}get onScroll(){return this._core.onScroll}get onSelectionChange(){return this._core.onSelectionChange}get onTitleChange(){return this._core.onTitleChange}get onWriteParsed(){return this._core.onWriteParsed}get element(){return this._core.element}get parser(){return this._parser||(this._parser=new h.ParserApi(this._core)),this._parser}get unicode(){return this._checkProposedApi(),new c.UnicodeApi(this._core)}get textarea(){return this._core.textarea}get rows(){return this._core.rows}get cols(){return this._core.cols}get buffer(){return this._buffer||(this._buffer=this.register(new a.BufferNamespaceApi(this._core))),this._buffer}get markers(){return this._checkProposedApi(),this._core.markers}get modes(){const e=this._core.coreService.decPrivateModes;let t="none";switch(this._core.coreMouseService.activeProtocol){case"X10":t="x10";break;case"VT200":t="vt200";break;case"DRAG":t="drag";break;case"ANY":t="any"}return{applicationCursorKeysMode:e.applicationCursorKeys,applicationKeypadMode:e.applicationKeypad,bracketedPasteMode:e.bracketedPasteMode,insertMode:this._core.coreService.modes.insertMode,mouseTrackingMode:t,originMode:e.origin,reverseWraparoundMode:e.reverseWraparound,sendFocusMode:e.sendFocus,wraparoundMode:e.wraparound}}get options(){return this._publicOptions}set options(e){for(const t in e)this._publicOptions[t]=e[t]}blur(){this._core.blur()}focus(){this._core.focus()}resize(e,t){this._verifyIntegers(e,t),this._core.resize(e,t)}open(e){this._core.open(e)}attachCustomKeyEventHandler(e){this._core.attachCustomKeyEventHandler(e)}registerLinkProvider(e){return this._core.registerLinkProvider(e)}registerCharacterJoiner(e){return this._checkProposedApi(),this._core.registerCharacterJoiner(e)}deregisterCharacterJoiner(e){this._checkProposedApi(),this._core.deregisterCharacterJoiner(e)}registerMarker(e=0){return this._verifyIntegers(e),this._core.registerMarker(e)}registerDecoration(e){var t,i,s;return this._checkProposedApi(),this._verifyPositiveIntegers(null!==(t=e.x)&&void 0!==t?t:0,null!==(i=e.width)&&void 0!==i?i:0,null!==(s=e.height)&&void 0!==s?s:0),this._core.registerDecoration(e)}hasSelection(){return this._core.hasSelection()}select(e,t,i){this._verifyIntegers(e,t,i),this._core.select(e,t,i)}getSelection(){return this._core.getSelection()}getSelectionPosition(){return this._core.getSelectionPosition()}clearSelection(){this._core.clearSelection()}selectAll(){this._core.selectAll()}selectLines(e,t){this._verifyIntegers(e,t),this._core.selectLines(e,t)}dispose(){super.dispose()}scrollLines(e){this._verifyIntegers(e),this._core.scrollLines(e)}scrollPages(e){this._verifyIntegers(e),this._core.scrollPages(e)}scrollToTop(){this._core.scrollToTop()}scrollToBottom(){this._core.scrollToBottom()}scrollToLine(e){this._verifyIntegers(e),this._core.scrollToLine(e)}clear(){this._core.clear()}write(e,t){this._core.write(e,t)}writeln(e,t){this._core.write(e),this._core.write("\r\n",t)}paste(e){this._core.paste(e)}refresh(e,t){this._verifyIntegers(e,t),this._core.refresh(e,t)}reset(){this._core.reset()}clearTextureAtlas(){this._core.clearTextureAtlas()}loadAddon(e){this._addonManager.loadAddon(this,e)}static get strings(){return t}_verifyIntegers(...e){for(const t of e)if(t===1/0||isNaN(t)||t%1!=0)throw new Error("This API only accepts integers")}_verifyPositiveIntegers(...e){for(const t of e)if(t&&(t===1/0||isNaN(t)||t%1!=0||t<0))throw new Error("This API only accepts positive integers")}}e.Terminal=d})(),s})(),e.exports=t()}}]); \ No newline at end of file diff --git a/dsql-app/.local_dist/static/chunks/framework-4ed89e9640adfb9e.js b/dsql-app/.local_dist/static/chunks/framework-4ed89e9640adfb9e.js new file mode 100644 index 0000000..684086c --- /dev/null +++ b/dsql-app/.local_dist/static/chunks/framework-4ed89e9640adfb9e.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9774],{64448:function(e,n,t){var r=t(67294),l=t(63840);function a(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,t=1;t