#flutter #mobile #flutter-layout
Вопрос:
Я завернул два развернутых вида в ряд, но не смог их завернуть. это выходит за рамки моего макета экрана.
как новичок в технологии flutter, я ценю чью — то помощь.
Row(
mainAxisSize: MainAxisSize.max,
children: [
Expanded(
flex: 1,
child: Row(
mainAxisSize: MainAxisSize.max,
children: [
Image.asset('assets/images/checked.png',height: 24,width: 24,),
SizedBox(width: 5,),
Text('Gated Security',style: Constant.infoTextStyle,)
],
),
),
Expanded(
flex: 1,
child: Row(
children: [
Image.asset('assets/images/checked.png',height: 24,width: 24,),
SizedBox(width: 5,),
Column(
children: [
Text('Individual slips and along-side docking',style: Constant.infoTextStyle,textAlign: TextAlign.start,),
],
)
],
),
),
],
),
Ответ №1:
Добавьте maxLines: null
в свой Text
виджет
Также оберните свой Column
виджет с Expanded
Комментарии:
1. Все то же самое 🙁
2. попробуйте обернуть виджеты столбцов и текста расширенными