extensions/amp-story/1.0/amp-story-page-attachment.js
/**
   * Updates the given element with the appropriate class or attribute, if the
   * page attachment's theme is 'dark'.
   * @param {!Element} element The element upon which to set the dark theme.
   * @private
   */
Updates the given element with the appropriate class or attribute, if the
page attachment's theme is 'dark'.
@param {!Element} element The element upon which to set the dark theme.
@private
Updates the given element with the appropriate class or attribute if the page attachment ' s theme is ' dark ' . @param { !Element } element The element upon which to set the dark theme . @private
maybeSetDarkThemeForElement_(element) {
    const theme = this.element.getAttribute('theme')?.toLowerCase();
    if (theme && AttachmentTheme.DARK === theme) {
      element.setAttribute('theme', theme);
    }
  }
maybeSetDarkThemeForElement_ ( element ) { const theme = this . element . getAttribute ( 'theme' ) ?. toLowerCase ( ) ; if ( theme && AttachmentTheme . DARK === theme ) { element . setAttribute ( 'theme' , theme ) ; } }
Updates the given element with the appropriate class or attribute, if the
 page attachment's theme is 'dark'.
Updates the given element with the appropriate class or attribute if the page attachment ' s theme is ' dark ' .