notherbase-fs 1.5.3 → 2.0.0

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.
Files changed (52) hide show
  1. package/controllers/creation.js +90 -0
  2. package/controllers/spirit-world.js +110 -0
  3. package/controllers/spirits/attribute.js +47 -0
  4. package/controllers/spirits/contact.js +16 -0
  5. package/controllers/spirits/inventory.js +71 -0
  6. package/controllers/spirits/item.js +41 -0
  7. package/controllers/spirits/serve.js +33 -0
  8. package/controllers/spirits/user.js +130 -0
  9. package/controllers/spirits/util.js +39 -0
  10. package/models/index.js +130 -14
  11. package/models/spirit.js +159 -0
  12. package/notherbase-fs.js +23 -73
  13. package/package.json +2 -2
  14. package/public/js/commune.js +22 -0
  15. package/public/js/establishment.js +44 -0
  16. package/public/js/memories.js +29 -30
  17. package/public/styles/main.css +9 -99
  18. package/test/explorer/coast/tall-beach/nono-cove/server-scripts/emailTime.js +7 -3
  19. package/test/explorer/coast/tall-beach/nono-cove/views/index.ejs +38 -60
  20. package/test/pages/server-scripts/emailTime.js +15 -0
  21. package/test/pages/test.ejs +30 -3
  22. package/test/the-front/server-scripts/emailTime.js +7 -3
  23. package/test/the-front/server-scripts/migrateBig.js +3 -0
  24. package/test/the-front/views/check.ejs +88 -2
  25. package/test/the-front/views/index.ejs +43 -101
  26. package/test-index.js +5 -0
  27. package/views/account.ejs +25 -36
  28. package/views/explorer.ejs +48 -1
  29. package/views/inventory.ejs +41 -99
  30. package/views/menu.ejs +8 -2
  31. package/views/more.ejs +8 -14
  32. package/views/player.ejs +37 -24
  33. package/controllers/authCheck.js +0 -18
  34. package/controllers/contact.js +0 -22
  35. package/controllers/explorer.js +0 -150
  36. package/controllers/game.js +0 -59
  37. package/controllers/index.js +0 -10
  38. package/controllers/inventory.js +0 -116
  39. package/controllers/item.js +0 -70
  40. package/controllers/pages.js +0 -33
  41. package/controllers/the-front.js +0 -70
  42. package/controllers/user.js +0 -413
  43. package/controllers/void.js +0 -16
  44. package/models/chat.js +0 -9
  45. package/models/contact.js +0 -14
  46. package/models/detail.js +0 -16
  47. package/models/game.js +0 -8
  48. package/models/inventory.js +0 -19
  49. package/models/item.js +0 -12
  50. package/models/page.js +0 -14
  51. package/models/user.js +0 -25
  52. package/test/test-index.js +0 -5
@@ -55,6 +55,7 @@ main {
55
55
  align-content: center;
56
56
  align-items: flex-start;
57
57
  background-color: var(--bgColor);
58
+ position: relative;
58
59
  }
59
60
 
