Skip to content

Commit

Permalink
Implemented All Info Pages for the Respective Programs
Browse files Browse the repository at this point in the history
  • Loading branch information
RishavKumarSinha committed Jun 12, 2024
1 parent 902b3b1 commit 129cdd3
Show file tree
Hide file tree
Showing 17 changed files with 1,249 additions and 6 deletions.
Binary file added assets/coding_ninja_swag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/github_swag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/participation_certificate.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/xyz_domain.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 11 additions & 1 deletion lib/programs screen/girl_script.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import 'package:multi_select_flutter/dialog/multi_select_dialog_field.dart';
import 'package:multi_select_flutter/util/multi_select_item.dart';
import 'package:opso/modals/book_mark_model.dart';
import 'package:opso/modals/gssoc_project_modal.dart';
import 'package:opso/programs_info_pages/gssoc_info.dart';
import 'package:opso/widgets/gssoc_project_widget.dart';
import 'package:opso/widgets/year_button.dart';
import '../widgets/SearchandFilterWidget.dart';
Expand Down Expand Up @@ -209,7 +210,16 @@ class _GSSOCScreenState extends State<GSSOCScreen> {
HandleBookmark.deleteBookmark(currentProject);
}
},
)
),
IconButton(
icon: const Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => const GSSOCInfo()),
);
},
),
]),
body: FutureBuilder<void>(
future: getProjectFunction,
Expand Down
12 changes: 11 additions & 1 deletion lib/programs screen/google_season_of_docs_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import 'package:opso/modals/gsod/gsod_modal_old.dart';
import 'package:opso/widgets/gsod/gsod_project_widget_new.dart';
import 'package:opso/widgets/gsod/gsod_project_widget_old.dart';
import 'package:opso/widgets/year_button.dart';
import 'package:opso/programs_info_pages/gsod_info.dart';



Expand Down Expand Up @@ -290,7 +291,16 @@ class _GoogleSeasonOfDocsScreenState extends State<GoogleSeasonOfDocsScreen> {
HandleBookmark.deleteBookmark(currentProgram);
}
},
)
),
IconButton(
icon: const Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => const GSODInfo()),
);
},
),
]),
body: FutureBuilder<void>(
future: getProjectFunction,
Expand Down
11 changes: 10 additions & 1 deletion lib/programs screen/google_summer_of_code_screen.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:opso/programs_info_pages/gsoc_info.dart';
import 'package:opso/widgets/gsoc/GsocProjectWidget.dart';
import 'package:url_launcher/url_launcher.dart';
import 'package:multi_select_flutter/multi_select_flutter.dart';
Expand Down Expand Up @@ -206,7 +207,15 @@ class _GoogleSummerOfCodeScreenState extends State<GoogleSummerOfCodeScreen> {
onRefresh: _refresh,
child: Scaffold(
appBar: AppBar(
title: Text('Google Summer of Code'),
title: const Text('Google Summer of Code'),
actions: <Widget>[IconButton(
icon: const Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => const GSOCInfo()), );
},
),],
),
body: FutureBuilder<void>(
future: _dataFetchFuture,
Expand Down
12 changes: 11 additions & 1 deletion lib/programs screen/linux_foundation.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:opso/modals/book_mark_model.dart';
import 'package:opso/modals/linux_foundation_modal.dart';
import 'package:opso/programs_info_pages/linux_info.dart';
import 'package:opso/widgets/linux_foundation_widget.dart';

class LinuxFoundation extends StatefulWidget {
Expand Down Expand Up @@ -99,7 +100,16 @@ class _LinuxFoundationState extends State<LinuxFoundation> {
HandleBookmark.deleteBookmark(currentProject);
}
},
)
),
IconButton(
icon: const Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => const LINUXInfo()),
);
},
),
]),
body: FutureBuilder<void>(
future: getProjectListFunction,
Expand Down
11 changes: 10 additions & 1 deletion lib/programs screen/social_winter_of_code.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import 'package:multi_select_flutter/dialog/multi_select_dialog_field.dart';
import 'package:multi_select_flutter/util/multi_select_item.dart';
import 'package:opso/modals/book_mark_model.dart';
import 'package:opso/modals/swoc_project_modal.dart';
import 'package:opso/programs_info_pages/swoc_info.dart';
import 'package:opso/widgets/swoc_project_widget.dart';
import 'package:opso/widgets/year_button.dart';

Expand Down Expand Up @@ -220,7 +221,15 @@ class _SWOCScreenState extends State<SWOCScreen> {
HandleBookmark.deleteBookmark(currentProject);
}
},
)
),
IconButton(
icon: Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => SWOCInfo()), );
},
),
]),
body: FutureBuilder<void>(
future: getProjectFunction,
Expand Down
12 changes: 11 additions & 1 deletion lib/programs screen/summer_of_bitcoin.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:opso/modals/sob_project_modal.dart';
import 'package:opso/programs_info_pages/sob_info.dart';
import 'package:opso/widgets/sob_project_widget.dart';
import 'package:opso/widgets/year_button.dart';

Expand Down Expand Up @@ -157,7 +158,16 @@ class _SummerOfBitcoinState extends State<SummerOfBitcoin> {
HandleBookmark.deleteBookmark(currentProject);
}
},
)
),
IconButton(
icon: const Icon(Icons.info_outline),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => const SOBInfo()),
);
},
),
]),
body: FutureBuilder<void>(
future: getProjectFunction,
Expand Down
201 changes: 201 additions & 0 deletions lib/programs_info_pages/gsoc_info.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,201 @@
import 'package:flutter/material.dart';
import 'package:timeline_tile/timeline_tile.dart';

class GSOCInfo extends StatelessWidget {
const GSOCInfo({super.key});

@override
Widget build(BuildContext context) {
final List<Map<String, dynamic>> events = [
{'date': 'February 21 - 18:00 UTC', 'description': 'List of accepted mentoring organizations published'},
{'date': 'February 22 - March 18', 'description': 'Potential GSoC contributors discuss application ideas with mentoring organizations'},
{'date': 'March 18 - 18:00 UTC', 'description': 'GSoC contributor application period begins'},
{'date': 'April 2 - 18:00 UTC', 'description': 'GSoC contributor application deadline'},
{'date': 'April 24 - 18:00 UTC', 'description': 'GSoC contributor proposal rankings due from Org Admins'},
{'date': 'May 1 - 18:00 UTC', 'description': 'Accepted GSoC contributor projects announced'},
{'date': 'May 1 - 26', 'description': 'Community Bonding Period | GSoC contributors get to know mentors, read documentation, get up to speed to begin working on their projects'},
{'date': 'May 27', 'description': 'Coding officially begins!'},
{'date': 'July 8 - 18:00 UTC', 'description': 'Mentors and GSoC contributors can begin submitting midterm evaluations'},
{'date': 'August 19 - 26 - 18:00 UTC', 'description': 'Final week: GSoC contributors submit their final work product and their final mentor evaluation (standard coding period)'},
{'date': 'August 26 - September 2 - 18:00 UTC', 'description': 'Mentors submit final GSoC contributor evaluations (standard coding period)'},
{'date': 'September 3', 'description': 'Initial results of Google Summer of Code 2024 announced'},
{'date': 'September 3 - November 4', 'description': 'GSoC contributors with extended timelines continue coding'},
{'date': 'November 4 - 18:00 UTC', 'description': 'Final date for all GSoC contributors to submit their final work product and final evaluation'},
];

return Scaffold(
appBar: AppBar(
title: const Text('Project Information'),
),
body: Padding(
padding: const EdgeInsets.all(10.0),
child: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Google Summer Of Code',
style: Theme.of(context).textTheme.titleLarge,
),
const SizedBox(height: 20),
_buildOutlinedBox(
context,
title: 'Overview',
content: 'Google Summer of Code is a global, online program focused on bringing new contributors into open source software development. GSoC Contributors work with an open source organization on a 12+ week programming project under the guidance of mentors.',
),
const SizedBox(height: 20),
_buildOutlinedBox(
context,
title: 'Eligibility : What are the eligibility requirements for participation?',
content:
'> You must be at least 18 years of age when you register.\n'
'> You must be eligible to work in the country you will reside in during the program.\n'
'> You must be an open source beginner or a student.\n'
'> You have not been accepted as a GSoC Contributor/Student in GSoC more than once.\n'
'> You must reside in a country that is not currently embargoed by the United States.',
),
const SizedBox(height: 20),
Text(
'Program Timeline',
style: Theme.of(context).textTheme.headlineSmall,
),
const SizedBox(height: 10),
_buildTimeline(events),
const SizedBox(height: 20),
Text(
'Prizes and Rewards',
style: Theme.of(context).textTheme.headlineSmall,
),
const SizedBox(height: 10),
Column(
children: [
_buildPrizeBox(
context,
'Google will provide a stipend to GSoC Contributors who pass their evaluations and are able to receive stipends.',
),
const SizedBox(height: 10),
_buildPrizeBox(
context,
'Google will also provide a Certificate of Completion to GSoC Contributors who pass their evaluations.',
),
],
),
],
),
),
),
);
}

