Amphtml: New amp-accordion headings error?

Created on 21 Aug 2019  路  4Comments  路  Source: ampproject/amphtml

What's the issue?

We have begun seeing a new error show up in the console that reads "amp-accordion headings should not have tap actions registered." for every use of the amp-accordion component on a page.

We have not modified this markup for quite some time so we are having difficulty troubleshooting the new error.

In looking at each use of amp-accordion, we also can not identify any tap actions being registered.

How do we reproduce the issue?

  1. Open https://www.google.com/amp/s/www.ebags.com/amp/product/tumi/cfx-bayview-travel-duffel/365912
  2. View errors listed in the console.

What browsers are affected?

This appears to be across browsers and device type.

Which AMP version is affected?

This appears to be a new issue.
Version 1908162134430

Bug

Most helpful comment

The issue seems like it's because amp-accordion doesn't allow to have tap event on the header. However after removed the tap event from header still failing for me.

Seems like the findAction_ in the action-impl.js is doing a loop for each of the parentElement, after removing the tap on my parent element it seems to be working. Why is the function not scoped at the accordion component only?

All 4 comments

I am also facing the same issue on an AMP based website. How do we fix this issue?

log.js:410 Uncaught (in promise) Resource: failed to build: amp-accordion#7: amp-accordion headings should not have tap actions registered.
at Na.f.assert (https://cdn.ampproject.org/v0.js:11:306)
at z (https://cdn.ampproject.org/v0/amp-accordion-0.1.js:2:873)
at https://cdn.ampproject.org/v0/amp-accordion-0.1.js:20:259
at Array.forEach ()
at S.push.f.S.buildCallback (https://cdn.ampproject.org/v0/amp-accordion-0.1.js:17:201)
at https://cdn.ampproject.org/v0.js:258:214
at new Promise ()
at HTMLElement.b.build (https://cdn.ampproject.org/v0.js:257:476)
at Oi.f.build (https://cdn.ampproject.org/v0.js:227:113)
at Vj (https://cdn.ampproject.org/v0.js:310:382)

image
I think the temporary solution is set the color for these sections first. asleast users still see texts

The issue seems like it's because amp-accordion doesn't allow to have tap event on the header. However after removed the tap event from header still failing for me.

Seems like the findAction_ in the action-impl.js is doing a loop for each of the parentElement, after removing the tap on my parent element it seems to be working. Why is the function not scoped at the accordion component only?

According to #23264 , bad use of hasAction method, third parameter should be the header element parent to prevent checking tap presence on all parents divs. @sparhami @cathyxz Is planned to do an emergency release or anything ? If not, we will have to remove all tap on parents elements.

Was this page helpful?
0 / 5 - 0 ratings