Github user sebastianrothbucher commented on the pull request:
https://github.com/apache/couchdb/pull/251#issuecomment-46887185
Thanks for your great feedback so far!
@garrensmith : I've included your suggestions and added some small methods
to the editor component to achieve that (I stuck to them quite closely except
for one method for replacing the line)
@bradnoble : I would only open the editor when the JSON as such is valid
(actually thanks for pointing this out, I put in some more code to
double-check). Reason being that the string gets unquoted - and a wrong string
can yield surprising / unpredictable results and really mess up the JSON
editor. And indeed: icon-edit (fa-edit in FontAwesome) does look better, I've
include this one instead of the keyboard. So far I'm turning the icon into
disabled state when either several lines are selected or the cursor / selection
is on a line without a string.
Concerning the idea of putting the icon besides the line (somewhat like a
SmartTag in some office suites ;-) ): I'm not sure and I also have no real
opinion just yet (as e.g. the button would come closer but you start chasing it
like a SmartTag; as the button gets to where your eyes are but outside the
toolbar where buttons are not unexpected). Just not sure. Let me / let us all
put some more thought into this one
Besides: I have to figure out how to do this anyway (by positioning, by css
class like the error icon, by some other way, ...), so maybe we get some more
feedback on this in parallel
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---