mirror of
				https://github.com/keanuplayz/TravBot-v3.git
				synced 2024-08-15 02:33:12 +00:00 
			
		
		
		
	Added a prototype of a live web panel
This commit is contained in:
		
							parent
							
								
									dcb5389590
								
							
						
					
					
						commit
						a8bcd744cb
					
				
					 12 changed files with 725 additions and 15 deletions
				
			
		|  | @ -1,5 +0,0 @@ | |||
| { | ||||
|     "prefix": "!!", // Bot Prefix | ||||
|     "token": "<token>", // Bot Token | ||||
|     "owners": ["<id>"] // Array of bot owner IDs | ||||
| } | ||||
							
								
								
									
										18
									
								
								docs/Specifications.md
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								docs/Specifications.md
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | |||
| # Top-Level Directory | ||||
| The top-level directory should be reserved only for things that absolutely need to be at the top for TravBot to work. | ||||
| - Node.js: `package.json` and `package-lock.json`. | ||||
| - GitHub: `README.md`, `LICENSE`, and `.gitignore`. | ||||
| - Other: `.eslintrc.json`. | ||||
| 
 | ||||
| # The `src` Directory | ||||
| This directory contains everything related to the actual code that runs TravBot. It contains `index.js`, the entry point for the program, at the top along with subdirectories which separate the code. | ||||
| 
 | ||||
| # The `data` Directory | ||||
| This directory is automatically generated upon loading TravBot and contains everything related to dynamic data that shouldn't be committed to GitHub. | ||||
| - `config.json`: The core data file which holds your bot's token, owners, prefix, etc. | ||||
| 
 | ||||
| # The `panel` Directory | ||||
| This directory contains the web panel for the bot which can receive events, request information, and send requests. | ||||
| 
 | ||||
