mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-07 04:20:12 +02:00
fix(build): do not add hash to favicon and assets
This commit is contained in:
+1
-1
@@ -870,7 +870,7 @@ if (!singleInstance) {
|
|||||||
app.whenReady()
|
app.whenReady()
|
||||||
.then(() => {
|
.then(() => {
|
||||||
protocol.handle('feishin', async (request) => {
|
protocol.handle('feishin', async (request) => {
|
||||||
const filePath = `file://${request.url.slice('feishin://'.length)}`;
|
const filePath = `file:${request.url.slice('feishin:'.length)}`;
|
||||||
const response = await net.fetch(filePath);
|
const response = await net.fetch(filePath);
|
||||||
const contentType = response.headers.get('content-type');
|
const contentType = response.headers.get('content-type');
|
||||||
|
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ export const useAppTheme = (overrideTheme?: AppTheme) => {
|
|||||||
textStyleRef.current.textContent = `
|
textStyleRef.current.textContent = `
|
||||||
@font-face {
|
@font-face {
|
||||||
font-family: "dynamic-font";
|
font-family: "dynamic-font";
|
||||||
src: url("feishin://${custom}");
|
src: url("feishin:${custom}");
|
||||||
}`;
|
}`;
|
||||||
} else {
|
} else {
|
||||||
const root = document.documentElement;
|
const root = document.documentElement;
|
||||||
|
|||||||
+9
-9
@@ -26,17 +26,17 @@ export default defineConfig({
|
|||||||
output: {
|
output: {
|
||||||
assetFileNames: (assetInfo) => {
|
assetFileNames: (assetInfo) => {
|
||||||
const stableNames = [
|
const stableNames = [
|
||||||
'32x32',
|
'32x32.png',
|
||||||
'64x64',
|
'64x64.png',
|
||||||
'128x128',
|
'128x128.png',
|
||||||
'256x256',
|
'256x256.png',
|
||||||
'512x512',
|
'512x512.png',
|
||||||
'1024x1024',
|
'1024x1024.png',
|
||||||
'favicon',
|
'favicon.ico',
|
||||||
'preview_full_screen_player',
|
'preview_full_screen_player.webp',
|
||||||
];
|
];
|
||||||
|
|
||||||
if (assetInfo.name && stableNames.includes(assetInfo.name)) {
|
if (assetInfo.names.length === 1 && stableNames.includes(assetInfo.names[0])) {
|
||||||
return 'assets/[name][extname]';
|
return 'assets/[name][extname]';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user