fix: use OnPush change detection on the keymap edit and add pages (#760)
* fix: use OnPush change detection on the keymap edit and add pages * fix: font-size
This commit is contained in:
committed by
László Monda
parent
a7d3b62512
commit
df817e86d6
6
packages/uhk-web/package-lock.json
generated
6
packages/uhk-web/package-lock.json
generated
@@ -227,9 +227,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@ert78gb/ngx-select-ex": {
|
"@ert78gb/ngx-select-ex": {
|
||||||
"version": "3.7.0",
|
"version": "3.7.2",
|
||||||
"resolved": "https://registry.npmjs.org/@ert78gb/ngx-select-ex/-/ngx-select-ex-3.7.0.tgz",
|
"resolved": "https://registry.npmjs.org/@ert78gb/ngx-select-ex/-/ngx-select-ex-3.7.2.tgz",
|
||||||
"integrity": "sha512-m3DyGB1VZrxsItgc/NjBt5ZfW1DuQrxLz82ekw/ur79DZHG89EYohKWbx68lonfu8wM+AT4IHUDVqF1gFhyK0g==",
|
"integrity": "sha512-tFliRieRxNLHLpUGqGez2++C5PmmUYd1AvriHK2127X0QhOp3hWZ1/4j9etF9ZgE4Ti465sUtu8KcK5B0jjiTQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"tslib": "1.9.0"
|
"tslib": "1.9.0"
|
||||||
|
|||||||
@@ -62,7 +62,7 @@
|
|||||||
"ng2-dragula": "1.5.0",
|
"ng2-dragula": "1.5.0",
|
||||||
"ng2-nouislider": "^1.7.7",
|
"ng2-nouislider": "^1.7.7",
|
||||||
"ngx-clipboard": "10.0.0",
|
"ngx-clipboard": "10.0.0",
|
||||||
"@ert78gb/ngx-select-ex": "3.7.0",
|
"@ert78gb/ngx-select-ex": "3.7.2",
|
||||||
"ngrx-store-freeze": "0.1.9",
|
"ngrx-store-freeze": "0.1.9",
|
||||||
"nouislider": "^11.1.0",
|
"nouislider": "^11.1.0",
|
||||||
"postcss-url": "^7.1.2",
|
"postcss-url": "^7.1.2",
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Component } from '@angular/core';
|
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
||||||
import { Store } from '@ngrx/store';
|
import { Store } from '@ngrx/store';
|
||||||
import { Keymap } from 'uhk-common';
|
import { Keymap } from 'uhk-common';
|
||||||
|
|
||||||
@@ -14,6 +14,7 @@ import { KeymapActions } from '../../../store/actions';
|
|||||||
selector: 'keymap-add',
|
selector: 'keymap-add',
|
||||||
templateUrl: './keymap-add.component.html',
|
templateUrl: './keymap-add.component.html',
|
||||||
styleUrls: ['./keymap-add.component.scss'],
|
styleUrls: ['./keymap-add.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
host: {
|
host: {
|
||||||
'class': 'container-fluid'
|
'class': 'container-fluid'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Component, HostListener } from '@angular/core';
|
import { ChangeDetectionStrategy, Component, HostListener } from '@angular/core';
|
||||||
import { ActivatedRoute } from '@angular/router';
|
import { ActivatedRoute } from '@angular/router';
|
||||||
import { Store } from '@ngrx/store';
|
import { Store } from '@ngrx/store';
|
||||||
import { Keymap } from 'uhk-common';
|
import { Keymap } from 'uhk-common';
|
||||||
@@ -24,6 +24,7 @@ import { ChangeKeymapDescription } from '../../../models/ChangeKeymapDescription
|
|||||||
selector: 'keymap-edit',
|
selector: 'keymap-edit',
|
||||||
templateUrl: './keymap-edit.component.html',
|
templateUrl: './keymap-edit.component.html',
|
||||||
styleUrls: ['./keymap-edit.component.scss'],
|
styleUrls: ['./keymap-edit.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
host: {
|
host: {
|
||||||
'class': 'container-fluid'
|
'class': 'container-fluid'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import {
|
import {
|
||||||
|
ChangeDetectionStrategy,
|
||||||
Component,
|
Component,
|
||||||
ElementRef,
|
ElementRef,
|
||||||
EventEmitter,
|
EventEmitter,
|
||||||
@@ -47,6 +48,7 @@ enum TabName {
|
|||||||
selector: 'popover',
|
selector: 'popover',
|
||||||
templateUrl: './popover.component.html',
|
templateUrl: './popover.component.html',
|
||||||
styleUrls: ['./popover.component.scss'],
|
styleUrls: ['./popover.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
animations: [
|
animations: [
|
||||||
trigger('popover', [
|
trigger('popover', [
|
||||||
state('closed', style({
|
state('closed', style({
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
import { Component, EventEmitter, HostListener, Output, Input } from '@angular/core';
|
import { ChangeDetectionStrategy, Component, EventEmitter, HostListener, Input, Output } from '@angular/core';
|
||||||
import { CaptureService } from '../../../../services/capture.service';
|
import { CaptureService } from '../../../../services/capture.service';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'capture-keystroke-button',
|
selector: 'capture-keystroke-button',
|
||||||
templateUrl: './capture-keystroke-button.component.html',
|
templateUrl: './capture-keystroke-button.component.html',
|
||||||
styleUrls: ['./capture-keystroke-button.component.scss']
|
styleUrls: ['./capture-keystroke-button.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush
|
||||||
})
|
})
|
||||||
export class CaptureKeystrokeButtonComponent {
|
export class CaptureKeystrokeButtonComponent {
|
||||||
@Input() isLink = false;
|
@Input() isLink = false;
|
||||||
|
|||||||
@@ -1,9 +1,10 @@
|
|||||||
import { Component, Input, OnInit } from '@angular/core';
|
import { ChangeDetectionStrategy, Component, Input, OnInit } from '@angular/core';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'icon',
|
selector: 'icon',
|
||||||
templateUrl: './icon.component.html',
|
templateUrl: './icon.component.html',
|
||||||
styleUrls: ['./icon.component.scss']
|
styleUrls: ['./icon.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush
|
||||||
})
|
})
|
||||||
export class IconComponent implements OnInit {
|
export class IconComponent implements OnInit {
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import { SvgKeyboardKey } from '../keys';
|
|||||||
import {
|
import {
|
||||||
SvgKeyCaptureEvent,
|
SvgKeyCaptureEvent,
|
||||||
SvgKeyClickEvent,
|
SvgKeyClickEvent,
|
||||||
SvgModuleCaptureEvent,
|
SvgModuleCaptureEvent,
|
||||||
SvgModuleKeyClickEvent
|
SvgModuleKeyClickEvent
|
||||||
} from '../../../models/svg-key-events';
|
} from '../../../models/svg-key-events';
|
||||||
|
|
||||||
|
|||||||
@@ -4,6 +4,10 @@ ngx-select,
|
|||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
input.input-sm {
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
.dropdown-header {
|
.dropdown-header {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 1em;
|
font-size: 1em;
|
||||||
|
|||||||
Reference in New Issue
Block a user