MCPcopy Create free account
hub / github.com/internetarchive/openlibrary / render

Method render

openlibrary/components/lit/OLButton.js:80–93  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

78 }
79
80 render() {
81 // The label and spinner are both always in the DOM so we can crossfade
82 // between them via CSS. The spinner has its own element (rather than a
83 // ::before on the button) because the scale-in transition and the
84 // rotation animation both need `transform` — splitting them across the
85 // wrapper span and its ::before keeps them from stepping on each other.
86 return html`
87 <button
88 type=${this.type}
89 ?disabled=${this.loading || this.disabled}
90 aria-busy=${this.loading ? 'true' : 'false'}
91 >${this._label}<span class="ol-btn-spinner" aria-hidden="true"></span></button>
92 `;
93 }
94}
95
96customElements.define('ol-button', OLButton);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected