mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-16 14:10:48 +08:00
feat(品牌): 支持 _local 外部优先 Logo 与图标覆盖
新增 /admin/brand-assets 静态挂载,并在前端与桌面端统一采用外部优先、内置兜底的品牌资源解析;同时补充 BRANDING 文档与 README 入口说明。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
b15ff4c31c
commit
acf1266e90
7 changed files with 106 additions and 13 deletions
|
|
@ -6,7 +6,11 @@ const pngToIco = typeof pngToIcoModule === "function" ? pngToIcoModule : pngToIc
|
|||
|
||||
async function main() {
|
||||
const desktopRoot = path.resolve(__dirname, "..");
|
||||
const svgPath = path.resolve(desktopRoot, "..", "src", "admin", "static", "oliver.svg");
|
||||
const svgCandidates = [
|
||||
path.resolve(desktopRoot, "..", "_local", "branding", "logo.svg"),
|
||||
path.resolve(desktopRoot, "..", "interfaces", "admin", "static", "oliver.svg"),
|
||||
];
|
||||
const svgPath = svgCandidates.find((p) => fs.existsSync(p)) || svgCandidates[svgCandidates.length - 1];
|
||||
const assetsDir = path.join(desktopRoot, "assets");
|
||||
const icoPath = path.join(assetsDir, "oclaw.ico");
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue