level 1
零点`
楼主
Consumer<_State>( builder: (context, ref, child) { return Container( width: double.infinity, padding: EdgeInsets.only(top: 20, left: 20, right: 20), child: ref.tabIndex == 0 ? ScanCodeComponent() : QrCode(), ); }, ),
这是条件渲染组件,QrCode() 中使用了TextField(),切换tabIndex 时就会报错,页面渲染不出来,把TextField()注释了就正常显示了#
2026年02月07日 08点02分
1
这是条件渲染组件,QrCode() 中使用了TextField(),切换tabIndex 时就会报错,页面渲染不出来,把TextField()注释了就正常显示了#