Skip to content

Commit 12c0729

Browse files
committed
chore: lint
1 parent 392859b commit 12c0729

File tree

1 file changed

+11
-13
lines changed

1 file changed

+11
-13
lines changed

src/snackbar/snackbar.android.ts

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ export class SnackBar extends SnackBarBase {
5252
while (attachView['_modal']) {
5353
attachView = attachView['_modal'];
5454
}
55-
const page = (attachView instanceof Page ? attachView : attachView.page);
56-
let nView = (page.nativeViewProtected as android.view.View).getParent();
57-
if ( page.hasActionBar) {
55+
const page = attachView instanceof Page ? attachView : attachView.page;
56+
let nView = (page.nativeViewProtected as android.view.View).getParent();
57+
if (page.hasActionBar) {
5858
nView = nView.getParent();
5959
}
6060
let nCoordinatorLayout: androidx.coordinatorlayout.widget.CoordinatorLayout = (page as any).nCoordinatorLayout;
@@ -64,9 +64,9 @@ export class SnackBar extends SnackBarBase {
6464
if (options.view) {
6565
const nAttachedView = options.view.nativeViewProtected as android.view.View;
6666
const params = new android.widget.FrameLayout.LayoutParams(nAttachedView.getWidth(), nAttachedView.getHeight());
67-
const myArray = (Array).create('int', 2);
67+
const myArray = Array.create('int', 2);
6868
nView.getLocationOnScreen(myArray);
69-
const otherArray = (Array).create('int', 2);
69+
const otherArray = Array.create('int', 2);
7070
options.view.nativeViewProtected.getLocationOnScreen(otherArray);
7171

7272
params.topMargin = otherArray[1] - myArray[1];
@@ -130,14 +130,14 @@ export class SnackBar extends SnackBarBase {
130130
resolve({
131131
command: SnackBarAction.ACTION,
132132
reason: _getReason(1),
133-
event: args,
133+
event: args
134134
});
135135
if (this._snackbarCallback) {
136136
this._snackbarCallback.cb = null;
137137
this._snackbarCallback = null;
138138
}
139139
this._snackbar = null;
140-
},
140+
}
141141
});
142142

143143
// set the action text, click listener
@@ -152,7 +152,7 @@ export class SnackBar extends SnackBarBase {
152152
resolve({
153153
command: SnackBarAction.DISMISS,
154154
reason: _getReason(event),
155-
event,
155+
event
156156
});
157157
(cb as any).resolve.resolve = null;
158158
}
@@ -167,9 +167,7 @@ export class SnackBar extends SnackBarBase {
167167
}
168168
},
169169

170-
onShown(snackbar: com.google.android.material.snackbar.Snackbar) {
171-
172-
},
170+
onShown(snackbar: com.google.android.material.snackbar.Snackbar) {}
173171
});
174172
cb.setListener(callbackListener);
175173
(cb as any).nListener = callbackListener; // handles the resolve of the promise
@@ -207,7 +205,7 @@ export class SnackBar extends SnackBarBase {
207205
setTimeout(() => {
208206
resolve({
209207
action: SnackBarAction.DISMISS,
210-
reason: _getReason(3),
208+
reason: _getReason(3)
211209
});
212210
}, 200);
213211
this._snackbar = null;
@@ -217,7 +215,7 @@ export class SnackBar extends SnackBarBase {
217215
} else {
218216
resolve({
219217
action: SnackBarAction.NONE,
220-
message: 'No actionbar to dismiss',
218+
message: 'No actionbar to dismiss'
221219
});
222220
}
223221
});

0 commit comments

Comments
 (0)