Flutter 按下按钮时颤振显示文本

Flutter 按下按钮时颤振显示文本,flutter,Flutter,我有一行文字,上面写着使用条款,还有一个按钮。我想显示一些数据,但可能我没有使用正确的关键字。我得到的只是如何在点击按钮时更改文本 无论如何,我应该怎么做才能让用户在点击按钮时看到使用条款 Container( padding: EdgeInsets.only(top: 20), child: Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, chil

我有一行文字,上面写着
使用条款
,还有一个按钮。我想显示一些数据,但可能我没有使用正确的关键字。我得到的只是如何在点击按钮时更改文本

无论如何,我应该怎么做才能让用户在点击按钮时看到使用条款

      Container(
        padding: EdgeInsets.only(top: 20),
        child: Row(
          mainAxisAlignment: MainAxisAlignment.spaceBetween,
          children: <Widget>[
            Text(
              "Terms of Use",
              style: TextStyle(
                color: Color(0xff18172b),
                fontSize: 18,
                fontFamily: "Poppins",
                fontWeight: FontWeight.w400,
              ),
            ),
            IconButton(
                iconSize: 18,
                onPressed: () {},
                icon: Icon(Icons.arrow_forward_ios))
          ],
        ),
      ),
容器(
填充:仅限边缘设置(顶部:20),
孩子:排(
mainAxisAlignment:mainAxisAlignment.spaceBetween,
儿童:[
正文(
“使用条款”,
样式:TextStyle(
颜色:颜色(0xff18172b),
尺码:18,
fontFamily:“罂粟”,
fontWeight:fontWeight.w400,
),
),
图标按钮(
iconSize:18,
按下:(){},
图标:图标(图标。箭头\前进\ ios))
],
),
),

您可以导航到另一个包含术语的页面,或显示如下模式:

            IconButton(
                iconSize: 18,
                onPressed: () async {
                  await showDialog(
                      barrierColor: Colors.black12.withOpacity(.6),
                      context: context,
                      builder: (_) {
                        return Dialog(
                          elevation: 0,
                          backgroundColor: Colors.transparent,
                          child: Container(
                            child: Text("TERMS"),
                          ),
                        );
                      });
                },
                icon: Icon(Icons.arrow_forward_ios))

您可以导航到另一个包含术语的页面,或显示如下模式:

            IconButton(
                iconSize: 18,
                onPressed: () async {
                  await showDialog(
                      barrierColor: Colors.black12.withOpacity(.6),
                      context: context,
                      builder: (_) {
                        return Dialog(
                          elevation: 0,
                          backgroundColor: Colors.transparent,
                          child: Container(
                            child: Text("TERMS"),
                          ),
                        );
                      });
                },
                icon: Icon(Icons.arrow_forward_ios))

这将以一种非常好的方式显示条款,是否可以只在同一页中执行?一旦应用程序与后端连接,所有数据都将来自
protobuf
对象。我只想在
容器下显示一些模拟数据。我还将为按钮添加一些动画。比如:右箭头会变成下箭头等等@FahimHoque当然可以。。检查我编辑的答案。这将以一种非常好的方式显示术语。是否可以只在同一页中执行?一旦应用程序与后端连接,所有数据都将来自
protobuf
对象。我只想在
容器下显示一些模拟数据。我还将为按钮添加一些动画。比如:右箭头会变成下箭头等等@FahimHoque当然可以。。检查答案,我已经编辑过了。