Giter VIP home page Giter VIP logo

Comments (11)

karger avatar karger commented on August 23, 2024

presumably history/undo is in the pipeline, at which point revert may be
less important

On 2/25/2016 9:59 PM, Lea Verou wrote:

Currently, pressing saves returns the user to read mode. However,
since editing is now global, it makes sense that the user would want
to save often, without necessarily concluding their editing.
Therefore, Edit should become a toggle between edit and read mode, and
save should do nothing more than save.

Then we can also move the saving progress indicator to the save
button, and maybe in the future have autosave.

The only wart is, now what does cancel do?
The easiest to implement option would be that it just discards any
unsaved changes. If they enabled autosave, well, tough luck. This is
probably what we'll do initially. And rename it to "Revert", obvs.


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39.

from mavo.

karger avatar karger commented on August 23, 2024

there's also the google docs model, which is that every operation is
persisted (unless there's a network failure etc.). There's no explicit
save. Then you navigate through history if you want to revert something.

On 2/25/2016 9:59 PM, Lea Verou wrote:

Currently, pressing saves returns the user to read mode. However,
since editing is now global, it makes sense that the user would want
to save often, without necessarily concluding their editing.
Therefore, Edit should become a toggle between edit and read mode, and
save should do nothing more than save.

Then we can also move the saving progress indicator to the save
button, and maybe in the future have autosave.

The only wart is, now what does cancel do?
The easiest to implement option would be that it just discards any
unsaved changes. If they enabled autosave, well, tough luck. This is
probably what we'll do initially. And rename it to "Revert", obvs.


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39.

from mavo.

LeaVerou avatar LeaVerou commented on August 23, 2024

Yes, it's in the pipeline :)

If the backend supports revisions (e.g. Dropbox, Github) we can even offer a UI for going through their history.

from mavo.

karger avatar karger commented on August 23, 2024

And if the back-end doesn't support revisions, we could store a
representation of the complete history (sequence of modification) in the
json file. Even if revisions are supported in theback end, we may get
more power with our own representation than when we rely on the back end.

On 2/25/2016 10:15 PM, Lea Verou wrote:

Yes, it's in the pipeline :)

If the backend supports revisions (e.g. Dropbox, Github) we can even
offer a UI for going through their history.


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39#issuecomment-189091490.

from mavo.

LeaVerou avatar LeaVerou commented on August 23, 2024

Why would we do that? If they want revisions, they can choose a backend that supports revisions. Reinventing that particular wheel ourselves seems neither interesting, nor fun. Unless you have some idea in mind about how we could do it better…

from mavo.

karger avatar karger commented on August 23, 2024

the advantage of doing it ourselves is that we know the semantics. we
can represent diffs in terms of additions, deletions, and edits of
fields, as opposed to changes in lines of a mysterious json file. Not
important for actually "checking out" a revision, but may be super
useful for comparing differences (and finding the particular revision
you want).

May not be hard to implement, using someone else's history library.

On 2/25/2016 10:28 PM, Lea Verou wrote:

Why would we do that? If they want revisions, they can choose a
backend that supports revisions. Reinventing that particular wheel
ourselves seems neither interesting, nor fun. Unless you have some
idea in mind about how we could do it better…


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39#issuecomment-189095722.

from mavo.

LeaVerou avatar LeaVerou commented on August 23, 2024

Probably easier to parse the diff than reimplement history.

Also, if we ever implement my "suggest edit" idea, we'd need to parse diffs anyway, to present the suggested edits (i.e. what would be a pull request behind the scenes).

from mavo.

karger avatar karger commented on August 23, 2024

parsing diffs will be messy and error prone, whereas recording each
change as we make it should be easy. and if we have that history
record, we can use it to build the suggested edits.

But, this is all in far future and not worth deciding now .

On 2/25/2016 10:38 PM, Lea Verou wrote:

Probably easier to parse the diff than reimplement history.

Also, if we ever implement my "suggest edit" idea, we'd need to parse
diffs anyway, to present the suggested edits (i.e. what would be a
pull request behind the scenes).


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39#issuecomment-189098339.

from mavo.

LeaVerou avatar LeaVerou commented on August 23, 2024

That will not work with pull requests, as we cannot update the main file.
We can of course save it as part of the pull request, but it gets really messy.

from mavo.

LeaVerou avatar LeaVerou commented on August 23, 2024

Actually, we don’t need to parse or store anything. If all we want is a visual indication of changes, we can just apply the new version of the file and highlight the properties that now have different values, in some kind of special mode.

from mavo.

karger avatar karger commented on August 23, 2024

very elegant!

On 2/25/2016 11:11 PM, Lea Verou wrote:

Actually, we don’t need to parse or store anything. If all we want is
a visual indication of changes, we can just apply the new version of
the file and highlight the properties that now have different values,
in some kind of special mode.


Reply to this email directly or view it on GitHub
https://github.com/LeaVerou/wysie/issues/39#issuecomment-189102863.

from mavo.

Related Issues (20)

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.