part of user_nick;

class UserNickPage extends StatefulWidget {
  const UserNickPage({Key? key}) : super(key: key);

  @override
  State<UserNickPage> createState() => _UserNickPageState();
}

class _UserNickPageState extends State<UserNickPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: CustomAppBar(
        title: const Text('设置昵称'),
        actions: [
          Container(
            height: 20,
            width: 40,
            decoration: BoxDecoration(
              borderRadius: BorderRadius.circular(10),
              border:Border.all(
                color: AppTheme.primary,
                width: 1
              )
            ),
            child: Center(child: const Text('保存',style: TextStyle(fontSize: 12,color: AppTheme.primary),)),
          )
        ],
      ),
      body: Container(
        margin: const EdgeInsets.symmetric(horizontal: AppTheme.margin),
        height: 52,
        decoration: BoxDecoration(
          borderRadius: BorderRadius.circular(8),
          color: Colors.white
        ),
        child: Container(
          padding: EdgeInsets.symmetric(horizontal: 15),
          child: Row(
            children: [
              Text('昵称'),
              Gaps.hGaps15,
              Expanded(
                child: TextField(
                  decoration: InputDecoration(
                    border: InputBorder.none,
                    enabledBorder: InputBorder.none,
                    focusedBorder: InputBorder.none,
                    suffixIcon: Center(
                      child: IconButton(
                        onPressed: (){

                        },
                        icon: Icon(Icons.clear),
                      ),
                    ),
                    suffixIconConstraints: BoxConstraints.tightFor(height: 15,width: 15)
                  ),
                ),
              )
            ],
          ),
        ),
      ),
    );
  }
}
