From b3be837c92f1b60874f6a17dadeea42c277aaff7 Mon Sep 17 00:00:00 2001 From: emma Date: Wed, 24 Jan 2024 18:00:14 -0500 Subject: [PATCH] fix remaining issues preventing build --- src/electron/rec-window.ts | 2 +- src/ui/app.ts | 20 ++++++++------------ src/ui/coll-index.ts | 5 ++--- src/ui/coll-info.ts | 2 +- src/ui/coll.ts | 11 +++++------ src/ui/upload.ts | 2 +- yarn.lock | 2 +- 7 files changed, 19 insertions(+), 25 deletions(-) diff --git a/src/electron/rec-window.ts b/src/electron/rec-window.ts index 4731f233..b06489ca 100644 --- a/src/electron/rec-window.ts +++ b/src/electron/rec-window.ts @@ -4,7 +4,7 @@ import { css, wrapCss, clickOnSpacebarPress, -} from "replaywebpage/dist/misc"; +} from "replaywebpage/src/misc"; import fasRefresh from "@fortawesome/fontawesome-free/svgs/solid/redo-alt.svg"; //import fasFullscreen from '@fortawesome/fontawesome-free/svgs/solid/desktop.svg'; diff --git a/src/ui/app.ts b/src/ui/app.ts index e3b0d27f..52f8bc53 100644 --- a/src/ui/app.ts +++ b/src/ui/app.ts @@ -1,6 +1,4 @@ -import { ifDefined } from "lit/directives/if-defined.js"; - -import { html, css, wrapCss, IS_APP, apiPrefix } from "replaywebpage/dist/misc"; +import { html, css, wrapCss, IS_APP, apiPrefix } from "replaywebpage/src/misc"; // replaywebpage imports import { ReplayWebApp, Embed, Loader } from "replaywebpage"; @@ -498,11 +496,9 @@ class ArchiveWebApp extends ReplayWebApp { this.embed || this.showDownloadProgress ? 0 : 10 } .shareOpts=${{ ipfsOpts: this.ipfsOpts, btrixOpts: this.btrixOpts }} - swName=${ifDefined(this.swName)} - embed="${ifDefined(this.embed === null ? undefined : this.embed)}" - sourceUrl="${ifDefined( - this.sourceUrl === null ? undefined : this.sourceUrl - )}" + .swName=${this.swName ?? null} + .embed="${this.embed}" + .sourceUrl="${this.sourceUrl}" appName="${this.appName}" appVersion=${VERSION} @replay-favicons=${this.onFavIcons} @@ -994,7 +990,7 @@ class ArchiveWebApp extends ReplayWebApp { type="url" name="btrixUrl" id="btrixUrl" - value="${this.btrixOpts && this.btrixOpts.url}" + value="${this.btrixOpts?.url || ""}" placeholder="https://..." />

@@ -1007,7 +1003,7 @@ class ArchiveWebApp extends ReplayWebApp { type="text" name="btrixUsername" id="btrixUsername" - value="${this.btrixOpts && this.btrixOpts.username}" + value="${this.btrixOpts?.username || ""}" placeholder="Username" />

@@ -1020,7 +1016,7 @@ class ArchiveWebApp extends ReplayWebApp { type="password" name="btrixPassword" id="btrixPassword" - value="${this.btrixOpts && this.btrixOpts.password}" + value="${this.btrixOpts?.password || ""}" placeholder="Password" />

@@ -1033,7 +1029,7 @@ class ArchiveWebApp extends ReplayWebApp { type="text" name="btrixOrgName" id="btrixOrgName" - value="${this.btrixOpts && this.btrixOpts.orgName}" + value="${this.btrixOpts?.orgName || ""}" placeholder="Organization (optional)" />

diff --git a/src/ui/coll-index.ts b/src/ui/coll-index.ts index 1b32bf3c..399056cd 100644 --- a/src/ui/coll-index.ts +++ b/src/ui/coll-index.ts @@ -1,9 +1,8 @@ import { ItemIndex } from "replaywebpage"; import type { PropertyValues } from "lit"; import { property } from "lit/decorators.js"; -import { ifDefined } from "lit/directives/if-defined.js"; -import { html } from "replaywebpage/dist/misc"; +import { html } from "replaywebpage/src/misc"; import prettyBytes from "pretty-bytes"; import { type WrRecCollInfo } from "./coll-info"; @@ -65,7 +64,7 @@ class WrRecCollIndex extends ItemIndex { renderItemInfo(item: WrRecItem) { return html`