Stack Exchange Network

Stack Exchange network consists of 175 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
14 views

viewsreference child view Sample Code

Is there any example code for creating a new paragraph object with a viewsreference field and setting a view on the viewsreference field with its "type" and other display options set? Can't really ...
1
vote
1answer
25 views

How to filter a node view on a paragraph field

I have a content type "Lunch" containing a paragraph type field named "Ingredients". This is a multiple values field which store a prapgraph type named "Ingedients" => Taxonomy term + Quantity LUNCH ...
0
votes
0answers
19 views

How to get file fid value in paragraph and view templates

Hi i am trying to access file fid value in paragraph twig template file but cant access it. Though I can print file uri but I need to access fid of the file Here is my code in paragraph.pdfdocument....
0
votes
0answers
9 views

How to access the value of another field in the same field collection from a field template file?

In Drupal 7 I've customised a file download field in a template file: field--field-downloads.tpl.php Within the same field collection (using the 'field_collection' module: https://www.drupal.org/...
0
votes
0answers
27 views

Rendering multiple field image in paragraph

I have field_image in my paragraph that has multiple values so img1.jpg, img2.jpg etc . I want to render it in twig but the first image needs to have different class then the rest of them . I've tried ...
0
votes
1answer
39 views

Get node data from entity reference field

I have an entity reference field to a content type blog. I referenced a specific blog, but when I render that field in twig using {{ content.field_blog }}. I want to get the autor name and time when ...
-3
votes
0answers
12 views

Alter Paragraph select field value

I am trying to alter select field list value. In the paragraph if i put editmode:'Open', it's get change, but editmode:'Preview', select field is didn't get alter. please guide me on same
0
votes
0answers
31 views

Migrate node with paragraph

I'm trying to figure out how migrating content from a Drupal 7 site to a Drupal 8 site works. I managed to understand how to create a custom module to migrate nodes with regular fields to my new D8 ...
-1
votes
0answers
15 views

Render field link [duplicate]

I have a paragraph with the field link and I'm supposed to get the url and name of that link field and render it in twig as a redirect to a different page fe. "read more". How can I achieve this using ...
0
votes
2answers
29 views

Paragraph within paragraphs that is in paragraph

I'm using Drupal 8. I have paragraph service_tile that is in paragraph service_tiles , which is in paragraph intro_service. How can I get all data within twigs without using preprocess page? I tried ...
0
votes
1answer
37 views

How to print the URL path of a referenced node using paragraphs?

I'm trying to print out the url path of a node from a referenced entity paragraph field in my twig template however have not had any success so far. I have tried various common twig functions but with ...
0
votes
0answers
16 views

Conditional Fields inside Paragraphs not working

