[nexus] fix(audit): resolve integration checker findings — straggler strings, query param pre-fill, orphaned import
Some checks failed
Docker / build-and-push (push) Has been cancelled

This commit is contained in:
Mikkel Georgsen 2026-03-31 11:08:53 +02:00
parent 104dd06036
commit 4c8cfcd851
5 changed files with 14 additions and 11 deletions

View file

@ -1,5 +1,4 @@
import { useEffect, useState } from "react"; import { useEffect, useState } from "react";
import { VOCAB } from "@paperclipai/branding";
import { useNavigate, useLocation } from "@/lib/router"; import { useNavigate, useLocation } from "@/lib/router";
import { useQuery, useMutation, useQueryClient } from "@tanstack/react-query"; import { useQuery, useMutation, useQueryClient } from "@tanstack/react-query";
import { approvalsApi } from "../api/approvals"; import { approvalsApi } from "../api/approvals";

View file

@ -1,4 +1,5 @@
import { useMemo } from "react"; import { useMemo } from "react";
import { VOCAB } from "@paperclipai/branding"; // [nexus]
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import { Link, useParams, useSearchParams } from "@/lib/router"; import { Link, useParams, useSearchParams } from "@/lib/router";
import { accessApi } from "../api/access"; import { accessApi } from "../api/access";
@ -70,7 +71,7 @@ export function BoardClaimPage() {
return ( return (
<div className="mx-auto max-w-xl py-10"> <div className="mx-auto max-w-xl py-10">
<div className="rounded-lg border border-border bg-card p-6"> <div className="rounded-lg border border-border bg-card p-6">
<h1 className="text-lg font-semibold">Board ownership claimed</h1> <h1 className="text-lg font-semibold">{VOCAB.board} ownership claimed</h1>
<p className="mt-2 text-sm text-muted-foreground"> <p className="mt-2 text-sm text-muted-foreground">
This instance is now linked to your authenticated user. This instance is now linked to your authenticated user.
</p> </p>
@ -88,7 +89,7 @@ export function BoardClaimPage() {
<div className="rounded-lg border border-border bg-card p-6"> <div className="rounded-lg border border-border bg-card p-6">
<h1 className="text-lg font-semibold">Sign in required</h1> <h1 className="text-lg font-semibold">Sign in required</h1>
<p className="mt-2 text-sm text-muted-foreground"> <p className="mt-2 text-sm text-muted-foreground">
Sign in or create an account, then return to this page to claim Board ownership. Sign in or create an account, then return to this page to claim {VOCAB.board} ownership.
</p> </p>
<Button asChild className="mt-4"> <Button asChild className="mt-4">
<Link to={`/auth?next=${encodeURIComponent(currentPath)}`}>Sign in / Create account</Link> <Link to={`/auth?next=${encodeURIComponent(currentPath)}`}>Sign in / Create account</Link>
@ -101,7 +102,7 @@ export function BoardClaimPage() {
return ( return (
<div className="mx-auto max-w-xl py-10"> <div className="mx-auto max-w-xl py-10">
<div className="rounded-lg border border-border bg-card p-6"> <div className="rounded-lg border border-border bg-card p-6">
<h1 className="text-xl font-semibold">Claim Board ownership</h1> <h1 className="text-xl font-semibold">Claim {VOCAB.board} ownership</h1>
<p className="mt-2 text-sm text-muted-foreground"> <p className="mt-2 text-sm text-muted-foreground">
This will promote your user to instance admin and migrate company ownership access from local trusted mode. This will promote your user to instance admin and migrate company ownership access from local trusted mode.
</p> </p>

View file

@ -1,4 +1,5 @@
import { useEffect, useMemo, useRef, useState, type ChangeEvent } from "react"; import { useEffect, useMemo, useRef, useState, type ChangeEvent } from "react";
import { VOCAB } from "@paperclipai/branding"; // [nexus]
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import type { import type {
CompanyPortabilityCollisionStrategy, CompanyPortabilityCollisionStrategy,
@ -1203,7 +1204,7 @@ export function CompanyImport() {
type="text" type="text"
value={newCompanyName} value={newCompanyName}
onChange={(e) => setNewCompanyName(e.target.value)} onChange={(e) => setNewCompanyName(e.target.value)}
placeholder="Imported Company" placeholder={`Imported ${VOCAB.company}`}
/> />
</Field> </Field>
)} )}

View file

@ -225,7 +225,7 @@ export function CompanySettings() {
<div className="max-w-2xl space-y-6"> <div className="max-w-2xl space-y-6">
<div className="flex items-center gap-2"> <div className="flex items-center gap-2">
<Settings className="h-5 w-5 text-muted-foreground" /> <Settings className="h-5 w-5 text-muted-foreground" />
<h1 className="text-lg font-semibold">Company Settings</h1> <h1 className="text-lg font-semibold">{VOCAB.company} Settings</h1>
</div> </div>
{/* General */} {/* General */}
@ -234,7 +234,7 @@ export function CompanySettings() {
General General
</div> </div>
<div className="space-y-3 rounded-md border border-border px-4 py-4"> <div className="space-y-3 rounded-md border border-border px-4 py-4">
<Field label="Company name" hint="The display name for your company."> <Field label={`${VOCAB.company} name`} hint={`The display name for your ${VOCAB.company.toLowerCase()}.`}>
<input <input
className="w-full rounded-md border border-border bg-transparent px-2.5 py-1.5 text-sm outline-none" className="w-full rounded-md border border-border bg-transparent px-2.5 py-1.5 text-sm outline-none"
type="text" type="text"

View file

@ -65,10 +65,12 @@ export function NewAgent() {
const navigate = useNavigate(); const navigate = useNavigate();
const [searchParams] = useSearchParams(); const [searchParams] = useSearchParams();
const presetAdapterType = searchParams.get("adapterType"); const presetAdapterType = searchParams.get("adapterType");
const presetRole = searchParams.get("role"); // [nexus]
const presetName = searchParams.get("name"); // [nexus]
const [name, setName] = useState(""); const [name, setName] = useState(presetName ?? ""); // [nexus]
const [title, setTitle] = useState(""); const [title, setTitle] = useState("");
const [role, setRole] = useState("general"); const [role, setRole] = useState(presetRole ?? "general"); // [nexus]
const [reportsTo, setReportsTo] = useState<string | null>(null); const [reportsTo, setReportsTo] = useState<string | null>(null);
const [configValues, setConfigValues] = useState<CreateConfigValues>(defaultCreateValues); const [configValues, setConfigValues] = useState<CreateConfigValues>(defaultCreateValues);
const [selectedSkillKeys, setSelectedSkillKeys] = useState<string[]>([]); const [selectedSkillKeys, setSelectedSkillKeys] = useState<string[]>([]);
@ -291,9 +293,9 @@ export function NewAgent() {
<div className="border-t border-border px-4 py-4"> <div className="border-t border-border px-4 py-4">
<div className="space-y-3"> <div className="space-y-3">
<div> <div>
<h2 className="text-sm font-medium">Company skills</h2> <h2 className="text-sm font-medium">{VOCAB.company} skills</h2>
<p className="mt-1 text-xs text-muted-foreground"> <p className="mt-1 text-xs text-muted-foreground">
Optional skills from the company library. Built-in Paperclip runtime skills are added automatically. Optional skills from the {VOCAB.company.toLowerCase()} library. Built-in {VOCAB.appName} runtime skills are added automatically.
</p> </p>
</div> </div>
{availableSkills.length === 0 ? ( {availableSkills.length === 0 ? (