@skyhelperbot/utils 2.0.0 → 2.0.2-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,5 +1,4 @@
1
- import { buildTimesHTML, parsePerms, postToHaste, recursiveReadDir, parseDateFormat } from "./utils/index.js";
1
+ export * from "./utils/index.js";
2
2
  export * from "./classes/index.js";
3
3
  export {} from "./utils/parsePerms.js";
4
- export { buildTimesHTML, parsePerms, postToHaste, parseDateFormat, recursiveReadDir };
5
4
  export * from "./constants/index.js";
package/dist/typings.d.ts CHANGED
@@ -1,5 +1,4 @@
1
- import { Client, Collection } from "discord.js";
2
- import moment from "moment-timezone";
1
+ import type { DateTime } from "luxon";
3
2
  import { Document } from "mongoose";
4
3
  /** Data of users provided for making a game leaderboard card */
5
4
  export interface userData {
@@ -34,13 +33,10 @@ export interface Background {
34
33
  export interface SkyEvent {
35
34
  eventActive: Boolean;
36
35
  eventName: string;
37
- eventStarts: moment.Moment;
38
- eventEnds: moment.Moment;
36
+ eventStarts: DateTime;
37
+ eventEnds: DateTime;
39
38
  eventDuration: string;
40
39
  }
41
- export interface SkyHelper extends Client {
42
- skyEvents: Collection<string, SkyEvent>;
43
- }
44
40
  export interface TSData extends Document {
45
41
  name: string;
46
42
  visitDate: string;
@@ -56,7 +52,7 @@ export interface ShardsCountdown {
56
52
  index: number;
57
53
  active?: boolean;
58
54
  ended?: boolean;
59
- start: moment.Moment;
60
- end: moment.Moment;
55
+ start: DateTime;
56
+ end: DateTime;
61
57
  duration: string;
62
58
  }
package/dist/typings.js CHANGED
@@ -1,3 +1 @@
1
- import { Client, Collection } from "discord.js";
2
- import moment from "moment-timezone";
3
1
  import { Document } from "mongoose";
@@ -7,199 +7,199 @@ import {} from "discord.js";
7
7
  * @param providedTime
8
8
  */
9
9
  export const buildTimesHTML = (interaction, fieldsData, offset, providedTime) => {
10
- return `
11
- <!DOCTYPE html>
12
-
13
-
14
- <html lang="en">
15
-
16
- <head>
17
- <meta charset="UTF-8">
18
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
19
- <!--=============== FAVICON ===============-->
20
- <link rel="shortcut icon" href="/assets/img/boticon.png" type="image/x-icon">
21
-
22
- <!--=============== BOXICONS ===============-->
23
- <link href='https://unpkg.com/boxicons@2.1.4/css/boxicons.min.css' rel='stylesheet'>
24
-
25
- <!--=============== SWIPER CSS ===============-->
26
- <link rel="stylesheet" href="/assets/css/swiper-bundle.min.css">
27
-
28
- <!--=============== CSS ===============-->
29
- <link rel="stylesheet" href="/assets/css/styles.css">
30
-
31
- <title>Timestamp - SkyHelper</title>
32
- </head>
33
- <body>
34
- <!--==================== HEADER ====================-->
35
-
36
- <header class="header" id="header">
37
-
38
- <nav class="nav container">
39
- <a href="/" class="nav__logo">
40
- <img src="/assets/img/boticon.png" style="top: 50px; left: 50px; widht: 40px; height: 40px;"> <p class="nav__logo-text">SkyHelper</p>
41
- </a>
42
- <a href="/" class="nav__link">
43
-
44
- <i class='bx bx-home-alt-2'></i>
45
- <span>Home</span>
46
- </a>
47
-
48
- <!-- Theme change button -->
49
- <i class='bx bx-moon change-theme' id="theme-button"></i>
50
- <a href="/commands" class="nav__link">
51
- <i class='bx bx-code-alt com-icon'></i><p class="nav__com">Commands</p>
52
- </a>
53
- <a href="https://discord.com/invite/u9zUjWbbQ4" class="button nav__button">
54
- Invite Me
55
- </a>
56
- </nav>
57
- </header>
58
-
59
- <!-- Content -->
60
- <main class="main">
61
- <section class="home section" id="home">
62
- <div class="home__container container grid">
63
- <div class="home__data">
64
- <h1 class="home__title">
65
- Timestamp
66
- </h1>
67
- </div>
68
- </div>
69
- </section>
70
-
71
- </main>
72
-
73
- <!-- timestamp -->
74
- <section class="value section" id="value">
75
- <div class="value__container container times__data">
76
- <h2 class="section__title">
77
- Timestamp for <img src="${interaction.user.displayAvatarURL()}" style="width:25px;height:25px;border-radius:50%;"><span> ${interaction.user.username}</span>
78
- </h2>
79
- <div class="alert alert-info">Provided Time: ${providedTime}<br>Offset: <strong>${offset}</strong>
80
- </div>
81
- <div class="value__accordion-item2">
10
+ return `
11
+ <!DOCTYPE html>
12
+
13
+
14
+ <html lang="en">
15
+
16
+ <head>
17
+ <meta charset="UTF-8">
18
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
19
+ <!--=============== FAVICON ===============-->
20
+ <link rel="shortcut icon" href="/assets/img/boticon.png" type="image/x-icon">
21
+
22
+ <!--=============== BOXICONS ===============-->
23
+ <link href='https://unpkg.com/boxicons@2.1.4/css/boxicons.min.css' rel='stylesheet'>
24
+
25
+ <!--=============== SWIPER CSS ===============-->
26
+ <link rel="stylesheet" href="/assets/css/swiper-bundle.min.css">
27
+
28
+ <!--=============== CSS ===============-->
29
+ <link rel="stylesheet" href="/assets/css/styles.css">
30
+
31
+ <title>Timestamp - SkyHelper</title>
32
+ </head>
33
+ <body>
34
+ <!--==================== HEADER ====================-->
35
+
36
+ <header class="header" id="header">
37
+
38
+ <nav class="nav container">
39
+ <a href="/" class="nav__logo">
40
+ <img src="/assets/img/boticon.png" style="top: 50px; left: 50px; widht: 40px; height: 40px;"> <p class="nav__logo-text">SkyHelper</p>
41
+ </a>
42
+ <a href="/" class="nav__link">
43
+
44
+ <i class='bx bx-home-alt-2'></i>
45
+ <span>Home</span>
46
+ </a>
47
+
48
+ <!-- Theme change button -->
49
+ <i class='bx bx-moon change-theme' id="theme-button"></i>
50
+ <a href="/commands" class="nav__link">
51
+ <i class='bx bx-code-alt com-icon'></i><p class="nav__com">Commands</p>
52
+ </a>
53
+ <a href="https://discord.com/invite/u9zUjWbbQ4" class="button nav__button">
54
+ Invite Me
55
+ </a>
56
+ </nav>
57
+ </header>
58
+
59
+ <!-- Content -->
60
+ <main class="main">
61
+ <section class="home section" id="home">
62
+ <div class="home__container container grid">
63
+ <div class="home__data">
64
+ <h1 class="home__title">
65
+ Timestamp
66
+ </h1>
67
+ </div>
68
+ </div>
69
+ </section>
70
+
71
+ </main>
72
+
73
+ <!-- timestamp -->
74
+ <section class="value section" id="value">
75
+ <div class="value__container container times__data">
76
+ <h2 class="section__title">
77
+ Timestamp for <img src="${interaction.user.displayAvatarURL()}" style="width:25px;height:25px;border-radius:50%;"><span> ${interaction.user.username}</span>
78
+ </h2>
79
+ <div class="alert alert-info">Provided Time: ${providedTime}<br>Offset: <strong>${offset}</strong>
80
+ </div>
81
+ <div class="value__accordion-item2">
82
82
  ${fieldsData
83
- .map((field) => `
84
-
85
- <div class="time__header">
86
- <strong>${field.name} (<span class="discUnix">${field.example}</span>)</strong></div>
87
-
88
- <br> <span class="code-block">${sanitizeField(field.value)}</span> <button class="copyBtn">
89
- <span><svg class ="copySvg" viewBox="0 0 467 512.22" clip-rule="evenodd" fill-rule="evenodd" image-rendering="optimizeQuality" text-rendering="geometricPrecision" shape-rendering="geometricPrecision" xmlns="http://www.w3.org/2000/svg" height="12" width="12"><path d="M131.07 372.11c.37 1 .57 2.08.57 3.2 0 1.13-.2 2.21-.57 3.21v75.91c0 10.74 4.41 20.53 11.5 27.62s16.87 11.49 27.62 11.49h239.02c10.75 0 20.53-4.4 27.62-11.49s11.49-16.88 11.49-27.62V152.42c0-10.55-4.21-20.15-11.02-27.18l-.47-.43c-7.09-7.09-16.87-11.5-27.62-11.5H170.19c-10.75 0-20.53 4.41-27.62 11.5s-11.5 16.87-11.5 27.61v219.69zm-18.67 12.54H57.23c-15.82 0-30.1-6.58-40.45-17.11C6.41 356.97 0 342.4 0 326.52V57.79c0-15.86 6.5-30.3 16.97-40.78l.04-.04C27.51 6.49 41.94 0 57.79 0h243.63c15.87 0 30.3 6.51 40.77 16.98l.03.03c10.48 10.48 16.99 24.93 16.99 40.78v36.85h50c15.9 0 30.36 6.5 40.82 16.96l.54.58c10.15 10.44 16.43 24.66 16.43 40.24v302.01c0 15.9-6.5 30.36-16.96 40.82-10.47 10.47-24.93 16.97-40.83 16.97H170.19c-15.9 0-30.35-6.5-40.82-16.97-10.47-10.46-16.97-24.92-16.97-40.82v-69.78zM340.54 94.64V57.79c0-10.74-4.41-20.53-11.5-27.63-7.09-7.08-16.86-11.48-27.62-11.48H57.79c-10.78 0-20.56 4.38-27.62 11.45l-.04.04c-7.06 7.06-11.45 16.84-11.45 27.62v268.73c0 10.86 4.34 20.79 11.38 27.97 6.95 7.07 16.54 11.49 27.17 11.49h55.17V152.42c0-15.9 6.5-30.35 16.97-40.82 10.47-10.47 24.92-16.96 40.82-16.96h170.35z" fill-rule="nonzero"></path></svg> Copy</span>
90
- <span>Copied</span>
91
- </button>
83
+ .map((field) => `
84
+
85
+ <div class="time__header">
86
+ <strong>${field.name} (<span class="discUnix">${field.example}</span>)</strong></div>
87
+
88
+ <br> <span class="code-block">${sanitizeField(field.value)}</span> <button class="copyBtn">
89
+ <span><svg class ="copySvg" viewBox="0 0 467 512.22" clip-rule="evenodd" fill-rule="evenodd" image-rendering="optimizeQuality" text-rendering="geometricPrecision" shape-rendering="geometricPrecision" xmlns="http://www.w3.org/2000/svg" height="12" width="12"><path d="M131.07 372.11c.37 1 .57 2.08.57 3.2 0 1.13-.2 2.21-.57 3.21v75.91c0 10.74 4.41 20.53 11.5 27.62s16.87 11.49 27.62 11.49h239.02c10.75 0 20.53-4.4 27.62-11.49s11.49-16.88 11.49-27.62V152.42c0-10.55-4.21-20.15-11.02-27.18l-.47-.43c-7.09-7.09-16.87-11.5-27.62-11.5H170.19c-10.75 0-20.53 4.41-27.62 11.5s-11.5 16.87-11.5 27.61v219.69zm-18.67 12.54H57.23c-15.82 0-30.1-6.58-40.45-17.11C6.41 356.97 0 342.4 0 326.52V57.79c0-15.86 6.5-30.3 16.97-40.78l.04-.04C27.51 6.49 41.94 0 57.79 0h243.63c15.87 0 30.3 6.51 40.77 16.98l.03.03c10.48 10.48 16.99 24.93 16.99 40.78v36.85h50c15.9 0 30.36 6.5 40.82 16.96l.54.58c10.15 10.44 16.43 24.66 16.43 40.24v302.01c0 15.9-6.5 30.36-16.96 40.82-10.47 10.47-24.93 16.97-40.83 16.97H170.19c-15.9 0-30.35-6.5-40.82-16.97-10.47-10.46-16.97-24.92-16.97-40.82v-69.78zM340.54 94.64V57.79c0-10.74-4.41-20.53-11.5-27.63-7.09-7.08-16.86-11.48-27.62-11.48H57.79c-10.78 0-20.56 4.38-27.62 11.45l-.04.04c-7.06 7.06-11.45 16.84-11.45 27.62v268.73c0 10.86 4.34 20.79 11.38 27.97 6.95 7.07 16.54 11.49 27.17 11.49h55.17V152.42c0-15.9 6.5-30.35 16.97-40.82 10.47-10.47 24.92-16.96 40.82-16.96h170.35z" fill-rule="nonzero"></path></svg> Copy</span>
90
+ <span>Copied</span>
91
+ </button>
92
92
  <br><br>`)
93
- .join("")}
94
-
95
- </div>
96
- </div>
97
- </section>
98
- <!--==================== FOOTER ====================-->
99
-
100
-
101
-
102
- <footer class="footer section">
103
-
104
- <div class="footer__container container grid">
105
- <div>
106
- <a href="#" class="footer__logo">
107
- <img src="/assets/img/boticon.png" style="top: 50px; left: 50px; widht: 20px; height: 20px;"> SkyHelper
108
- </a>
109
- <p class="footer__description">
110
- A discord bot for the game Sky: Children of the Light
111
- </p>
112
- </div>
113
- <div class="footer__content">
114
- <div>
115
- <h3 class="footer__title">
116
- About
117
- </h3>
118
- <ul class="footer__links">
119
- <li>
120
- <a href="/" class="footer__link">About Me</a>
121
- </li>
122
-
123
- <li>
124
-
125
- <a href="/#popular" class="footer__link">Features</a>
126
-
127
- </li>
128
- <li>
129
-
130
- <a href="https://docs.skyhelper.xyz" class="footer__link">Documentation</a>
131
-
132
- </li>
133
- </ul>
134
- </div>
135
- <div>
136
-
137
- <h3 class="footer__title">
138
-
139
- Support
140
- </h3>
141
- <ul class="footer__links">
142
- <li>
143
- <a href="/#value" class="footer__link">FAQs</a>
144
- </li>
145
- <li>
146
-
147
- <a href="https://discord.com/invite/u9zUjWbbQ4" class="footer__link">Support Server</a>
148
-
149
- </li>
150
- <li>
151
-
152
- <a href="/contact-us" class="footer__link">Contact Us</a>
153
-
154
- </li>
155
- </ul>
156
- </div>
157
- <div>
158
-
159
- <h3 class="footer__title">
160
-
161
- Socials
162
- </h3>
163
- <ul class="footer__social">
164
- <a href="https://github.com/imnaiyar/SkyHelper" target="_blank" class="footer__social-link">
165
- <i class='bx bxl-github'></i>
166
- </a>
167
- <a href="https://discord.com/invite/u9zUjWbbQ4" target="_blank" class="footer__social-link">
168
- <i class='bx bxl-discord' ></i>
169
- </a>
170
- </ul>
171
- </div>
172
- </div>
173
- </div>
174
-
175
- <div class="footer__info container">
176
- <span class="footer__copy">
177
- &#169; SkyHelper. All rights reserved
178
- </span>
179
-
180
- <div class="footer__privacy">
181
- <a href="/tos">Terms of Service</a>
182
- <a href="/privacy">Privacy Policy</a>
183
- </div>
184
- </div>
185
- </footer>
186
-
187
-
188
- <!--========== SCROLL UP ==========-->
189
- <a href="#" class="scrollup" id="scroll-up">
190
- <i class='bx bx-chevrons-up' ></i>
191
- </a>
192
-
193
- <!--=============== SCROLLREVEAL ===============-->
194
- <script src="/assets/js/scrollreveal.min.js"></script>
195
-
196
- <!--=============== SWIPER JS ===============-->
197
- <script src="/assets/js/swiper-bundle.min.js"></script>
198
-
199
- <!--=============== MAIN JS ===============-->
200
- <script src="/assets/js/main.js"></script>
201
- </body>
202
- </html>
93
+ .join("")}
94
+
95
+ </div>
96
+ </div>
97
+ </section>
98
+ <!--==================== FOOTER ====================-->
99
+
100
+
101
+
102
+ <footer class="footer section">
103
+
104
+ <div class="footer__container container grid">
105
+ <div>
106
+ <a href="#" class="footer__logo">
107
+ <img src="/assets/img/boticon.png" style="top: 50px; left: 50px; widht: 20px; height: 20px;"> SkyHelper
108
+ </a>
109
+ <p class="footer__description">
110
+ A discord bot for the game Sky: Children of the Light
111
+ </p>
112
+ </div>
113
+ <div class="footer__content">
114
+ <div>
115
+ <h3 class="footer__title">
116
+ About
117
+ </h3>
118
+ <ul class="footer__links">
119
+ <li>
120
+ <a href="/" class="footer__link">About Me</a>
121
+ </li>
122
+
123
+ <li>
124
+
125
+ <a href="/#popular" class="footer__link">Features</a>
126
+
127
+ </li>
128
+ <li>
129
+
130
+ <a href="https://docs.skyhelper.xyz" class="footer__link">Documentation</a>
131
+
132
+ </li>
133
+ </ul>
134
+ </div>
135
+ <div>
136
+
137
+ <h3 class="footer__title">
138
+
139
+ Support
140
+ </h3>
141
+ <ul class="footer__links">
142
+ <li>
143
+ <a href="/#value" class="footer__link">FAQs</a>
144
+ </li>
145
+ <li>
146
+
147
+ <a href="https://discord.com/invite/u9zUjWbbQ4" class="footer__link">Support Server</a>
148
+
149
+ </li>
150
+ <li>
151
+
152
+ <a href="/contact-us" class="footer__link">Contact Us</a>
153
+
154
+ </li>
155
+ </ul>
156
+ </div>
157
+ <div>
158
+
159
+ <h3 class="footer__title">
160
+
161
+ Socials
162
+ </h3>
163
+ <ul class="footer__social">
164
+ <a href="https://github.com/imnaiyar/SkyHelper" target="_blank" class="footer__social-link">
165
+ <i class='bx bxl-github'></i>
166
+ </a>
167
+ <a href="https://discord.com/invite/u9zUjWbbQ4" target="_blank" class="footer__social-link">
168
+ <i class='bx bxl-discord' ></i>
169
+ </a>
170
+ </ul>
171
+ </div>
172
+ </div>
173
+ </div>
174
+
175
+ <div class="footer__info container">
176
+ <span class="footer__copy">
177
+ &#169; SkyHelper. All rights reserved
178
+ </span>
179
+
180
+ <div class="footer__privacy">
181
+ <a href="/tos">Terms of Service</a>
182
+ <a href="/privacy">Privacy Policy</a>
183
+ </div>
184
+ </div>
185
+ </footer>
186
+
187
+
188
+ <!--========== SCROLL UP ==========-->
189
+ <a href="#" class="scrollup" id="scroll-up">
190
+ <i class='bx bx-chevrons-up' ></i>
191
+ </a>
192
+
193
+ <!--=============== SCROLLREVEAL ===============-->
194
+ <script src="/assets/js/scrollreveal.min.js"></script>
195
+
196
+ <!--=============== SWIPER JS ===============-->
197
+ <script src="/assets/js/swiper-bundle.min.js"></script>
198
+
199
+ <!--=============== MAIN JS ===============-->
200
+ <script src="/assets/js/main.js"></script>
201
+ </body>
202
+ </html>
203
203
  `;
204
204
  };
205
205
  function sanitizeField(value) {
@@ -1,5 +1,5 @@
1
- export { buildTimesHTML, type Field } from "./buildTimesHTML.js";
2
- export { postToHaste } from "./postToBin.js";
3
- export { parsePerms, type Permission } from "./parsePerms.js";
4
- export { recursiveReadDir } from "./recursiveReadDir.js";
5
- export { parseDateFormat } from "./parseDateFormat.js";
1
+ export * from "./postToBin.js";
2
+ export * from "./parsePerms.js";
3
+ export * from "./recursiveReadDir.js";
4
+ export * from "./parseDateFormat.js";
5
+ export * from "./resolveColors.js";
@@ -1,5 +1,5 @@
1
- export { buildTimesHTML } from "./buildTimesHTML.js";
2
- export { postToHaste } from "./postToBin.js";
3
- export { parsePerms } from "./parsePerms.js";
4
- export { recursiveReadDir } from "./recursiveReadDir.js";
5
- export { parseDateFormat } from "./parseDateFormat.js";
1
+ export * from "./postToBin.js";
2
+ export * from "./parsePerms.js";
3
+ export * from "./recursiveReadDir.js";
4
+ export * from "./parseDateFormat.js";
5
+ export * from "./resolveColors.js";
@@ -0,0 +1,79 @@
1
+ /** Original code credit to discord.js */
2
+ /**
3
+ * Can be a number, hex string, an RGB array like:
4
+ * ```js
5
+ * [255, 0, 255] // purple
6
+ * ```
7
+ * or one of the following strings:
8
+ * - `Default`
9
+ * - `White`
10
+ * - `Aqua`
11
+ * - `Green`
12
+ * - `Blue`
13
+ * - `Yellow`
14
+ * - `Purple`
15
+ * - `LuminousVividPink`
16
+ * - `Fuchsia`
17
+ * - `Gold`
18
+ * - `Orange`
19
+ * - `Red`
20
+ * - `Grey`
21
+ * - `Navy`
22
+ * - `DarkAqua`
23
+ * - `DarkGreen`
24
+ * - `DarkBlue`
25
+ * - `DarkPurple`
26
+ * - `DarkVividPink`
27
+ * - `DarkGold`
28
+ * - `DarkOrange`
29
+ * - `DarkRed`
30
+ * - `DarkGrey`
31
+ * - `DarkerGrey`
32
+ * - `LightGrey`
33
+ * - `DarkNavy`
34
+ * - `Blurple`
35
+ * - `Greyple`
36
+ * - `DarkButNotBlack`
37
+ * - `NotQuiteBlack`
38
+ * - `Random`
39
+ */
40
+ export type ColorResolvable = keyof typeof Colors | "Random" | "Default" | `#${string}` | number | number[];
41
+ /**
42
+ * Resolves a ColorResolvable into a color number.
43
+ * @param color Color to resolve
44
+ * @returns A color
45
+ */
46
+ export declare function resolveColor(color: ColorResolvable): number;
47
+ declare const Colors: {
48
+ Default: number;
49
+ White: number;
50
+ Aqua: number;
51
+ Green: number;
52
+ Blue: number;
53
+ Yellow: number;
54
+ Purple: number;
55
+ LuminousVividPink: number;
56
+ Fuchsia: number;
57
+ Gold: number;
58
+ Orange: number;
59
+ Red: number;
60
+ Grey: number;
61
+ Navy: number;
62
+ DarkAqua: number;
63
+ DarkGreen: number;
64
+ DarkBlue: number;
65
+ DarkPurple: number;
66
+ DarkVividPink: number;
67
+ DarkGold: number;
68
+ DarkOrange: number;
69
+ DarkRed: number;
70
+ DarkGrey: number;
71
+ DarkerGrey: number;
72
+ LightGrey: number;
73
+ DarkNavy: number;
74
+ Blurple: number;
75
+ Greyple: number;
76
+ DarkButNotBlack: number;
77
+ NotQuiteBlack: number;
78
+ };
79
+ export {};
@@ -0,0 +1,63 @@
1
+ /** Original code credit to discord.js */
2
+ /**
3
+ * Resolves a ColorResolvable into a color number.
4
+ * @param color Color to resolve
5
+ * @returns A color
6
+ */
7
+ export function resolveColor(color) {
8
+ let resolvedColor;
9
+ if (typeof color === "string") {
10
+ if (color === "Random")
11
+ return Math.floor(Math.random() * (0xffffff + 1));
12
+ if (color === "Default")
13
+ return 0;
14
+ if (/^#?[\da-f]{6}$/i.test(color))
15
+ return parseInt(color.replace("#", ""), 16);
16
+ resolvedColor = Colors[color];
17
+ }
18
+ else if (Array.isArray(color)) {
19
+ resolvedColor = (color[0] << 16) + (color[1] << 8) + color[2];
20
+ }
21
+ else {
22
+ resolvedColor = color;
23
+ }
24
+ if (!Number.isInteger(resolvedColor)) {
25
+ throw new Error("Not a number");
26
+ }
27
+ if (resolvedColor < 0 || resolvedColor > 0xffffff) {
28
+ throw new Error("Not in color range");
29
+ }
30
+ return resolvedColor;
31
+ }
32
+ const Colors = {
33
+ Default: 0x000000,
34
+ White: 0xffffff,
35
+ Aqua: 0x1abc9c,
36
+ Green: 0x57f287,
37
+ Blue: 0x3498db,
38
+ Yellow: 0xfee75c,
39
+ Purple: 0x9b59b6,
40
+ LuminousVividPink: 0xe91e63,
41
+ Fuchsia: 0xeb459e,
42
+ Gold: 0xf1c40f,
43
+ Orange: 0xe67e22,
44
+ Red: 0xed4245,
45
+ Grey: 0x95a5a6,
46
+ Navy: 0x34495e,
47
+ DarkAqua: 0x11806a,
48
+ DarkGreen: 0x1f8b4c,
49
+ DarkBlue: 0x206694,
50
+ DarkPurple: 0x71368a,
51
+ DarkVividPink: 0xad1457,
52
+ DarkGold: 0xc27c0e,
53
+ DarkOrange: 0xa84300,
54
+ DarkRed: 0x992d22,
55
+ DarkGrey: 0x979c9f,
56
+ DarkerGrey: 0x7f8c8d,
57
+ LightGrey: 0xbcc0c0,
58
+ DarkNavy: 0x2c3e50,
59
+ Blurple: 0x5865f2,
60
+ Greyple: 0x99aab5,
61
+ DarkButNotBlack: 0x2c2f33,
62
+ NotQuiteBlack: 0x23272a,
63
+ };