This forum is for assistance with theme development.

How to render a custom field using a formatter in twig when hidden from content display

Hey,

I have a custom image field and would like to use the colorbox field formatter to render the image in a a node twig template.

The field is hidden from the content display for various reasons.

Any idea how to render the image in twig using the colorbox formatter?

Alternatively how to get the D8 color box module to open an image specified in the href by adding a class like you could do in D7?

Thanks heaps.

How to use preprocess_node for custom node?

I know this is the core of D8 theming, but the documentation is really leaving me flat...

I read this page and, well... i ended up asking for help here :)
https://www.drupal.org/docs/8/theming/twig/twig-best-practices-preproces...

I copied /mytheme/templates/content/node.html.twig and made /node--view--nhp-news-slider.html.twig with some edits.
Now i want my slider to point to this new, edited node instead of the default.

Alter Markup In The Views Group By Title

I am currently trying to figure out how I can alter the markup of the Views Group By Title. I created a view that groups by a date field. The date field automatically becomes the Group By Title. I have been using the template_preprocess_views_view_field hook. Whenever I change the markup of the date field it changes it both in the title and in the view field as well. I want to just change the markup in the title.

Can't Get maintenance-page--offline.html.twig template to work...

I'm having trouble getthing the maintenance offline template to work. There's not a whole lot of documentation our there, but it seems like setting up a maintenance-page--offline.html.twig template should work.

I am specifying my maintenance theme in my settings. And the regular maintenance page works fine. But when the database is offline I just get a white screen with text.
$settings['maintenance_theme'] = 'xxxxxx';

Anyone else having issues with this? Or am I missing something.

One Page Scroll

Using the Flat Zymphonies theme for a one page site. Modules Void Menu used to set the menu links.
The menu links scroll to the top of each region as designed but I had to make the menu header a little taller and now the menu links scroll the page too far. I can't find the css used to control this scroll.
Any help is appreciated.

Paragraph Theming

Hello I cannot find a way to theme http://morella.e-tck.com/node/11 page paragraph image (field_quote_image) the 3 blue rectengular images. The images that I want them to add class "img-circle"

Pages

Subscribe with RSS Subscribe to RSS - Theme development