flutter 我可以在主集装箱边界将一个集装箱放在另一个小集装箱上吗?

r6hnlfcb  于 2023-03-03  发布在  Flutter
关注(0)|答案(1)|浏览(135)

Like This Type
我想使这种类型的用户界面和它的可能不使用堆栈?

jtw3ybtb

jtw3ybtb1#

SizedBox(
              width: MediaQuery.of(context).size.width,
              height: MediaQuery.of(context).size.height / 4,
              child: Padding(
                padding: EdgeInsets.symmetric(horizontal: 8, vertical: 5),
                child: Stack(alignment: Alignment.bottomCenter, children: [
                  Container(
                    margin: EdgeInsets.only(bottom: 5),
                    decoration: BoxDecoration(
                        color: Colors.blueGrey,
                        borderRadius: BorderRadius.circular(20)),
                  ),
                  Container(
                    height: 15,
                    width: MediaQuery.of(context).size.width / 4,
                    decoration: BoxDecoration(
                        color: Colors.black,
                        borderRadius: BorderRadius.circular(20)),
                  )
                ]),
              ),
            )

your problem is fixed now , use this code

相关问题