Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion components/tiers/new-form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,8 @@ export function TiersNewForm({ open, onOpenChange, onSuccess }: TiersNewFormProp
<DialogBody className="min-h-0 overflow-y-auto overscroll-contain">
{!type ? (
<div className="grid grid-cols-1 gap-4 md:grid-cols-2">
{TIER_PROVIDERS.map((item) => (
{/* Wasabi is hidden pending future workflow and scenario improvements. */}
{TIER_PROVIDERS.filter((item) => item.value !== "wasabi").map((item) => (
<button
key={item.value}
id={`tier-provider-${item.value}`}
Expand Down
3 changes: 2 additions & 1 deletion tests/lib/tier-support-source.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ test("tier picker hides Huawei and Tencent without filtering existing rows", ()
assert.equal(hookSource.includes("UNSUPPORTED_TIER_TYPES"), false)
})

test("Wasabi is supported by tier rows and all name-based actions", () => {
test("Wasabi is hidden from the tier picker while existing rows and name-based actions remain supported", () => {
const newFormSource = fs.readFileSync("components/tiers/new-form.tsx", "utf8")
const pageSource = fs.readFileSync("app/(dashboard)/tiers/page.tsx", "utf8")
const hookSource = fs.readFileSync("hooks/use-tiers.ts", "utf8")
Expand All @@ -37,6 +37,7 @@ test("Wasabi is supported by tier rows and all name-based actions", () => {
assert.match(newFormSource, /buildTierPayload\(type,/)
assert.match(newFormSource, /selectedOption\?\.labelKey/)
assert.match(newFormSource, /disabled=\{item\.disabled\}/)
assert.match(newFormSource, /TIER_PROVIDERS\.filter\(\(item\) => item\.value !== "wasabi"\)\.map/)
})

test("Wasabi form keeps failures in context and protects duplicate submissions", () => {
Expand Down
Loading