Skip to content

Commit

Permalink
Dependencies updated and new release
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisChV committed Dec 14, 2020
1 parent 0440acf commit 15106c9
Show file tree
Hide file tree
Showing 10 changed files with 83 additions and 45 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## [0.1.0]

- `isOnIOS()` function added
- Dependencies updated

## [0.0.1]

- First release
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Flutter package with general functions, get environment, get device, get network
- **isOnRelease():** Verifies if the app is running on release.
- **isOnTest():** Verifies if the app is running in a test environment.
- **isOnWeb():** Verifies if the app is running on web
- **isOnIOS():** Verifies if the app is running in iOS
- **supportsAppleSignIn():** Verifies if the app supports Apple Sign In.
- **getGmailProfileUrl():** Get the Gmail profile URL with configurable height and width. Generally used in Google login.
- **getFacebookProfileUrl():** Get the Facebook profile URL with configurable height and width. Generally used in Facebook login.
Expand Down
1 change: 1 addition & 0 deletions example/android/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
org.gradle.jvmargs=-Xmx1536M
android.useAndroidX=true
android.enableJetifier=true
android.enableR8=true
2 changes: 2 additions & 0 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ class _MyHomePageState extends State<MyHomePage> {
SizedBox(height: 40),
PUtils.isOnWeb() ? Text("App is running in Web") : Text("App is not running in Web"),
SizedBox(height: 40),
PUtils.isOnIOS() ? Text("App is running in iOS") : Text("App is not running in iOS"),
SizedBox(height: 40),
FutureBuilder(
future: PUtils.supportsAppleSignIn(),
builder: (context, snap){
Expand Down
49 changes: 28 additions & 21 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,49 +7,49 @@ packages:
name: async
url: "https://pub.dartlang.org"
source: hosted
version: "2.5.0-nullsafety"
version: "2.5.0-nullsafety.3"
boolean_selector:
dependency: transitive
description:
name: boolean_selector
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety"
version: "2.1.0-nullsafety.3"
characters:
dependency: transitive
description:
name: characters
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety.2"
version: "1.1.0-nullsafety.5"
charcode:
dependency: transitive
description:
name: charcode
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0-nullsafety"
version: "1.2.0-nullsafety.3"
clock:
dependency: transitive
description:
name: clock
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety"
version: "1.1.0-nullsafety.3"
collection:
dependency: transitive
description:
name: collection
url: "https://pub.dartlang.org"
source: hosted
version: "1.15.0-nullsafety.2"
version: "1.15.0-nullsafety.5"
connectivity:
dependency: transitive
description:
name: connectivity
url: "https://pub.dartlang.org"
source: hosted
version: "0.4.9+3"
version: "2.0.2"
connectivity_for_web:
dependency: transitive
description:
Expand Down Expand Up @@ -84,7 +84,7 @@ packages:
name: device_info
url: "https://pub.dartlang.org"
source: hosted
version: "0.4.2+8"
version: "1.0.0"
device_info_platform_interface:
dependency: transitive
description:
Expand All @@ -98,7 +98,7 @@ packages:
name: fake_async
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety"
version: "1.2.0-nullsafety.3"
flutter:
dependency: "direct main"
description: flutter
Expand All @@ -114,27 +114,34 @@ packages:
description: flutter
source: sdk
version: "0.0.0"
js:
dependency: transitive
description:
name: js
url: "https://pub.dartlang.org"
source: hosted
version: "0.6.3-nullsafety.3"
matcher:
dependency: transitive
description:
name: matcher
url: "https://pub.dartlang.org"
source: hosted
version: "0.12.10-nullsafety"
version: "0.12.10-nullsafety.3"
meta:
dependency: transitive
description:
name: meta
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.0-nullsafety.2"
version: "1.3.0-nullsafety.6"
path:
dependency: transitive
description:
name: path
url: "https://pub.dartlang.org"
source: hosted
version: "1.8.0-nullsafety"
version: "1.8.0-nullsafety.3"
paulonia_utils:
dependency: "direct main"
description:
Expand All @@ -160,56 +167,56 @@ packages:
name: source_span
url: "https://pub.dartlang.org"
source: hosted
version: "1.8.0-nullsafety"
version: "1.8.0-nullsafety.4"
stack_trace:
dependency: transitive
description:
name: stack_trace
url: "https://pub.dartlang.org"
source: hosted
version: "1.10.0-nullsafety"
version: "1.10.0-nullsafety.6"
stream_channel:
dependency: transitive
description:
name: stream_channel
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety"
version: "2.1.0-nullsafety.3"
string_scanner:
dependency: transitive
description:
name: string_scanner
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0-nullsafety"
version: "1.1.0-nullsafety.3"
term_glyph:
dependency: transitive
description:
name: term_glyph
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0-nullsafety"
version: "1.2.0-nullsafety.3"
test_api:
dependency: transitive
description:
name: test_api
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.19-nullsafety"
version: "0.2.19-nullsafety.6"
typed_data:
dependency: transitive
description:
name: typed_data
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.0-nullsafety.2"
version: "1.3.0-nullsafety.5"
vector_math:
dependency: transitive
description:
name: vector_math
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0-nullsafety.2"
version: "2.1.0-nullsafety.5"
sdks:
dart: ">=2.10.0-0.0.dev <2.10.0"
dart: ">=2.12.0-0.0 <3.0.0"
flutter: ">=1.17.0 <2.0.0"
5 changes: 5 additions & 0 deletions lib/paulonia_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ class PUtils {
return kIsWeb;
}

/// Verifies if the app is running in iOS
static bool isOnIOS() {
return PUtilsPlatform.isOnIOS();
}

/// Verifies if the app supports Apple Sign In
static Future<bool> supportsAppleSignIn() {
return PUtilsPlatform.supportsAppleSignIn();
Expand Down
5 changes: 5 additions & 0 deletions lib/paulonia_utils_mobile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,9 @@ class PUtilsPlatform {
static bool isOnTest() {
return Platform.environment.containsKey('FLUTTER_TEST');
}

/// Verifies if the app is running in iOS
static bool isOnIOS() {
return Platform.isIOS;
}
}
5 changes: 5 additions & 0 deletions lib/paulonia_utils_web.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,9 @@ class PUtilsPlatform {
static bool isOnTest() {
return false;
}

/// Verifies if the app is running in iOS
static bool isOnIOS() {
return false;
}
}
Loading

0 comments on commit 15106c9

Please sign in to comment.