Skip to content

Commit

Permalink
feat: add list example (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
bharat-1809 authored May 21, 2024
1 parent 423f702 commit f26c5fe
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions example/lib/glass_card_list.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
import 'package:example/ios_home/glass_widget.dart';
import 'package:flutter/material.dart';

class GlassCardList extends StatelessWidget {
const GlassCardList({super.key});
@override
Widget build(BuildContext context) {
return Scaffold(
body: Container(
alignment: Alignment.center,
decoration: BoxDecoration(
image: DecorationImage(
fit: BoxFit.cover,
image: AssetImage('assets/bg_1.jpg'),
),
),
child: SafeArea(
child: ListView.separated(
itemCount: 50,
padding: EdgeInsets.all(16),
separatorBuilder: (context, index) => SizedBox(height: 16),
itemBuilder: (context, index) {
return SizedBox(
height: 102,
child: GlassWidget(
child: ListTile(
title: Text('Item $index'),
leading: Icon(Icons.ac_unit),
subtitle: Text('Subtitle $index'),
trailing: Icon(Icons.arrow_forward_ios),
),
),
);
},
),
),
),
);
}
}

0 comments on commit f26c5fe

Please sign in to comment.