Fix URL List showing scope accidentally (#1536)
fix call from when(...) to call function directly, avoid implicit true, which results in page scope being shown for url list. fixes #1535 To test: 1) Create new workflow of type URL List 2) Ensure the Crawl Scope drop down is not shown. --------- Co-authored-by: sua yoo <sua@suayoo.com>
This commit is contained in:
parent
be1dc80e4a
commit
ba18abc063
@ -19,6 +19,7 @@ import {
|
|||||||
import { when } from "lit/directives/when.js";
|
import { when } from "lit/directives/when.js";
|
||||||
import { msg, localized, str } from "@lit/localize";
|
import { msg, localized, str } from "@lit/localize";
|
||||||
import { ifDefined } from "lit/directives/if-defined.js";
|
import { ifDefined } from "lit/directives/if-defined.js";
|
||||||
|
import { choose } from "lit/directives/choose.js";
|
||||||
import compact from "lodash/fp/compact";
|
import compact from "lodash/fp/compact";
|
||||||
import { mergeDeep } from "immutable";
|
import { mergeDeep } from "immutable";
|
||||||
import flow from "lodash/fp/flow";
|
import flow from "lodash/fp/flow";
|
||||||
@ -666,14 +667,11 @@ export class CrawlConfigEditor extends LiteElement {
|
|||||||
<btrix-tab-panel name="newJobConfig-crawlSetup" class="scroll-m-3">
|
<btrix-tab-panel name="newJobConfig-crawlSetup" class="scroll-m-3">
|
||||||
${this.renderPanelContent(
|
${this.renderPanelContent(
|
||||||
html`
|
html`
|
||||||
${when(this.jobType === "url-list", this.renderUrlListSetup)}
|
${choose(this.jobType, [
|
||||||
${when(
|
["url-list", () => this.renderUrlListSetup(false)],
|
||||||
this.jobType === "seed-crawl",
|
["seed-crawl", () => this.renderSeededCrawlSetup()],
|
||||||
this.renderSeededCrawlSetup,
|
["custom", () => this.renderUrlListSetup(true)],
|
||||||
)}
|
])}
|
||||||
${when(this.jobType === "custom", () =>
|
|
||||||
this.renderUrlListSetup(true),
|
|
||||||
)}
|
|
||||||
`,
|
`,
|
||||||
{ isFirst: true },
|
{ isFirst: true },
|
||||||
)}
|
)}
|
||||||
|
Loading…
Reference in New Issue
Block a user