Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [paragraphs]

Use it for questions relating to the Paragraphs module, not for text or body paragraphs.

0
votes
0answers
8 views

Link an Image field to a colorbox popup text field in pargraphs

I created a paragraph that collects an Image and some text in long format with no summary. How can I configure this so clicking on the Image displays the long format text in a colorbox popup? I can ...
0
votes
0answers
22 views

Unable to fetch paragraph's multi field values inside node twig

I have a content type as "worker". I have a Paragraph "test" and I am referencing "test" paragraph inside my content type "worker". This allows multiple values to be saved. How can I get the multiple ...
1
vote
1answer
37 views

How do I access paragraphs with the JSON API?

With the JSON API module, I am trying to access paragraphs. In the JSON object is does not allow me to access the nested paragraphs. How would I go about accessing the paragraphs with the JSON API?
0
votes
0answers
14 views

How Do I Use the Page Translation as a Contextual Filter in a View?

I have a Products content type and I've setup a a Product Markets vocabulary which allows me to specify the markets individual products are available in (Europe, North America, etc.) Each Product ...
0
votes
0answers
14 views

How to output a paragraph image field

I have a view that is pulling in multiple fields from a paragraph. (The idea here is that the view block will be output in a particular region.) I also have a custom paragraph.twig.html template that ...
0
votes
0answers
28 views

Paragraph translation

I have a Drupal 8.6.3 site that is using translations. English and Arabic are the only two languages as of now. I'm having a problem with paragraphs not translating between the original, English ...
0
votes
3answers
28 views

How to print an image in a paragraph that references a node with an image field

I have the following scenario: I have a paragraph called Timeslot that contains an entity reference field to a content type called Class. That content type has an image field called Class Badge. I ...
0
votes
1answer
20 views

How to pre-populate paragraphs when creating a page

I have tried for some time to find out a way to populate a new page with a few paragraphs to save time on most of the pages (but which might change position or even get dropped for some pages) but so ...
0
votes
0answers
33 views

Paragraph type can't delete individual items

I use Paragraph module Version: 8.x-1.5. Somehow I can't delete individual items anymore? Is there a settings somewhere I missed?
0
votes
0answers
25 views

How do I get the paragraph fields values in hook_node_form_alter

I have a field named field_page_schedule which relates to an entity reference paragraph field and the paragraph has two fields named field_start_date_and_time & field_end_date_and_time. I need to ...
1
vote
0answers
32 views

Migration - Paragraph is not attaching to node content type

I have below code My data.csv id, title,location_place_1,location_address_1 1,"test","Test","India" /my-project/docroot/modules/custom/data_migrate/config/install/migrate_plus.migration.data.yml ...
0
votes
0answers
31 views

How do I get fields attached to a field which contains a paragraph as entity reference on a field twig template

I am trying to get a field value which I added within a paragraph which is referenced on to another paragraph using entity reference. Unfortunately, It was the structure built earlier and I have no ...
0
votes
0answers
32 views

Dynamically set theme per block/paragraph

I'm looking to apply specific themes to individual items on a page - a different theme to the rest of the page. I realise this seems quite obscure, but the general premise is similar to a styleguide. ...
0
votes
1answer
41 views

Passing Image through hook

Background: Im working in Drupal 8 and I have a paragraph type that contains a title and an image and I am trying to pass it through the preprocessor hook so I can set it inside a html template. For ...
1
vote
3answers
149 views

Custom Theming Bootsrap Carousel with Paragraph Type

Background Info: I tried to create a custom theme for my carousel section and I am unable to get it to work. I have tried using the default carousel that Drupal comes with. I have tried using slide ...
0
votes
1answer
35 views

Different Templates for Same Field

I want to have two different templates for the same field on a node template. For example: <div class="navigation>{{ content.field_section }}</div> // uses paragraph--section.html....
0
votes
0answers
22 views

add editable custom attributes to a link field of a paragraph

I have a paragraph which contains a standard Link field. uuid: c5d70757-f6d4-4a22-ba32-bd83b9e822c6 langcode: en status: true dependencies: config: - field.storage.paragraph.field_link - ...
0
votes
1answer
46 views

