mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-18 08:43:57 +00:00
feat: notification preview on theme editor
This commit is contained in:
@@ -20,11 +20,10 @@ import { db, gamesSublevel, levelKeys } from "@main/level";
|
||||
import { orderBy, slice } from "lodash-es";
|
||||
import type {
|
||||
AchievementCustomNotificationPosition,
|
||||
AchievementNotificationInfo,
|
||||
ScreenState,
|
||||
UserPreferences,
|
||||
} from "@types";
|
||||
import { AuthPage } from "@shared";
|
||||
import { AuthPage, generateAchievementCustomNotificationTest } from "@shared";
|
||||
import { isStaging } from "@main/constants";
|
||||
|
||||
export class WindowManager {
|
||||
@@ -377,23 +376,7 @@ export class WindowManager {
|
||||
this.notificationWindow?.webContents.send(
|
||||
"on-achievement-unlocked",
|
||||
userPreferences.achievementCustomNotificationPosition ?? "top_left",
|
||||
[
|
||||
{
|
||||
title: t("test_achievement_notification_title", {
|
||||
ns: "notifications",
|
||||
lng: language,
|
||||
}),
|
||||
description: t("test_achievement_notification_description", {
|
||||
ns: "notifications",
|
||||
lng: language,
|
||||
}),
|
||||
iconUrl: "https://cdn.losbroxas.org/favicon.svg",
|
||||
points: 100,
|
||||
isHidden: false,
|
||||
isRare: false,
|
||||
isPlatinum: false,
|
||||
},
|
||||
] as AchievementNotificationInfo[]
|
||||
[generateAchievementCustomNotificationTest(t, language)]
|
||||
);
|
||||
}, 1000);
|
||||
}
|
||||
@@ -419,7 +402,7 @@ export class WindowManager {
|
||||
}
|
||||
|
||||
const editorWindow = new BrowserWindow({
|
||||
width: 600,
|
||||
width: 720,
|
||||
height: 720,
|
||||
minWidth: 600,
|
||||
minHeight: 540,
|
||||
|
||||
Reference in New Issue
Block a user