Commit Graph

27 Commits

Author SHA1 Message Date
Elijah R
6fd6028a25 refactor display scaling again
- fix screen blanking bug
- turns out the timeout wasn't needed (only added it because I thought writing so many times was causing the above bug)
2024-04-10 21:28:58 -04:00
Elijah R
3b4d6ce6df minor bugfix in screen scaling 2024-04-10 19:03:17 -04:00
Elijah R
49f1daa634 add display scaling 2024-04-10 18:24:40 -04:00
Elijah R
17afad3dcd update dynamic strings on language change 2024-04-09 19:22:54 -04:00
Elijah R
c8b7b3e00a dogok banned for cause merge conflict 2024-04-05 17:32:16 -04:00
dakrk
72d0cbb37b
Fix indentation (consistent formatting CHALLENGE)
You people have a prettierrc yet never run prettier

tabs or spaces. WHICH IS IT
2 width or 4 width WHICH IS IT

(i'd make index.html 4 width tab but there's more that uses space there)
2024-04-05 17:16:20 +01:00
Elijah R
54255cc118 implement account authentication (webapp) 2024-04-05 09:11:21 -04:00
modeco80
999bdd0809 format fixes and unittest additions, translated document title
We also actually use our format utilities to set the title.
2024-03-16 18:57:19 -04:00
modeco80
0cef7194ce More i18n related updates
- More string keys
- Reworked string keys entirely
- Moved formatting into seperate typescript module
- Write unit tests using `jest` for the format module
- README improvements

Pirate language needs to be reworked and it should be a bit less painful now to actually add more string keys later on (eventually making the whole webapp strings lie inside the stringkeys)
2024-03-15 04:01:40 -04:00
modeco80
6327036283 Implement basic i18n
Not fully functional yet, so this won't/shouldn't be pushed onto the site yet (no language dropdown, there are still quite a few hardcoded strings that need to become string keys ...) but it works more than well enough to at least test and add more things as string keys that are currently hardcoded.

There are two languages provided, "en-us" and "pirate". Pirate is a test language to make sure all string keys are applying properly and all that.

As a bonus the new I18n system also offers a slightly less boneheaded way to do replacements, which is much more flexible than blind replace calls, and can take any type which is able to be stringified.

The parsing code for this is far from my best work, but it'll do for now, and seems to work okay (and has basic idiot proofing), so eh.

Supersedes #13.
2024-03-12 06:45:03 -04:00
modeco80
7691b84073 add Permissions#set
This avoids constructing a Permissions just to reset it, when we can just set it to nothing

Also contains some var->let or var->const work
2024-03-12 03:02:02 -04:00
modeco80
125e6a769d reformat typescript code with prettier
Mostly just for nicity. I did manually clean up a few things, but other than that, this basically was just importing configs from cvm3/crusttest, adding prettier as a dev dependency, and just ctrl-shift-I on every typescript file part of the codebase
2024-03-12 01:28:23 -04:00
modeco80
6dc3ba20af Remove most "as" casting
Since the places where this was being done actually typecheck now (thanks mostly to the nanoevent interfaces), we no longer need wonky "as U" casts anymore!
2024-03-12 01:18:39 -04:00
modeco80
4561eb1f63 Use nanoevents typing where possible
(this also fixes the use of a generic function type, where Nanoevents explciitly provides a cleaner type alias)
2024-03-12 00:10:24 -04:00
modeco80
3b4891c0a7 ok thank you javascript for not being a half baked language at all 2024-03-11 23:47:49 -04:00
modeco80
4dd5c42d55 Make CollabVMClient#send use typescript magic to allow passing any type
This allows passing any type (though practically, this is only ever going to include numbers) into it. This removes the need to constantly .toString() (though booleans are still kind of awful, but I guess we could factor that out somehow)
2024-03-11 23:40:43 -04:00
modeco80
72f321f689 Make admin opcodes a enum
just for typesafety. we're on typescript after all
2024-03-11 23:28:37 -04:00
modeco80
b59ebe2466 implement mouse wheel handling and clean up mouse handling in general 2024-03-11 21:24:40 -04:00
Elijah R
63902f6cdb fix logging in as mod 2024-02-04 13:02:45 -05:00
Elijah R
917109442e Implement admin login and features 2024-02-04 13:02:45 -05:00
Elijah R
d7d377fe53 implement vote-to-reset, screenshotting, and fix system messages 2024-02-04 13:02:45 -05:00
MDMCK10
795bf7bd01 fix merge conflict 2024-02-04 13:02:45 -05:00
Elijah R
b4559a3841 add turns and control 2024-02-04 13:02:45 -05:00
Elijah R
76ef47c5b2 chat and rename, half-working turn status. re-add crusty guac keyboard shit 2024-02-04 13:02:45 -05:00
Elijah R
33d16f4c2f Implement opening the VM, as well as viewing the screen, chat, and userlist. It's pretty much fully functional as a view-only client, next up is interaction 2024-02-04 13:02:45 -05:00
Elijah R
225f91f7a4 Basic VM list support. 2024-02-04 13:02:45 -05:00
Elijah R
f244ae412f Set up the source tree for the typescript rewrite. Nothing really here just yet, just filler 2024-02-04 13:02:45 -05:00