-
Notifications
You must be signed in to change notification settings - Fork 157
Closed
Description
hi, thanks for great package
I am using ReorderableWrap of 'reorderables' package.
I found feedback's location is wrong when using responsive_framework package.
More generally, there are same problem when using Draggable widget.
following is minimal reproducible application.
import 'package:flutter/material.dart';
import 'package:responsive_framework/responsive_framework.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
builder: (context, widget) {
return ResponsiveWrapper.builder(
BouncingScrollWrapper.builder(context, widget),
maxWidth: 1200,
minWidth: 350,
debugLog: false,
defaultScale: true,
breakpoints: [
ResponsiveBreakpoint.resize(350, name: MOBILE, scaleFactor: 0.8),
ResponsiveBreakpoint.autoScale(800, name: TABLET, scaleFactor: 1.4),
ResponsiveBreakpoint.autoScale(1000, name: TABLET, scaleFactor: 1.4),
const ResponsiveBreakpoint.resize(1200, name: DESKTOP),
const ResponsiveBreakpoint.autoScale(2460, name: "4K"),
],
mediaQueryData: MediaQuery.of(context).copyWith(textScaleFactor: 1),
background: Container(),
);
},
home: DraggableExample(),
);
}
}
class DraggableExample extends StatefulWidget {
@override
DraggableExampleState createState() => DraggableExampleState();
}
class DraggableExampleState extends State<DraggableExample> with SingleTickerProviderStateMixin {
@override
Widget build(BuildContext context) {
return Scaffold(
body: Column(
children: [
Spacer(),
Row(
children: [
Spacer(),
Draggable(
feedback: Container(
width: 60,
height: 60,
color: Colors.red,
),
child: Container(
width: 60,
height: 60,
color: Colors.red,
),
),
],
),
SizedBox(height: MediaQuery.of(context).padding.bottom,),
],
)
);
}
}
If item is on top-left, there are no or small difference, on right-bottom there are big difference.
I intentionally put scale factor apart from 1.0
Can you help me?
gcostaapps, cyrilOrderoo and ed-oo
Metadata
Metadata
Assignees
Labels
No labels