2024-08-19 08:44:44 +00:00
|
|
|
// import 'package:flutter/material.dart';
|
|
|
|
|
2024-08-30 12:24:54 +00:00
|
|
|
// class ModalBottomSheetDemo extends StatelessWidget {
|
|
|
|
// const ModalBottomSheetDemo({Key? key}) : super(key: key);
|
2024-08-19 08:44:44 +00:00
|
|
|
|
|
|
|
// @override
|
2024-08-30 12:24:54 +00:00
|
|
|
// Widget build(BuildContext context) {
|
|
|
|
// return Center(
|
|
|
|
// child: ElevatedButton(
|
|
|
|
// child: const Text('showModalBottomSheet'),
|
|
|
|
// onPressed: () {
|
|
|
|
// // when raised button is pressed
|
|
|
|
// // we display showModalBottomSheet
|
|
|
|
// showModalBottomSheet<dynamic>(
|
|
|
|
// isScrollControlled: true,
|
|
|
|
// // context and builder are
|
|
|
|
// // required properties in this widget
|
|
|
|
// context: context,
|
|
|
|
// builder: (BuildContext context) {
|
|
|
|
// // we set up a container inside which
|
|
|
|
// // we create center column and display text
|
|
|
|
|
|
|
|
// // Returning SizedBox instead of a Container
|
|
|
|
// return Container(
|
|
|
|
// width: double.infinity,
|
|
|
|
// child: Wrap(
|
|
|
|
// // mainAxisSize: MainAxisSize.max,
|
|
|
|
// children: [
|
|
|
|
// Expanded(
|
|
|
|
// child: SingleChildScrollView(
|
|
|
|
// child: Column(
|
|
|
|
// //mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
// children: <Widget>[
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
// Text('GeeksforGeeks'),
|
|
|
|
|
|
|
|
// // ListView(
|
|
|
|
// // children: [
|
|
|
|
// // ...List.generate(
|
|
|
|
// // 10,
|
|
|
|
// // (index) => Text('GeeksforGeeks'),
|
|
|
|
// // )
|
|
|
|
// // ],
|
|
|
|
// // )
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
// );
|
|
|
|
// },
|
|
|
|
// );
|
|
|
|
// },
|
|
|
|
// ),
|
|
|
|
// );
|
2024-08-19 08:44:44 +00:00
|
|
|
// }
|
2024-08-30 12:24:54 +00:00
|
|
|
// }
|
|
|
|
// import 'package:flutter/material.dart';
|
2024-08-19 08:44:44 +00:00
|
|
|
|
2024-08-30 12:24:54 +00:00
|
|
|
// // Define your number of items
|
|
|
|
// const int numberOfItems = 5; // Replace with the desired number
|
2024-08-19 08:44:44 +00:00
|
|
|
|
2024-08-30 12:24:54 +00:00
|
|
|
// class MyCarousel extends StatelessWidget {
|
2024-08-19 08:44:44 +00:00
|
|
|
// @override
|
|
|
|
// Widget build(BuildContext context) {
|
|
|
|
// return Scaffold(
|
2024-08-30 12:24:54 +00:00
|
|
|
// body: ExpandableCarousel(
|
|
|
|
// options: CarouselOptions(
|
|
|
|
// showIndicator: false,
|
|
|
|
// slideIndicator: CircularWaveSlideIndicator(
|
|
|
|
// alignment: Alignment.bottomCenter,
|
|
|
|
// currentIndicatorColor: Colors.blue, // Replace with your color
|
|
|
|
// indicatorBackgroundColor: Colors.grey,
|
|
|
|
// ),
|
|
|
|
// autoPlay: true,
|
|
|
|
// autoPlayInterval: const Duration(seconds: 2),
|
|
|
|
// ),
|
|
|
|
// items: List.generate(numberOfItems, (index) {
|
|
|
|
// return Builder(
|
|
|
|
// builder: (BuildContext context) {
|
|
|
|
// return Center(
|
|
|
|
// child: Padding(
|
|
|
|
// padding: const EdgeInsets.all(8.0),
|
|
|
|
// child: Card(
|
|
|
|
// margin: EdgeInsets.all(1.0),
|
|
|
|
// shape: RoundedRectangleBorder(
|
|
|
|
// borderRadius: BorderRadius.circular(10),
|
2024-08-19 08:44:44 +00:00
|
|
|
// ),
|
2024-08-30 12:24:54 +00:00
|
|
|
// child: Container(
|
|
|
|
// decoration: BoxDecoration(
|
|
|
|
// color: Colors.blueAccent, // Replace with your gradient or color
|
|
|
|
// borderRadius: BorderRadius.circular(10),
|
2024-08-19 08:44:44 +00:00
|
|
|
// ),
|
2024-08-30 12:24:54 +00:00
|
|
|
// child: Padding(
|
|
|
|
// padding: EdgeInsets.all(10.0),
|
|
|
|
// child: Column(
|
|
|
|
// mainAxisSize: MainAxisSize.min,
|
|
|
|
// crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
// children: [
|
|
|
|
// Text(
|
|
|
|
// index == 0
|
|
|
|
// ? "Top Event Topics"
|
|
|
|
// : index == 1
|
|
|
|
// ? "Top Publication Topics"
|
|
|
|
// : index == 2
|
|
|
|
// ? "Top Products Discussed"
|
|
|
|
// : index == 3
|
|
|
|
// ? "Drugs Prescribed"
|
|
|
|
// : "Condition Treated",
|
|
|
|
// style: TextStyle(
|
|
|
|
// fontSize: 16.0,
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
// color: Colors.white,
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// const SizedBox(height: 10.0),
|
|
|
|
// // Example content, you can replace this with your dynamic data
|
|
|
|
// Row(
|
|
|
|
// children: [
|
|
|
|
// Container(
|
|
|
|
// decoration: BoxDecoration(
|
|
|
|
// color: Colors.grey[800], // Replace with your color
|
|
|
|
// borderRadius: BorderRadius.circular(10),
|
|
|
|
// ),
|
|
|
|
// child: Padding(
|
|
|
|
// padding: const EdgeInsets.all(5.0),
|
|
|
|
// child: Row(
|
|
|
|
// children: [
|
|
|
|
// Icon(
|
|
|
|
// Icons.circle,
|
|
|
|
// color: Colors.white,
|
|
|
|
// size: 13.0,
|
|
|
|
// ),
|
|
|
|
// SizedBox(width: 5.0),
|
|
|
|
// Text(
|
|
|
|
// "Item $index",
|
|
|
|
// style: TextStyle(
|
|
|
|
// fontSize: 14.0,
|
|
|
|
// color: Colors.white,
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// SizedBox(width: 5.0),
|
|
|
|
// Container(
|
|
|
|
// decoration: BoxDecoration(
|
|
|
|
// color: Colors.black, // Replace with your color
|
|
|
|
// borderRadius: BorderRadius.circular(5),
|
|
|
|
// ),
|
|
|
|
// child: Padding(
|
|
|
|
// padding: const EdgeInsets.all(1.0),
|
|
|
|
// child: Text(
|
|
|
|
// "(378)",
|
|
|
|
// style: TextStyle(
|
|
|
|
// fontSize: 14.0,
|
|
|
|
// color: Colors.white,
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ),
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
// ],
|
|
|
|
// ),
|
2024-08-19 08:44:44 +00:00
|
|
|
// ),
|
|
|
|
// ),
|
2024-08-30 12:24:54 +00:00
|
|
|
// ),
|
2024-08-19 08:44:44 +00:00
|
|
|
// ),
|
2024-08-30 12:24:54 +00:00
|
|
|
// );
|
|
|
|
// },
|
|
|
|
// );
|
|
|
|
// }).toList(),
|
2024-08-19 08:44:44 +00:00
|
|
|
// ),
|
|
|
|
// );
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
|