|
|
|
|
@ -4,6 +4,10 @@ import 'dart:io';
|
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
import 'package:nfc_manager/nfc_manager.dart';
|
|
|
|
|
import 'package:nfc_manager/platform_tags.dart';
|
|
|
|
|
import 'package:test_sa/dashboard_latest/dashboard_view.dart';
|
|
|
|
|
import 'package:test_sa/extensions/context_extension.dart';
|
|
|
|
|
import 'package:test_sa/new_views/app_style/app_color.dart';
|
|
|
|
|
import 'package:test_sa/views/app_style/sizing.dart';
|
|
|
|
|
|
|
|
|
|
void showNfcReader(BuildContext context, {Function(String nfcId)? onNcfScan}) {
|
|
|
|
|
showModalBottomSheet(
|
|
|
|
|
@ -79,6 +83,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
|
|
|
|
|
Widget scanNfc() {
|
|
|
|
|
return Container(
|
|
|
|
|
color: AppColor.background(context),
|
|
|
|
|
key: ValueKey(1),
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
|
@ -86,11 +91,12 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 30,
|
|
|
|
|
),
|
|
|
|
|
const Text(
|
|
|
|
|
Text(
|
|
|
|
|
"Ready To Scan",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontSize: 24,
|
|
|
|
|
color:AppColor.headingTextColor(context)
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
@ -99,6 +105,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/ic_nfc.png",
|
|
|
|
|
height: MediaQuery.of(context).size.width / 3,
|
|
|
|
|
color: AppColor.iconColor(context),
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
),
|
|
|
|
|
const SizedBox(
|
|
|
|
|
@ -139,6 +146,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
|
|
|
|
|
Widget doneNfc() {
|
|
|
|
|
return Container(
|
|
|
|
|
color: AppColor.background(context),
|
|
|
|
|
key: ValueKey(2),
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisSize: MainAxisSize.min,
|
|
|
|
|
@ -151,6 +159,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontSize: 24,
|
|
|
|
|
color:AppColor.headingTextColor(context)
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
@ -161,6 +170,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
"assets/images/ic_done.png",
|
|
|
|
|
height: MediaQuery.of(context).size.width / 3,
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
color: AppColor.iconColor(context),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 30,
|
|
|
|
|
@ -189,7 +199,7 @@ class _NfcLayoutState extends State<NfcLayout> {
|
|
|
|
|
// },
|
|
|
|
|
onPressed: null,
|
|
|
|
|
// elevation: 0,
|
|
|
|
|
child: Text("DONE"),
|
|
|
|
|
child: Text("DONE",style: TextStyle(color: context.isDark?AppColor.primary10:null),),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
|