diff --git a/web/src/giscus.ts b/web/src/giscus.ts index 2bc8f18a..dcb42a4f 100644 --- a/web/src/giscus.ts +++ b/web/src/giscus.ts @@ -24,7 +24,6 @@ export class GiscusWidget extends LitElement { iframe { width: 100%; border: none; - color-scheme: normal; min-height: 150px; } `; @@ -309,11 +308,11 @@ export class GiscusWidget extends LitElement { backLink, }; + const host = this.host || this.GISCUS_DEFAULT_HOST; const locale = this.lang ? `/${this.lang}` : ''; - const searchParams = new URLSearchParams(params); - return `${this.host}${locale}/widget?${searchParams}`; + return `${host}${locale}/widget?${searchParams}`; } render() { @@ -324,6 +323,7 @@ export class GiscusWidget extends LitElement { ${ref(this._iframeRef)} src=${this.getIframeSrc()} loading=${this.loading} + allow="clipboard-write" part="iframe" > `;