Am able to get the configured conditional fields in hook_field_widget_WIDGET_TYPE_form_alter() and trying to apply them for Paragraph fields but not working, below is the code(most of it copied from ...
0
votes
0answers
23 views

Update to drupal 8.7 caused paragraphs to display improperly

I am using bootstrap paragraphs (BP) as part of my project. When I updated to D8.7, the BPs that define layout (e.g. 2 column, accordion, etc.) stopped displaying. I then tried a roll back to 8.6 ...
0
votes
0answers
23 views

Need to alter “No Paragraph added yet. Select a Paragraph type and press the button below to add one.” message - Paragraph Module

I am using paragraph bundle and I want to alter this message with my custom text "Please click on below button to add data".
1
vote
2answers
44 views

Change autocomplete results based users selected checkbox

I have a drupal 8 site that uses the paragraphs module. In one of the paragraph is a field that contains an autocomplete field. It is already set up to reference a small list of Content Types. For ...
0
votes
0answers
48 views

Loop Paragraph types with all values in field--field-page-detail-paragraph.html.twig

I have two paragraph types called First Type & Second Type and added Image & Text fields on it separately. I have created the basic page & added the two above paragraphs(First Type & ...
0
votes
0answers
38 views

How to access specific checkboxes in a widget_type form alter?

I have a Paragraph with two List (text) fields. One is using the Select widget and the other using Check boxes. There are 14 checkbox options—I'm trying to show/hide certain checkboxes based on the ...
0
votes
3answers
60 views

How can I have a nested slideshow with paragraphs and views?

Initial situation I have a node type with a paragraph field. Each paragraph of the paragraph field is rendered among themselves. What I want to achieve The paragraph field inside the node should ...
2
votes
1answer
48 views

How to disable views pager programatically in certain cases

I have a paragraph which shows a view. The editor may set some options as argument filters, sort and show/hide pager. "Normal" fields are used to collect these options and ...
0
votes
1answer
34 views

How to query paragraphs content?

Does any one have an example how I can query the paragraph entity type of a given node ? Let's say I have a node that contains a field 'field_paragraph' that is linked to the paragraph module . How ...
1
vote
1answer
70 views

Change title of certain paragraphs in a form

Please see the attached pictures. In one of my projects I have a taxonomy, which users can edit and add data. It has multiple tabs (see picture one) and each tab has multiple fields in which ...
1
vote
0answers
30 views

How to hide paragraph with data?

I am using paragraph module. Named Address: It has fields address 1, address 2, state, country. (User can add unlimited addresses) While creating the node, I have added 2 address. While edit, I ...
0
votes
0answers
59 views

The “paragraphs_type” entity type did not specify a access handler

When i try to access paragraph type page i get following error. Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException: The "paragraphs_type" entity type did not specify a access handler ...
0
votes
1answer
43 views

Add/List/Edit paragraphs while add/edit node

I have installed paragraph module. I have paragraph called Address contains relevant info. It is attached to node. Per page/article I have more than 100 address. If I use default Paragraph Classic ...
1
vote
2answers
60 views

Trying to access and print the values from the fields within Paragraph

I'm having trouble trying to access and print the values manually within the Paragraph. This is a snippet from the paragraph field template I have created. I wanted to access and print values manually ...
0
votes
1answer
41 views

Editing contents of custom block referenced in paragraph type, doesn't reflect changes in node where displayed

So, I have a Custom Block type, let's call it Sidebar Links Block. In an Article, we have a Sidebar paragraph type that allows quite a few different entities, one of which is the Article Sidebar Links ...
0
votes
1answer
146 views

How to retrieve value of hidden field in twig?

How to retrieve value of hidden field in twig? PFB screenshot: I am able to retrieve value of "Partition Count" field when not disabled. But not able to retrieve it's value when disabled. Exact ...
0
votes
0answers
26 views

Paragraphs using dependent fields

I have the following contents and taxonomies set up: Army - Content Unit Type - Content Unit - Paragraph type Factions - Taxonomy The Army content type contains a paragraph type Unit which ...
0
votes
0answers
18 views

Footnotes module not working properly with Paragraphs module

When using Footnotes with Paragraphs, the module puts footnotes at the bottom of each of the paragraphs rather than at the end of the page. Is there any way to change this?
0
votes
1answer
21 views

How do I use a views data with a paragraph? [duplicate]

I have a content type with dynamic content block section. Each block section is managed by paragraph bundle. Let's explain using an example to make more clear- Content type name is Employee. A ...
0
votes
0answers
20 views

Views Entity reference permission issue for anonymous users

The issue comes when I used views reference field in paragraph type. Contents are added from admin side and views reference field displaying views id in the frontend for admin users. But this display ...
0
votes
1answer
86 views

Adding Constraint to Paragraph field

I have a Content Type with a field that references 6 different paragraph types. The field is set up to accept unlimited values. For one of the types I would like to have exactly four values added. ...
1
vote
1answer
57 views

How do I programmatically update a UUID?

Reason: Receiving uid does not exist error. Upon investigating, this error appears only when we edit or save the preexisting columns paragraph. If we create new columns paragraph, the error doesn't ...
0
votes
1answer
35 views

Two different editor in one content typ

is there a way in drupal 8 to use two different editors (CKeditor with two different buttonpanels or two differently allowed html tags) in one content type? I have created a content type of a text ...
0
votes
1answer
105 views

Paragraphs module decoupled structure

I'm looking to use the Paragraphs Drupal 8 module with a decoupled installation of Drupal 8 but would like the structure made in the admin area to be output in the JSON API responses. How can I ...
1
vote
1answer
33 views

How do I create a jump link to a paragraph item?

I'm trying to create a jump link to the paragraph item. This is what I tried create a compact display of the page just printing out a title and short summary. using the advanced text formatter I ...
0
votes
0answers
62 views

Paragraph containing an entity reference field as a select - Show options by something other than label

I have an author content type. I have a book content type. I associate multiple books with an author by having a books paragraph field in the Author create / edit form. In my Book Paragraph field I ...
0
votes
1answer
26 views

Custom form from scratch in template

I have a paragraph that I fully themed into a contact form with the necessary tags etc... Now my question is: How do I add the actual functionality to this? Because right now it's just plain html in ...
0
votes
1answer
41 views

How to show in a view the total number of paragraphs for a node?

I have a content type with a field of type paragraphs, with possible unlimited values. I need to show the total number of paragraphs for every node, in a column, in a views (table of fields). It seems ...
0
votes
0answers
20 views

Access to a block view in a paragraph

I created a paragraph in drupal which has a reference to a block. In the preprocess I did : $variables['bloc_video'] = \Drupal::entityTypeManager()->getViewBuilder('block_content')->view($bp); ...
0
votes
1answer
108 views

Pass hidden fields using drupalSettings to Twig template

We have a paragraph field (field_pr_custom) on the Basic page content type that has a custom twig template, pr-custom.html.twig. In the twig template, we need to pass in an array inside of a <...
0
votes
0answers
22 views

How do I show all paragraph items?

My project user profile has a paragraph with 3 columns (Lesson, Experience, Price) which shows a teacher's private lesson prices. I want to show all the teacher's lessons, but in a view I am only able ...
0
votes
1answer
29 views

Groups and Private File Visibiility

I have created a content type Agenda - the body is paragraphs - there are two types: (1) Text and public files and (2) Private Files. The fields work properly - Anonymous cannot see Private Files. ...
0
votes
0answers
26 views

Make Views table header with multiple values field sortable

Following this answer I was able to create a sortable Views table using Paragraphs relationships. I need to do so to make the related values sortable. So I try to make a reference to the second value ...
0
votes
0answers
82 views

Get paragraph bundle (paragraphs_item) value for migration

I am migrating node from D7 to D8 but I need to get the paragraph body value and concatenate it with the value of the body. Here is a dump of the node: object(Drupal\migrate\Row)#1848 (8) { ["...
1
vote
1answer
222 views

Controlling a dependent field in a multi-instance paragraph

The fields below are part of the node/add node/edit forms of my custom node type. The paragraph field_para_city contain one field_city. (I later need to add other fields in the paragraph). The user ...
0
votes
1answer
29 views

Add paragraphs item to user entity

I want to create a new paragraph item to a user bundle. This is the code: $name = "Test"; $userdata = user_load($user->uid); $paragraph = entity_create('paragraphs_item', array('field_name' => '...
1
vote
1answer
59 views

Add a class retrieved from a sibling field to responsive image

I have a Profile paragraph type that has the following fields: Profile Image [Responsive Image Field format] Profile Headline [Plain Text] Profile Description [Plain Text] Rounded Profile Image [...
0
votes
1answer
51 views

How do I get the field definition of a paragraphs image field

I need to get the resolution of the image using getFieldDefinitions(). For normal fields I can get the field definitions with below. $fieldDefinition = \Drupal::entityManager()->...
0
votes
1answer
201 views

How to print paragraph field values in paragraph template?

I'm trying to output paragraph field values in a sample paragraph template, but it does not work. I created a twig template in paragraph/paragraph--article--default.html.twig I have a field called ...