| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677 |
- import 'package:electronic_assistant/base/base_page.dart';
- import 'package:electronic_assistant/module/files/controller.dart';
- import 'package:flutter/material.dart';
- import '../../resource/assets.gen.dart';
- class FilesPage extends BasePage<FilesController> {
- const FilesPage({super.key});
- @override
- Widget? buildBody(BuildContext context) {
- return Flex(
- direction: Axis.vertical,
- children: [
- Column(
- children: [
- AppBar(
- title: const Text('文件夹'),
- actions: [
- IconButton(
- onPressed: () {},
- icon: ImageIcon(Assets.images.iconFilesNewDir.provider()),
- ),
- IconButton(
- onPressed: () {},
- icon: ImageIcon(Assets.images.iconMore.provider()),
- ),
- ],
- ),
- Container(
- height: 36,
- decoration: BoxDecoration(
- color: Colors.white,
- borderRadius: BorderRadius.circular(8),
- ),
- child: Flex(
- direction: Axis.horizontal,
- children: [
- ImageIcon(Assets.images.iconSearch.provider()),
- const Expanded(
- child: TextField(
- decoration: InputDecoration(
- hintText: '搜索所有文件标题 / 内容',
- ),
- ))
- ],
- ),
- ),
- ],
- ),
- Expanded(
- child: NestedScrollView(
- headerSliverBuilder: (BuildContext context, bool innerBoxIsScrolled) {
- return <Widget>[
- GridView.builder(
- gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(
- crossAxisCount: 2,
- ),
- itemBuilder: (BuildContext context, int index) {
- return const SizedBox();
- },
- ),
- const Text('全部谈话'),
- ];
- },
- body: AnimatedList(
- initialItemCount: 10,
- itemBuilder:
- (BuildContext context, int index, Animation<double> animation) {
- return const SizedBox();
- },
- ),
- ))
- ],
- );
- }
- }
|