This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/main.dart b/lib/main.dart | |
index 439d0fb..fafcf3a 100644 | |
--- a/lib/main.dart | |
+++ b/lib/main.dart | |
@@ -27,6 +27,9 @@ class MyStatefulWidget extends StatefulWidget { | |
class _MyStatefulWidgetState extends State<MyStatefulWidget> { | |
var isSameAddress = true; | |
+ final billingAddress1Key = UniqueKey(); | |
+ final billingAddress2Key = UniqueKey(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/main.dart b/lib/main.dart | |
index 526ac61..439d0fb 100644 | |
--- a/lib/main.dart | |
+++ b/lib/main.dart | |
@@ -31,11 +31,11 @@ class _MyStatefulWidgetState extends State<MyStatefulWidget> { | |
// has been removed | |
@override | |
- Widget build(BuildContext context) => ListView( | |
+ Widget build(BuildContext context) => AutofillGroup( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/main.dart b/lib/main.dart | |
index 4f1704b..526ac61 100644 | |
--- a/lib/main.dart | |
+++ b/lib/main.dart | |
@@ -65,15 +65,18 @@ class _MyStatefulWidgetState extends State<MyStatefulWidget> { | |
}, | |
), | |
if (!isSameAddress) | |
- Column( | |
+ AutofillGroup( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/main.dart b/lib/main.dart | |
index 1460ece..ae75939 100644 | |
--- a/lib/main.dart | |
+++ b/lib/main.dart | |
@@ -35,12 +35,14 @@ class _MyStatefulWidgetState extends State<MyStatefulWidget> { | |
padding: EdgeInsets.symmetric(horizontal: 16), | |
children: [ | |
TextFormField( | |
+ autofillHints: [AutofillHints.streetAddressLine1], | |
decoration: const InputDecoration( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/main.dart b/lib/main.dart | |
index ae75939..4f1704b 100644 | |
--- a/lib/main.dart | |
+++ b/lib/main.dart | |
@@ -33,6 +33,9 @@ class _MyStatefulWidgetState extends State<MyStatefulWidget> { | |
@override | |
Widget build(BuildContext context) => ListView( | |
padding: EdgeInsets.symmetric(horizontal: 16), | |
+ children: [ | |
+ AutofillGroup( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
void main() => runApp(MyApp()); | |
/// This Widget is the main application widget. | |
class MyApp extends StatelessWidget { | |
static const String _title = 'Flutter Code Sample'; | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (var index = 0; index < numDetections; index++) { | |
String detectedClass = localLabels[outputClasses[index].toInt()]; | |
final top = max(0.0, outputLocations[index * 4 + 0]); | |
final left = max(0.0, outputLocations[index * 4 + 1]); | |
final bottom = min(1.0, outputLocations[index * 4 + 2]); | |
final right = min(1.0, outputLocations[index * 4 + 3]); | |
final thisSesult = DetectionResult( | |
rect: Rect.fromLTRB(left, top, right, bottom), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ... | |
final List<DetectionResult> results = List(); | |
for (var index = 0; index < numDetections; index++) { | |
String detectedClass = localLabels[outputClasses[index].toInt()]; | |
// final top // explain shortly after | |
// final left // explain shortly after | |
// final bottom // explain shortly after | |
// final right // explain shortly after |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://www.tensorflow.org/lite/models/object_detection/overview | |
final outputTensors = localInterpreter.getOutputTensors(); | |
final outputLocationsTensor = outputTensors[0]; | |
// shape 1, 10, 4; | |
Float32List outputLocations = | |
outputLocationsTensor.data.buffer.asFloat32List(); | |
final outputClassesTensor = outputTensors[1]; | |
// shape 1, 10 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index | Name | Expected type | Description | |
---|---|---|---|---|
0 | Locations | List<List<Float32>> | Multidimensional array of [10][4] floating point values between 0 and 1, the inner arrays representing bounding boxes in the form [top, left, bottom, right] | |
1 | Classes | List<Float32> | Array of 10 integers (output as floating point values) each indicating the index of a class label from the labels file | |
2 | Scores | List<Float32> | Array of 10 floating point values between 0 and 1 representing probability that a class was detected | |
3 | Number and detections | Float32 | Array of length 1 containing a floating point value expressing the total number of detection results |
NewerOlder