如何删除容器和分隔符之间的填充

how to remove the padding betwen container and divider

所以在这个函数中,我的目标是显示一行,其中我有一个标题,然后是一个间隔符,然后是一个值。我的目标是给这个值上色,就好像它是一个彩色的列,但我有问题,我在容器和分隔线之间有一些填充,我希望分隔线就在容器旁边,没有任何填充 有什么问题

coloredRowTable(String title, String value) {
    return Column(
      children: [
        Row(
          children: [
            Text(
              title,
              style: const TextStyle(
                  fontSize: 17,
                  fontFamily: 'SFProRegular',
                  color: Color(0xFF131313)),
            ),
            const Spacer(),
            Container(
              padding: const EdgeInsets.only(bottom: 0.0, top: 0.0),
              color: Colors.green,
              height: 50,
              width: 50,
              child: Text(
                value,
                style: const TextStyle(
                    fontSize: 17,
                    fontFamily: 'SFProRegular',
                    color: Color(0xFF131313)),
              ),
            ),
          ],
        ),
        Divider(
          color: Colors.grey[300],
          indent: 0,
          thickness: 1,
        ),
      ],
    );
  }

您尝试过将 height:0 添加到分隔线吗?

Divider(
 height: 0,
 color: Colors.grey[300],
 indent: 0,
 thickness: 1,
),

对于此类问题,请转到小部件的一个并阅读其parameters.if您尝试所有这些,可能您的问题就会消失。

  Divider(
                color: Colors.grey[300],
                height: 0,
                indent: 0,
                thickness: 1,
              ),