Plone.app.themingplugins seems to do the same thing as themefragments and jbot

Looking at the functionality of collective.themefragments and collective.jbot.
It seems you can get identical functionality from the plone.app.themingplugins package.

Is that the case, or am I missing something?

1 Like

"Theme overrides" in themingplugins is jbot. But as jbot, it only works for filesystem packaged themes. As do themingplugins' views. Themefragments work TTW.

1 Like

Thanks @datakurre that helps to clear things up. So Themefragments wins in terms of being applicable to TTW and filesystem.

rapido wins over both. Works in both fs and ttw and lets write in templates or python, not just zpt.

@djay Only if you are using Plone 5, the other packages also work in Plone 4.

This is me speaking out of ignorance.... but I don't see where I can do a template override with Rapido.

Regarding "template overriding", Rapido works exactly like themefragments: you do not directly provide your custom version of colophon.pt (like jbot allows to), you just hook your own small "template" (themefragments calls it a fragments, rapido calls it a block, but whatever) into Diazo (using a <replace> rule) so it replaces the Plone regular content with yours.

1 Like

Themingfragments has a very useful 'fragments tile' that let you add fragments to 'mosaic pages', not sure if there is something similar for Rapido.

1 Like

Yes Rapido also provides Mosaic tiles.
Here is how to enable it:
http://rapidoplone.readthedocs.io/en/latest/reference/display.html#mosaic

2 Likes

Is there (our should there be) an easy way to set a view to a fragment of rapido template ?

You can use extra views: http://rapidoplone.readthedocs.io/en/latest/reference/display.html#extra-views

When you say template of a view do mean make rapido block a dynamic display view for a dexterity type? (Like displayview option on https://github.com/plomino/rapido.plone/issues/9)

Or do you mean more like jbot? Where you specifically want to override the template of a named browser view? And you want a rapido block that might have access to both its own elements and the browser view class?

I added in the jbot replacement option into that same issue. https://github.com/plomino/rapido.plone/issues/9

Rapido doesn't do this yet but I think its possible.

The current rapido way is to use something in the HTML or path to trigger a diazo rule to replace part of the page. So the underlying template is still run. And rapido doesn't get access to the browserview object. But you can access the context object etc so for a lot purposes this is fine. Also means you don't have to look at code to figure out what view template you are trying to override.

  1. Enable 'rapido' for a content type
  2. Choose which 'templates should be available'
  3. Choose 'rapido view on some content of that type'
  4. Choose a template

(!?)

You cannot "choose" (like with the Display menu) a Rapido view for a content type, but you can quite easily add a Diazo rule to replace the content-type default view content with a rapido block.

@ebrehault @espenmn that would be a sweet feature if it were implemented ...

That is most like the displayview option on https://github.com/plomino/rapido.plone/issues/9 but a slightly different way of configuring it. I've added your option too.

It would be nice to have, especially if it allows access to the view object directly.

However as @ebrehault points out its trivial to add a diazo rule to override any template for a particular content type using a rule similar to

<replace css:content="body.template-summary.portaltype-folder #content">
  <include css:content="form" href="@@rapido/myapp/block/myblock" />
</replace> 

and you do get full access to the DX object (just not the original view object you are overriding).

yes, it was a 'wish list' / brainstorming

Plone Foundation Code of Conduct