ellatrix / focus

Focus!
21 stars 5 forks source link

Dim the media/editor/mode controls when actively typing #21

Closed markjaquith closed 10 years ago

markjaquith commented 10 years ago

Right now the media button and the editor controls and the mode (visual/text) controls are the most "visible" elements when you're composing a post. Even when you're just typing away. I don't think they need to be this "in your face" all the time. Can we dim them like we dim the site toolbar when the user is just typing, but bring them back upon ANY mouse movement, or on any text selection (which could indicate they want to link/bold/whatever something)? I would love to just be able to type type type without all those buttons staring at me so brightly.

ellatrix commented 10 years ago

Haha, how dare they be in my face all the time.

I'll come back to this tomorrow. It works nicely but we'll have to use a separate overlay for each of those areas to make it visually okay. There's a line between the tabs and toolbar. :/

https://cloudup.com/cPv4qhfqkTF

ellatrix commented 10 years ago

It looks like any kind of scroll (programmatic/manual) triggers a mousemove event, at least on a mac. So if you're typing and the editor scroll with the text, the toolbars fade in an out...

ellatrix commented 10 years ago

Hm, and simply caching the pageX|Y or clientX|Y from the event won't work inside the editor since the whole iframe moves (and technically all the coordinate change, though not relative to the main window). We could use look at the position of the iframe, but that's way too expensive for a mousemove event.

ellatrix commented 10 years ago

Reopened because this might cause a bit too much movement.

markjaquith commented 10 years ago

We rolled this back. I retract my brightness complaints.