Skip to content

Commit 85c8e16

Browse files
committed
fix linter
1 parent 681d235 commit 85c8e16

File tree

4 files changed

+23
-32
lines changed

4 files changed

+23
-32
lines changed

src/fab-common.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export class FloatingActionButtonBase extends View implements definitions.Fab {
4343
: this._getDurationDefault(animationType);
4444

4545
swipeItem.on("pan", (args: PanGestureEventData) => {
46-
//Swipe up
46+
// Swipe up
4747
if (args.deltaY < -10) {
4848
switch (animationType) {
4949
case "slideUp":
@@ -106,7 +106,7 @@ export class FloatingActionButtonBase extends View implements definitions.Fab {
106106
break;
107107
}
108108
} else if (args.deltaY > 0) {
109-
//Swipe Down
109+
// Swipe Down
110110
switch (animationType) {
111111
case "slideUp":
112112
fab.animate({

src/fab.android.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export class Fab extends FloatingActionButtonBase {
7373
}
7474

7575
[backgroundInternalProperty.setNative](value: any) {
76-
//NOOP
76+
// NOOP
7777
}
7878

7979
[rippleColorProperty.setNative](value: Color) {

src/fab.ios.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ export class Fab extends FloatingActionButtonBase {
3030
if (ImageSource.isFileOrResourcePath(value)) {
3131
iconDrawable = ImageSource.fromFileOrResource(value);
3232

33-
//Set the new one
33+
// Set the new one
3434
if (iconDrawable !== null) {
3535
newImageView = UIImageView.alloc().initWithImage(iconDrawable.ios);
3636
}
3737
} else {
38-
//Default image
38+
// Default image
3939
const defaultImage = ImageSource.fromBase64(
4040
"iVBORw0KGgoAAAANSUhEUgAAAJAAAACQAQAAAADPPd8VAAAAAnRSTlMAAHaTzTgAAAAqSURBVHgBY6AMjIJRYP9n0AuNCo0KMf+HgwPDTmgoRMeo0KgQRWAUjAIABsnZRR7bYyUAAAAASUVORK5CYII="
4141
);
@@ -44,12 +44,12 @@ export class Fab extends FloatingActionButtonBase {
4444
}
4545

4646
if (newImageView !== null) {
47-
//Kill the old Image, cocoapod doesn't support changing it yet
47+
// Kill the old Image, cocoapod doesn't support changing it yet
4848
const button = this.nativeView.subviews[0];
4949
const oldBadImageView = button.subviews[0];
5050
oldBadImageView.removeFromSuperview();
5151

52-
//Add the new guy
52+
// Add the new guy
5353
button.addSubview(newImageView);
5454
}
5555
}

src/package.json

Lines changed: 16 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
{
22
"name": "nativescript-floatingactionbutton",
33
"version": "4.1.0",
4-
"description":
5-
"A NativeScript plugin for Material Design Floating Action Button.",
4+
"description": "A NativeScript plugin for Material Design Floating Action Button.",
65
"main": "fab",
76
"typings": "index.d.ts",
87
"nativescript": {
@@ -24,31 +23,24 @@
2423
"scripts": {
2524
"tsc": "tsc -skipLibCheck",
2625
"build": "npm i && tsc",
27-
"postclone":
28-
"npm i && node scripts/postclone.js && cd ../demo && npm i && cd ../src && npm run plugin.link",
29-
"test.android":
30-
"npm i && npm run tsc && npm run tslint && cd ../demo && tns build android && tns test android --justlaunch",
31-
"test.ios":
32-
"npm i && npm run tsc && npm run tslint && cd ../demo && tns build ios && tns test ios --justlaunch",
33-
"tslint":
34-
"cd .. && tslint \"**/*.ts\" --config tslint.json --exclude \"**/node_modules/**\"",
35-
"plugin.link":
36-
"npm link && cd ../demo && npm link nativescript-floatingactionbutton && cd ../src",
26+
"postclone": "npm i && node scripts/postclone.js && cd ../demo && npm i && cd ../src && npm run plugin.link",
27+
"test.android": "npm i && npm run tsc && npm run tslint && cd ../demo && tns build android && tns test android --justlaunch",
28+
"test.ios": "npm i && npm run tsc && npm run tslint && cd ../demo && tns build ios && tns test ios --justlaunch",
29+
"tslint": "cd .. && tslint \"**/*.ts\" --config tslint.json --exclude \"**/node_modules/**\"",
30+
"plugin.link": "npm link && cd ../demo && npm link nativescript-floatingactionbutton && cd ../src",
3731
"plugin.tscwatch": "npm run tsc -- -w",
38-
"demo.ios":
39-
"npm i && npm run tsc && cd ../demo && tns run ios --syncAllFiles",
40-
"demo.android":
41-
"npm i && npm run tsc && cd ../demo && tns run android --syncAllFiles",
32+
"demo.ios": "npm i && npm run tsc && cd ../demo && tns run ios --syncAllFiles",
33+
"demo.android": "npm i && npm run tsc && cd ../demo && tns run android --syncAllFiles",
4234
"demo.reset": "cd ../demo && rimraf platforms",
43-
"plugin.prepare":
44-
"npm run tsc && cd ../demo && tns plugin remove nativescript-floatingactionbutton && tns plugin add ../src",
45-
"clean":
46-
"cd ../demo && rimraf hooks node_modules platforms && cd ../src && rimraf node_modules && npm run plugin.link",
47-
"ci.tslint":
48-
"npm i && tslint '**/*.ts' --config '../tslint.json' --exclude '**/node_modules/**'",
35+
"plugin.prepare": "npm run tsc && cd ../demo && tns plugin remove nativescript-floatingactionbutton && tns plugin add ../src",
36+
"clean": "cd ../demo && rimraf hooks node_modules platforms && cd ../src && rimraf node_modules && npm run plugin.link",
37+
"ci.tslint": "npm i && tslint '**/*.ts' --config '../tslint.json' --exclude '**/node_modules/**'"
4938
},
5039
"lint-staged": {
51-
"*.ts": ["prettier --write", "git add"]
40+
"*.ts": [
41+
"prettier --write",
42+
"git add"
43+
]
5244
},
5345
"keywords": [
5446
"ecosystem:nativescript",
@@ -99,8 +91,7 @@
9991
}
10092
],
10193
"license": "MIT",
102-
"bugs":
103-
"https://github.com/bradmartin/nativescript-floatingactionbutton/issues",
94+
"bugs": "https://github.com/bradmartin/nativescript-floatingactionbutton/issues",
10495
"homepage": "https://github.com/bradmartin/nativescript-floatingactionbutton",
10596
"devDependencies": {
10697
"husky": "^0.13.4",

0 commit comments

Comments
 (0)