* Remove ngx-bootstrap dependency
* Add material button toggle for decorationspull/40/head
parent
0aefb9c6d9
commit
3a6e9b093a
|
@ -4218,8 +4218,8 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"delegates": "^1.0.0",
|
||||
"readable-stream": "^2.0.6"
|
||||
"delegates": "1.0.0",
|
||||
"readable-stream": "2.3.6"
|
||||
}
|
||||
},
|
||||
"balanced-match": {
|
||||
|
@ -4230,7 +4230,7 @@
|
|||
"version": "1.1.11",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"balanced-match": "^1.0.0",
|
||||
"balanced-match": "1.0.0",
|
||||
"concat-map": "0.0.1"
|
||||
}
|
||||
},
|
||||
|
@ -4284,7 +4284,7 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"minipass": "^2.2.1"
|
||||
"minipass": "2.2.4"
|
||||
}
|
||||
},
|
||||
"fs.realpath": {
|
||||
|
@ -4297,14 +4297,14 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"aproba": "^1.0.3",
|
||||
"console-control-strings": "^1.0.0",
|
||||
"has-unicode": "^2.0.0",
|
||||
"object-assign": "^4.1.0",
|
||||
"signal-exit": "^3.0.0",
|
||||
"string-width": "^1.0.1",
|
||||
"strip-ansi": "^3.0.1",
|
||||
"wide-align": "^1.1.0"
|
||||
"aproba": "1.2.0",
|
||||
"console-control-strings": "1.1.0",
|
||||
"has-unicode": "2.0.1",
|
||||
"object-assign": "4.1.1",
|
||||
"signal-exit": "3.0.2",
|
||||
"string-width": "1.0.2",
|
||||
"strip-ansi": "3.0.1",
|
||||
"wide-align": "1.1.2"
|
||||
}
|
||||
},
|
||||
"glob": {
|
||||
|
@ -4312,12 +4312,12 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"fs.realpath": "^1.0.0",
|
||||
"inflight": "^1.0.4",
|
||||
"inherits": "2",
|
||||
"minimatch": "^3.0.4",
|
||||
"once": "^1.3.0",
|
||||
"path-is-absolute": "^1.0.0"
|
||||
"fs.realpath": "1.0.0",
|
||||
"inflight": "1.0.6",
|
||||
"inherits": "2.0.3",
|
||||
"minimatch": "3.0.4",
|
||||
"once": "1.4.0",
|
||||
"path-is-absolute": "1.0.1"
|
||||
}
|
||||
},
|
||||
"has-unicode": {
|
||||
|
@ -4330,7 +4330,7 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"safer-buffer": "^2.1.0"
|
||||
"safer-buffer": "2.1.2"
|
||||
}
|
||||
},
|
||||
"ignore-walk": {
|
||||
|
@ -4338,7 +4338,7 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"minimatch": "^3.0.4"
|
||||
"minimatch": "3.0.4"
|
||||
}
|
||||
},
|
||||
"inflight": {
|
||||
|
@ -4346,8 +4346,8 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"once": "^1.3.0",
|
||||
"wrappy": "1"
|
||||
"once": "1.4.0",
|
||||
"wrappy": "1.0.2"
|
||||
}
|
||||
},
|
||||
"inherits": {
|
||||
|
@ -4363,7 +4363,7 @@
|
|||
"version": "1.0.0",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"number-is-nan": "^1.0.0"
|
||||
"number-is-nan": "1.0.1"
|
||||
}
|
||||
},
|
||||
"isarray": {
|
||||
|
@ -4375,7 +4375,7 @@
|
|||
"version": "3.0.4",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"brace-expansion": "^1.1.7"
|
||||
"brace-expansion": "1.1.11"
|
||||
}
|
||||
},
|
||||
"minimist": {
|
||||
|
@ -4386,8 +4386,8 @@
|
|||
"version": "2.2.4",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"safe-buffer": "^5.1.1",
|
||||
"yallist": "^3.0.0"
|
||||
"safe-buffer": "5.1.1",
|
||||
"yallist": "3.0.2"
|
||||
}
|
||||
},
|
||||
"minizlib": {
|
||||
|
@ -4415,9 +4415,9 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"debug": "^2.1.2",
|
||||
"iconv-lite": "^0.4.4",
|
||||
"sax": "^1.2.4"
|
||||
"debug": "2.6.9",
|
||||
"iconv-lite": "0.4.21",
|
||||
"sax": "1.2.4"
|
||||
}
|
||||
},
|
||||
"node-pre-gyp": {
|
||||
|
@ -4442,8 +4442,8 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"abbrev": "1",
|
||||
"osenv": "^0.1.4"
|
||||
"abbrev": "1.1.1",
|
||||
"osenv": "0.1.5"
|
||||
}
|
||||
},
|
||||
"npm-bundled": {
|
||||
|
@ -4456,8 +4456,8 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"ignore-walk": "^3.0.1",
|
||||
"npm-bundled": "^1.0.1"
|
||||
"ignore-walk": "3.0.1",
|
||||
"npm-bundled": "1.0.3"
|
||||
}
|
||||
},
|
||||
"npmlog": {
|
||||
|
@ -4465,10 +4465,10 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"are-we-there-yet": "~1.1.2",
|
||||
"console-control-strings": "~1.1.0",
|
||||
"gauge": "~2.7.3",
|
||||
"set-blocking": "~2.0.0"
|
||||
"are-we-there-yet": "1.1.4",
|
||||
"console-control-strings": "1.1.0",
|
||||
"gauge": "2.7.4",
|
||||
"set-blocking": "2.0.0"
|
||||
}
|
||||
},
|
||||
"number-is-nan": {
|
||||
|
@ -4484,7 +4484,7 @@
|
|||
"version": "1.4.0",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"wrappy": "1"
|
||||
"wrappy": "1.0.2"
|
||||
}
|
||||
},
|
||||
"os-homedir": {
|
||||
|
@ -4502,8 +4502,8 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"os-homedir": "^1.0.0",
|
||||
"os-tmpdir": "^1.0.0"
|
||||
"os-homedir": "1.0.2",
|
||||
"os-tmpdir": "1.0.2"
|
||||
}
|
||||
},
|
||||
"path-is-absolute": {
|
||||
|
@ -4521,10 +4521,10 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"deep-extend": "^0.5.1",
|
||||
"ini": "~1.3.0",
|
||||
"minimist": "^1.2.0",
|
||||
"strip-json-comments": "~2.0.1"
|
||||
"deep-extend": "0.5.1",
|
||||
"ini": "1.3.5",
|
||||
"minimist": "1.2.0",
|
||||
"strip-json-comments": "2.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"minimist": {
|
||||
|
@ -4539,13 +4539,13 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"core-util-is": "~1.0.0",
|
||||
"inherits": "~2.0.3",
|
||||
"isarray": "~1.0.0",
|
||||
"process-nextick-args": "~2.0.0",
|
||||
"safe-buffer": "~5.1.1",
|
||||
"string_decoder": "~1.1.1",
|
||||
"util-deprecate": "~1.0.1"
|
||||
"core-util-is": "1.0.2",
|
||||
"inherits": "2.0.3",
|
||||
"isarray": "1.0.0",
|
||||
"process-nextick-args": "2.0.0",
|
||||
"safe-buffer": "5.1.1",
|
||||
"string_decoder": "1.1.1",
|
||||
"util-deprecate": "1.0.2"
|
||||
}
|
||||
},
|
||||
"rimraf": {
|
||||
|
@ -4553,7 +4553,7 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"glob": "^7.0.5"
|
||||
"glob": "7.1.2"
|
||||
}
|
||||
},
|
||||
"safe-buffer": {
|
||||
|
@ -4589,9 +4589,9 @@
|
|||
"version": "1.0.2",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"code-point-at": "^1.0.0",
|
||||
"is-fullwidth-code-point": "^1.0.0",
|
||||
"strip-ansi": "^3.0.0"
|
||||
"code-point-at": "1.1.0",
|
||||
"is-fullwidth-code-point": "1.0.0",
|
||||
"strip-ansi": "3.0.1"
|
||||
}
|
||||
},
|
||||
"string_decoder": {
|
||||
|
@ -4599,14 +4599,14 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"safe-buffer": "~5.1.0"
|
||||
"safe-buffer": "5.1.1"
|
||||
}
|
||||
},
|
||||
"strip-ansi": {
|
||||
"version": "3.0.1",
|
||||
"bundled": true,
|
||||
"requires": {
|
||||
"ansi-regex": "^2.0.0"
|
||||
"ansi-regex": "2.1.1"
|
||||
}
|
||||
},
|
||||
"strip-json-comments": {
|
||||
|
@ -4638,7 +4638,7 @@
|
|||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"string-width": "^1.0.2"
|
||||
"string-width": "1.0.2"
|
||||
}
|
||||
},
|
||||
"wrappy": {
|
||||
|
@ -7734,11 +7734,6 @@
|
|||
"integrity": "sha1-yobR/ogoFpsBICCOPchCS524NCw=",
|
||||
"dev": true
|
||||
},
|
||||
"ngx-bootstrap": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/ngx-bootstrap/-/ngx-bootstrap-3.0.1.tgz",
|
||||
"integrity": "sha512-ni91yYtn8ldgf/pxrlwl9lkVcLURGzopSpJnEbbgG1v1EZWTobI8y7J3mx4Kxptkn0EeiQwnLel67G7XJSox4A=="
|
||||
},
|
||||
"ngx-clipboard": {
|
||||
"version": "11.1.1",
|
||||
"resolved": "https://registry.npmjs.org/ngx-clipboard/-/ngx-clipboard-11.1.1.tgz",
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
"jquery": "^3.1.0",
|
||||
"jquery-ui": "^1.12.0",
|
||||
"jquery-ui-bundle": "^1.11.4",
|
||||
"ngx-bootstrap": "^3.0.1",
|
||||
"ngx-clipboard": "^11.1.1",
|
||||
"ngx-cookie-service": "^1.0.9",
|
||||
"ngx-infinite-scroll": "^0.5.2",
|
||||
|
|
|
@ -1,10 +1,16 @@
|
|||
<div class="select-list">
|
||||
<div class="input-group list-header pull-left">
|
||||
<div class="btn-group" (click)="filterDecorations()">
|
||||
<label class="btn btn-success" [(ngModel)]="radioModel" btnRadio="BLUFOR" uncheckable>{{fraction.BLUFOR}}</label>
|
||||
<label class="btn btn-success" [(ngModel)]="radioModel" btnRadio="OPFOR" uncheckable>{{fraction.OPFOR}}</label>
|
||||
<label class="btn btn-success" [(ngModel)]="radioModel" btnRadio="GLOBAL" uncheckable>Global</label>
|
||||
</div>
|
||||
<mat-button-toggle-group #group="matButtonToggleGroup">
|
||||
<mat-button-toggle value="BLUFOR" (change)="filterDecorations(group)">
|
||||
{{fraction.BLUFOR}}
|
||||
</mat-button-toggle>
|
||||
<mat-button-toggle value="OPFOR" (change)="filterDecorations(group)">
|
||||
{{fraction.OPFOR}}
|
||||
</mat-button-toggle>
|
||||
<mat-button-toggle value="GLOBAL" (change)="filterDecorations(group)">
|
||||
Global
|
||||
</mat-button-toggle>
|
||||
</mat-button-toggle-group>
|
||||
<a class="pull-right btn btn-success" (click)="openNewDecorationForm()">+</a>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -7,6 +7,8 @@ import {Observable} from 'rxjs/Observable';
|
|||
import {Decoration} from '../../models/model-interfaces';
|
||||
import {DecorationService} from '../../services/army-management/decoration.service';
|
||||
import {Fraction} from '../../utils/fraction.enum';
|
||||
import {MatButtonToggleGroup} from '@angular/material';
|
||||
import {UIHelpers} from '../../utils/global.helpers';
|
||||
|
||||
@Component({
|
||||
selector: 'decoration-list',
|
||||
|
@ -21,7 +23,7 @@ export class DecorationListComponent implements OnInit {
|
|||
|
||||
searchTerm = new FormControl();
|
||||
|
||||
public radioModel: string;
|
||||
radioModel: string = '';
|
||||
|
||||
readonly fraction = Fraction;
|
||||
|
||||
|
@ -73,7 +75,8 @@ export class DecorationListComponent implements OnInit {
|
|||
}
|
||||
}
|
||||
|
||||
filterDecorations() {
|
||||
filterDecorations(group?: MatButtonToggleGroup) {
|
||||
this.radioModel = UIHelpers.toggleReleaseButton(this.radioModel, group);
|
||||
this.decorations$ = this.decorationService.findDecorations(this.searchTerm.value, this.radioModel);
|
||||
}
|
||||
|
||||
|
|
|
@ -4,11 +4,11 @@ import {CommonModule} from '@angular/common';
|
|||
import {DecorationStore} from '../services/stores/decoration.store';
|
||||
import {DecorationService} from '../services/army-management/decoration.service';
|
||||
import {NgModule} from '@angular/core';
|
||||
import {ButtonsModule} from 'ngx-bootstrap';
|
||||
import {MatButtonToggleModule} from '@angular/material';
|
||||
|
||||
@NgModule({
|
||||
declarations: decorationsRoutingComponents,
|
||||
imports: [CommonModule, SharedModule, ButtonsModule.forRoot(), decorationRoutesModule],
|
||||
imports: [CommonModule, SharedModule, MatButtonToggleModule, decorationRoutesModule],
|
||||
providers: [DecorationStore, DecorationService]
|
||||
})
|
||||
export class DecorationsModule {
|
||||
|
|
|
@ -2,13 +2,12 @@ import {NgModule} from '@angular/core';
|
|||
import {SharedModule} from '../shared.module';
|
||||
import {CommonModule} from '@angular/common';
|
||||
import {RankService} from '../services/army-management/rank.service';
|
||||
import {ButtonsModule} from 'ngx-bootstrap';
|
||||
import {pubRouterModule, pubRoutingComponents} from './public.routing';
|
||||
import {DecorationService} from '../services/army-management/decoration.service';
|
||||
|
||||
@NgModule({
|
||||
declarations: pubRoutingComponents,
|
||||
imports: [CommonModule, SharedModule, ButtonsModule.forRoot(), pubRouterModule],
|
||||
imports: [CommonModule, SharedModule, pubRouterModule],
|
||||
providers: [DecorationService, RankService]
|
||||
})
|
||||
export class PublicModule {
|
||||
|
|
|
@ -4,12 +4,11 @@ import {SharedModule} from '../shared.module';
|
|||
import {statsRouterModule, statsRoutingComponents} from './stats.routing';
|
||||
import {WarService} from '../services/logs/war.service';
|
||||
import {NgxChartsModule} from '@swimlane/ngx-charts';
|
||||
import {AccordionModule, ButtonsModule} from 'ngx-bootstrap';
|
||||
import {CampaignService} from '../services/logs/campaign.service';
|
||||
import {NgxDatatableModule} from '@swimlane/ngx-datatable';
|
||||
import {PlayerService} from '../services/logs/player.service';
|
||||
import {LogsService} from '../services/logs/logs.service';
|
||||
import {MatButtonToggleModule, MatExpansionModule, MatFormFieldModule} from '@angular/material';
|
||||
import {MatButtonToggleModule, MatExpansionModule} from '@angular/material';
|
||||
|
||||
@NgModule({
|
||||
declarations: statsRoutingComponents,
|
||||
|
|
Loading…
Reference in New Issue