Skip to content

Commit 0537635

Browse files
authored
Quick-fix for the Google button (#181)
1 parent 137bc93 commit 0537635

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

packages/google-signin/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,19 @@ try {
7878
} catch (e) {}
7979
}
8080
```
81+
#### Angular usage
82+
On your `module.ts`
83+
```ts
84+
import { registerElement } from '@nativescript/angular';
85+
registerElement('GoogleSignInButton', () => require('@nativescript/google-signin').GoogleSignInButton);
86+
```
87+
88+
And then it can be called from your `html` file choosing the desired option for colorScheme and colorStyle as:
89+
```xml
90+
<GoogleSignInButton colorScheme='auto' colorStyle='standard' (tap)="yourGoogleSigninFunction()"></GoogleSignInButton>
91+
```
92+
93+
`colorScheme` supports 'auto', 'dark' and 'light' options and `colorStyle`supports 'standard'. 'wide' and 'icon'. Since it's a button, you can also set some of its properties such as `height` or `width`.
8194

8295
## configure(options)
8396

packages/google-signin/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ declare class GoogleSignin {
5454
static playServicesAvailable(): Promise<boolean>;
5555
}
5656

57-
declare class GoogleSignInButton extends GoogleSignInButtonBase {
57+
export declare class GoogleSignInButton extends GoogleSignInButtonBase {
5858
colorScheme: ColorSchemeType;
5959
colorStyle: ColorStyleType;
6060
}

0 commit comments

Comments
 (0)