Problem/Motivation

We want to be able to check that all the SDC components render properly within a page.

Steps to reproduce

Proposed resolution

Create a dummy page that has all the components in it.

Remaining tasks

  • Figure location and URL
  • Add code
  • Update docs to point at this for debugging

User interface changes

There will be a reference page with all components you can look at.

API changes

Data model changes

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Kristen Pol created an issue. See original summary.

kristen pol’s picture

Assigning this one to Jacob, but I'll help figure out where this goes.

kristen pol’s picture

Assigned: jacobadeutsch » kristen pol

I played around with this a couple days ago and ran into road block so parking for the moment.

kristen pol’s picture

Assigned: kristen pol » alan.cole

Assigning to Alan.

kristen pol’s picture

Assigned: alan.cole » joshua1234511
Priority: Normal » Major

Assigning to Joshua since Alan is out most of this week.

kristen pol’s picture

Here's an example of how someone tested rendering of a component:

https://www.drupal.org/project/demo_design_system/issues/3465043#comment...

kristen pol’s picture

Priority: Major » Critical

Bumping priority.

joshua1234511’s picture

I did play around with the code and could think of two approaches and a blocker

Creating a Demo Page: programmatically create a page that shows all components by adding paragraphs for each component. However, this approach requires creating an actual page with these paragraphs, which would need default content.

Alternative Using Views: Another approach could be to create a view that lists all paragraphs. If each field in the paragraph has a default value, you can list them directly in the view. This could serve as a dynamic display of components, though it still relies on having those paragraphs with default content in place.

In both cases the blocker: overriding the paragraph templates to embed/include the SDC components.
Needs to be done manually as done here https://www.drupal.org/project/demo_design_system/issues/3465043#comment...
-- Once all components are updated paragraph templates to embed/include the SDC components. ie : reference https://git.drupalcode.org/project/demo_design_system/-/merge_requests/3...

kristen pol’s picture

Thanks. Perhaps discuss this with Richard and Alan to get their thoughts on this

richardgaunt’s picture

https://github.com/civictheme/civictheme_content

This is how CivicTheme generates content - can you utilise these methods to generate components to your needs.

kristen pol’s picture

Bummer… I was hoping we didn’t need a separate module…

joshua1234511’s picture

If we are going with the module then it's just adding the steps in the document.
The module is updated with latest CivicTheme components which will create random content for various components.
If we manually try to add the data, will need to create function to create each component, is basically what the module will do.

kristen pol’s picture

We also need content for the custom components do we wouldn’t use that module. We’d have to make a companion one for SDDS.

joshua1234511’s picture

Proof of Concept (PoC) for content provisioning with Content & Callout Component.

POC 1
POC 2

kristen pol’s picture

Assigned: joshua1234511 » jacobadeutsch
Status: Active » Needs review

Thanks. Assigning to Jacob to test.

kristen pol’s picture

Assigned: jacobadeutsch » Unassigned
Status: Needs review » Postponed

Let's hold off on this one for now because we also want to try to get rid of unnecessary dependencies for the demo so this might be at odds with that:

#3465047: Remove unnecessary dependencies before DrupalCon Barcelona

kristen pol’s picture

Priority: Critical » Normal

Lowering priority. We are starting to be able to see components in XB so we might not need this.

kristen pol’s picture

Removing parent. This work might be considered post-Barcelona.

Note, later, there may be a way to pre-build all of these in XB for viewing/testing.

kristen pol’s picture

Status: Postponed » Closed (duplicate)