Content-only view

  • 1/21/2020 10:08:23 AM by KinaUna
  • 1 comment

I am embedding the docs in a mobile or desktop app, as part of the help functionality within the app.

One could obviously just copy the content, but then you will have to edit the app data every time you update a document.

It works as it is, you can use a web view to show the document, but the menus, headers, footers and widgets can make it look very cluttered on a mobile device.

So, I think it would be great to have a way to just display the content of a doc or article, kind of like the full screen editor.

1 comment

Ryan Healey posted 2/2/2020 5:18:10 PM

Hi Kina,

Thank you so much for your suggestion.

This should actually already be possible with Plato 1.0.9 or above. We use a similar approach within our Plato Desktop app.

The basic steps would be...

Create a new Minimal theme (copy the Default theme folder and rename to "Minimal")...


Open up \Minimal\theme.txt and change the name from Default to Minimal. Save theme.txt.

Update the \Minimal\theme.css to hide the header, sidebars etc.

.layout-asides { display: none !important; }

Please note I've not tested this CSS so should you encounter any issues please don't hesitate to respond here.

To force your winform or UWP webview control to use the new Minimal theme created above you can set a request header named "X-Plato-Theme" with a value of "Minimal" with your request. For example with a UWP web view this would be...

var requestMsg = new HttpRequestMessage(HttpMethod.Get, "");
requestMsg.Headers.Add("X-Plato-Theme", "minimal");

The logic for which theme Plato should load can be found within our ThemeSelector implementation here...

For security reasons we don't allow arbitrary theme names so you would likely need to modify the switch statement within "GetViaHttptHeaders" within "ThemeSelector" to support your minimal theme.

Does this help you achieve what you require Kina? The approach is not perfect as this depends upon client side CSS to modify the layout. Ideally we would implement a server side solution that modifies the output before it's sent to the client. We will be looking at how we can improve this. If I can assist further or you would like to see this implemented in a different way of course please don't hesitate to respond to discuss further.

For your reference you can see a similar technique within our Plato Desktop app here...

Thank you again for your feedback and posting here. If you have any further ideas of course please don't hesitate to post here and we'll review them as quickly as possible. Thank you for using Plato Kina 😃


Ryan Healey
Plato - All-in-one product support

Have a suggestion? Login or register to post
Your Suggestion
  • Posted 1/21/2020 10:08:23 AM
  • Modified 3/28/2020 1:11:24 PM
  • Latest Reply 2/2/2020 5:18:10 PM
  • 948 views, 1 reply