jsonnull / alea Goto Github PK
View Code? Open in Web Editor NEWA groundbreaking online tabletop role-playing platform
License: MIT License
A groundbreaking online tabletop role-playing platform
License: MIT License
From this Firebase post:
"To get guaranteed chronological ordering, you probably shouldn’t rely on push IDs but instead use our ServerValue.TIMESTAMP feature"
This is a map of desired improvements to the /roll command for chat
/r
shortcutChat messages should be able to support basic markdown features (italics, bold, code).
In addition, there should be an emoji feature with an emoji picker.
Calling the unsubscribe function returned by props.data.subscribeToMore
should properly cancel subscriptions at the resolver level where they're created. Not doing so will leak running subscriptions each time they're instantiated, although Firebase may currently dedupe those subscriptions at the network level.
Right now the user.data
part of the state tree is required before the app finishes loading, because this contains the user's current session info.
Since the sessions revamp, the current session variable has been removed.
As such user.data
can be renamed to user.sessions
, and this can be lazy-loaded in the background.
I'll edit this shortly to expand on this. In short, want to incorporate some of the react-dev-utils.
Right now you can't edit your username
When focused on the input to send messages, using the up arrow on the keyboard cycles through previous messages, allowing you to use/modify recent rolls more quickly.
Down arrow performs the inverse of this if the user has used the up arrow to insert a previous message.
Unfocusing (blurring) the chat textarea resets this feature.
Currently user preferences load in the background after the app has finished loading. Unfortunately this means if you're using the dark theme, you'll get a flash of light screen after the app loads but before your preferences have registered.
To fix this, let's hold off on firing APP_FINISHED_LOADING
until a call to HYDRATE_USER_PREFERENCES
has been made.
Come to think of it, that won't work if the user is not logged in (preferences will not load), so we'll need to consider a way around this for the time being.
I see three major ways forward:
Allow duplicate display name text and use a tag to differentiate between duplicates in the client. Discord does this. Looks like Jason#1234.
Do not allow duplicate display name text and make display names first-come-first-serve. Using this strategy, we can still allow users to have a custom display name per game they are a member of. A complication with this strategy is that we would also have to consider allowing users to have a custom photo to accompany each username, which I do not think would scale well.
Just allow duplicate display names.
I'm looking forward to comments and further ideas.
Right now you can only how long ago a message was sent, but often you want to see when a user sent a message which was not recent.
If possible, add an alt
attribute to the messages relative time which displays the messages exact date and time on hover.
Some user preferences like selected theme should be set for each user device. This way if users want one experience on mobile and a different on desktop, there's no hassle.
Chat messages will not send after relogging
Messages need to check for game membership using the game's participants list.
Currently blocked by #77.
These currently live in frontend/firebase, but most or all of them are replaced by GraphQL resolvers. The old ones need to be removed.
Settings will become a separate page instead of a modal.
Settings page will have tabbed navigation with the following controls:
Since chatting and rolling are so frequent, it would nice to be able to focus the chat box automatically—I think receiving 'Enter' would be ideal.
One problem: We don't want enter to focus the chat if the user is editing something else.
I propose adding a variable to the redux UI state branch called isEditableFocused
, and creating two actions: { type: UI_EDITABLE_FOCUSED }
and { type: UI_EDITABLE_UNFOCUSED }
which will set isEditableFocused
to true and false respectively.
When isEditableFocused
is true, an 'Enter' key press will not focus chat.
To close it out, ensure that the generic Editable
component dispatches these actions when focused and blurred.
Missing features for the game view
Tracking issue for a static frontpage.
Currently the app is served at a single endpoint, /index.html
. The goal is to serve a statically rendered index.html
and direct logged-in users to a dynamic /app.html
.
The redirect/rewrite scheme will be this:
Server-side rewrites
/
-> /index.html
/*
-> /app.html
Breakdown for users and login state
/
-> User is served index.html
, follows links to access logged-in home (/games
)/*
-> User is served app.html
, app waits for login state and redirects to /login
if logged-outLogout endpoint needs to perform the user logout and redirect to home.
Sessions view is need of a visual overhaul as well as new features
I may have gone a little too deep on testing the first time! Snapshots update often and components change often, requiring tests to change every time a component changes.
Currently hero.png
lives in-repo, but I'd rather generate these images during the build process so they don't have to be in the repo.
Todos:
This is a tracking issue for the migration to Firestore.
Firestore is a beta NoSQL database provided by Firebase which offers support for collections, queries, and a variety of data types. I expect it to provide a better long-term developer experience and will open the door for more features to be added.
Todos:
When a Firebase connection is established, a set of the most recent chat messages are loaded and pushed into the Redux store.
This happens on load, but unfortunately also happens if the connection is reestablished, such as after a period of inactivity or if the internet connection is reset, meaning the messages are loaded and inserted into the Redux store, which already contains messages, resulting in duplicates.
A solution would be to prevent duplicate messages from being inserted in the reducer.
Currently the display name is empty if one has not been set, meaning messages in chat will not show a sender.
The display name can default to the email address the user registered with for the time being. In the future, this will need to be changed and the user will be required to enter a display name, for privacy considerations.
A tracking issue for multiple small details and bugs in the UI which need fixing.
When redirected to login, there's currently no intelligent redirect once a login completes.
There's a dangling reference in the codebase to a 'default.png' which no longer exists. This needs to be removed.
Login view is missing a lot of necessary features
Adding a generic tooltip component will help users to learn functionality of items in the user-interface by progressively revealing details and functionality which might not be otherwise apparent.
To keep games from being too full and keep performance expectations realistic, a limit should be imposed on the number of members which may have access to a game. I'm thinking 12 to start with, and leave open the possibility of raising this in the future.
There's been an error in the travis builds when running Flow:
Error: node_modules/protobufjs/src/bower.json:4
4: "version": /*?== VERSION */,
^ Unexpected token ,
I'm not able to reproduce as this particular bower.json dependency does not exist on my installation. I'm really not sure why this is here.
I've fixed this temporarily by removing the file in the before_script
section of the travis config. Hopefully this file goes away at some point and that config can be removed.
Since the app uses graphql now and a lot of internal state is no longer kept in redux, it's no longer useful to have the router location in the redux store. As such, we can remove react-router-redux.
Todos:
push()
actionRight now we're prone to errors on the frontend when fields are added and expected to be present. There needs to be a way for users/games to migrate their data forward when new fields are added.
The strategy going forward will be to have the API respond with defaults for fields which are not present. To enforce this, we'll re-use Flow types currently referenced on the frontend (DBUser
, DBProfile
, etc.) to type the defaults values.
When entire documents are not present, the API should attempt to write a full set of defaults and then return this value. If this fails, a more specific error can be sent to the client than doc does not exist
. I think this may only apply to user details like profiles, preferences, etc.
Add default types
Attempt to write defaults for users if not present
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.