60
61
  footer {
@@ -81,6 +82,10 @@ footer a {
81
82
  height: 100%;
82
83
  }
83
84
 
85
+ h1, h2, h3, h4, h5, h6 {
86
+ width: 100%;
87
+ }
88
+
84
89
  hr {
85
90
  border: none;
86
91
  border-bottom: 1px solid var(--textColor);
@@ -122,107 +127,12 @@ input[type=submit]:hover, button:hover, a:hover {
122
127
  cursor: pointer;
123
128
  }
124
129
 
125
- .locked {
126
- background-color: var(--bgColor);
127
- padding: 10px;
128
- border-radius: 5px;
129
- border: 1px solid var(--textColor);
130
- color: var(--textColor);
131
- margin: 5px;
132
- margin-top: 20px;
133
- text-decoration: none;
134
- text-align: center;
135
- filter: brightness(.5);
136
- user-select: none;
137
- }
138
-
139
- .to {
140
- width: 100%;
141
- height: 200px;
142
- display: flex;
143
- justify-content: flex-end;
144
- align-items: flex-end;
145
- padding: 20px;
146
- }
147
-
148
- .return {
149
- width: 100%;
150
- height: 75px;
151
- display: flex;
152
- justify-content: flex-end;
153
- align-items: flex-end;
154
- padding: 20px;
155
- }
156
-
157
- .do {
158
- width: 100%;
159
- height: 200px;
160
- display: flex;
161
- justify-content: flex-end;
162
- align-items: flex-end;
163
- padding: 20px;
164
- }
165
-
166
- h2, h3 {
167
- color: var(--textColor);
168
- width: 100%;
169
- }
170
-
171
- ul {
172
- margin: 10px;
173
- }
174
-
175
- .door {
176
- border: 1px solid var(--darkWoodColor);
177
- width: 100px;
178
- height: 150px;
179
- background-color: var(--woodColor);
180
- position: relative;
181
- }
182
-
183
- .knob {
130
+ .login-cover {
184
131
  position: absolute;
185
- width: 20px;
186
- height: 20px;
187
- border-radius: 50%;
188
- right: 5px;
189
- top: 50%;
190
- background-color: var(--darkWoodColor);
191
- }
192
-
193
- iframe {
194
- border: none;
195
- }
196
-
197
- .auth-form {
198
- height: 100%;
132
+ left: 0;
133
+ top: 0;
199
134
  width: 100%;
200
- padding: 40px 5px;
201
- overflow: hidden;
202
- display: flex;
203
- justify-content: center;
204
- flex-wrap: wrap;
205
- }
206
-
207
- .auth-form h3 {
208
- width: calc(100% - 20px);
209
- text-align: center;
210
- margin: 10px;
211
- font-size: 15px;
212
- }
213
-
214
- .auth-form h1 {
215
- width: calc(100% - 20px);
216
- text-align: center;
217
- margin: 10px;
218
- font-size: 20px;
219
- }
220
-
221
- .auth-form p {
222
- width: calc(100% - 20px);
223
- text-align: center;
224
- margin: 10px;
225
- font-size: 12px;
135
+ height: 100%;
226
136
  }
227
137
 
228
138
  @media only screen and (max-width: 1000px) {
@@ -1,8 +1,12 @@
1
- export default async function emailTime(db, route, user, params) {
1
+ export default async function emailTime(req, user) {
2
2
  try {
3
- await db.sendMail.send(params.toEmail, params.subject, params.html);
3
+ await req.db.SendMail.send(
4
+ req.body.data.toEmail,
5
+ req.body.data.subject,
6
+ req.body.data.html
7
+ );
4
8
 
5
- return "Sent"
9
+ return "Sent";
6
10
  }
7
11
  catch(err) {
8
12
  console.log(err);
@@ -4,73 +4,27 @@
4
4
 
5
5
  <hr>
6
6
 
7
- <div class="chat-box" id="test-chat">
7
+ <h3>chat</h3>
8
8
 
9
- </div>
10
-
11
- <div class="chat-box" id="test-chat-2">
12
-
13
- </div>
14
-
15
- <div class="chat-box" id="test-chat-3">
16
-
17
- </div>
9
+ <div class="chat-box" id="test-chat"></div>
10
+ <div class="chat-box" id="test-chat-2"></div>
11
+ <div class="chat-box" id="test-chat-3"></div>
18
12
 
19
13
  <hr>
20
14
 
21
- <h3>memories Test</h3>
15
+ <h3>serve, memories and institution Test</h3>
22
16
 
23
17
  <button onclick="setTime()">Add</button>
24
18
  <p id="timer">0:00</p>
19
+ <p id="timer-g">0:00</p>
20
+ <p id="u">N</p>
25
21
  <button onclick="emailTime()">email</button>
26
22
 
27
23
  <hr>
28
24
 
29
25
  <button onclick="tradeForDoll()" id="trade">Trade 5g for a doll</button>
30
26
 
31
- <hr>
32
-
33
- <section class="floor" id="items">
34
- <h2>Items</h2>
35
- <button id="toggle">Toggle</button>
36
27
 
37
- <div class="content invisible">
38
- <ul class="items">
39
-
40
- </ul>
41
-
42
- <div class="editor">
43
- <div class="edit invisible">
44
- <h5>Item Name:</h5>
45
- <input type="text" id="name">
46
-
47
- <h5>Short Item Description:</h5>
48
- <textarea id="short" name="short" cols="30" rows="3"></textarea>
49
-
50
- <h5>Full Item Description:</h5>
51
- <textarea id="full" name="full" cols="30" rows="10"></textarea>
52
-
53
- <button id="cancel" onclick="itemFloor.cancelEdit()">Cancel</button>
54
- <button id="save" onclick="itemFloor.saveSelectedItem()">Save</button>
55
- </div>
56
-
57
- <div class="read">
58
- <h5 id="name">Item Name</h5>
59
-
60
- <h5>Short Item Description:</h5>
61
- <p id="short"></p>
62
-
63
- <h5>Full Item Description:</h5>
64
- <p id="full"></p>
65
-
66
- <button id="new" onclick="itemFloor.createNewItem()">Create New</button>
67
- <button id="edit" onclick="itemFloor.editSelectedItem()">Edit</button>
68
- <button id="delete" onclick="itemFloor.deleteSelectedItem()">Delete</button>
69
- <button id="refresh" onclick="itemFloor.updateItems()">Refresh List</button>
70
- </div>
71
- </div>
72
- </div>
73
- </section>
74
28
 
75
29
  <hr>
76
30
 
@@ -99,7 +53,8 @@
99
53
 
100
54
  if (paid) {
101
55
  bought = true;
102
- await playerInventory.change("Rag Doll", 1);
56
+ let received = await playerInventory.change("Rag Doll", 1);
57
+ if (!received) playerInventory.change("Gold Coin", 5);
103
58
  }
104
59
  else {
105
60
  $("#trade").removeClass("invisible");
@@ -108,15 +63,20 @@
108
63
  }
109
64
 
110
65
  let time = 0;
66
+ let gtime = 0;
111
67
 
112
68
  (async () => {
113
69
  let load = await memories.load("time", "/void/test");
114
- console.log(load);
70
+ let loadg = await establishment.load("time", "/void/test");
71
+ console.log(load, loadg);
115
72
  time = load.time;
73
+ $("p#u").text(`Last: ${loadg.u}`);
74
+ gtime = loadg.time;
116
75
  })();
117
76
 
118
77
  let setTime = async function setTime() {
119
78
  time = Date.now();
79
+ gtime = time;
120
80
 
121
81
  await memories.save("time", {
122
82
  time: time,
@@ -132,20 +92,38 @@
132
92
  arrray: [32, "sg", 45]
133
93
  }
134
94
  }, "/void/test");
95
+
96
+ await establishment.save("time", {
97
+ time: time,
98
+ u: "<%= user.username %>",
99
+ a: "dabfb",
100
+ bln: false,
101
+ numba: 4236,
102
+ arrray: [32, "sg", 45],
103
+ check: {
104
+ time: time,
105
+ a: "dabfb",
106
+ bln: false,
107
+ numba: 4236,
108
+ arrray: [32, "sg", 45]
109
+ }
110
+ }, "/void/test");
111
+
112
+ $("p#u").text("Last: <%= user.username %>");
135
113
  }
136
114
 
137
115
  let updateTime = function updateTime() {
138
- $("#timer").text(Math.floor((Date.now() - time) / 1000));
116
+ $("#timer").text(`Local: ${Math.floor((Date.now() - time) / 1000)}`);
117
+ $("#timer-g").text(`Global: ${Math.floor((Date.now() - gtime) / 1000)}`);
139
118
  }
140
119
 
141
120
  let emailTime = async () => {
142
- $.post("/coast/tall-beach/nono-cove/index/serve/emailTime", {
121
+ await commune("serveExplorer", {
122
+ script: "emailTime",
143
123
  toEmail: "wyattsushi@gmail.com",
144
124
  subject: "New Time Update!",
145
125
  html: `New Time: ${time}`
146
- }, (res) => {
147
- console.log(res);
148
- })
126
+ }, { route: currentRoute });
149
127
  }
150
128
 
151
129
  setInterval(updateTime, 1000);
@@ -0,0 +1,15 @@
1
+ export default async function emailTime(req, user) {
2
+ try {
3
+ await req.db.SendMail.send(
4
+ req.body.data.toEmail,
5
+ req.body.data.subject,
6
+ req.body.data.html
7
+ );
8
+
9
+ return "Sent";
10
+ }
11
+ catch(err) {
12
+ console.log(err);
13
+ return false;
14
+ }
15
+ }
@@ -2,11 +2,38 @@
2
2
  <html lang="en">
3
3
  <head>
4
4
  <meta charset="UTF-8">
5
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
- <title>Document</title>
5
+ <title>Test</title>
6
+ <meta name="viewport" content="width=device-width,initial-scale=1.0">
7
+ <script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
8
+ <link rel="preconnect" href="https://fonts.googleapis.com">
9
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
10
+ <!-- font-family: 'Roboto' or 'Roboto Condensed', sans-serif; -->
11
+ <link href="https://fonts.googleapis.com/css2?family=Roboto&family=Roboto+Condensed:wght@700&display=swap" rel="stylesheet">
12
+ <!-- 'Redacted Script', cursive; -->
13
+ <link href="https://fonts.googleapis.com/css2?family=Redacted+Script:wght@300&display=swap" rel="stylesheet">
14
+ <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
15
+ <link rel="stylesheet" href="/styles/main.css">
16
+ <link rel="stylesheet" href="/styles/menu.css">
17
+ <link rel="stylesheet" href="/styles/inventory.css">
18
+ <link rel="stylesheet" href="/styles/player.css">
19
+ <link rel="stylesheet" href="/styles/account.css">
20
+ <link rel="stylesheet" href="/styles/more.css">
21
+ <link rel="stylesheet" href="/styles/chat.css">
8
22
  </head>
9
23
  <body>
10
24
  Test hahahahahah
25
+ <button onclick="emailTime()">email</button>
11
26
  </body>
27
+
28
+ <script src="/js/commune.js"></script>
29
+ <script>
30
+ let emailTime = async () => {
31
+ await commune("servePages", {
32
+ script: "emailTime",
33
+ toEmail: "wyattsushi@gmail.com",
34
+ subject: "New Time Update!",
35
+ html: `New Time: 358970976`
36
+ }, { route: "/test" });
37
+ }
38
+ </script>
12
39
  </html>
@@ -1,8 +1,12 @@
1
- export default async function emailTime(db, route, user, params) {
1
+ export default async function emailTime(req, user) {
2
2
  try {
3
- await db.sendMail.send(params.toEmail, params.subject, params.html);
3
+ await req.db.SendMail.send(
4
+ req.body.data.toEmail,
5
+ req.body.data.subject,
6
+ req.body.data.html
7
+ );
4
8
 
5
- return "Sent"
9
+ return "Sent";
6
10
  }
7
11
  catch(err) {
8
12
  console.log(err);
@@ -0,0 +1,3 @@
1
+ export default async (req, user) => {
2
+
3
+ }
@@ -1,7 +1,93 @@
1
- <p>Hello</p>
1
+ <h1>The Big Check</h1>
2
+
3
+ <hr>
4
+
5
+ <h4>Creation</h4>
6
+
7
+ <p>Page Loaded: True</p>
8
+ <% if (user) { %>
9
+ <p>User: <%= user.username %></p>
10
+ <% } else { %>
11
+ <p>User: not logged in</p>
12
+ <% } %>
13
+
14
+ <hr>
15
+
16
+ <h4>Spirit World</h4>
17
+
18
+ <p class="info" id="spirit-world"></p>
19
+
20
+ <h5>Establishment</h5>
21
+
22
+ <p id="establish">not loaded</p>
23
+ <input type="text" id="establish" onkeyup="saveEstablishment(event)">
24
+
25
+ <h5>Memories</h5>
26
+
27
+ <p id="memory">not loaded</p>
28
+ <input type="text" id="memory" onkeyup="saveMemories(event)">
29
+
30
+ <h5>Serve Scripts</h5>
31
+
32
+ <button onclick="emailTime()">Email Wyatt</button>
2
33
 
3
34
  <hr>
4
35
 
5
36
  <a href="/the-front">
6
37
  Go to The Front
7
- </a>
38
+ </a>
39
+
40
+ <script>
41
+ let saveEstablishment = async (e) => {
42
+ let $send = $("input#establish");
43
+
44
+ if (e.key === "Enter") {
45
+ await establishment.save("test", {
46
+ line: $send.val()
47
+ });
48
+
49
+ $("p#establish").text($send.val());
50
+ $send.val("");
51
+ }
52
+ }
53
+
54
+ let loadEstablishment = async () => {
55
+ let load = await establishment.load("test");
56
+
57
+ $("p#establish").text(load.line);
58
+ }
59
+
60
+ loadEstablishment();
61
+
62
+ let saveMemories = async (e) => {
63
+ let $send = $("input#memory");
64
+
65
+ if (e.key === "Enter") {
66
+ let response = await memories.save("test", {
67
+ line: $send.val()
68
+ });
69
+
70
+ if (response.status === "success") {
71
+ $("p#memory").text($send.val());
72
+ $send.val("");
73
+ }
74
+ }
75
+ }
76
+
77
+ let loadMemories = async () => {
78
+ let load = await memories.load("test");
79
+
80
+ $("p#memory").text(load.line);
81
+ }
82
+
83
+ loadMemories();
84
+
85
+ let emailTime = async () => {
86
+ await commune("serveFront", {
87
+ script: "emailTime",
88
+ toEmail: "wyattsushi@gmail.com",
89
+ subject: "New Time Update!",
90
+ html: `New Time: From the Big Check!`
91
+ }, { route: currentRoute });
92
+ }
93
+ </script>
@@ -6,6 +6,13 @@
6
6
 
7
7
  <button onclick="emailTime()">email</button>
8
8
 
9
+ <input type="text" id="general">
10
+
11
+ <button onclick="newItem()">newItem</button>
12
+ <button onclick="deleteItem()">deleteItem</button>
13
+ <button onclick="playerInventory.change($('#general').val(), 3)">add Item to inv</button>
14
+ <button onclick="emailTime()">email time</button>
15
+
9
16
  <hr>
10
17
 
11
18
  <h3>Register Account</h3>
@@ -17,19 +24,9 @@
17
24
 
18
25
  <hr>
19
26
 
20
- <div class="auth-form" id="login-form">
21
- <h1>NotherBase</h1>
22
- <h3>Login to Your Account</h3>
23
- <input type="email" name="email" placeholder="user@email.com" id="login-email">
24
- <input type="password" name="password" placeholder="password" id="login-pass">
25
- <button id="login-button">Login</button>
26
- <button id="reset-password">Reset Password</button>
27
- <p id="login-info"></p>
28
- </div>
29
-
30
27
  <div class="auth-form" id="reset-form">
31
28
  <h1>NotherBase</h1>
32
- <h3>Login to Your Account</h3>
29
+ <h3>Reset your Password</h3>
33
30
  <input type="number" name="token" placeholder="Your Reset Code" id="token">
34
31
  <input type="password" name="password" placeholder="Type Your New Password Here" minlength="8" required id="password">
35
32
  <input type="password" name="confirmation" placeholder="Type Your New Password Here Again" minlength="8" required id="confirmation">
@@ -39,11 +36,7 @@
39
36
 
40
37
  <hr>
41
38
 
42
- <div class="locked to nother-base">
43
- Go to Nono Cove
44
- </div>
45
-
46
- <a href="/coast/tall-beach/nono-cove" class="invisible to nother-base">
39
+ <a href="/coast/tall-beach/nono-cove" class="to nother-base">
47
40
  Go inside
48
41
  </a>
49
42
 
@@ -53,8 +46,6 @@
53
46
 
54
47
  <script>
55
48
  let $resetPassword = $("#reset-password");
56
- let $loginButton = $("#login-button");
57
- let $loginInfo = $("#login-info");
58
49
  let $registerButton = $("#register-button");
59
50
  let $registerInfo = $("#register-info");
60
51
  let $changePasswordButton = $("button#change-password");
@@ -62,110 +53,61 @@
62
53
  let $toNonoButton = $(".locked.to.nother-base");
63
54
  let $toNonoLink = $(".invisible.to.nother-base");
64
55
 
65
- <% if (user) { %>
66
- $toNonoButton.addClass("invisible");
67
- $toNonoLink.removeClass("invisible");
68
- <% } %>
69
-
70
- $loginButton.on("click", async function () {
71
- try {
72
- await $.post("/user/login", {
73
- email: $("#login-email").val(),
74
- password: $("#login-pass").val()
75
- }, (data) => {
76
- $loginInfo.text("To your right you hear the sound of a bang against a chain-link fence. You've logged in.");
77
- $toNonoButton.addClass("invisible");
78
- $toNonoLink.removeClass("invisible");
79
-
80
- playerInventory.refresh();
81
- playerAttributes.refresh();
82
- accountServices.refresh();
83
- });
84
- } catch (error) {
85
- if (error.status === 401) {
86
- $loginInfo.text("Login Error: Email or password incorrect!");
87
- }
88
- else if (error.status === 500) {
89
- $loginInfo.text("Server Error: Try again later!");
90
- }
91
- }
92
- });
93
-
94
56
  $registerButton.on("click", async function () {
95
- try {
96
- await $.post("/user/register", {
57
+ await $.post("/s", JSON.stringify({
58
+ action: "register",
59
+ data: {
97
60
  username: $("#register-user").val(),
98
61
  password: $("#register-pass").val(),
99
62
  email: $("#register-email").val()
100
- }, (data) => {
101
- $registerInfo.text("Account registered.");
102
- });
103
- } catch (error) {
104
- //console.log(error);
105
- if (error.status === 400) {
106
- $registerInfo.text("Login Error: Username already taken!");
107
- }
108
- else if (error.status === 500) {
109
- $registerInfo.text("Server Error: Try again later!");
110
63
  }
111
- }
112
- });
113
-
114
- $resetPassword.on("click", async function () {
115
- try {
116
- await $.get("/user/password-reset", { email: $("#login-email").val() });
117
- $loginInfo.text("Reset link sent to your email.");
118
- }
119
- catch(err) {
120
- if (error.status === 401) {
121
- $loginInfo.text("Reset Error: Email not found!");
122
- }
123
- else if (error.status === 500) {
124
- $loginInfo.text("Server Error: Try again later!");
125
- }
126
- }
64
+ }), (data) => {
65
+ if (data.status === "success") $registerInfo.text("Account registered.");
66
+ else console.log(data);
67
+ });
127
68
  });
128
69
 
129
70
  $changePasswordButton.on("click", async function () {
130
- try {
131
- let token = $("#reset-form #token").val();
71
+ let token = $("#reset-form #token").val();
132
72
 
133
- await $.post(`/user/password-reset/${token}`, {
73
+ await $.post("/s", JSON.stringify({
74
+ action: "changePassword",
75
+ data: {
134
76
  token: token,
135
77
  password: $("#reset-form #password").val(),
136
78
  confirmation: $("#reset-form #confirmation").val()
137
- }, (data) => {
138
- $changeInfo.text("Password changed.");
139
- });
140
- } catch (error) {
141
- if (error.status === 498) {
142
- $changeInfo.text("Change Error: Your reset code expired! Please request a new one.");
143
- }
144
- else if (error.status === 400) {
145
- $changeInfo.text("Change Error: Passwords must match!");
146
- }
147
- else if (error.status === 404) {
148
- $changeInfo.text("Change Error: Reset code not valid!");
149
79
  }
150
- else if (error.status === 500) {
151
- $changeInfo.text("Server Error: Try again later!");
152
- }
153
- }
80
+ }), (data) => {
81
+ if (data.status === "success") $changeInfo.text("Password changed.");
82
+ else console.log(data);
83
+ });
154
84
  });
155
85
 
156
86
  let addGold = function addGold(params) {
157
- playerInventory.change(itemIDs[0], 2);
87
+ playerInventory.change("Gold Coin", 23);
158
88
  }
159
89
 
160
- let time = 0;
90
+ let newItem = async () => {
91
+ await commune("newItem", {
92
+ name: $("#general").val()
93
+ });
94
+
95
+ let items = await commune("getAllItems");
96
+ console.log(items);
97
+ }
98
+
99
+ let deleteItem = async () => {
100
+ await commune("deleteItem", {
101
+ name: $("#general").val()
102
+ });
103
+ }
161
104
 
162
105
  let emailTime = async () => {
163
- $.post("/coast/tall-beach/nono-cove/index/serve/emailTime", {
106
+ await commune("serveFront", {
107
+ script: "emailTime",
164
108
  toEmail: "wyattsushi@gmail.com",
165
109
  subject: "New Time Update!",
166
- html: `New Time: ${time}`
167
- }, (res) => {
168
- console.log(res);
169
- })
110
+ html: `New Time: 3 0976`
111
+ }, { route: currentRoute });
170
112
  }
171
113
  </script>
package/test-index.js ADDED
@@ -0,0 +1,5 @@
1
+ import NotherBaseFS from "./notherbase-fs.js";
2
+ import { fileURLToPath } from 'node:url';
3
+ const __dirname = fileURLToPath(new URL('./test', import.meta.url));
4
+
5
+ const notherBaseFS = new NotherBaseFS(__dirname);