Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flexible widget demo #1

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
80 changes: 43 additions & 37 deletions README.md
Expand Up @@ -5,58 +5,64 @@
A flutter appliction listing all the widgets covered in [Flutter widget of the week playlist](https://www.youtube.com/playlist?list=PLjxrf2q8roU23XGwz3Km7sQZFTdB996iG)

## About
I created this project to improve my skills with dart and flutter as a development platform. I am used to developing native android apps so I'll be focusing on designing this project for android platform.</br>

I created this project to improve my skills with dart and flutter as a development platform. I am used to developing native android apps so I'll be focusing on designing this project for android platform.</br>
This project might help you to learn about Flutter if you are a beginner in this space.</br>
My experience with flutter has been great thus far.</br>
My experience with flutter has been great thus far.</br>
I hope you like it too.
</br>The project is developed in [Dart](https://www.dartlang.org/) language.</br>
All the files are listed in the [/lib](https://github.com/annshsingh/flutter-widget-guide/tree/master/lib) folder.</br>

#### :star: the repo to show some :heart: and motivate me to work on the project :smiley:

## Widget List
1. [Safe Area](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/safe_area.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-safearea-widget-in-5-mins-or-less-df4620a7d08f)
2. [Expanded](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/expanded.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-expanded-widget-in-5-mins-or-less-7fac99839658)
3. [Wrap](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/wrap.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-wrap-widget-in-5-mins-or-less-f77ad249c176)
4. [Animated Container](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/animated_container.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-animatedcontainer-widget-in-5-mins-or-less-347b69eaad0f)
5. [Opacity](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/opacity.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-opacity-widget-in-5-mins-or-less-969c3f635437)
6. [Future Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/future_builder.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-futurebuilder-widget-in-5-mins-or-less-3bef3e5e1bff)
7. [Fade Transition](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fade_transition.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-fadetransition-widget-in-5-mins-or-less-78e714ba722)
8. [Floating Action Button](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/floating_action_button.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-fab-widget-in-5-mins-or-less-bbf84db22d3c)
9. [Page View](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/page_view.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-pageview-widget-in-5-mins-or-less-bc7968f264ac)
10. [Table](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/table.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-table-widget-in-5-mins-or-less-9b7f7f796014)
11. [Sliver App Bar](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_app_bar.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-sliverappbar-widget-in-5-mins-or-less-d39ae4bf98c8)
12. [Sliver List](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_list.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-sliverlist-widget-in-5-mins-or-less-d1215c677388)
13. [Sliver Grid](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_grid.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-slivergrid-widget-in-5-mins-or-less-e6a95d6c4e76)
14. [Fade In Image](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fade_in_image.dart)
15. [Stream Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/stream_builder.dart)
16. [Inherited Model](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/inherited_model.dart)
17. [ClipRRect](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/clip_r_rect.dart)
18. [Hero](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/hero.dart)
19. [Custom Paint](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/custom_paint.dart)
20. [Tooltip](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/tooltip.dart)
21. [Fitted Box](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fitted_box.dart)
22. [Layout Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/layout_builder.dart)
23. [Absorb Pointer](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/absorb_pointer.dart)
24. [Transform](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/transform.dart)
25. [Back Drop Filter](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/backdrop_filter.dart)
26. [Align](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/align.dart)
27. [Positioned](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/positioned.dart)
28. [Animated Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/animated_builder.dart)
29. [Dismissible](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/dismissible.dart)
30. [Sized Widget](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sized_box.dart)
31. Value Listnable Builder (coming soon)
32. Draggable (coming soon)
33. AnimatedList (coming soon)
34. Flexible (coming soon)
35. MediaQuery (coming soon)

1. [Safe Area](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/safe_area.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-safearea-widget-in-5-mins-or-less-df4620a7d08f)
2. [Expanded](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/expanded.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-expanded-widget-in-5-mins-or-less-7fac99839658)
3. [Wrap](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/wrap.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-wrap-widget-in-5-mins-or-less-f77ad249c176)
4. [Animated Container](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/animated_container.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-animatedcontainer-widget-in-5-mins-or-less-347b69eaad0f)
5. [Opacity](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/opacity.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-opacity-widget-in-5-mins-or-less-969c3f635437)
6. [Future Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/future_builder.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-futurebuilder-widget-in-5-mins-or-less-3bef3e5e1bff)
7. [Fade Transition](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fade_transition.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-fadetransition-widget-in-5-mins-or-less-78e714ba722)
8. [Floating Action Button](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/floating_action_button.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-fab-widget-in-5-mins-or-less-bbf84db22d3c)
9. [Page View](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/page_view.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-pageview-widget-in-5-mins-or-less-bc7968f264ac)
10. [Table](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/table.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-table-widget-in-5-mins-or-less-9b7f7f796014)
11. [Sliver App Bar](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_app_bar.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-sliverappbar-widget-in-5-mins-or-less-d39ae4bf98c8)
12. [Sliver List](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_list.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-sliverlist-widget-in-5-mins-or-less-d1215c677388)
13. [Sliver Grid](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sliver_grid.dart) | [![read](medium_icon.png)](https://medium.com/@annsh/flutter-widget-guide-slivergrid-widget-in-5-mins-or-less-e6a95d6c4e76)
14. [Fade In Image](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fade_in_image.dart)
15. [Stream Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/stream_builder.dart)
16. [Inherited Model](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/inherited_model.dart)
17. [ClipRRect](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/clip_r_rect.dart)
18. [Hero](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/hero.dart)
19. [Custom Paint](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/custom_paint.dart)
20. [Tooltip](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/tooltip.dart)
21. [Fitted Box](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/fitted_box.dart)
22. [Layout Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/layout_builder.dart)
23. [Absorb Pointer](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/absorb_pointer.dart)
24. [Transform](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/transform.dart)
25. [Back Drop Filter](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/backdrop_filter.dart)
26. [Align](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/align.dart)
27. [Positioned](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/positioned.dart)
28. [Animated Builder](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/animated_builder.dart)
29. [Dismissible](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/dismissible.dart)
30. [Sized Widget](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/sized_box.dart)
31. Value Listnable Builder (coming soon)
32. Draggable (coming soon)
33. AnimatedList (coming soon)
34. [Flexible](https://github.com/annshsingh/flutter-widget-guide/blob/master/lib/screens/flexible.dart)
35. MediaQuery (coming soon)

#### I'll try my best to keep the list in sync with the [Youtube Playlist](https://www.youtube.com/playlist?list=PLOU2XLYxmsIL0pH0zWe_ZOHgGhZ7UasUE) :thumbsup:

## Learn more on Flutter

[Official Flutter documentation](https://flutter.dev/docs)</br>
[Flutter widget list](https://flutter.dev/docs/development/ui/widgets)</br>
[Flutter youtube channel](https://www.youtube.com/channel/UCwXdFgeE9KYzlDdR7TG9cMw)

## Created & maintained by

[Annsh Singh](https://github.com/annshsingh)
([LinkedIn](https://www.linkedin.com/in/annsh/))
([Play Store](https://play.google.com/store/apps/dev?id=4716299969505523086&hl=en))
Expand Down
17 changes: 17 additions & 0 deletions android/.project
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>android</name>
<comment>Project android created by Buildship.</comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.buildship.core.gradleprojectbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.buildship.core.gradleprojectnature</nature>
</natures>
</projectDescription>
2 changes: 2 additions & 0 deletions android/.settings/org.eclipse.buildship.core.prefs
@@ -0,0 +1,2 @@
connection.project.dir=
eclipse.preferences.version=1
6 changes: 6 additions & 0 deletions android/app/.classpath
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-12/"/>
<classpathentry kind="con" path="org.eclipse.buildship.core.gradleclasspathcontainer"/>
<classpathentry kind="output" path="bin/default"/>
</classpath>
23 changes: 23 additions & 0 deletions android/app/.project
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>app</name>
<comment>Project app created by Buildship.</comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.buildship.core.gradleprojectbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.buildship.core.gradleprojectnature</nature>
</natures>
</projectDescription>
2 changes: 2 additions & 0 deletions android/app/.settings/org.eclipse.buildship.core.prefs
@@ -0,0 +1,2 @@
connection.project.dir=..
eclipse.preferences.version=1
4 changes: 4 additions & 0 deletions android/app/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,4 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=13
org.eclipse.jdt.core.compiler.compliance=13
org.eclipse.jdt.core.compiler.source=13
1 change: 1 addition & 0 deletions ios/Flutter/Debug.xcconfig
@@ -1 +1,2 @@
#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
#include "Generated.xcconfig"
1 change: 1 addition & 0 deletions ios/Flutter/Release.xcconfig
@@ -1 +1,2 @@
#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
#include "Generated.xcconfig"
71 changes: 71 additions & 0 deletions ios/Podfile
@@ -0,0 +1,71 @@
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

project 'Runner', {
'Debug' => :debug,
'Profile' => :release,
'Release' => :release,
}

def parse_KV_file(file, separator='=')
file_abs_path = File.expand_path(file)
if !File.exists? file_abs_path
return [];
end
pods_ary = []
skip_line_start_symbols = ["#", "/"]
File.foreach(file_abs_path) { |line|
next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
plugin = line.split(pattern=separator)
if plugin.length == 2
podname = plugin[0].strip()
path = plugin[1].strip()
podpath = File.expand_path("#{path}", file_abs_path)
pods_ary.push({:name => podname, :path => podpath});
else
puts "Invalid plugin specification: #{line}"
end
}
return pods_ary
end

target 'Runner' do
use_frameworks!

# Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
# referring to absolute paths on developers' machines.
system('rm -rf .symlinks')
system('mkdir -p .symlinks/plugins')

# Flutter Pods
generated_xcode_build_settings = parse_KV_file('./Flutter/Generated.xcconfig')
if generated_xcode_build_settings.empty?
puts "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter packages get is executed first."
end
generated_xcode_build_settings.map { |p|
if p[:name] == 'FLUTTER_FRAMEWORK_DIR'
symlink = File.join('.symlinks', 'flutter')
File.symlink(File.dirname(p[:path]), symlink)
pod 'Flutter', :path => File.join(symlink, File.basename(p[:path]))
end
}

# Plugin Pods
plugin_pods = parse_KV_file('../.flutter-plugins')
plugin_pods.map { |p|
symlink = File.join('.symlinks', 'plugins', p[:name])
File.symlink(p[:path], symlink)
pod p[:name], :path => File.join(symlink, 'ios')
}
end

post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['ENABLE_BITCODE'] = 'NO'
end
end
end
22 changes: 22 additions & 0 deletions ios/Podfile.lock
@@ -0,0 +1,22 @@
PODS:
- Flutter (1.0.0)
- url_launcher (0.0.1):
- Flutter

DEPENDENCIES:
- Flutter (from `.symlinks/flutter/ios`)
- url_launcher (from `.symlinks/plugins/url_launcher/ios`)

EXTERNAL SOURCES:
Flutter:
:path: ".symlinks/flutter/ios"
url_launcher:
:path: ".symlinks/plugins/url_launcher/ios"

SPEC CHECKSUMS:
Flutter: 58dd7d1b27887414a370fcccb9e645c08ffd7a6a
url_launcher: 0067ddb8f10d36786672aa0722a21717dba3a298

PODFILE CHECKSUM: ebd43b443038e611b86ede96e613bd6033c49497

COCOAPODS: 1.7.0.beta.2