Open krkartikay opened 3 years ago
By "Cannot scroll", do you mean literally using the scroll wheel?
Currently the canvas is virtually limitless by clicking/touching and dragging.
I am curious about adding a scrollbar, and how feasible that might be. At first thought, I think it might add needless complexity to the app: I'm thinking it needs to be able to drag to new areas on the canvas, but scroll to established areas on the canvas? Also, I'm worried about issues related to gigantic canvases that are mostly off-screen; might be able to be solved just by adding dummy elements surrounding the canvas which vary in size, but that still seems complex to me.
Thoughts?
Oh, I didn’t try dragging. That would be more natural on a phone, perhaps; but I’m on a laptop and I assumed the page would scroll down as I reached the bottom and pressed enter, without using the mouse (like it happens in Notepad or MS Word).
So maybe we could add that feature, page scrolls down automatically as you hit the bottom, or maybe the issue here is discoverability of the scroll action?
yeah that's good to know. I think scrolling is expected behaviour, so I think it is a good feature to add; I'm only concerned with finding a simple solution for it. This isn't really a text editor, more of a text editor simulator! :)
I'll give it some more thought.
Loosely related to #56
What are your thoughts on always centering text? That more closely aligns with how a typewriter works. Though, I want a happy medium where we can prioritize UX also.
Well I think that’s also an interesting and fun idea, to move the page instead of the cursor. It would certainly look cool, but you’re right that we will have to do it in a way that doesn’t compromise UX.
In my case, I was just trying to find a site that would let me write distraction free while giving me the feeling of typewriting on a paper. So that I could write something and “throw it away” without worrying about anyone else reading it. (or maybe save it for some later day). Also I really like the creative limitations of a typewriter, like not being able to erase stuff and having to write slowly which makes you think more before writing.
So as long as centering the text wouldn’t make it harder to write I’d be happy to see it implemented. I haven’t seen the code yet so I don’t know how difficult it would be to implement it, but I would be happy to help if I can.
I did a big revamp of the codebase recently, so hopefully it's less haphazard than it was (started as a single-file codepen).
I'll try to find some time to demo the centered cursor; even that seems like a lot of re-rendering. currently it only has to add the new character. moving the entire canvas with each keypress means a lot more work. I might need to do a performance check too to see if it's easier to copy the canvas as an image instead of wiping and re-typing all the characters... 🤔
Browser: Latest version of Google Chrome on Windows
The paper is finite. It severly limits the usefulness of the app. I would have used it as my online journal if it wasn't the case.
Please fix this issue if you get time :)
P.S. Thank you for building this wonderful app!