Folks,

The changecount macro and haschanged mechanism is built on Javascript and 
forms part of the core. Thus I am asking this question here for coders of 
JS, and with a deep tiddlywiki understanding.

   - I am wondering if it could be possible to reset the changecount on 
   tiddlers, according to a filter or per tiddler, thus I believe their 
   listing in haschanged will not occur?
   - If possible It would be nice to provide a mechanism where the export 
   process or a custom export button, can be set to do this automatically. 
   Perhaps it needs to be an action widget.
   - The change count can be reset by a save and reload, or a reload and 
   not save (loosing the changes) but this does not help.
   - I am willing to risk the fact the export may not complete, because in 
   part I can leverage local storage, and the export can be re-initiated.


*Why;*

Current Example: If I am building a package and I export the content say to 
a json file or plugin package, I would like to reset the change count 
because this indicates the tiddlers no longer need saving because they have 
being saved via an export. 

One strong use case it if a user is on a readonly wiki, such as where they 
do not have a suitable saver or access to save, eg github hosted/php hosted 
etc.. then they could fill out a survey. Once they export their survey 
answers, the they are not longer "unsaved" changes, I can reset the dirty 
indicator and they can leave the site without a warning, until then the 
dirty indicator will protect them from leaving the site before their 
changes are saved/exported.

A similar method may be used if the package of tiddlers are sent as an 
attachment by email (which I am yet to build)

*Possible issue*

   - I am not sure if the local storage plugin relies on this same 
   mechanism? However this could be a way to clear the dirty indicator for 
   items saved in local storage. 
   - Will this disrupt the save mechanisms?


Thank you for reading this. I would appreciate your help.
Regards
Tony

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywikidev/3d811561-ab49-4a21-8b6a-8d3f45dd6ae2o%40googlegroups.com.

Reply via email to