Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(sdk): flutter configs #3

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 2 additions & 15 deletions flutter/ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
PODS:
- Flutter (1.0.0)
- geocoding_ios (1.0.5):
- Flutter
- geolocator_apple (1.2.0):
- Flutter
- location (0.0.1):
- Flutter
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
- permission_handler_apple (9.1.1):
- Flutter
- url_launcher_ios (0.0.1):
Expand All @@ -18,25 +13,19 @@ PODS:

DEPENDENCIES:
- Flutter (from `Flutter`)
- geocoding_ios (from `.symlinks/plugins/geocoding_ios/ios`)
- geolocator_apple (from `.symlinks/plugins/geolocator_apple/ios`)
- location (from `.symlinks/plugins/location/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
- webview_flutter_wkwebview (from `.symlinks/plugins/webview_flutter_wkwebview/ios`)

EXTERNAL SOURCES:
Flutter:
:path: Flutter
geocoding_ios:
:path: ".symlinks/plugins/geocoding_ios/ios"
geolocator_apple:
:path: ".symlinks/plugins/geolocator_apple/ios"
location:
:path: ".symlinks/plugins/location/ios"
path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/darwin"
permission_handler_apple:
:path: ".symlinks/plugins/permission_handler_apple/ios"
url_launcher_ios:
Expand All @@ -46,14 +35,12 @@ EXTERNAL SOURCES:

SPEC CHECKSUMS:
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
geocoding_ios: a389ea40f6f548de6e63006a2e31bf66ff80769a
geolocator_apple: cc556e6844d508c95df1e87e3ea6fa4e58c50401
location: d5cf8598915965547c3f36761ae9cc4f4e87d22e
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943
permission_handler_apple: e76247795d700c14ea09e3a2d8855d41ee80a2e6
url_launcher_ios: 08a3dfac5fb39e8759aeb0abbd5d9480f30fc8b4
url_launcher_ios: 68d46cc9766d0c41dbdc884310529557e3cd7a86
webview_flutter_wkwebview: 2e2d318f21a5e036e2c3f26171342e95908bd60a

PODFILE CHECKSUM: 3a174512d42ae52b7c64ab3e1db696302157cc9f

COCOAPODS: 1.11.3
COCOAPODS: 1.13.0
63 changes: 48 additions & 15 deletions flutter/lib/main.dart
Original file line number Diff line number Diff line change
@@ -1,26 +1,51 @@
import 'package:flutter/material.dart';
import 'package:vatom_wallet_sdk/vatom_wallet_sdk.dart';
import 'package:vatom_flutter/vatom_classes.dart';
import 'package:vatom_flutter/vatom_wallet.dart';

// import 'package:my_app/gradient_color.dart';

main() {
final vatomKey = GlobalKey<VatomWalletState>();
final VatomConfig vatomConfig = VatomConfig(
baseUrl: "https://23e9-201-141-16-18.ngrok-free.app",
features: VatomConfigFeatures(
hideNavigation: false,
scanner: ScannerFeatures(enabled: null),
vatom: VatomFeatures(
hideTokenActions: true,
),
),
);

final VatomWallet wallet = VatomWallet(
key: vatomKey,
businessId: "dZCHAOE76T",

accessToken:
"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6Imw0Mjd4WnJxNjJlR0xhS0hhc0d0bkkyZ1JZVjF3c0VUUm0weDlDcEZiOWsifQ.eyJ1cm46dmF0b21pbmM6Z3Vlc3QiOmZhbHNlLCJ1cm46dmF0b21pbmM6cmVnaW9uIjoidXMtZWFzdDQuZ2NwIiwianRpIjoiRHoxRmhpdERBU2g4WG8zaEFmX1pBIiwic3ViIjoiY3hwNGs5cCIsIm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gPvel-shCxS04FI-7pRxY9-cf_YfaEscho8BQOvFTLnhj40E-6YGITlFgxLWnQ4doisYu4gqRTXEUCflbA9Z6HMqpu85xE67sgqWWwt2YSCBOYNEa0dOYeMbL82E4OP1nOVNtfRgt0asqUwKQg9FgleM0l55zt9iYBW_DAgt8y4rZfIui_PfQqBPRUNnaf_o6kWIMoOTwuSoPYW4dZS1UWYvL05dg2hHKmAwplWprcVnt8mfRI5vwcu8Z8A",
config: VatomConfigFeatures(
hideNavigation: false,
// baseUrl: "https://0dda-201-141-20-186.ngrok-free.app/"
),
// config: VatomConfigFeatures(
// hideNavigation: false,
// hideTokenActions: true,
// disableNewTokenToast: true,
// baseUrl: "https://0dda-201-141-20-186.ngrok-free.app/",
// scanner: ScannerFeatures(enabled: false),
// pageConfig: PageConfig(
// theme: PageTheme(
// header: PageThemeHeader(
// logo: "https://resources.vatom.com/a8BxS4bNj9/UR_Logo.png"),
// iconTitle: PageThemeIconTitle(),
// icon: PageThemeIcon(),
// main: PageThemeMain(),
// emptyState: PageThemeEmptyState(),
// mode: "dark",
// pageTheme: "dark"),
// text: PageText(emptyState: ""),
// features: PageFeatures(
// notifications: PageFeaturesNotifications(),
// card: PageFeaturesCard(),
// footer: PageFeaturesFooter(enabled: true, icons: [
// PageFeaturesFooterIcon(
// src: "https:sites.vatom.com/a8BxS4bNj9",
// title: "Home",
// id: "home")
// ]),
// vatom: PageFeaturesVatom()),
// ),
// ),
);

runApp(
Expand All @@ -36,6 +61,8 @@ main() {
children: [
ElevatedButton(
onPressed: () async {
var t = await vatomKey.currentState?.getTabs();
print("TABS $t");
// await vatomKey.currentState?.openCommunity('sahMOa1qQR',
// roomId: '!EcINyJyITqdmqVEAVe%3Avatom.com');
var tabs = await vatomKey.currentState?.getCurrentUser();
Expand All @@ -51,10 +78,16 @@ main() {
),
ElevatedButton(
onPressed: () async {
await vatomKey.currentState?.navigateToTab("Home");
await vatomKey.currentState?.navigateToTab("Wallet");
},
child: Text('Home'),
child: Text('Wallet'),
),
ElevatedButton(
onPressed: () async {
await vatomKey.currentState?.navigateToTab("Map");
},
child: Text('Map'),
)
],
),
],
Expand Down
Loading