【问题标题】:Flutter How to make CupertinoFullScreenDialog?Flutter 如何制作 CupertinoFullScreenDialog?
【发布时间】:2020-04-18 00:52:36
【问题描述】:

我想在flutter中破解iOS全屏对话框something like this,有什么建议或解决方案吗?

提前致谢

【问题讨论】:

    标签: flutter flutter-cupertino


    【解决方案1】:

    来试试这个吧,我想这就是你要找的东西

    //This should be one of the first lines in your build function
    Size size = MediaQuery.of(context).size;
    
    RaisedButton(
                    child: Text('Show Bottom Modal'),
                    onPressed: () => showModalBottomSheet(
                      isScrollControlled: true,
                      shape: RoundedRectangleBorder(
                          borderRadius: BorderRadius.circular(30)),
                      context: context,
                      builder: (context) => Container(
                        color: Colors.amber,
                        height: size.height,
                      ),
                    ),
                  )
    

    让我知道这对你有什么作用

    【讨论】:

      猜你喜欢
      • 2019-05-19
      • 2023-03-25
      • 2020-12-22
      • 2022-09-23
      • 2021-10-04
      • 2023-03-18
      • 2021-08-19
      • 2020-11-28
      • 2021-10-02
      相关资源
      最近更新 更多