Coder Social home page Coder Social logo

prat's People

Contributors

bkad avatar cespare avatar marcia avatar mdietz avatar stevenguyenimpermium avatar ytamura avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

prat's Issues

Video embeds

Youtube, vimeo, etc.

I started doing this but then realized it's a pain in the ass because of how callbacks work with sundown.

Here's a regex for youtube.com links to get started:

r"(https?://)?(www\.)?youtube\.com/watch\?\w*v=(?P<id>[0-9A-Za-z+)\w*"

Alert user on new messages in other channels

Whenever a new message comes in on a channel you're not active in, do something like accent the border of that channel to quietly inform the user that there are new messages to be read

History fixes

Right now if you navigate to a different page and then navigate back, you'll get the view of the page when it loaded. subsequent messages will be appended, so you end up with a big gap of missing messages. You can reload the page to fix this.

We should use the HTML5 history API to fix this experience.

Need tests

This project needs tests. Right now, they would be valuable for the webserver code. The client code will likely become complex enough that you'll want coffeescript tests as well.

It sucks to work on a project when it's complex enough that you have no way of knowing that you're not breaking stuff.

Keep the window scrolled to the bottom

Right now, if I'm scrolled to the bottom and I make the window smaller, I'll be scrolled a little bit up. We should make the bottom "sticky"; i.e. if we're in "at the bottom" mode we should stay scrolled to the bottom if we resize the window.

Persona support

Mozilla's persona project allows for federated login support using an email address as the identifier for a user (and the identity assertion is backed by some clever public key crypto so this should be more secure than any kind of bearer token based federated login system).

http://www.mozilla.org/en-US/persona/

Quick send toggle

Allow the user to toggle between using Enter and Shift+Enter to send a message. Expose a little toggleable button to switch between the states.

Cleanup websocket file descriptors

Right now whenever you refresh, you leave behind websocket file descriptors in a CLOSE_WAIT state. You hit the file descriptor cap for a process pretty quickly, and the process crashes in a blazing fire.

Prat over SSL

This is important if we want to use Prat for any kind of corporate use. That way we can use it without VPN.

Channel switching scroll bug

There is a weird bug that occurs if you switch channels. After switching, it will be at the bottom of the screen, but if you use the scroll wheel at all you'll suddenly jump to the top.

replace jquery with zepto

Consider using zeptojs as a drop-in replacement for jquery.

In principle it seems nice because the library is smaller and drops support for older browsers.

link to room

create a /rooms/:name route
when a user navigates to it, it adds it to the list of the user's rooms and sets it as the current room

switch to pyzmq.green

Not quite released yet, but soon the functionality of gevent_zeromq will be merged into pyzmq

#foo should be a link to the channel foo

Turn #foo into a channel link. Clicking it will add it to your list of channels if it isn't already in your channel list, then sets it as your current channel.

running process to evict orphaned client_ids in redis

To determine whether a user is online, we track all their open clients in a redis sets (under key: user-clients:[email protected], adding and removing clients as they connect/disconnect.

It's possible, however, for a client to connect, and add their key to the open clients set, and then fail (due to a server shutting down, or some other error). In order to evict these orphaned client ids, one could run a separate process which sends hooks into the pub/sub system, sends pings to clients, who send back pongs which include their client ids. The process could then determine which keys are valid in the redis client pool and evict those which aren't.

Could be a nice chance to write some gevent code. Could have a master thread tracking all open clients, which spawns randomly offset X seconds from eachother and reaps a thread when the user the thread is tracking is has no open clients. Each child thread polls its open client pool every Y, sends pings, waits Z seconds, then evicts all client_ids which didnt send a pong.

Keyboard shortcuts

We'll need a keyboard shortcut help dialog of some kind as well.

Some initial ideas: (ctrl on linux/windows, cmd on mac)

  • j/k to scroll the message pane up and down
  • ctrl-u/d to scroll up and down by half a page
  • G to scroll to the bottom
  • ctrl-n/p to switch next/previous channel
  • ? open keyboard shortcut help
  • enter to focus the text box
  • Typing anything that isn't a shortcut on the page also focuses the text box?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.