Skip to content
This repository was archived by the owner on Feb 4, 2025. It is now read-only.

Commit 52039cd

Browse files
author
Sebastian Superczynski
committed
more lint fixes
1 parent 3b6f404 commit 52039cd

File tree

4 files changed

+17
-16
lines changed

4 files changed

+17
-16
lines changed

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"karma-coverage-istanbul-reporter": "^1.2.1",
4343
"karma-jasmine": "~1.1.0",
4444
"karma-jasmine-html-reporter": "^0.2.2",
45-
"ng-packagr": "^1.3.0",
45+
"ng-packagr": "^1.5.0",
4646
"node-sass": "^4.5.3",
4747
"protractor": "~5.1.2",
4848
"rxjs": "^5.4.3",
@@ -64,6 +64,7 @@
6464
"angular",
6565
"angular2",
6666
"angular4",
67+
"angular5",
6768
"ng2",
6869
"table",
6970
"angular table",

src/app/components/header/header.component.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { Component, Input, Output, EventEmitter } from '@angular/core';
77
<input type="text"
88
id="search_{{ column['key'] }}"
99
aria-label="Search"
10-
placeholder="Search {{ column['key'] }}"
10+
placeholder="Search {{ column['title'] }}"
1111
class="ngx-table__header-search ngx-form-input ngx-input-sm"
1212
#input
1313
(input)="update.emit({value: input.value, key: column['key']})"

src/app/pipes/global-search-pipe.ts

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { Pipe, PipeTransform } from "@angular/core";
2-
import { ResourceService } from "../services/resource-service";
1+
import { Pipe, PipeTransform } from '@angular/core';
2+
import { ResourceService } from '../services/resource-service';
33

44
@Pipe({
55
name: 'global'
@@ -10,30 +10,30 @@ export class GlobalSearchPipe implements PipeTransform {
1010
}
1111

1212
transform(dataArr, filter) {
13-
if (typeof dataArr === "undefined") {
13+
if (typeof dataArr === 'undefined') {
1414
return;
1515
}
16-
if (typeof filter === 'undefined' || Object.keys(filter).length === 0 || filter === "") {
16+
if (typeof filter === 'undefined' || Object.keys(filter).length === 0 || filter === '') {
1717
return dataArr;
1818
}
1919
this.resource.data = [];
2020
dataArr.forEach((row) => {
2121
for (const value in row) {
2222
if (row.hasOwnProperty(value)) {
2323
let element;
24-
if (typeof row[value] === "object") {
24+
if (typeof row[value] === 'object') {
2525
element = JSON.stringify(row[value]).toLocaleLowerCase();
2626
}
27-
if (typeof row[value] === "boolean") {
28-
element = "" + row[value];
27+
if (typeof row[value] === 'boolean') {
28+
element = '' + row[value];
2929
}
30-
if (typeof row[value] === "string") {
30+
if (typeof row[value] === 'string') {
3131
element = row[value].toLocaleLowerCase();
3232
}
33-
if (typeof row[value] === "number") {
34-
element = "" + row[value];
33+
if (typeof row[value] === 'number') {
34+
element = '' + row[value];
3535
}
36-
if (element.indexOf(filter["value"].toLocaleLowerCase()) >= 0) {
36+
if (element.indexOf(filter['value'].toLocaleLowerCase()) >= 0) {
3737
this.resource.data.push(row);
3838
return;
3939
}

src/app/services/index.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
export * from './config-service';
2-
export * from './filters-service';
3-
export * from './resource-service';
1+
export { ConfigService } from './config-service';
2+
export { FiltersService } from './filters-service';
3+
export { ResourceService } from './resource-service';
44

55
// TODO export * from doesn't work with current ng-packagr version
66
// https://github.com/dherges/ng-packagr/issues/195

0 commit comments

Comments
 (0)