Widget _buildOutlinedBox(BuildContext context, {required String title, required String content}) {
return Container(
padding: const EdgeInsets.all(10.0),
decoration: BoxDecoration(
border: Border.all(color: Colors.orange, width: 1.0),
borderRadius: BorderRadius.circular(8.0),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
title,
style: Theme.of(context).textTheme.headlineSmall,
),
const SizedBox(height: 10),
Text(
content,
style: Theme.of(context).textTheme.bodyLarge,
),
],
),
);
}

Widget _buildTimeline(List<Map<String, dynamic>> events) {
return Column(
children: events.asMap().entries.map((entry) {
int index = entry.key;
Map<String, dynamic> event = entry.value;
final bool isFirst = index == 0;
final bool isLast = index == events.length - 1;
final bool isLeft = index % 2 == 0;

return TimelineTile(
axis: TimelineAxis.vertical,
alignment: TimelineAlign.center,
isFirst: isFirst,
isLast: isLast,
beforeLineStyle: const LineStyle(
color: Colors.orange,
thickness: 4,
),
afterLineStyle: const LineStyle(
color: Colors.orange,
thickness: 4,
),
indicatorStyle: IndicatorStyle(
indicator: Container(
decoration: const BoxDecoration(
color: Colors.orange,
shape: BoxShape.circle,
),
child: const Icon(
Icons.event,
size: 15,
color: Colors.white,
),
),
),
startChild: isLeft ? _buildEventChild(event) : null,
endChild: isLeft ? null : _buildEventChild(event),
);
}).toList(),
);
}

Widget _buildEventChild(Map<String, dynamic> event) {
return Container(
width: 150,
margin: const EdgeInsets.all(10),
padding: const EdgeInsets.all(10),
decoration: BoxDecoration(
color: Colors.orange,
borderRadius: BorderRadius.circular(8),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
event['date'],
style: const TextStyle(
fontWeight: FontWeight.bold,
fontSize: 16,
),
),
const SizedBox(height: 8),
Text(
event['description'],
style: const TextStyle(
fontSize: 14,
),
),
],
),
);
}

Widget _buildPrizeBox(BuildContext context, String description) {
return Container(
padding: const EdgeInsets.all(10.0),
decoration: BoxDecoration(
border: Border.all(color: Colors.orange, width: 1.0),
borderRadius: BorderRadius.circular(8),
),
child: Text(
description,
textAlign: TextAlign.center,
style: Theme.of(context).textTheme.bodyLarge,
),
);
}
}
Loading

0 comments on commit 129cdd3

Please sign in to comment.