UNPKG

@fntio/infra-client

Version:

Self-hosted AWS access portal: credential vending, target-account trust, and grant-driven private networking as CDK stacks and constructs.

14 lines (13 loc) • 628 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.DASHBOARD_LAYOUT_MODES = void 0; exports.resolveDashboardLayout = resolveDashboardLayout; exports.DASHBOARD_LAYOUT_MODES = ["auto", "sections", "plain"]; /** A bad value must fail synth — the API would silently fall back to `auto`. */ function resolveDashboardLayout(cfg) { const layout = cfg?.layout ?? "auto"; if (!exports.DASHBOARD_LAYOUT_MODES.includes(layout)) { throw new Error(`dashboard.layout must be one of ${exports.DASHBOARD_LAYOUT_MODES.join(", ")} (got ${JSON.stringify(layout)}).`); } return layout; }