Add 'New update available' dialog to the electron version (#299)

* build(tsconfig): Rename root tsconfig.json -> tsconfig.base.json

* feat(auto-update): Add update dialog

When new update available than new message will visible of the top of the screen with 2 buttons 'Update' and 'Close'.
- Update button: Update the application (close and restart)
- Close button: Hide the updatePanel

* fix(auto-update): Add types to the event methods

* style: Add comma after SafeStylePipe import

I forgot add the comma when I rebased the branch

* fix(auto-update): Use electron-is-dev package to detect dev build

I removed the isDev() function from the shared util library because it is electron specific code.

* ci: Change osx_image: xcode8.3

Recommended after the last travis upgrade

* feat(auto-update): Add auto update settings page and save config save on electron platform

* ci: Fix osx image

* ci: Upgrade the electron builder -> 19.6.1

The builder now use the 2 package.json structure and build only
the necessary dependencies.
This commit is contained in:
Róbert Kiss
2017-06-22 14:22:54 +02:00
committed by László Monda
parent 2598109f8c
commit 121807a65a
49 changed files with 1028 additions and 129 deletions

View File

@@ -60,7 +60,7 @@ import {
} from './shared/components/svg/keys';
import { SvgModuleComponent } from './shared/components/svg/module';
import { SvgKeyboardWrapComponent } from './shared/components/svg/wrap';
import { MainAppComponent, appRoutingProviders, routing } from './main-app';
import { appRoutingProviders, MainAppComponent, routing } from './main-app';
import { CancelableDirective } from './shared/directives';
import { SafeStylePipe } from './shared/pipes';
@@ -69,14 +69,15 @@ import { CaptureService } from './shared/services/capture.service';
import { MapperService } from './shared/services/mapper.service';
import { SvgModuleProviderService } from './shared/services/svg-module-provider.service';
import { KeymapEffects, MacroEffects, UserConfigEffects } from './shared/store/effects';
import { AutoUpdateSettingsEffects, KeymapEffects, MacroEffects, UserConfigEffects } from './shared/store/effects';
import { KeymapEditGuard } from './shared/components/keymap/edit';
import { MacroNotFoundGuard } from './shared/components/macro/not-found';
import { DATA_STORAGE_REPOSITORY } from './shared/services/datastorage-repository.service';
import { LocalDataStorageRepositoryService } from './shared/services/local-datastorage-repository.service';
import { DefaultUserConfigurationService } from './shared/services/default-user-configuration.service';
import { reducer } from '../../shared/src/store/reducers/index';
import { reducer } from './shared/store/reducers/index';
import { AutoUpdateSettings } from './shared/components/auto-update-settings/auto-update-settings';
@NgModule({
declarations: [
@@ -127,7 +128,8 @@ import { reducer } from '../../shared/src/store/reducers/index';
SettingsComponent,
KeyboardSliderComponent,
CancelableDirective,
SafeStylePipe
SafeStylePipe,
AutoUpdateSettings
],
imports: [
BrowserModule,
@@ -147,7 +149,8 @@ import { reducer } from '../../shared/src/store/reducers/index';
Select2Module,
EffectsModule.runAfterBootstrap(KeymapEffects),
EffectsModule.runAfterBootstrap(MacroEffects),
EffectsModule.runAfterBootstrap(UserConfigEffects)
EffectsModule.runAfterBootstrap(UserConfigEffects),
EffectsModule.runAfterBootstrap(AutoUpdateSettingsEffects)
],
providers: [
SvgModuleProviderService,
@@ -156,9 +159,10 @@ import { reducer } from '../../shared/src/store/reducers/index';
KeymapEditGuard,
MacroNotFoundGuard,
CaptureService,
{provide: DATA_STORAGE_REPOSITORY, useClass: LocalDataStorageRepositoryService},
{ provide: DATA_STORAGE_REPOSITORY, useClass: LocalDataStorageRepositoryService },
DefaultUserConfigurationService
],
bootstrap: [MainAppComponent]
})
export class AppModule { }
export class AppModule {
}

View File

@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.json",
"extends": "../../tsconfig.base.json",
"exclude": [
"config-serializer"
]