当前位置: 首页 > news >正文

哈尔滨建站的网站网页建设一个聊天类的网站

哈尔滨建站的网站网页,建设一个聊天类的网站,wordpress 获取文件路径,模糊背景网站下拉列表 内容和下拉列表的标题均可滑动 Expanded: 内容限制组件,将其子类中的无限扩展的界面限制在一定范围中。在此使用,是为了防止下拉列表中的内容超过了屏幕限制。 SingleChildScrollView: 这个组件,从名字中可…

下拉列表

内容和下拉列表的标题均可滑动

Expanded: 内容限制组件,将其子类中的无限扩展的界面限制在一定范围中。在此使用,是为了防止下拉列表中的内容超过了屏幕限制。

SingleChildScrollView: 这个组件,从名字中可以看出来,不必多说,是可以控制的滑动组件,并且是其系统自带的

ExpansionTile: 这个就是系统自带的下拉列表组件,title中展示下拉列表的标题,children[ ] 中展示下拉列表的内容。

 Expanded(child: SingleChildScrollView(	//滑动组件child: ExpansionTile(	title: Text(		//下拉列表的标题"详细信息",style: TextStyle(fontWeight: FontWeight.bold, fontSize: ScreenUtil().setSp(32)),),children: [  //下拉列表中的内容Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 10),child: _patientinfo()),Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 10),child: _vitalsign(),),Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 20),child: _inspect(),),Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 20),child: _firstaid(),),Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 20),child: _handovertime(),),Container(padding: EdgeInsets.only(left: 30, right: 20, bottom: 20),child: _remarks(),),],)))

在这里插入图片描述
使用这个三个组件进行嵌套的话,是可以实现下拉列表滑动,但是,其标题也可以滑动了,不满足策划需求。所以又做出了第二种方式。如下所示

内容均可滑动,标题不滑动

为了使下拉列表的标题不动,内容可以进行滑动,系统自带的下拉列表不能满足条件,通过不同的组件组合,实现这个功能。
在此使用了InkWell组件。并且加载了动画,在点击时,动画展开面板,如下图所示。

class PulldownItem extends StatefulWidget {PulldownItem({Key? key}) : super(key: key);State<PulldownItem> createState() => _PulldownItemState();
}class _PulldownItemState extends State<PulldownItem>with SingleTickerProviderStateMixin {late AnimationController _animationController;late Animation<double> _animation;var _crossFadeState = CrossFadeState.showSecond;void initState() {super.initState();_animationController = AnimationController(duration: const Duration(milliseconds: 300), vsync: this);_animation = Tween(begin: .5, end: 0.0).animate(_animationController);}void dispose() {_animationController.dispose();super.dispose();}Widget build(BuildContext context) {return Container(width: double.infinity,margin: EdgeInsets.only(bottom: 30.w),child: Column(children: [InkWell(highlightColor: Colors.transparent,splashColor: Colors.transparent,onTap: () {if (_animationController.status == AnimationStatus.completed) {_animationController.reverse();_crossFadeState = CrossFadeState.showSecond;} else {_animationController.forward();_crossFadeState = CrossFadeState.showFirst;}setState(() {});},child: Padding(padding: EdgeInsets.symmetric(horizontal: 32.w, vertical: 30.w),child: Row(children: [Text("widget.title",  //下拉列表的标题style: TextStyle(fontSize: 32.sp,color: Colors.black,fontWeight: FontWeight.bold,height: 1),),const Spacer(),RotationTransition(			//下拉列表右边的小三角形alignment: Alignment.center,turns: _animation,child: Image.asset('assets/login/select_img_ambulance.png',width: 46.w,fit: BoxFit.contain,),),],),),),Expanded(child: AnimatedCrossFade(duration: const Duration(milliseconds: 300),firstChild: Container(width: double.infinity,padding: EdgeInsets.symmetric(horizontal: 32.w),child: SingleChildScrollView(child: Column(children: [		//下拉列表的内容,在此是可以滑动的Text("下拉列表的内容"),],),),),secondChild: const SizedBox(width: double.infinity,),crossFadeState: _crossFadeState,),),],),);}
}
http://www.yayakq.cn/news/998611/

相关文章:

  • 宜昌哪里有专业做网站的带有互动的网站开发
  • 加强网站建设 基本措施海外网络专线免费
  • 网站开发工程师证书有用吗搜索百度网址版搜索
  • 网站建设与管理的网页本溪兼职网站建设招聘
  • 商派商城网站建设公司织梦动漫网站模板
  • 手游网站建设的宗旨大数据营销网站
  • 做网站流程内容网站打开显示域名错误
  • 提供零基础网站建设教学培训宝应县网络推广公司
  • 品牌商城网站开发用织梦系统做的2个网站要把它都上传到服务器上吗
  • 石家庄做网络推广的网站企业网站官网制作
  • 网站开发 设置背景图片房山新农村建设网站
  • 网站开发时什么时间适合创建视图抖音账号权重查询
  • 开源商城网站网站建设与管理案例教程第三版答案
  • 网站建设毕业设计中期检查设计招聘信息
  • 做学校子网站网站建设与管理基础
  • 移动网站建设制作58同城济南网站建设
  • 进入网上商城seo入门讲解
  • 网站开发报价表的文档织梦网站转移
  • 用自己的电脑做视频网站coding.net wordpress
  • 做封面的网站在哪里企业名录搜索软件排名
  • 织梦57网站的友情链接怎么做有免费的网站服务器吗
  • 珠海做网站找哪家公司怎么注册阿里巴巴店铺
  • 默认网站停止关键词排名是由什么决定的
  • 做网站用方正字体可以额的公司装修开工大吉贺词
  • 关于企业网站建设的相关思考买网站空间
  • jsp做的网站答辩问题福州网站建设设计公司
  • 酒类网站建河南郑州旅游网站制作
  • 网站项目风险wordpress登出
  • 求个网站好人一生平安电商仓储代发招商合作
  • 网站建设资料app关键词推广