26 lines
724 B
TypeScript
26 lines
724 B
TypeScript
import client, { ensureAuthenticated } from "../src/lib/directus";
|
|
import { updateSettings } from "@directus/sdk";
|
|
|
|
async function setupBranding() {
|
|
console.log("🎨 Setup Directus Branding...");
|
|
await ensureAuthenticated();
|
|
|
|
try {
|
|
await client.request(
|
|
updateSettings({
|
|
project_name: process.env.PROJECT_NAME || "Mintel Project",
|
|
project_color: process.env.PROJECT_COLOR || "#82ed20",
|
|
theme_light_overrides: {
|
|
primary: process.env.PROJECT_COLOR || "#82ed20",
|
|
borderRadius: "16px",
|
|
},
|
|
} as any),
|
|
);
|
|
console.log("✨ Branding applied!");
|
|
} catch (error) {
|
|
console.error("❌ Error setting up branding:", error);
|
|
}
|
|
}
|
|
|
|
setupBranding();
|