EntityQuery on nodes related by ERR and paragraphs

I have content type Publication which relates to content type Project using paragraphs: Publication [field_mention] -> Mention (paragraphs) [field_project] -> Project Now I want to show all ...
1
vote
1answer
58 views

Paragraphs Entity Type Causing Issues After Core Update

I am getting this error whenever I try to create a node on Drupal 8.6.2. Drupal\Component\Plugin\Exception\PluginNotFoundException: The paragraph entity type does not exist. in Drupal\Core\Entity\...
0
votes
0answers
22 views

Set Custom “Paragraph Type Icon” For Paragraph Type With Module During Install

Drupal 8.x I have a paragraph that is installed via a custom module, this is done with .yml files in the MYMODULE/config/install/ directory. I would like to have a custom icon added to the "Paragraph ...
0
votes
0answers
24 views

How to get paragraph items in user views list

I have lessons paragraph bundles which used for user accounts. I'm trying to list teacher user with paragraph bundle items. What I did: I've created user list.I added paragraph lesson fields but no ...
0
votes
1answer
43 views

Confused about Owl carousel with Paragraph

I'm very new to Drupal and not (yet) familiar with the terms and namings. I came across a web site in Drupal 8 that uses Paragraph. I'm trying to reproduce the slideshow that apparently uses Owl ...
0
votes
1answer
53 views

Custom validation for paragraph field

I have a content type with one paragraph field which has a checkbox and a text field. By default, the text field is optional. I want to make it required when the checkbox is checked. Conditional ...
0
votes
0answers
13 views

Trying to get a paragraph bundle within an OG to use EVA display

I am looking for help getting a news block working for my website. I currently have: A paragraphs field on a content type where the user can add a "Department News" paragraph. The page it's being ...
1
vote
1answer
60 views

Paragraphs: referenced entity error on save

I recently updated to Drupal 8.6.2 and Paragraphs 8.x-1.3. I have a content type with a Paragraphs field. When I try to update an existing node I get the following error message: The referenced ...
0
votes
0answers
25 views

How to disable caching for a preprocessed template variable in a paragraph

I have a preprocess function for a paragraph that has a variable which contains a render array. I cannot seem to find a way to disable the caching of this variable when rendered on a page, it is ...
1
vote
1answer
111 views

Limit amount of adding a certain Paragraph per Content type

I use Drupal 8 Paragraphs module. I created a Content type Landingpage. I create some Paragraph types like Hero Image, Intro text etc. In the Content type Landingpage I created a Paragraph Entity ...
0
votes
1answer
119 views

Node body to entity reference revision (paragraph) field not working/processing

I want to migrate the Drupal 7 body of my blog to a Drupal 8 paragraph (field_stories_content which is Entity reference revisions). The body is to be assign to the field_stories_text_formatted field. ...
0
votes
1answer
37 views

How to programmatically update a paragraph field

