fix(connection): correct MongoDB OIDC form layout
This commit is contained in:
2 files changed
+17
-3
No files matched your search
@@ -6964,9 +6964,12 @@ function openExternalUrl(url: string) {
|
|||||||
</SelectContent>
|
</SelectContent>
|
||||||
</Select>
|
</Select>
|
||||||
</div>
|
</div>
|
||||||
<p v-if="mongoAuthMechanism === 'MONGODB-OIDC'" class="col-start-2 col-span-3 text-xs text-muted-foreground">
|
<div v-if="mongoAuthMechanism === 'MONGODB-OIDC'" class="grid grid-cols-4 items-start gap-4">
|
||||||
{{ t("connection.oidcBrowserAuthHint") }}
|
<span />
|
||||||
</p>
|
<p class="col-span-3 text-xs text-muted-foreground">
|
||||||
|
{{ t("connection.oidcBrowserAuthHint") }}
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
<div class="grid grid-cols-4 items-center gap-4">
|
<div class="grid grid-cols-4 items-center gap-4">
|
||||||
<Label :class="connectionLabelClass">{{ t("connection.urlParams") }}</Label>
|
<Label :class="connectionLabelClass">{{ t("connection.urlParams") }}</Label>
|
||||||
<Input v-model="form.url_params" class="col-span-3" placeholder="replicaSet=rs0&authSource=admin" />
|
<Input v-model="form.url_params" class="col-span-3" placeholder="replicaSet=rs0&authSource=admin" />
|
||||||
|
|||||||
+11
@@ -0,0 +1,11 @@
|
|||||||
|
import { readFileSync } from "node:fs";
|
||||||
|
import { describe, expect, it } from "vitest";
|
||||||
|
|
||||||
|
const dialogSource = readFileSync(new URL("../../../components/connection/ConnectionDialog.vue", import.meta.url), "utf8");
|
||||||
|
|
||||||
|
describe("MongoDB OIDC connection form", () => {
|
||||||
|
it("keeps the browser authentication hint inside a complete form row", () => {
|
||||||
|
expect(dialogSource).toContain(`<div v-if="mongoAuthMechanism === 'MONGODB-OIDC'" class="grid grid-cols-4 items-start gap-4">`);
|
||||||
|
expect(dialogSource).not.toContain(`<p v-if="mongoAuthMechanism === 'MONGODB-OIDC'" class="col-start-2 col-span-3`);
|
||||||
|
});
|
||||||
|
});
|
||||||
Reference in new issue
Block a user