refactor(app): replace TauriService with ElectronService usage

This commit is contained in:
4gray committed 2025-10-18 13:05:26 +02:00
1 parent 03268ab8c5
commit 6dcbbadda8
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -24,8 +24,8 @@ import { DataService } from 'services';
import { dbConfig } from 'shared-interfaces';
import { AppConfig } from '../environments/environment';
import { routes } from './app.routes';
import { ElectronService } from './services/electron.service';
import { PwaService } from './services/pwa.service';
import { TauriService } from './services/tauri.service';
// AoT requires an exported function for factories
export function HttpLoaderFactory(http: HttpClient): TranslateHttpLoader {
@@ -37,7 +37,7 @@ export function HttpLoaderFactory(http: HttpClient): TranslateHttpLoader {
*/
export function DataFactory() {
if (window.electron) {
return new TauriService();
return new ElectronService();
}
return new PwaService();
}
@@ -21,7 +21,7 @@ import { AppConfig } from '../../environments/environment';
@Injectable({
providedIn: 'root',
})
export class TauriService extends DataService {
export class ElectronService extends DataService {
private eventListeners: { [key: string]: () => void } = {};
private snackBar = inject(MatSnackBar);