Skip to content

Commit c1d0c89

Browse files
committed
set-accordion-placeholders copy on=dark attribute to children
1 parent 50d90f3 commit c1d0c89

File tree

2 files changed

+12
-11
lines changed

2 files changed

+12
-11
lines changed

elements/pfe-accordion/demo/index.html

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -90,38 +90,39 @@ <h3>Where do the main characters work as adults?</h3>
9090
<section class="dark-background" >
9191
<h2 style="color:white;">pfe-accordion on=dark only, manually copied to children</h2><br/>
9292
<pfe-accordion on="dark">
93-
<pfe-accordion-header on="dark">
93+
<pfe-accordion-header>
9494
<h3>Why do wizards need money if they could just create it?</h3>
9595
</pfe-accordion-header>
96-
<pfe-accordion-panel on="dark">
96+
<pfe-accordion-panel>
9797
<p>There is legislation that decides what you can conjure and what you can not. Because things that you conjure out of thin air will not last, it is illegal in the wizarding world.</p>
9898
</pfe-accordion-panel>
99-
<pfe-accordion-header on="dark">
99+
<pfe-accordion-header>
100100
<h3>Why doesn't Harry have a portrait of his parents?</h3>
101101
</pfe-accordion-header>
102-
<pfe-accordion-panel on="dark">
102+
<pfe-accordion-panel>
103103
<p><a href="#">The characters in the portraits</a> are not actually ghosts. They mainly are there just to repeat common phrases or serve as a general represe<a href="foobarbaz.com">ntation of the individual</a> they depict. A portrait of his parents would not be of much help to Harry.</p>
104104
</pfe-accordion-panel>
105-
<pfe-accordion-header on="dark">
105+
<pfe-accordion-header>
106106
<h3>Why is Harry considered a half-blood if both of his parents could use magic?</h3>
107107
</pfe-accordion-header>
108-
<pfe-accordion-panel on="dark">
108+
<pfe-accordion-panel>
109109
<p>Because Harry's grandparents were not able to do magic. This is generally frowned upon by those who consider themselves pure, such as the Malfoy's or other antagonists.</p>
110110
</pfe-accordion-panel>
111-
<pfe-accordion-header on="dark">
111+
<pfe-accordion-header>
112112
<h3>Is Hogwarts the only wizarding school?</h3>
113113
</pfe-accordion-header>
114-
<pfe-accordion-panel on="dark">
114+
<pfe-accordion-panel>
115115
<p>No! It has been revealed that there are actually 11 long established and prestigious schools around the globe. These include Castelobruxo in the rainforest of Brazil, Durmstrang Institute (whereas nobody is certain of it’s whereabouts), and Ilvermorny, right here in the United States.</p>
116116
</pfe-accordion-panel>
117-
<pfe-accordion-header on="dark">
117+
<pfe-accordion-header>
118118
<h3>Where do the main characters work as adults?</h3>
119119
</pfe-accordion-header>
120-
<pfe-accordion-panel on="dark">
120+
<pfe-accordion-panel>
121121
<p>Harry and Hermione are at the Ministry: he ends up leading the Auror department. Ron helps George at the joke shop and does very well. Ginny becomes a professional Quidditch player and then sportswriter for the Daily Prophet.</p>
122122
<p><a href="https://www.pottermore.com/collection/characters" target="blank">Read more about the characters</a></p>
123123
</pfe-accordion-panel>
124124
</pfe-accordion>
125125
</section>
126+
126127
</body>
127128
</html>

elements/pfe-accordion/src/pfe-accordion.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class PfeAccordion extends PFElement {
6565
}
6666

6767
static get observedAttributes() {
68-
return ["theme", "color"];
68+
return ["theme", "color", "on"];
6969
}
7070

7171
static get cascadingAttributes() {

0 commit comments

Comments
 (0)