| # The `docs` Directory | ||||
| This directory contains information about the bot. | ||||
							
								
								
									
										653
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							
							
						
						
									
										653
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							|  | @ -71,6 +71,15 @@ | |||
|         "event-target-shim": "^5.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "accepts": { | ||||
|       "version": "1.3.7", | ||||
|       "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", | ||||
|       "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", | ||||
|       "requires": { | ||||
|         "mime-types": "~2.1.24", | ||||
|         "negotiator": "0.6.2" | ||||
|       } | ||||
|     }, | ||||
|     "acorn": { | ||||
|       "version": "7.2.0", | ||||
|       "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.2.0.tgz", | ||||
|  | @ -83,6 +92,11 @@ | |||
|       "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "after": { | ||||
|       "version": "0.8.2", | ||||
|       "resolved": "https://registry.npmjs.org/after/-/after-0.8.2.tgz", | ||||
|       "integrity": "sha1-/ts5T58OAqqXaOcCvaI7UF+ufh8=" | ||||
|     }, | ||||
|     "ajv": { | ||||
|       "version": "6.12.2", | ||||
|       "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz", | ||||
|  | @ -133,23 +147,98 @@ | |||
|         "sprintf-js": "~1.0.2" | ||||
|       } | ||||
|     }, | ||||
|     "array-flatten": { | ||||
|       "version": "1.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", | ||||
|       "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=" | ||||
|     }, | ||||
|     "arraybuffer.slice": { | ||||
|       "version": "0.0.7", | ||||
|       "resolved": "https://registry.npmjs.org/arraybuffer.slice/-/arraybuffer.slice-0.0.7.tgz", | ||||
|       "integrity": "sha512-wGUIVQXuehL5TCqQun8OW81jGzAWycqzFF8lFp+GOM5BXLYj3bKNsYC4daB7n6XjCqxQA/qgTJ+8ANR3acjrog==" | ||||
|     }, | ||||
|     "astral-regex": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", | ||||
|       "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "async-limiter": { | ||||
|       "version": "1.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz", | ||||
|       "integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==" | ||||
|     }, | ||||
|     "asynckit": { | ||||
|       "version": "0.4.0", | ||||
|       "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", | ||||
|       "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" | ||||
|     }, | ||||
|     "backo2": { | ||||
|       "version": "1.0.2", | ||||
|       "resolved": "https://registry.npmjs.org/backo2/-/backo2-1.0.2.tgz", | ||||
|       "integrity": "sha1-MasayLEpNjRj41s+u2n038+6eUc=" | ||||
|     }, | ||||
|     "balanced-match": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", | ||||
|       "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "base64-arraybuffer": { | ||||
|       "version": "0.1.5", | ||||
|       "resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz", | ||||
|       "integrity": "sha1-c5JncZI7Whl0etZmqlzUv5xunOg=" | ||||
|     }, | ||||
|     "base64id": { | ||||
|       "version": "2.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/base64id/-/base64id-2.0.0.tgz", | ||||
|       "integrity": "sha512-lGe34o6EHj9y3Kts9R4ZYs/Gr+6N7MCaMlIFA3F1R2O5/m7K06AxfSeO5530PEERE6/WyEg3lsuyw4GHlPZHog==" | ||||
|     }, | ||||
|     "better-assert": { | ||||
|       "version": "1.0.2", | ||||
|       "resolved": "https://registry.npmjs.org/better-assert/-/better-assert-1.0.2.tgz", | ||||
|       "integrity": "sha1-QIZrnhueC1W0gYlDEeaPr/rrxSI=", | ||||
|       "requires": { | ||||
|         "callsite": "1.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "blob": { | ||||
|       "version": "0.0.5", | ||||
|       "resolved": "https://registry.npmjs.org/blob/-/blob-0.0.5.tgz", | ||||
|       "integrity": "sha512-gaqbzQPqOoamawKg0LGVd7SzLgXS+JH61oWprSLH+P+abTczqJbhTR8CmJ2u9/bUYNmHTGJx/UEmn6doAvvuig==" | ||||
|     }, | ||||
|     "body-parser": { | ||||
|       "version": "1.19.0", | ||||
|       "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", | ||||
|       "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", | ||||
|       "requires": { | ||||
|         "bytes": "3.1.0", | ||||
|         "content-type": "~1.0.4", | ||||
|         "debug": "2.6.9", | ||||
|         "depd": "~1.1.2", | ||||
|         "http-errors": "1.7.2", | ||||
|         "iconv-lite": "0.4.24", | ||||
|         "on-finished": "~2.3.0", | ||||
|         "qs": "6.7.0", | ||||
|         "raw-body": "2.4.0", | ||||
|         "type-is": "~1.6.17" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "debug": { | ||||
|           "version": "2.6.9", | ||||
|           "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", | ||||
|           "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", | ||||
|           "requires": { | ||||
|             "ms": "2.0.0" | ||||
|           } | ||||
|         }, | ||||
|         "ms": { | ||||
|           "version": "2.0.0", | ||||
|           "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", | ||||
|           "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "brace-expansion": { | ||||
|       "version": "1.1.11", | ||||
|       "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", | ||||
|  | @ -160,6 +249,16 @@ | |||
|         "concat-map": "0.0.1" | ||||
|       } | ||||
|     }, | ||||
|     "bytes": { | ||||
|       "version": "3.1.0", | ||||
|       "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", | ||||
|       "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" | ||||
|     }, | ||||
|     "callsite": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/callsite/-/callsite-1.0.0.tgz", | ||||
|       "integrity": "sha1-KAOY5dZkvXQDi28JBRU+borxvCA=" | ||||
|     }, | ||||
|     "callsites": { | ||||
|       "version": "3.1.0", | ||||
|       "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", | ||||
|  | @ -259,12 +358,50 @@ | |||
|         "delayed-stream": "~1.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "component-bind": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/component-bind/-/component-bind-1.0.0.tgz", | ||||
|       "integrity": "sha1-AMYIq33Nk4l8AAllGx06jh5zu9E=" | ||||
|     }, | ||||
|     "component-emitter": { | ||||
|       "version": "1.2.1", | ||||
|       "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", | ||||
|       "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=" | ||||
|     }, | ||||
|     "component-inherit": { | ||||
|       "version": "0.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/component-inherit/-/component-inherit-0.0.3.tgz", | ||||
|       "integrity": "sha1-ZF/ErfWLcrZJ1crmUTVhnbJv8UM=" | ||||
|     }, | ||||
|     "concat-map": { | ||||
|       "version": "0.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", | ||||
|       "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "content-disposition": { | ||||
|       "version": "0.5.3", | ||||
|       "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz", | ||||
|       "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==", | ||||
|       "requires": { | ||||
|         "safe-buffer": "5.1.2" | ||||
|       } | ||||
|     }, | ||||
|     "content-type": { | ||||
|       "version": "1.0.4", | ||||
|       "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", | ||||
|       "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==" | ||||
|     }, | ||||
|     "cookie": { | ||||
|       "version": "0.4.0", | ||||
|       "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", | ||||
|       "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==" | ||||
|     }, | ||||
|     "cookie-signature": { | ||||
|       "version": "1.0.6", | ||||
|       "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", | ||||
|       "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw=" | ||||
|     }, | ||||
|     "cross-spawn": { | ||||
|       "version": "7.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", | ||||
|  | @ -280,7 +417,6 @@ | |||
|       "version": "4.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", | ||||
|       "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", | ||||
|       "dev": true, | ||||
|       "requires": { | ||||
|         "ms": "^2.1.1" | ||||
|       } | ||||
|  | @ -296,6 +432,16 @@ | |||
|       "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", | ||||
|       "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" | ||||
|     }, | ||||
|     "depd": { | ||||
|       "version": "1.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", | ||||
|       "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" | ||||
|     }, | ||||
|     "destroy": { | ||||
|       "version": "1.0.4", | ||||
|       "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", | ||||
|       "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" | ||||
|     }, | ||||
|     "discord.js": { | ||||
|       "version": "12.2.0", | ||||
|       "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-12.2.0.tgz", | ||||
|  | @ -320,11 +466,91 @@ | |||
|         "esutils": "^2.0.2" | ||||
|       } | ||||
|     }, | ||||
|     "ee-first": { | ||||
|       "version": "1.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", | ||||
|       "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" | ||||
|     }, | ||||
|     "emoji-regex": { | ||||
|       "version": "8.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", | ||||
|       "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" | ||||
|     }, | ||||
|     "encodeurl": { | ||||
|       "version": "1.0.2", | ||||
|       "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", | ||||
|       "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=" | ||||
|     }, | ||||
|     "engine.io": { | ||||
|       "version": "3.4.2", | ||||
|       "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-3.4.2.tgz", | ||||
|       "integrity": "sha512-b4Q85dFkGw+TqgytGPrGgACRUhsdKc9S9ErRAXpPGy/CXKs4tYoHDkvIRdsseAF7NjfVwjRFIn6KTnbw7LwJZg==", | ||||
|       "requires": { | ||||
|         "accepts": "~1.3.4", | ||||
|         "base64id": "2.0.0", | ||||
|         "cookie": "0.3.1", | ||||
|         "debug": "~4.1.0", | ||||
|         "engine.io-parser": "~2.2.0", | ||||
|         "ws": "^7.1.2" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "cookie": { | ||||
|           "version": "0.3.1", | ||||
|           "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.3.1.tgz", | ||||
|           "integrity": "sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s=" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "engine.io-client": { | ||||
|       "version": "3.4.3", | ||||
|       "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-3.4.3.tgz", | ||||
|       "integrity": "sha512-0NGY+9hioejTEJCaSJZfWZLk4FPI9dN+1H1C4+wj2iuFba47UgZbJzfWs4aNFajnX/qAaYKbe2lLTfEEWzCmcw==", | ||||
|       "requires": { | ||||
|         "component-emitter": "~1.3.0", | ||||
|         "component-inherit": "0.0.3", | ||||
|         "debug": "~4.1.0", | ||||
|         "engine.io-parser": "~2.2.0", | ||||
|         "has-cors": "1.1.0", | ||||
|         "indexof": "0.0.1", | ||||
|         "parseqs": "0.0.5", | ||||
|         "parseuri": "0.0.5", | ||||
|         "ws": "~6.1.0", | ||||
|         "xmlhttprequest-ssl": "~1.5.4", | ||||
|         "yeast": "0.1.2" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "component-emitter": { | ||||
|           "version": "1.3.0", | ||||
|           "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", | ||||
|           "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==" | ||||
|         }, | ||||
|         "ws": { | ||||
|           "version": "6.1.4", | ||||
|           "resolved": "https://registry.npmjs.org/ws/-/ws-6.1.4.tgz", | ||||
|           "integrity": "sha512-eqZfL+NE/YQc1/ZynhojeV8q+H050oR8AZ2uIev7RU10svA9ZnJUddHcOUZTJLinZ9yEfdA2kSATS2qZK5fhJA==", | ||||
|           "requires": { | ||||
|             "async-limiter": "~1.0.0" | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "engine.io-parser": { | ||||
|       "version": "2.2.0", | ||||
|       "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-2.2.0.tgz", | ||||
|       "integrity": "sha512-6I3qD9iUxotsC5HEMuuGsKA0cXerGz+4uGcXQEkfBidgKf0amsjrrtwcbwK/nzpZBxclXlV7gGl9dgWvu4LF6w==", | ||||
|       "requires": { | ||||
|         "after": "0.8.2", | ||||
|         "arraybuffer.slice": "~0.0.7", | ||||
|         "base64-arraybuffer": "0.1.5", | ||||
|         "blob": "0.0.5", | ||||
|         "has-binary2": "~1.0.2" | ||||
|       } | ||||
|     }, | ||||
|     "escape-html": { | ||||
|       "version": "1.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", | ||||
|       "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" | ||||
|     }, | ||||
|     "escape-string-regexp": { | ||||
|       "version": "1.0.5", | ||||
|       "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", | ||||
|  | @ -460,11 +686,68 @@ | |||
|       "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "etag": { | ||||
|       "version": "1.8.1", | ||||
|       "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", | ||||
|       "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" | ||||
|     }, | ||||
|     "event-target-shim": { | ||||
|       "version": "5.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/event-target-shim/-/event-target-shim-5.0.1.tgz", | ||||
|       "integrity": "sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==" | ||||
|     }, | ||||
|     "express": { | ||||
|       "version": "4.17.1", | ||||
|       "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz", | ||||
|       "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==", | ||||
|       "requires": { | ||||
|         "accepts": "~1.3.7", | ||||
|         "array-flatten": "1.1.1", | ||||
|         "body-parser": "1.19.0", | ||||
|         "content-disposition": "0.5.3", | ||||
|         "content-type": "~1.0.4", | ||||
|         "cookie": "0.4.0", | ||||
|         "cookie-signature": "1.0.6", | ||||
|         "debug": "2.6.9", | ||||
|         "depd": "~1.1.2", | ||||
|         "encodeurl": "~1.0.2", | ||||
|         "escape-html": "~1.0.3", | ||||
|         "etag": "~1.8.1", | ||||
|         "finalhandler": "~1.1.2", | ||||
|         "fresh": "0.5.2", | ||||
|         "merge-descriptors": "1.0.1", | ||||
|         "methods": "~1.1.2", | ||||
|         "on-finished": "~2.3.0", | ||||
|         "parseurl": "~1.3.3", | ||||
|         "path-to-regexp": "0.1.7", | ||||
|         "proxy-addr": "~2.0.5", | ||||
|         "qs": "6.7.0", | ||||
|         "range-parser": "~1.2.1", | ||||
|         "safe-buffer": "5.1.2", | ||||
|         "send": "0.17.1", | ||||
|         "serve-static": "1.14.1", | ||||
|         "setprototypeof": "1.1.1", | ||||
|         "statuses": "~1.5.0", | ||||
|         "type-is": "~1.6.18", | ||||
|         "utils-merge": "1.0.1", | ||||
|         "vary": "~1.1.2" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "debug": { | ||||
|           "version": "2.6.9", | ||||
|           "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", | ||||
|           "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", | ||||
|           "requires": { | ||||
|             "ms": "2.0.0" | ||||
|           } | ||||
|         }, | ||||
|         "ms": { | ||||
|           "version": "2.0.0", | ||||
|           "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", | ||||
|           "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "external-editor": { | ||||
|       "version": "3.1.0", | ||||
|       "resolved": "https://registry.npmjs.org/external-editor/-/external-editor-3.1.0.tgz", | ||||
|  | @ -510,6 +793,35 @@ | |||
|         "flat-cache": "^2.0.1" | ||||
|       } | ||||
|     }, | ||||
|     "finalhandler": { | ||||
|       "version": "1.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", | ||||
|       "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", | ||||
|       "requires": { | ||||
|         "debug": "2.6.9", | ||||
|         "encodeurl": "~1.0.2", | ||||
|         "escape-html": "~1.0.3", | ||||
|         "on-finished": "~2.3.0", | ||||
|         "parseurl": "~1.3.3", | ||||
|         "statuses": "~1.5.0", | ||||
|         "unpipe": "~1.0.0" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "debug": { | ||||
|           "version": "2.6.9", | ||||
|           "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", | ||||
|           "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", | ||||
|           "requires": { | ||||
|             "ms": "2.0.0" | ||||
|           } | ||||
|         }, | ||||
|         "ms": { | ||||
|           "version": "2.0.0", | ||||
|           "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", | ||||
|           "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "flat-cache": { | ||||
|       "version": "2.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz", | ||||
|  | @ -527,6 +839,16 @@ | |||
|       "integrity": "sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "forwarded": { | ||||
|       "version": "0.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz", | ||||
|       "integrity": "sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ=" | ||||
|     }, | ||||
|     "fresh": { | ||||
|       "version": "0.5.2", | ||||
|       "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", | ||||
|       "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" | ||||
|     }, | ||||
|     "fs.realpath": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", | ||||
|  | @ -571,12 +893,44 @@ | |||
|         "type-fest": "^0.8.1" | ||||
|       } | ||||
|     }, | ||||
|     "has-binary2": { | ||||
|       "version": "1.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/has-binary2/-/has-binary2-1.0.3.tgz", | ||||
|       "integrity": "sha512-G1LWKhDSvhGeAQ8mPVQlqNcOB2sJdwATtZKl2pDKKHfpf/rYj24lkinxf69blJbnsvtqqNU+L3SL50vzZhXOnw==", | ||||
|       "requires": { | ||||
|         "isarray": "2.0.1" | ||||
|       } | ||||
|     }, | ||||
|     "has-cors": { | ||||
|       "version": "1.1.0", | ||||
|       "resolved": "https://registry.npmjs.org/has-cors/-/has-cors-1.1.0.tgz", | ||||
|       "integrity": "sha1-XkdHk/fqmEPRu5nCPu9J/xJv/zk=" | ||||
|     }, | ||||
|     "has-flag": { | ||||
|       "version": "3.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", | ||||
|       "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "http-errors": { | ||||
|       "version": "1.7.2", | ||||
|       "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", | ||||
|       "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", | ||||
|       "requires": { | ||||
|         "depd": "~1.1.2", | ||||
|         "inherits": "2.0.3", | ||||
|         "setprototypeof": "1.1.1", | ||||
|         "statuses": ">= 1.5.0 < 2", | ||||
|         "toidentifier": "1.0.0" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "inherits": { | ||||
|           "version": "2.0.3", | ||||
|           "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", | ||||
|           "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "iconv-lite": { | ||||
|       "version": "0.4.24", | ||||
|       "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", | ||||
|  | @ -607,6 +961,11 @@ | |||
|       "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "indexof": { | ||||
|       "version": "0.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/indexof/-/indexof-0.0.1.tgz", | ||||
|       "integrity": "sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10=" | ||||
|     }, | ||||
|     "inflight": { | ||||
|       "version": "1.0.6", | ||||
|       "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", | ||||
|  | @ -689,6 +1048,11 @@ | |||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "ipaddr.js": { | ||||
|       "version": "1.9.1", | ||||
|       "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", | ||||
|       "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==" | ||||
|     }, | ||||
|     "is-extglob": { | ||||
|       "version": "2.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", | ||||
|  | @ -709,6 +1073,11 @@ | |||
|         "is-extglob": "^2.1.1" | ||||
|       } | ||||
|     }, | ||||
|     "isarray": { | ||||
|       "version": "2.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.1.tgz", | ||||
|       "integrity": "sha1-o32U7ZzaLVmGXJ92/llu4fM4dB4=" | ||||
|     }, | ||||
|     "isexe": { | ||||
|       "version": "2.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", | ||||
|  | @ -758,6 +1127,26 @@ | |||
|       "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz", | ||||
|       "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==" | ||||
|     }, | ||||
|     "media-typer": { | ||||
|       "version": "0.3.0", | ||||
|       "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", | ||||
|       "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" | ||||
|     }, | ||||
|     "merge-descriptors": { | ||||
|       "version": "1.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", | ||||
|       "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" | ||||
|     }, | ||||
|     "methods": { | ||||
|       "version": "1.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", | ||||
|       "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=" | ||||
|     }, | ||||
|     "mime": { | ||||
|       "version": "1.6.0", | ||||
|       "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", | ||||
|       "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" | ||||
|     }, | ||||
|     "mime-db": { | ||||
|       "version": "1.44.0", | ||||
|       "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz", | ||||
|  | @ -821,11 +1210,29 @@ | |||
|       "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "negotiator": { | ||||
|       "version": "0.6.2", | ||||
|       "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", | ||||
|       "integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==" | ||||
|     }, | ||||
|     "node-fetch": { | ||||
|       "version": "2.6.0", | ||||
|       "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.0.tgz", | ||||
|       "integrity": "sha512-8dG4H5ujfvFiqDmVu9fQ5bOHUC15JMjMY/Zumv26oOvvVJjM67KF8koCWIabKQ1GJIa9r2mMZscBq/TbdOcmNA==" | ||||
|     }, | ||||
|     "object-component": { | ||||
|       "version": "0.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/object-component/-/object-component-0.0.3.tgz", | ||||
|       "integrity": "sha1-8MaapQ78lbhmwYb0AKM3acsvEpE=" | ||||
|     }, | ||||
|     "on-finished": { | ||||
|       "version": "2.3.0", | ||||
|       "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", | ||||
|       "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", | ||||
|       "requires": { | ||||
|         "ee-first": "1.1.1" | ||||
|       } | ||||
|     }, | ||||
|     "once": { | ||||
|       "version": "1.4.0", | ||||
|       "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", | ||||
|  | @ -871,6 +1278,27 @@ | |||
|         "callsites": "^3.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "parseqs": { | ||||
|       "version": "0.0.5", | ||||
|       "resolved": "https://registry.npmjs.org/parseqs/-/parseqs-0.0.5.tgz", | ||||
|       "integrity": "sha1-1SCKNzjkZ2bikbouoXNoSSGouJ0=", | ||||
|       "requires": { | ||||
|         "better-assert": "~1.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "parseuri": { | ||||
|       "version": "0.0.5", | ||||
|       "resolved": "https://registry.npmjs.org/parseuri/-/parseuri-0.0.5.tgz", | ||||
|       "integrity": "sha1-gCBKUNTbt3m/3G6+J3jZDkvOMgo=", | ||||
|       "requires": { | ||||
|         "better-assert": "~1.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "parseurl": { | ||||
|       "version": "1.3.3", | ||||
|       "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", | ||||
|       "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==" | ||||
|     }, | ||||
|     "path-is-absolute": { | ||||
|       "version": "1.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", | ||||
|  | @ -883,6 +1311,11 @@ | |||
|       "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "path-to-regexp": { | ||||
|       "version": "0.1.7", | ||||
|       "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", | ||||
|       "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" | ||||
|     }, | ||||
|     "prelude-ls": { | ||||
|       "version": "1.2.1", | ||||
|       "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", | ||||
|  | @ -900,12 +1333,42 @@ | |||
|       "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "proxy-addr": { | ||||
|       "version": "2.0.6", | ||||
|       "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz", | ||||
|       "integrity": "sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw==", | ||||
|       "requires": { | ||||
|         "forwarded": "~0.1.2", | ||||
|         "ipaddr.js": "1.9.1" | ||||
|       } | ||||
|     }, | ||||
|     "punycode": { | ||||
|       "version": "2.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", | ||||
|       "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "qs": { | ||||
|       "version": "6.7.0", | ||||
|       "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", | ||||
|       "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" | ||||
|     }, | ||||
|     "range-parser": { | ||||
|       "version": "1.2.1", | ||||
|       "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", | ||||
|       "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" | ||||
|     }, | ||||
|     "raw-body": { | ||||
|       "version": "2.4.0", | ||||
|       "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz", | ||||
|       "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==", | ||||
|       "requires": { | ||||
|         "bytes": "3.1.0", | ||||
|         "http-errors": "1.7.2", | ||||
|         "iconv-lite": "0.4.24", | ||||
|         "unpipe": "1.0.0" | ||||
|       } | ||||
|     }, | ||||
|     "regexpp": { | ||||
|       "version": "3.1.0", | ||||
|       "resolved": "https://registry.npmjs.org/regexpp/-/regexpp-3.1.0.tgz", | ||||
|  | @ -949,6 +1412,11 @@ | |||
|         "tslib": "^1.9.0" | ||||
|       } | ||||
|     }, | ||||
|     "safe-buffer": { | ||||
|       "version": "5.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", | ||||
|       "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" | ||||
|     }, | ||||
|     "safer-buffer": { | ||||
|       "version": "2.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", | ||||
|  | @ -960,11 +1428,69 @@ | |||
|       "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "send": { | ||||
|       "version": "0.17.1", | ||||
|       "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz", | ||||
|       "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==", | ||||
|       "requires": { | ||||
|         "debug": "2.6.9", | ||||
|         "depd": "~1.1.2", | ||||
|         "destroy": "~1.0.4", | ||||
|         "encodeurl": "~1.0.2", | ||||
|         "escape-html": "~1.0.3", | ||||
|         "etag": "~1.8.1", | ||||
|         "fresh": "0.5.2", | ||||
|         "http-errors": "~1.7.2", | ||||
|         "mime": "1.6.0", | ||||
|         "ms": "2.1.1", | ||||
|         "on-finished": "~2.3.0", | ||||
|         "range-parser": "~1.2.1", | ||||
|         "statuses": "~1.5.0" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "debug": { | ||||
|           "version": "2.6.9", | ||||
|           "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", | ||||
|           "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", | ||||
|           "requires": { | ||||
|             "ms": "2.0.0" | ||||
|           }, | ||||
|           "dependencies": { | ||||
|             "ms": { | ||||
|               "version": "2.0.0", | ||||
|               "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", | ||||
|               "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         "ms": { | ||||
|           "version": "2.1.1", | ||||
|           "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", | ||||
|           "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "serve-static": { | ||||
|       "version": "1.14.1", | ||||
|       "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz", | ||||
|       "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==", | ||||
|       "requires": { | ||||
|         "encodeurl": "~1.0.2", | ||||
|         "escape-html": "~1.0.3", | ||||
|         "parseurl": "~1.3.3", | ||||
|         "send": "0.17.1" | ||||
|       } | ||||
|     }, | ||||
|     "setimmediate": { | ||||
|       "version": "1.0.5", | ||||
|       "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", | ||||
|       "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=" | ||||
|     }, | ||||
|     "setprototypeof": { | ||||
|       "version": "1.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz", | ||||
|       "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==" | ||||
|     }, | ||||
|     "shebang-command": { | ||||
|       "version": "2.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", | ||||
|  | @ -1004,12 +1530,93 @@ | |||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "socket.io": { | ||||
|       "version": "2.3.0", | ||||
|       "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-2.3.0.tgz", | ||||
|       "integrity": "sha512-2A892lrj0GcgR/9Qk81EaY2gYhCBxurV0PfmmESO6p27QPrUK1J3zdns+5QPqvUYK2q657nSj0guoIil9+7eFg==", | ||||
|       "requires": { | ||||
|         "debug": "~4.1.0", | ||||
|         "engine.io": "~3.4.0", | ||||
|         "has-binary2": "~1.0.2", | ||||
|         "socket.io-adapter": "~1.1.0", | ||||
|         "socket.io-client": "2.3.0", | ||||
|         "socket.io-parser": "~3.4.0" | ||||
|       } | ||||
|     }, | ||||
|     "socket.io-adapter": { | ||||
|       "version": "1.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-1.1.2.tgz", | ||||
|       "integrity": "sha512-WzZRUj1kUjrTIrUKpZLEzFZ1OLj5FwLlAFQs9kuZJzJi5DKdU7FsWc36SNmA8iDOtwBQyT8FkrriRM8vXLYz8g==" | ||||
|     }, | ||||
|     "socket.io-client": { | ||||
|       "version": "2.3.0", | ||||
|       "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-2.3.0.tgz", | ||||
|       "integrity": "sha512-cEQQf24gET3rfhxZ2jJ5xzAOo/xhZwK+mOqtGRg5IowZsMgwvHwnf/mCRapAAkadhM26y+iydgwsXGObBB5ZdA==", | ||||
|       "requires": { | ||||
|         "backo2": "1.0.2", | ||||
|         "base64-arraybuffer": "0.1.5", | ||||
|         "component-bind": "1.0.0", | ||||
|         "component-emitter": "1.2.1", | ||||
|         "debug": "~4.1.0", | ||||
|         "engine.io-client": "~3.4.0", | ||||
|         "has-binary2": "~1.0.2", | ||||
|         "has-cors": "1.1.0", | ||||
|         "indexof": "0.0.1", | ||||
|         "object-component": "0.0.3", | ||||
|         "parseqs": "0.0.5", | ||||
|         "parseuri": "0.0.5", | ||||
|         "socket.io-parser": "~3.3.0", | ||||
|         "to-array": "0.1.4" | ||||
|       }, | ||||
|       "dependencies": { | ||||
|         "ms": { | ||||
|           "version": "2.0.0", | ||||
|           "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", | ||||
|           "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" | ||||
|         }, | ||||
|         "socket.io-parser": { | ||||
|           "version": "3.3.0", | ||||
|           "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.3.0.tgz", | ||||
|           "integrity": "sha512-hczmV6bDgdaEbVqhAeVMM/jfUfzuEZHsQg6eOmLgJht6G3mPKMxYm75w2+qhAQZ+4X+1+ATZ+QFKeOZD5riHng==", | ||||
|           "requires": { | ||||
|             "component-emitter": "1.2.1", | ||||
|             "debug": "~3.1.0", | ||||
|             "isarray": "2.0.1" | ||||
|           }, | ||||
|           "dependencies": { | ||||
|             "debug": { | ||||
|               "version": "3.1.0", | ||||
|               "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", | ||||
|               "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", | ||||
|               "requires": { | ||||
|                 "ms": "2.0.0" | ||||
|               } | ||||
|             } | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     "socket.io-parser": { | ||||
|       "version": "3.4.1", | ||||
|       "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-3.4.1.tgz", | ||||
|       "integrity": "sha512-11hMgzL+WCLWf1uFtHSNvliI++tcRUWdoeYuwIl+Axvwy9z2gQM+7nJyN3STj1tLj5JyIUH8/gpDGxzAlDdi0A==", | ||||
|       "requires": { | ||||
|         "component-emitter": "1.2.1", | ||||
|         "debug": "~4.1.0", | ||||
|         "isarray": "2.0.1" | ||||
|       } | ||||
|     }, | ||||
|     "sprintf-js": { | ||||
|       "version": "1.0.3", | ||||
|       "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", | ||||
|       "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "statuses": { | ||||
|       "version": "1.5.0", | ||||
|       "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", | ||||
|       "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" | ||||
|     }, | ||||
|     "string-width": { | ||||
|       "version": "4.2.0", | ||||
|       "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz", | ||||
|  | @ -1114,6 +1721,16 @@ | |||
|         "os-tmpdir": "~1.0.2" | ||||
|       } | ||||
|     }, | ||||
|     "to-array": { | ||||
|       "version": "0.1.4", | ||||
|       "resolved": "https://registry.npmjs.org/to-array/-/to-array-0.1.4.tgz", | ||||
|       "integrity": "sha1-F+bBH3PdTz10zaek/zI46a2b+JA=" | ||||
|     }, | ||||
|     "toidentifier": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", | ||||
|       "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" | ||||
|     }, | ||||
|     "tslib": { | ||||
|       "version": "1.13.0", | ||||
|       "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", | ||||
|  | @ -1139,6 +1756,20 @@ | |||
|       "integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "type-is": { | ||||
|       "version": "1.6.18", | ||||
|       "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", | ||||
|       "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", | ||||
|       "requires": { | ||||
|         "media-typer": "0.3.0", | ||||
|         "mime-types": "~2.1.24" | ||||
|       } | ||||
|     }, | ||||
|     "unpipe": { | ||||
|       "version": "1.0.0", | ||||
|       "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", | ||||
|       "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" | ||||
|     }, | ||||
|     "uri-js": { | ||||
|       "version": "4.2.2", | ||||
|       "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", | ||||
|  | @ -1148,12 +1779,22 @@ | |||
|         "punycode": "^2.1.0" | ||||
|       } | ||||
|     }, | ||||
|     "utils-merge": { | ||||
|       "version": "1.0.1", | ||||
|       "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", | ||||
|       "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" | ||||
|     }, | ||||
|     "v8-compile-cache": { | ||||
|       "version": "2.1.1", | ||||
|       "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.1.tgz", | ||||
|       "integrity": "sha512-8OQ9CL+VWyt3JStj7HX7/ciTL2V3Rl1Wf5OL+SNTm0yK1KvtReVulksyeRnCANHHuUxHlQig+JJDlUhBt1NQDQ==", | ||||
|       "dev": true | ||||
|     }, | ||||
|     "vary": { | ||||
|       "version": "1.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", | ||||
|       "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" | ||||
|     }, | ||||
|     "which": { | ||||
|       "version": "2.0.2", | ||||
|       "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", | ||||
|  | @ -1188,6 +1829,16 @@ | |||
|       "version": "7.3.0", | ||||
|       "resolved": "https://registry.npmjs.org/ws/-/ws-7.3.0.tgz", | ||||
|       "integrity": "sha512-iFtXzngZVXPGgpTlP1rBqsUK82p9tKqsWRPg5L56egiljujJT3vGAYnHANvFxBieXrTFavhzhxW52jnaWV+w2w==" | ||||
|     }, | ||||
|     "xmlhttprequest-ssl": { | ||||
|       "version": "1.5.5", | ||||
|       "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-1.5.5.tgz", | ||||
|       "integrity": "sha1-wodrBhaKrcQOV9l+gRkayPQ5iz4=" | ||||
|     }, | ||||
|     "yeast": { | ||||
|       "version": "0.1.2", | ||||
|       "resolved": "https://registry.npmjs.org/yeast/-/yeast-0.1.2.tgz", | ||||
|       "integrity": "sha1-AI4G2AlDIMNy28L47XagymyKxBk=" | ||||
|     } | ||||
|   } | ||||
| } | ||||
|  |  | |||
|  | @ -14,9 +14,11 @@ | |||
|   "license": "Apache-2.0", | ||||
|   "dependencies": { | ||||
|     "discord.js": "^12.2.0", | ||||
|     "express": "^4.17.1", | ||||
|     "inquirer": "^7.3.0", | ||||
|     "moment": "^2.27.0", | ||||
|     "ms": "^2.1.2" | ||||
|     "ms": "^2.1.2", | ||||
|     "socket.io": "^2.3.0" | ||||
|   }, | ||||
|   "devDependencies": { | ||||
|     "eslint": "^7.0.0", | ||||
|  |  | |||
							
								
								
									
										3
									
								
								panel/index.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								panel/index.html
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,3 @@ | |||
| <h1>test</h1> | ||||
| <script src="/socket.io/socket.io.js"></script> | ||||
| <script src="main.js"></script> | ||||
							
								
								
									
										2
									
								
								panel/main.js
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								panel/main.js
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,2 @@ | |||
| const socket = io(); | ||||
| socket.on('result', console.log); | ||||
							
								
								
									
										0
									
								
								panel/style.css
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										0
									
								
								panel/style.css
									
										
									
									
									
										Normal file
									
								
							|  | @ -1,5 +1,6 @@ | |||
| /* eslint-disable no-unused-vars */ | ||||
| const Command = require('./../Structures/Command.js'); | ||||
| const panel = require('../panel.js'); | ||||
| 
 | ||||
| module.exports = class extends Command { | ||||
| 
 | ||||
|  | @ -11,6 +12,7 @@ module.exports = class extends Command { | |||
| 
 | ||||
| 	async run(message, args) { | ||||
| 		message.channel.send('Hello'); | ||||
| 		panel.send(this); | ||||
| 	} | ||||
| 
 | ||||
| }; | ||||
|  |  | |||
|  | @ -3,7 +3,7 @@ const Util = require('./Util.js'); | |||
| 
 | ||||
| module.exports = class BotClient extends Client { | ||||
| 
 | ||||
| 	constructor(options = {}) { | ||||
| 	constructor(options = {}, panel) { | ||||
| 		super({ | ||||
| 			disableMentions: 'everyone' | ||||
| 		}); | ||||
|  | @ -26,6 +26,7 @@ module.exports = class BotClient extends Client { | |||
| 			const mentionRegexPrefix = RegExp(`^<@!${this.user.id}> `); | ||||
| 
 | ||||
| 			if (!message.guild || message.author.bot) return; | ||||
| 			panel.send(message); | ||||
| 
 | ||||
| 			if (message.content.match(mentionRegex)) message.channel.send(`My prefix for ${message.guild.name} is \`${this.prefix}\`.`); | ||||
| 
 | ||||
|  | @ -40,6 +41,11 @@ module.exports = class BotClient extends Client { | |||
| 				command.run(message, args); | ||||
| 			} | ||||
| 		}); | ||||
| 
 | ||||
| 		panel.listen('message', info => { | ||||
| 			if (!info || !('channel' in info) || !('message' in info)) return; | ||||
| 			this.channels.cache.get(info.channel).send(info.message); | ||||
| 		}); | ||||
| 	} | ||||
| 
 | ||||
| 	validate(options) { | ||||
|  |  | |||
|  | @ -3,7 +3,8 @@ | |||
| 
 | ||||
| 	const BotClient = require('./Structures/BotClient'); | ||||
| 	const config = require('../data/config.json'); | ||||
| 	const panel = require('./panel.js'); | ||||
| 
 | ||||
| 	const client = new BotClient(config); | ||||
| 	const client = new BotClient(config, panel); | ||||
| 	client.start(); | ||||
| })() | ||||
|  |  | |||
							
								
								
									
										29
									
								
								src/panel.js
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								src/panel.js
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,29 @@ | |||
| const express = require('express'); | ||||
| const app = express(); | ||||
| const http = require('http').createServer(app); | ||||
| const io = require('socket.io')(http); | ||||
| const { Collection } = require('discord.js'); | ||||
| const listeners = new Collection(); | ||||
| 
 | ||||
| io.on('connection', socket => { | ||||
| 	for (const [id, callback] of listeners) socket.on(id, callback); | ||||
| }); | ||||
| 
 | ||||
| app.use(express.static('panel')); | ||||
| 
 | ||||
| http.listen(80, () => { | ||||
| 	console.log("Web panel ready!"); | ||||
| }); | ||||
| 
 | ||||
| module.exports = { | ||||
| 	send(data) { | ||||
| 		io.emit('result', data); | ||||
| 	}, | ||||
| 	// Set an event listener for the web panel with access to local variables.
 | ||||
| 	// This is for the client (web panel) to send a request (like "send message") to the server.
 | ||||
| 	// I can't find a way to dynamically attach event listeners, so you should add any event listeners you want while loading the bot, meaning you won't be able to add events in a command for example until the web panel page is refreshed. Though now that I think of it, why would you need to? If you want to log data to the web panel's console, just use panel.send().
 | ||||
| 	listen(id, callback) { | ||||
| 		if (!id || !callback) return console.error("No valid callback function or ID was provided for listening to the web panel!"); | ||||
| 		listeners.set(id, callback); | ||||
| 	} | ||||
| }; | ||||
							
								
								
									
										13
									
								
								src/setup.js
									
										
									
									
									
								
							
							
						
						
									
										13
									
								
								src/setup.js
									
										
									
									
									
								
							|  | @ -1,21 +1,21 @@ | |||
| // This file is called (or at least should be called) automatically as long as a config file doesn\'t exist yet.
 | ||||
| // And that file won\'t be written until the data is successfully initialized.
 | ||||
| // This file is called (or at least should be called) automatically as long as a config file doesn't exist yet.
 | ||||
| // And that file won't be written until the data is successfully initialized.
 | ||||
| const fs = require('fs'); | ||||
| const inquirer = require('inquirer'); | ||||
| const prompts = [{ | ||||
| 	type: 'input', | ||||
| 	name: 'prefix', | ||||
| 	message: 'What do you want your bot\'s prefix to be?', | ||||
| 	message: "What do you want your bot's prefix to be?", | ||||
| 	default: '!!' | ||||
| }, { | ||||
| 	type: 'password', | ||||
| 	name: 'token', | ||||
| 	message: 'What\'s your bot\'s token?', | ||||
| 	message: "What's your bot's token?", | ||||
| 	mask: true | ||||
| }, { | ||||
| 	type: 'input', | ||||
| 	name: 'owners', | ||||
| 	message: 'Enter a list of bot owners (by their IDs) separated by spaces.' | ||||
| 	message: "Enter a list of bot owners (by their IDs) separated by spaces." | ||||
| }]; | ||||
| const dir = 'data'; | ||||
| const path = `${dir}/config.json`; | ||||
|  | @ -34,11 +34,12 @@ module.exports = { | |||
| 		const answers = await inquirer.prompt([{ | ||||
| 			type: 'password', | ||||
| 			name: 'token', | ||||
| 			message: 'What\'s your bot\'s token?', | ||||
| 			message: "What's your bot's token?", | ||||
| 			mask: true | ||||
| 		}]); | ||||
| 		const config = JSON.parse(fs.readFileSync(path)); | ||||
| 		config.token = answers.token; | ||||
| 		fs.writeFileSync(path, JSON.stringify(config, null, 4)); | ||||
| 		process.exit(); | ||||
| 	} | ||||
| }; | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue