Skip to content

Commit

Permalink
Revert "html構造が見やすいようにした"
Browse files Browse the repository at this point in the history
This reverts commit eb3f80b.
  • Loading branch information
IttetsuSato committed Nov 4, 2024
1 parent eb3f80b commit f30dd30
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/components/definitionList/sp-definition-list.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ const styles = new CSSStyleSheet();
styles.replaceSync(`${resetStyle} ${foundationStyle} ${spDefinitionListStyle}`);

export class SpDefinitionList extends HTMLElement {
#dlElement = document.createElement("dl");
#slotElement = document.createElement("slot");

constructor() {
super();
this.attachShadow({ mode: "open" });
Expand All @@ -19,11 +22,9 @@ export class SpDefinitionList extends HTMLElement {
...this.shadowRoot.adoptedStyleSheets,
styles,
];
this.shadowRoot.innerHTML = `
<dl class="base">
<slot></slot>
</dl>
`;
this.#dlElement.classList.add("base");
this.#dlElement.appendChild(this.#slotElement);
this.shadowRoot.appendChild(this.#dlElement);
}
}

Expand Down

0 comments on commit f30dd30

Please sign in to comment.