我正在做一个项目,为此我想要一张图像背景模糊的底页。为此,我实现了这段代码,该代码工作正常,但有一个问题。
Widget build(BuildContext context) {
return Container(
height: MediaQuery.of(context).size.height * 0.33,
child: Stack(
overflow: Overflow.visible,
fit: StackFit.expand,
children: [
Container(
height: MediaQuery.of(context).size.height * 0.25,
decoration: new BoxDecoration(
image: new DecorationImage(
image: new AssetImage("assets/images/bookshelf.jpg"),
fit: BoxFit.cover,
)),
),
Positioned(
width: MediaQuery.of(context).size.width,
height: MediaQuery.of(context).size.height * 0.25,
child: BackdropFilter(
filter: ImageFilter.blur(sigmaX: 3, sigmaY: 3),
child: Container(color: Colors.white.withOpacity(0)),
),
),
],
),
);
}
Run Code Online (Sandbox Code Playgroud)
输出是这样的:
它使整个屏幕模糊,但我想仅在模态表中模糊。我的问题是什么?我是颤振新手,所以对此了解不多。请在这件事上给予我帮助。
我为大学创建了一个 Django 应用程序(“监考管理系统”)。我没有包含任何登录授权,因为它只会被大学管理员使用。在这个应用程序中,我还剩下一项任务,我必须通过邮件为数据库中的所有用户发送可用性表格,要求他们填写表格,无论他们当天是否有空,根据他们的回复我必须存储它们在数据库中的可用性状态。如何通过邮件发送表格?或者我应该向他们发送表格的链接?如果我必须发送链接,如何仅通过更改他们获得的链接来防止一个用户访问其他用户的表单,知道如何添加令牌及其唯一 id 吗?