Commit Graph
100 Commits
Author SHA1 Message Date
Taso 4e7e6b3e92 fix(client/marketplace): Fixed typo preventing listings from being sent 2021-03-22 14:44:34 -04:00
Taso 0f61088999 refactor(events): Events are now tied to a common enum typings (#167)
* chore(scripts/twitter): Refactored twitter to use event enums

* chore(scripts/marketplace): Refactored marketplace to use event enums

* chore(scripts/messages): Refactored messages to use event enums

* chore(scripts/contacts): Refactored contacts to use event enums

* chore(scripts/calls): Refactored calls to use event enums

* chore(scripts/notes): Refactored notes to use event enums

* chore(scripts/photos): Refactored photos to use event enums

* chore(scripts/bank): Refactored bank to use event enums

* chore(scripts/phone): Refactored phone to use event enums

* chore(events): Removed old events object

* refactor(phone/nui-events): Attached NUI events to respective enum

* tweak(event-enums): Added npwd prefix to all events

* tweak(phone/serve): Added craco to override CRA without eject

Also bumped react-scripts to 4.0.1, with seemingly no issues

* fix(typings/twitter): Fixed method enums for twitter
2021-03-22 13:37:07 -04:00
Taso 2a4457b323 feat(phone/settings): Schema validation & Reset Settings
You can now reset your settings to default using the action in the Settings App

Setting schema validation has been added that will temporarily reset to default settings if
the JSON string contains unexpected values. A alert will pop up informing the user
that they should reset to default settings using the action in the settings app,
as a permanent solution.
2021-03-20 12:57:22 -04:00
Taso a2c0f94bd8 fix(whoops): Forgot to remove the string-parser change from last commit 2021-03-17 20:27:25 -04:00
Taso e8d28359a9 chore(server): Bumped deps & tweaked build
We are now ignoring the Cardinal and parse-connection-string warnings
that used to pop up after build.

Deps were bumped using standard `yarn upgrade`
2021-03-17 20:11:37 -04:00
Taso 67b557b7c3 fix(phone/sourcemaps): Add .map to client files 2021-03-17 17:36:45 -04:00
Taso 4b29cbbce3 fix(phone/home): Fixed incorrect props for Grid item 2021-03-17 13:59:53 -04:00
Taso 06137d77ad fix(phone/notifications): Fixed error when setting for app is not defined 2021-03-17 13:55:45 -04:00
Taso 279778e4f3 tweak(phone/webpack): Generate source maps 2021-03-17 11:18:37 -04:00
Taso f1f6a05981 tweak(dialer): Several fixes and improvements
Time has been changed to a relative format. Locale specifics are pending
merge of #168.

Several typos have been fixed where "DAILER" was referenced instead of
"DIALER"

A translation key was added for when a user has no call history.

The input box has been unlocked so users can use their keyboard directly
rather than using the dial pad.
2021-03-17 10:26:52 -04:00
Taso a6e8c769c0 feat(locale): Added a locale setting in Settings app
This removes the need to rebuild the phone in order to change language
2021-03-17 10:24:28 -04:00
Taso 1ecdb7a4a8 fix(locales): Fixed Bosnian Alpha-2 code 2021-03-16 21:14:52 -04:00
Taso d5d483eee8 tweak(phone/settings): Enabled copy and paste for number 2021-03-16 17:56:40 -04:00
Taso ef30daeb65 fix(phone/twitter): Altered transform on ShowMore
I wasn't sure what the comment was referring to, but changed this to a
standard top offset, and it fixed a issue with the transform being
screwed up between tweets.
2021-03-16 17:45:54 -04:00
Taso 19e228894d tweak(phone/settings): Added streamer mode desc 2021-03-16 17:31:41 -04:00
Taso a244183976 fix(server/types): Fixed type on Tweet create sql resp 2021-03-16 16:24:27 -04:00
Taso e01057d818 refactor(server/tweets): Slight tweaks to twitter handling on server 2021-03-16 16:24:27 -04:00
Taso 9ffca0d14e chore(server/messages): Type create message response 2021-03-16 16:24:27 -04:00
Taso 1a9c21f89d fix/cleanup(server/twitter): Fix for fetch after tweet & gen cleanup 2021-03-16 16:24:27 -04:00
Taso 3031e650e3 cleanup(server/marketplace): General cleanup of marketplace
Tweaked SQL tables to reference 'marketplace' and not 'sellout'

Removed if/else in favor of if/return
2021-03-16 16:24:27 -04:00
Taso 23ef9b8cd6 chore(server/photo): Added try/catch to missing sql query 2021-03-16 16:24:27 -04:00
Taso 598bcd2eb3 chore(server/notes): Removed redundant pSource call 2021-03-16 16:24:27 -04:00
Taso 78961b788f tweak(server/messages): General cleanup changes and added missing docs
I personally don't like if else chains, so changed to if checks
2021-03-16 16:24:27 -04:00
Taso adf9758d9f tweak(server/calls): Tweaked call handling
Added Sanity checks

Switched timestamp creation to server
2021-03-16 16:24:27 -04:00
Taso ff0e75d82b fix(phone/bank): Fixed transactionList 2021-03-15 12:06:39 -04:00
Taso f0c5e5101e chore(typings): Moved common typings to root dir 2021-03-14 15:19:30 -04:00
Taso 378830245d chore(server/players): Removed unused imports & misc debug logs 2021-03-14 15:07:04 -04:00
Taso b8ef6b1695 Merge pull request #155 from project-error/tweak/remove-esx-code
feat(standalone): Allows for the phone to be free from framework requirements
2021-03-10 21:50:55 -05:00
Taso 08e477f360 tweak(server/players): Commented getPlayers command for debug 2021-03-10 21:49:10 -05:00
Taso 044f5ba39c chore(server/players): Unused import cleanup 2021-03-10 21:44:00 -05:00
Taso 7fd02913da Revert "tweak(server/player): Added regex replace to getIdentifierByPhoneNumber"
Reverted as to ensure current compatibility with messages app, messages
should be altered to deal with this in the future.

This reverts commit 258ea66746.
2021-03-10 21:27:21 -05:00
Taso b0e5458504 refactor(server/discord): Refactored Discord reports to use webhooks (#158) 2021-03-10 21:10:34 -05:00
Taso c6bdf4b331 fix(sellout/report): Fixed sellout discord reports 2021-03-10 21:04:59 -05:00
Taso 1801255c04 fix(server/players): Fixed public name setters 2021-03-10 17:21:36 -05:00
Taso 6dd57beae5 fix(server/players): Fixed getIdentifierFromPhoneNumber 2021-03-10 22:18:27 +00:00
Taso e20e39728a tweak(server/player): Debug tools 2021-03-10 16:44:32 -05:00
Taso 258ea66746 tweak(server/player): Added regex replace to getIdentifierByPhoneNumber
Added a regex replace to match the old signature for this function. Also
migrated messages to use the new util function rather than a locally
defined query
2021-03-08 20:35:25 -05:00
Taso 6e9c3e6d1a enhance(server/player): Several enhancements
Attach a readonly username property to Player class

Implement setters/getters for Player class to ensure future
compatibility for servers who implement a character switching system

Attach a fetch argument to getIdentifierByPhoneNumber that will force a
DB query if player is not online
2021-03-08 20:18:20 -05:00
Taso e5fac800ee refactor(server/player): Added player management system internally
This system stores loaded players in maps handled entirely by NPWD.

This should entirely remove the ESX dependency on practically everything.
2021-03-08 18:43:21 -05:00
Taso 7d233a9efa tweak(sql): Added default twitter avatar to import.sql 2021-03-08 16:22:19 -05:00
Taso 8116dd074d tweak(ci): Small tweaks to job names 2021-03-07 13:19:57 -05:00
Taso 6e72e2c50e fix(phone/snackbar): Fixed animations & simplified logic (#146) 2021-03-06 17:32:01 -05:00
Taso 605f957f9a feat(client/debug): Phone restart command (#145)
Trigger a UI restart by entering the command `phone:restart` in the F8 console.
2021-03-06 10:38:10 -05:00
Taso f4834b78c8 tweak(phone/sound): Removed howl instance console log on ready 2021-03-05 18:05:18 -05:00
Taso b303e648df tweak(phone/debug): Set default data property for mockNuiEvent 2021-03-05 17:09:09 -05:00
Taso 6419245d93 Revert "feat(phone/settings): Add localStorage settings schema validation (#139)"
This reverts commit cb5a00e57e.
Reverted due a non-descript bug in CEF. Will be reapplied after fix.
2021-03-05 12:38:22 -05:00
Taso da5694863a tweak(sql): Moved import.sql to resource root 2021-03-05 11:45:11 -05:00
Taso 60431d2de7 tweak(phone/settings): Altered localStorage key 2021-03-05 10:31:37 -05:00
Taso 5c9c75c36c tweak(phone/snackbar-provider): Altered API to expect a string for message, not a key (#135)
Change SnackbarProviderAlert message property to allow for any string rather than a explicit translation key
2021-03-04 22:40:17 -05:00
Taso 42d3d573cb tweak(phone/sentry): Only enable in prod 2021-03-04 17:24:14 -05:00
Taso b2e3698936 fix(phone/settings): Fixed incorrect setting ref for localStore 2021-03-04 11:33:25 -05:00
Taso eae06b2dc6 tweak(phone/settings): Added a SettingItemIconAction component
Currently used for phone number
2021-03-04 11:33:25 -05:00
Taso 140a28bef7 tweak(phone/default-settings): Set default twitter noti volume to 50% 2021-03-04 11:33:25 -05:00
Taso 58868f3644 fix(phone/context-menu): Fixed issue where backdrop was fixed height 2021-03-04 11:33:25 -05:00
Taso 924d17c2f6 tweak(phone/context-menu): Lock scroll when context menu is open 2021-03-04 11:33:25 -05:00
Taso 64c4e0ec16 enhance(phone/settings): Added labels to settings and misc cleanup
This change alters the default localStorage schema, please clear your localStorage cache for testing
2021-03-04 11:33:25 -05:00
Taso 41b50d6429 tweak(phone/utils): Moved isImageValid util to common dir 2021-03-03 22:19:59 -05:00
Taso 18c1676c01 tweak(phone/utils): Refactored image validation to promise from cb 2021-03-03 22:19:59 -05:00
Taso e330b89889 tweak(phone/debug): Restricted global mockNuiEvent to dev env
Probably a good idea so we don't forget
2021-03-03 22:04:20 -05:00
Taso b6352ccf82 feat(phone/debug): Added a global window dispatch method
See JSDocs for usage details.
2021-03-03 21:48:45 -05:00
Taso 52992b7d10 chore(client): Removed unused variables 2021-03-02 13:54:32 -05:00
Taso 95866cc51c tweak(server/logging): Added try catch and logging to calls fetch 2021-03-02 13:42:37 -05:00
Taso 187e534e08 chore(dependencies): Cleaned up dependencies/package.json 2021-02-17 14:43:12 -05:00
Taso 17f5fb62d9 fix(client/photos): Fixes #98 2021-02-16 17:52:57 -05:00
Taso 513407249a feat(client/net): Promisfied net events (#95) 2021-02-16 17:31:22 -05:00
Taso 9e648d858b Use callback optimizations 2021-02-14 23:20:39 -05:00
Taso 68360e7619 feat(phone/useSound): Initial useSound implementation 2021-02-14 23:16:09 -05:00
Taso 1aa6a383ab refactor(server/source-handling): Altered how we handle source
These changes are made in case source is not guranteed to remain the same

Due to how JS should operate, this shouldn't be an issue but this just ensures that
2021-02-14 20:17:41 -05:00
TasoandChristopher Gjelten 211576e237 feat(server/debug): Added initial implementation of new Logger (#84)
- Logs out to a file w/ relevant meta data
- Provides better readability for end user

This should help provide better troubleshooting for both
development and end users.

This also fixes any previous catches that were attempting to print stack traces,
causing the [object Object] message to appear.

Co-authored-by: Christopher Gjelten <[email protected]>
2021-02-14 17:28:13 -05:00
Taso 1f07a469d8 Merge branch 'master' into enhance/debug 2021-02-14 17:15:01 -05:00
Taso 992719980a Merge pull request #83 from project-error/cleanup/game-scripts
Cleanup/game scripts - Misc. cleanup of game scripts
2021-02-11 16:51:28 -05:00
Taso e1f409fed3 fix(scripts/typings): Fixed reference to changed type 2021-02-11 16:40:01 -05:00
Taso 587185535f fix(phone/anim): Added missing phoneClose anim to handler 2021-02-10 17:46:46 -05:00
Taso 8f78423591 Merge branch 'master' into cleanup/game-scripts 2021-02-10 16:31:00 -05:00
Taso 9486fb69b9 chore(phone/nui): update for cerulean fxversion 2021-02-10 16:29:28 -05:00
Taso f0a2d8c77e refactor(phone/visibility): Improved organization of visibility flow 2021-02-10 14:25:00 -05:00
Taso 368a8c57f8 optimize(scripts/anims): Optimized and organized open/close animations 2021-02-09 18:45:48 -05:00
Taso 47e1f2950e fix(scripts/nui-callbacks): Fixed NUI callback stalls 2021-02-09 18:43:54 -05:00
Taso 6b21cfddd0 cleanup(scripts/cl_photo): Cleaned up code 2021-02-09 18:16:04 -05:00
Taso b73919c147 fix(phone/tweet): Fixed possible XSS vector
As we were parsing user input for \n in order to convert to <br> tags, a XSS vulnerability was introduced allowing for users to pass arbitrary script tags to be rendered in tweets.
2021-02-09 11:14:52 -05:00
Taso c0509be2d1 Refactored Contacts to use Routes and not a Modal (#80)
The new route allows for other components to directly route to contacts/:id, where id is the contact id for a users given contacts. It also adds a getContact function accessible by the useConfig hook in case a contact needs to be retrieved using a contact id.
2021-02-09 09:59:54 -05:00
Taso cd9e9e820c chore(readme): updated with dev tools instructions 2021-02-08 23:15:34 -05:00
Taso 9dfff30224 feat(build): One command to build both phone and scripts
To build for both scripts run yarn build in root
2021-02-08 23:04:06 -05:00
Taso f39ed37e73 chore(phone/build): Removed unnecessary files 2021-02-08 23:02:25 -05:00
Taso 7b6d49f661 feat(phone/webpack): Allow for use of react-devtools in game
This is dynamically added to the bundle depending on the environment. In production, react-devtools will not be bundled. Build a development bundle using `yarn build:dev`
2021-02-08 23:00:33 -05:00
Taso 5d3fad36f7 chore(phone/twitter): Allow for use of Twitter in browser 2021-02-08 15:11:47 -05:00
Taso 9dd47a2a43 fix(lol): lol 2021-02-08 13:53:42 -05:00
Taso 1ac3d89f59 fix(resources/calls): Fixed save call not saving identifier 2021-02-06 20:02:40 -05:00
Taso f626d1b0ce fix(resources/calls): invalid sql syntax 2021-02-06 19:56:48 -05:00
Taso 447c51a07e Feat/inject debug - Use new abstraction to clean up debug data (#70)
* feat(phone/debug): Inject debug data for development

* refactor(phone/debug): Refactored mock data to InjectDebugEvents

* fix(phone/debug) removed useless debug injections
2021-02-06 16:00:09 -05:00
Taso 686b86acf9 Merge pull request #68 from project-error/fix/zoom
Fixed issues with using non standard `zoom` css property
2021-02-06 13:38:05 -05:00
Taso 263275b921 tweak(phone/app-grid): Tweaked tooltip styling 2021-02-06 13:32:43 -05:00
Taso 7e9c1d0f35 fix(phone/apps): Fixed locales for apps 2021-02-06 13:18:06 -05:00
Taso fd2aac31a0 chore(resources): Removed unnecessary true in watch script 2021-02-04 00:48:47 -05:00
Taso ea2fcdba00 chore(resources): Removed random lua file 2021-02-04 00:42:53 -05:00
Taso d0de0e4bac Feat: Lerna integration with husky for precommit checks (#57)
* feat: Lerna integration with husky

* Lint-staged integration

* tweak(ci/cd): Removed prettier integration

* Added lint-staged to precommit hook call

* tweak: removed git add from lint-staged

* tweak(gitignore): Removed package.json from ignore
2021-01-18 15:17:41 -05:00
Taso 8a2f281790 enhance(phone): useNuiEvent types and integrated DebugLogger 2021-01-17 15:49:22 -05:00
Taso a8deb8b578 feat(call): More progress 2021-01-17 20:10:33 +01:00
Taso ec1451a9aa Fix: prettier config in resources\ not being standard. 2021-01-13 20:36:03 -05:00
Taso d56112a0cb Feat: Debug logger 2021-01-13 20:31:14 -05:00