New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better support for read-only vs. edit modes #1213
Comments
👍 that reads like a very nice draft |
ok |
+1 Great idea. The design science department of my university will use tw5 as website now (in combination with taskgraph) and a readonly theme would be great (we could use it as prototype for our own read only theme). I will report back some ideas when we start building a read only theme. Also some tiddler actions need to be hidden in read only (clone tiddler etc.). Regards |
I just noticed it is really confusing when a a website user is asked to create a tiddler if it doesn't exist in read only mode. edit sorry I see it is already on the list (the last point) |
IMO read only mode TWs need to check the "missing" tab prior to publishing to prevent this behaviour. ... So there is some more work + knowledge + responsibility left for the editor. |
I think the best solution to making it impossible to navigate links to missing tiddlers might be to not render them as links, but as static text. |
I was just about to propose supporting exporting to an read-only html and found this. I really like it! |
This would really bring TiddlyWiki to a new level. Has there been any updates on this issue? |
Hi @lukehsiao no updates as yet, no. Too much to do! |
Fair enough. For now, one workaround I've been using is to set the theme as ReadOnly, save the TiddyWiki, then afterwords, edit the HTML file to include this tiddler to have the sidebar hidden by default: <div created="[timestamp]" creator="[author]" modified="[timestamp]" modifier="[author]" title="$:/state/sidebar">
<pre>no</pre>
</div> Then I host this file on my public server. Although it still allows viewers to get to the functions if they try, people rarely notice the small '<<' for the sidebar and happily navigate around the Wiki as if it was read-only. |
Hi @lukehsiao there is another trick you can use: make a custom "save changes" button that also adjusts the sidebar state:
|
Dear @Jermolene, That's a very neat trick! What about adding a tiddler to TW.com called saving to read only mode |
@Jermolene I'd love this sort of button. However, I'm admittedly not familiar enough with TiddlyWiki yet to know where I should place that code. Can you give me a pointer? |
Just place it in any tiddler. Then open that tiddler when you want to press that button. You can also tag that tiddler appropriately if you want to place it in the sidebar for example |
@danielo515 So to accomplish the same thing I was doing above, I believe my button should be:
However, when I click this button, I see the sidebar disappear and it saves the Wiki, but when I open the wiki again, the sidebar is visible. It doesn't seem to properly make it not visible be default. |
Yes, that is correct. How is the TW saved? By downloading it as a new copy or overriding the current tiddler one? Please note that maybe you unhide the sidebar and save again. |
@lukehsiao [1] https://groups.google.com/forum/#!msg/tiddlywiki/hF30Y9WD9lE/YbZHrUK_c2kJ |
I made a simple server example that allows editing only when login via Gitlab https://github.com/linonetwo/try-passportjs-gitlab-tiddlywiki I think "edit" means "allow saving to the fs", and "read-only" means "you can edit on-page but not affecting the fs", is enouth. |
Hi @linonetwo that's great, very handy for some common usecases |
Currently, support for read-only mode is limited to a theme that hides some of the editing apparatus. It's a clumsy arrangement:
It is proposed to replace the current implementation with a new system whereby:
$:/mode
)<$reveal state="$:/mode">
In view mode the following features would be hidden or disabled:
The text was updated successfully, but these errors were encountered: