-
Notifications
You must be signed in to change notification settings - Fork 43
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
Updated with minor changes. #31
Merged
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
8899417
The colors have been updated to pull from the constants folder.
mustafauys 779ec66
the page structure has been edited, construction update, pubspec lock…
mustafauys de97568
Color constants file added.
mustafauys ea95806
Constants file images added.
mustafauys 7d1cc60
Updated
mustafauys 3a123dd
Readme updated
mustafauys 7f569ea
The theme infrastructure has been added.
mustafauys 587dd4c
Merge branch 'master' of https://github.com/mustafauys/flutter-ready-…
mustafauys 942788c
The theme infrastructure has been added.
mustafauys 6795a47
Google fonts pubspec yaml added.
mustafauys 3303648
version updated
mustafauys File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ import 'package:flutter/material.dart'; | |
import 'glow_image.dart'; | ||
|
||
class ExampleGlowImage extends StatefulWidget { | ||
ExampleGlowImage({Key? key}) : super(key: key); | ||
const ExampleGlowImage({Key? key}) : super(key: key); | ||
|
||
@override | ||
State<ExampleGlowImage> createState() => _ExampleGlowImageState(); | ||
|
@@ -14,8 +14,7 @@ class _ExampleGlowImageState extends State<ExampleGlowImage> { | |
|
||
@override | ||
Widget build(BuildContext context) { | ||
final size = MediaQuery.of(context).size; | ||
final _width = 300.0; | ||
const _width = 300.0; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. width burad atutamylaim ustte veriabvle |
||
return Scaffold( | ||
body: SafeArea( | ||
child: Column( | ||
|
@@ -30,9 +29,9 @@ class _ExampleGlowImageState extends State<ExampleGlowImage> { | |
child: AnimatedContainer( | ||
curve: Curves.easeInOutBack, | ||
width: tapped ? _width : _width * 0.8, | ||
duration: Duration(milliseconds: 450), | ||
duration: const Duration(milliseconds: 450), | ||
child: GlowImage( | ||
child: Photo() | ||
child: const Photo() | ||
// Container( | ||
// width: _width, | ||
// color: Colors.green, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
// Çalışma Mantığı | ||
// Kullanacağımız renk kodunu ismiyle birlikte buraya ekliyoruz. | ||
// Daha sonra buradaki rengi kullanacağımız widget içine önce bu file import ediyoruz. | ||
// Import ettikten sonra rengi kullanacağımız satıra gelip 'ColorConstants.white' örneği gibi istediğimiz rengi ekliyoruz. Detaylar Readme.md | ||
class ColorConstants { | ||
static const Color black = Color(0xFF000000); | ||
static const Color white = Color(0xFFffffff); | ||
static const Color white70 = Color(0xB3FFFFFF); | ||
static const Color amaranth = Color(0xFFE91E63); | ||
static const Color pomegranate = Color(0xFFE91E63); | ||
static const Color dodgerBlue = Color(0xFF2196F3); | ||
static const Color fruitSalad = Color(0xFF4CAF50); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
abstract class BaseTheme { | ||
ThemeData get themeData; | ||
|
||
TextStyle get customSnackBar; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:ready_to_use_widgets/core/init/theme/base/base_theme.dart'; | ||
|
||
class DarkTheme extends BaseTheme { | ||
static DarkTheme? _instance; | ||
|
||
static DarkTheme? get instance { | ||
if (_instance != null) return _instance; | ||
_instance = DarkTheme._init(); | ||
return _instance; | ||
} | ||
|
||
DarkTheme._init(); | ||
|
||
@override | ||
ThemeData get themeData => throw UnimplementedError(); | ||
|
||
@override | ||
TextStyle get customSnackBar => throw UnimplementedError(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
enum AppTheme { dark, light } | ||
|
||
extension AppThemeExtension on AppTheme { | ||
String get appThemeToString { | ||
switch (this) { | ||
case AppTheme.dark: | ||
return 'AppTheme.DARK'; | ||
case AppTheme.light: | ||
return 'AppTheme.LIGHT'; | ||
default: | ||
{ | ||
return 'AppTheme.LIGHT'; | ||
} | ||
} | ||
} | ||
} | ||
|
||
extension AppThemeStringExtension on String { | ||
AppTheme get stringToAppTheme { | ||
switch (this) { | ||
case 'AppTheme.DARK': | ||
return AppTheme.dark; | ||
case 'AppTheme.LIGHT': | ||
return AppTheme.light; | ||
default: | ||
{ | ||
return AppTheme.light; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:google_fonts/google_fonts.dart'; | ||
import 'package:ready_to_use_widgets/atomic/beauty_textfield/beauty_textfield.dart'; | ||
import 'package:ready_to_use_widgets/core/init/constants/color_constant.dart'; | ||
import 'package:ready_to_use_widgets/core/init/theme/base/base_theme.dart'; | ||
|
||
class LightTheme extends BaseTheme { | ||
static LightTheme? _instance; | ||
|
||
static LightTheme? get instance { | ||
if (_instance != null) return _instance; | ||
_instance = LightTheme._init(); | ||
return _instance; | ||
} | ||
|
||
LightTheme._init(); | ||
|
||
@override | ||
ThemeData get themeData => throw UnimplementedError(); | ||
|
||
// Örnek olarak yapılmıştır. | ||
|
||
@override | ||
TextStyle get customSnackBar => GoogleFonts.ubuntu( | ||
textStyle: const TextStyle( | ||
fontSize: 16, | ||
fontWeight: FontWeight.bold, | ||
color: ColorConstants.dodgerBlue, | ||
), | ||
); | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bunu bir classa alalim styler oradan gelsin color propertlyerde constlardan gelsin