adobe / aem-core-wcm-components

Standardized components to build websites with AEM.
https://docs.adobe.com/content/help/en/experience-manager-core-components/using/introduction.html
Apache License 2.0
730 stars 736 forks source link

[Accordion] Unable to add items into Accordion component in SPA Editor (Angular) #934

Closed claudiab closed 4 years ago

claudiab commented 4 years ago

Issue with proxy version of the Accordion component in Angular SPA Editor. The child does not load and I'm unable to new add components. Is this related to Edit configs (eg. listeners) not being supported in the SPA Editor? Is there a possible workaround?

Current Behavior

Proxy Component: core/wcm/components/accordion/v1/accordion

  1. Create an Angular Front-End project with archetype 23

mvn -B archetype:generate \ -D archetypeGroupId=com.adobe.granite.archetypes \ -D archetypeArtifactId=aem-project-archetype \ -D archetypeVersion=23 \ -D aemVersion=6.5.2 \ -D appTitle="My Site" \ -D appId="mysite" \ -D groupId="com.mysite" \ -D frontendModule=angular \ -D includeExamples=y

1a. Navigate to ui.frontend

  1. Create a dummy component for accordion ng g c components/accordion --module app.module

2a. Map AEM Accordion Component to Sample Angular Accordion component

Screen Shot 2020-02-24 at 1 35 21 PM

2b. Add AccordionComponent to entryComponents

Screen Shot 2020-02-24 at 1 34 09 PM
  1. Enable All "My Site - Content" components at http://localhost:4502/editor.html/conf/mysite/settings/wcm/templates/spa-page-template/structure.html

  2. Drop Accordion into SPA Editor

Screen Shot 2020-02-24 at 1 35 21 PM (2)

View from CRX

Screen Shot 2020-02-24 at 1 50 38 PM Screen Shot 2020-02-24 at 1 50 33 PM

Expected behavior/code

I'm able to run AEM Core Components (2.8.0) locally to test expected functionality. http://localhost:4502/editor.html/content/core-components-examples/library/accordion.html

Screen Shot 2020-02-24 at 1 25 49 PM (2)

Environment

AEM (6.5.2.0) Core Components version 2.8.0 Java(TM) SE Runtime Environment (build 1.8.0_211-b12)

gabrielwalt commented 4 years ago

Hi @claudiab, thank you for the detailed bug report! We'll have to investigate this issue as it seems likely that it is located in the SPA Editor rather than in the Core Component. For this reason, and if this issue is blocking your project, I'd recommend to also open a DayCare issue for it; you can just link to this one issue if you don't want to repeat the same details there.

pfauchere commented 4 years ago

@claudiab here are quick hints.

Looking at the ticket, I am expecting that what you actually are missing is the implementation of the Accordion Front-End component, how it consumes the model and how it displays the content.

gabrielwalt commented 4 years ago

It seems that this is working as designed and that there are parts missing on your client-side implementation, @claudiab. I'm therefore closing this issue for now, but please reopen it if if you encounter further issues.