Trying to get certain paragraph field of certain node updated with new value with the following code: function my_module_node_update($node) { if ($node->nid == '111') { foreach ($node->...
0
votes
0answers
37 views

Show specific number of items on paragraph field

I have configured a field like this: When I create a Node, the field shows like this: How can I, programmatically, start this field with two elements and not have to click on the "Add pet" button? ...
0
votes
0answers
19 views

Node not appearing in taxonomy list when taxonomy term is selected within a paragraph

When I had my content type have a taxonomy term field in it, you could select the term and that content would be listed within that taxonomy page. However, due to the need to group that taxonomy field ...
2
votes
2answers
65 views

How limit access to a paragraph type by role, like it is for content types?

The permissions page at /admin/people/permissions provides very fine grain control over which actions people can do with specific content types. How can I add all paragraph types under this ...
1
vote
2answers
132 views

How can I “form alter” fields in a nested Paragraph, depending on where the field is used

I have these entity types: A node type: nodepage A Paragraph type: pg_a A Paragraph type: pg_b A Paragraph type: pg_child I have a content model which is: nodepage ->field_a Referenced ...
0
votes
1answer
32 views

Why is my property being rendered when I don't call render?

I have a string property, and HTML is getting rendered instead of a string, even though I don't call render where the property is being accessed. Twig template: {{ attach_library('mymodule/video') }}...
-1
votes
1answer
66 views

Find all content that has Paragraph Content

Is there any way to find all content that has any value in the field created by Paragraph module? Looking to find content and move it into the Body field so that: We don't loose the content. We can ...
0
votes
0answers
25 views

user list referenced by paragraph item

I want to list teachers(users) based on lesson term which are used in paragraph bundle. User list will be on path .../path/% For example .../lesson/math Path page will show math teachers. What I ...
0
votes
1answer
121 views

How to render a paragraph field in Twig in correct language?

I've got nodes with hero images. The hero images are a paragraph field with unlimited cardinality, each with an image and a translatable text. For design reasons I need to print the hero images in ...
1
vote
1answer
61 views

load paragraph in graphql

i have a content type with "artist" and i have a paragraph type with "album" name. in album i have two field 1. name 2. release date. i create a field with "field_album" name in "artist" content type ...
1
vote
1answer
86 views

How to pass variable of paragraphs type to another preprocess function

I want to override the fontawesomeicons.html.twig (Fontawesome Module). But I only want to do this for "my-very-special-paragraphs-type" and not in general. I think it is a good idea to declare a ...
0
votes
1answer
99 views

Paragraph image URI with image styles in paragraphs-item.tpl

I have Paragraph bundle with Multi Value Image Field which is limit of 3 numbers. i tried to print these three images separately because i want to used different image styles for each images. I tried ...
0
votes
1answer
22 views

List most recents files used

We have a Documents bundle which is a list of documents, and an Accordeon which includes the previous one. NODE_PAGE | |--- DOCUMENTS | |--- ACCORDEON | | | |--- DOCUMENTS With this choice, I ...
0
votes
0answers
37 views

How to display Paragraph bundles fields links inside a page.html.twig file that are within a paragraph bundle in Twig? [duplicate]

My content type asks for up to 3 links that will be rendered in the header area of my page and not within the body of the node. The tag appears in the page.html.twig file for the theme(Bootstrap) ...
2
votes
1answer
116 views

What is the difference between getValue() and referencedEntities() to fetch paragraphs?

What is the difference between using getValue() and referencedEntities() in order to get the paragraph on a node? See example below. Both examples are used in a node template such as node--page--full....
0
votes
0answers
113 views

How to migrate nodes with multiple paragraphs

I have successfully migrated content into nodes/paragraphs from Excel spreadsheets (using the awesome https://www.drupal.org/project/migrate_spreadsheet module) although it's not really any different ...
0
votes
1answer
41 views

How do you add validation (constraints?) on a paragraph? Compare two fields

How does one go about adding validation (contraints?) on a paragraph? I need to compare two entity reference fields on submission. If one field has a certain entity referenced, the other cannot have ...
1
vote
0answers
159 views

Get token of image field in paragraph field

We're implementing the Open Graph metatags so that social media shares can know which image to use as the "share" image on our pages. I'm having a problem figuring out the token for a image field URL ...
2
votes
2answers
104 views

Finding the host node of a paragraph

I'm trying to find all the absolute URLs in a site (in wysiwyg content, url fields, config) to convert them into relative URLs later via manual administration. All the URLs in question are within the ...
0
votes
1answer
32 views

How can I sort a view based on a date value in a multi-value paragraph reference field?

I have a custom entity type that uses an entity reference revisions field that accepts multiple values. The referenced paragraphs contain a date field. I would like to sort the entities (descending) ...
0
votes
0answers
7 views

Search Api Result Link to Paragraph instead of full Article

Is it in any way possible to link from a search result to a paragraph where the found word is in, instead of to the full article? So I have an article build up with paragraphs from the paragraph ...
0
votes
1answer
81 views

Paragraphs Align Media Left or Right of Text with CSS

I am using Paragraphs module to create a cutom paragraph. The custom paragraph will have three fields: Image, Text and Position. Would like to use css to align as follows based on the value of the ...