123456789101112131415161718192021222324252627282930313233343536373839404142 |
- import 'package:douyin_demo/providers/recommend_provider.dart';
- import 'package:flutter/material.dart';
- import 'package:provider/provider.dart';
- class BtnContent extends StatelessWidget {
- const BtnContent({Key? key}) : super(key: key);
- @override
- Widget build(BuildContext context) {
- RecommendProvider provider = Provider.of<RecommendProvider>(context);
- return Container(
- child: Column(
- mainAxisSize: MainAxisSize.min,
- children: [
- ListTile(
- title: Text(
- "@${provider.mainInfo.userName}",
- style: TextStyle(color: Colors.white, fontSize: 16),
- ),
- subtitle: Text(
- "${provider.mainInfo.content}",
- style: TextStyle(color: Colors.white, fontSize: 16),
- maxLines: 3,
- overflow: TextOverflow.ellipsis,
- ),
- ),
- Row(
- children: [
- SizedBox(
- width: 10,
- ),
- Icon(
- Icons.music_note,
- color: Colors.white,
- ),
- ],
- )
- ],
- ),
- );
- }
- }
|