Repository: afgprogrammer/Flutter-e-commerce-app-example
Branch: master
Commit: 2d070ae29586
Files: 55
Total size: 124.1 KB
Directory structure:
gitextract_ll6dtwim/
├── .gitignore
├── .metadata
├── .vscode/
│ └── launch.json
├── LICENSE
├── README.md
├── android/
│ ├── .gitignore
│ ├── app/
│ │ ├── build.gradle
│ │ └── src/
│ │ ├── debug/
│ │ │ └── AndroidManifest.xml
│ │ ├── main/
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── kotlin/
│ │ │ │ └── com/
│ │ │ │ └── example/
│ │ │ │ └── day34/
│ │ │ │ └── MainActivity.kt
│ │ │ └── res/
│ │ │ ├── drawable/
│ │ │ │ └── launch_background.xml
│ │ │ ├── drawable-v21/
│ │ │ │ └── launch_background.xml
│ │ │ ├── values/
│ │ │ │ └── styles.xml
│ │ │ └── values-night/
│ │ │ └── styles.xml
│ │ └── profile/
│ │ └── AndroidManifest.xml
│ ├── build.gradle
│ ├── gradle/
│ │ └── wrapper/
│ │ └── gradle-wrapper.properties
│ ├── gradle.properties
│ └── settings.gradle
├── assets/
│ └── products.json
├── ios/
│ ├── .gitignore
│ ├── Flutter/
│ │ ├── AppFrameworkInfo.plist
│ │ ├── Debug.xcconfig
│ │ └── Release.xcconfig
│ ├── Runner/
│ │ ├── AppDelegate.swift
│ │ ├── Assets.xcassets/
│ │ │ ├── AppIcon.appiconset/
│ │ │ │ └── Contents.json
│ │ │ └── LaunchImage.imageset/
│ │ │ ├── Contents.json
│ │ │ └── README.md
│ │ ├── Base.lproj/
│ │ │ ├── LaunchScreen.storyboard
│ │ │ └── Main.storyboard
│ │ ├── Info.plist
│ │ └── Runner-Bridging-Header.h
│ ├── Runner.xcodeproj/
│ │ ├── project.pbxproj
│ │ ├── project.xcworkspace/
│ │ │ ├── contents.xcworkspacedata
│ │ │ └── xcshareddata/
│ │ │ ├── IDEWorkspaceChecks.plist
│ │ │ └── WorkspaceSettings.xcsettings
│ │ └── xcshareddata/
│ │ └── xcschemes/
│ │ └── Runner.xcscheme
│ └── Runner.xcworkspace/
│ ├── contents.xcworkspacedata
│ └── xcshareddata/
│ ├── IDEWorkspaceChecks.plist
│ └── WorkspaceSettings.xcsettings
├── lib/
│ ├── animation/
│ │ └── FadeAnimation.dart
│ ├── main.dart
│ ├── models/
│ │ └── product.dart
│ └── pages/
│ ├── cart.dart
│ ├── explore.dart
│ ├── notification.dart
│ ├── payment.dart
│ ├── payment_success.dart
│ ├── product_view.dart
│ ├── profile.dart
│ └── search.dart
├── pubspec.yaml
├── test/
│ └── widget_test.dart
└── web/
├── index.html
└── manifest.json
================================================
FILE CONTENTS
================================================
================================================
FILE: .gitignore
================================================
# Miscellaneous
*.class
*.log
*.pyc
*.swp
.DS_Store
.atom/
.buildlog/
.history
.svn/
# IntelliJ related
*.iml
*.ipr
*.iws
.idea/
# The .vscode folder contains launch configuration and tasks you configure in
# VS Code which you may wish to be included in version control, so this line
# is commented out by default.
#.vscode/
# Flutter/Dart/Pub related
**/doc/api/
**/ios/Flutter/.last_build_id
.dart_tool/
.flutter-plugins
.flutter-plugins-dependencies
.packages
.pub-cache/
.pub/
/build/
# Web related
lib/generated_plugin_registrant.dart
# Symbolication related
app.*.symbols
# Obfuscation related
app.*.map.json
# Android Studio will place build artifacts here
/android/app/debug
/android/app/profile
/android/app/release
================================================
FILE: .metadata
================================================
# This file tracks properties of this Flutter project.
# Used by Flutter tool to assess capabilities and perform upgrades etc.
#
# This file should be version controlled and should not be manually edited.
version:
revision: d79295af24c3ed621c33713ecda14ad196fd9c31
channel: stable
project_type: app
================================================
FILE: .vscode/launch.json
================================================
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "day34",
"request": "launch",
"type": "dart",
"args": [
"--no-sound-null-safety",
]
},
{
"name": "day34 (profile mode)",
"request": "launch",
"type": "dart",
"flutterMode": "profile",
"args": [
"--no-sound-null-safety",
]
}
]
}
================================================
FILE: LICENSE
================================================
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
================================================
FILE: README.md
================================================
## Flutter e-commerce Application Example - Day 34
```dart
class Afgprogrammer extends Flutter100DaysOfCode {
video() {
return {
"title": "Flutter e-commerce Application Example",
"description": "Let’s make an e-commerce application.",
"day": 34,
}
}
}
```
Assets
* [Unsplash](https://unsplash.com)
* [icon8](https://icons8.com)
## Previous Designs
[Checkout my Youtube channel](https://youtube.com/afgprogrammer)
## Development Setup
Clone the repository and run the following commands:
```
flutter pub get
flutter run
```
## Screenshot
### Home Page
### Filter Modal
### Product View
### Cart Page
### Payment Page
## Links
* [Website](https://afgprogrammer.com)
* [Youtube channel](https://youtube.com/afgprogrammer)
* [Twitter](https://twitter.com/afgprogrammer)
* [Instagram](https://instagram.com/afgprogrammer)
================================================
FILE: android/.gitignore
================================================
gradle-wrapper.jar
/.gradle
/captures/
/gradlew
/gradlew.bat
/local.properties
GeneratedPluginRegistrant.java
# Remember to never publicly share your keystore.
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
key.properties
================================================
FILE: android/app/build.gradle
================================================
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
localPropertiesFile.withReader('UTF-8') { reader ->
localProperties.load(reader)
}
}
def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
}
def flutterVersionName = localProperties.getProperty('flutter.versionName')
if (flutterVersionName == null) {
flutterVersionName = '1.0'
}
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
android {
compileSdkVersion 30
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "com.example.day34"
minSdkVersion 16
targetSdkVersion 30
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
}
}
}
flutter {
source '../..'
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
================================================
FILE: android/app/src/debug/AndroidManifest.xml
================================================
================================================
FILE: android/app/src/main/AndroidManifest.xml
================================================
================================================
FILE: android/app/src/main/kotlin/com/example/day34/MainActivity.kt
================================================
package com.example.day34
import io.flutter.embedding.android.FlutterActivity
class MainActivity: FlutterActivity() {
}
================================================
FILE: android/app/src/main/res/drawable/launch_background.xml
================================================
================================================
FILE: android/app/src/main/res/drawable-v21/launch_background.xml
================================================
================================================
FILE: android/app/src/main/res/values/styles.xml
================================================
================================================
FILE: android/app/src/main/res/values-night/styles.xml
================================================
================================================
FILE: android/app/src/profile/AndroidManifest.xml
================================================
================================================
FILE: android/build.gradle
================================================
buildscript {
ext.kotlin_version = '1.3.50'
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.1.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects {
repositories {
google()
jcenter()
}
}
rootProject.buildDir = '../build'
subprojects {
project.buildDir = "${rootProject.buildDir}/${project.name}"
project.evaluationDependsOn(':app')
}
task clean(type: Delete) {
delete rootProject.buildDir
}
================================================
FILE: android/gradle/wrapper/gradle-wrapper.properties
================================================
#Fri Jun 23 08:50:38 CEST 2017
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
================================================
FILE: android/gradle.properties
================================================
org.gradle.jvmargs=-Xmx1536M
android.useAndroidX=true
android.enableJetifier=true
================================================
FILE: android/settings.gradle
================================================
include ':app'
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
def properties = new Properties()
assert localPropertiesFile.exists()
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
================================================
FILE: assets/products.json
================================================
{
"products": [
{
"name": "Winter Coat",
"imageURL": "https://images.unsplash.com/photo-1539533018447-63fcce2678e3?ixid=MnwxMjA3fDB8MHxzZWFyY2h8MXx8Y29hdHxlbnwwfHwwfHw%3D&ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=60",
"brand": "OSIRUS",
"price": 100
},
{
"name": "Cotton Sweatshirt",
"imageURL": "https://images.unsplash.com/photo-1556172732-bcded74ff3a2?ixid=MnwxMjA3fDB8MHxzZWFyY2h8NTd8fHN3ZWF0c2hpcnR8ZW58MHx8MHx8&ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=60",
"brand": "OSIRUS",
"price": 49
},
{
"name": "Cotton Pant",
"imageURL": "https://images.unsplash.com/photo-1506629082955-511b1aa562c8?ixid=MnwxMjA3fDB8MHxzZWFyY2h8MTl8fHBhbnR8ZW58MHx8MHx8&ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=60",
"brand": "OSIRUS",
"price": 58
},
{
"name": "Green Sweater",
"imageURL": "https://images.unsplash.com/photo-1536992266094-82847e1fd431?ixid=MnwxMjA3fDB8MHxzZWFyY2h8NHx8c3dlYXRlcnxlbnwwfHwwfHw%3D&ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=60",
"brand": "OSIRUS",
"price": 69
}
]
}
================================================
FILE: ios/.gitignore
================================================
*.mode1v3
*.mode2v3
*.moved-aside
*.pbxuser
*.perspectivev3
**/*sync/
.sconsign.dblite
.tags*
**/.vagrant/
**/DerivedData/
Icon?
**/Pods/
**/.symlinks/
profile
xcuserdata
**/.generated/
Flutter/App.framework
Flutter/Flutter.framework
Flutter/Flutter.podspec
Flutter/Generated.xcconfig
Flutter/ephemeral/
Flutter/app.flx
Flutter/app.zip
Flutter/flutter_assets/
Flutter/flutter_export_environment.sh
ServiceDefinitions.json
Runner/GeneratedPluginRegistrant.*
# Exceptions to above rules.
!default.mode1v3
!default.mode2v3
!default.pbxuser
!default.perspectivev3
================================================
FILE: ios/Flutter/AppFrameworkInfo.plist
================================================
CFBundleDevelopmentRegion
en
CFBundleExecutable
App
CFBundleIdentifier
io.flutter.flutter.app
CFBundleInfoDictionaryVersion
6.0
CFBundleName
App
CFBundlePackageType
FMWK
CFBundleShortVersionString
1.0
CFBundleSignature
????
CFBundleVersion
1.0
MinimumOSVersion
8.0
================================================
FILE: ios/Flutter/Debug.xcconfig
================================================
#include "Generated.xcconfig"
================================================
FILE: ios/Flutter/Release.xcconfig
================================================
#include "Generated.xcconfig"
================================================
FILE: ios/Runner/AppDelegate.swift
================================================
import UIKit
import Flutter
@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
override func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
GeneratedPluginRegistrant.register(with: self)
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
}
}
================================================
FILE: ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json
================================================
{
"images" : [
{
"size" : "20x20",
"idiom" : "iphone",
"filename" : "Icon-App-20x20@2x.png",
"scale" : "2x"
},
{
"size" : "20x20",
"idiom" : "iphone",
"filename" : "Icon-App-20x20@3x.png",
"scale" : "3x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "Icon-App-29x29@1x.png",
"scale" : "1x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "Icon-App-29x29@2x.png",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "Icon-App-29x29@3x.png",
"scale" : "3x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "Icon-App-40x40@2x.png",
"scale" : "2x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "Icon-App-40x40@3x.png",
"scale" : "3x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "Icon-App-60x60@2x.png",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "Icon-App-60x60@3x.png",
"scale" : "3x"
},
{
"size" : "20x20",
"idiom" : "ipad",
"filename" : "Icon-App-20x20@1x.png",
"scale" : "1x"
},
{
"size" : "20x20",
"idiom" : "ipad",
"filename" : "Icon-App-20x20@2x.png",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "ipad",
"filename" : "Icon-App-29x29@1x.png",
"scale" : "1x"
},
{
"size" : "29x29",
"idiom" : "ipad",
"filename" : "Icon-App-29x29@2x.png",
"scale" : "2x"
},
{
"size" : "40x40",
"idiom" : "ipad",
"filename" : "Icon-App-40x40@1x.png",
"scale" : "1x"
},
{
"size" : "40x40",
"idiom" : "ipad",
"filename" : "Icon-App-40x40@2x.png",
"scale" : "2x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "Icon-App-76x76@1x.png",
"scale" : "1x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "Icon-App-76x76@2x.png",
"scale" : "2x"
},
{
"size" : "83.5x83.5",
"idiom" : "ipad",
"filename" : "Icon-App-83.5x83.5@2x.png",
"scale" : "2x"
},
{
"size" : "1024x1024",
"idiom" : "ios-marketing",
"filename" : "Icon-App-1024x1024@1x.png",
"scale" : "1x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
================================================
FILE: ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json
================================================
{
"images" : [
{
"idiom" : "universal",
"filename" : "LaunchImage.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "LaunchImage@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "LaunchImage@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
================================================
FILE: ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md
================================================
# Launch Screen Assets
You can customize the launch screen with your own desired assets by replacing the image files in this directory.
You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
================================================
FILE: ios/Runner/Base.lproj/LaunchScreen.storyboard
================================================
================================================
FILE: ios/Runner/Base.lproj/Main.storyboard
================================================
================================================
FILE: ios/Runner/Info.plist
================================================
CFBundleDevelopmentRegion
$(DEVELOPMENT_LANGUAGE)
CFBundleExecutable
$(EXECUTABLE_NAME)
CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)
CFBundleInfoDictionaryVersion
6.0
CFBundleName
day34
CFBundlePackageType
APPL
CFBundleShortVersionString
$(FLUTTER_BUILD_NAME)
CFBundleSignature
????
CFBundleVersion
$(FLUTTER_BUILD_NUMBER)
LSRequiresIPhoneOS
UILaunchStoryboardName
LaunchScreen
UIMainStoryboardFile
Main
UISupportedInterfaceOrientations
UIInterfaceOrientationPortrait
UIInterfaceOrientationLandscapeLeft
UIInterfaceOrientationLandscapeRight
UISupportedInterfaceOrientations~ipad
UIInterfaceOrientationPortrait
UIInterfaceOrientationPortraitUpsideDown
UIInterfaceOrientationLandscapeLeft
UIInterfaceOrientationLandscapeRight
UIViewControllerBasedStatusBarAppearance
================================================
FILE: ios/Runner/Runner-Bridging-Header.h
================================================
#import "GeneratedPluginRegistrant.h"
================================================
FILE: ios/Runner.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
9705A1C41CF9048500538489 /* Embed Frameworks */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 10;
files = (
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; };
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; };
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; };
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; };
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
97C146EB1CF9000F007C117D /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
9740EEB11CF90186004384FC /* Flutter */ = {
isa = PBXGroup;
children = (
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
9740EEB21CF90195004384FC /* Debug.xcconfig */,
7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
9740EEB31CF90195004384FC /* Generated.xcconfig */,
);
name = Flutter;
sourceTree = "";
};
97C146E51CF9000F007C117D = {
isa = PBXGroup;
children = (
9740EEB11CF90186004384FC /* Flutter */,
97C146F01CF9000F007C117D /* Runner */,
97C146EF1CF9000F007C117D /* Products */,
);
sourceTree = "";
};
97C146EF1CF9000F007C117D /* Products */ = {
isa = PBXGroup;
children = (
97C146EE1CF9000F007C117D /* Runner.app */,
);
name = Products;
sourceTree = "";
};
97C146F01CF9000F007C117D /* Runner */ = {
isa = PBXGroup;
children = (
97C146FA1CF9000F007C117D /* Main.storyboard */,
97C146FD1CF9000F007C117D /* Assets.xcassets */,
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
97C147021CF9000F007C117D /* Info.plist */,
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
74858FAE1ED2DC5600515810 /* AppDelegate.swift */,
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */,
);
path = Runner;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
97C146ED1CF9000F007C117D /* Runner */ = {
isa = PBXNativeTarget;
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
buildPhases = (
9740EEB61CF901F6004384FC /* Run Script */,
97C146EA1CF9000F007C117D /* Sources */,
97C146EB1CF9000F007C117D /* Frameworks */,
97C146EC1CF9000F007C117D /* Resources */,
9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
);
buildRules = (
);
dependencies = (
);
name = Runner;
productName = Runner;
productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1020;
ORGANIZATIONNAME = "";
TargetAttributes = {
97C146ED1CF9000F007C117D = {
CreatedOnToolsVersion = 7.3.1;
LastSwiftMigration = 1100;
};
};
};
buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
compatibilityVersion = "Xcode 9.3";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 97C146E51CF9000F007C117D;
productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
97C146ED1CF9000F007C117D /* Runner */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
97C146EC1CF9000F007C117D /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Thin Binary";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
};
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Run Script";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
97C146EA1CF9000F007C117D /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */,
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
97C146FA1CF9000F007C117D /* Main.storyboard */ = {
isa = PBXVariantGroup;
children = (
97C146FB1CF9000F007C117D /* Base */,
);
name = Main.storyboard;
sourceTree = "";
};
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
97C147001CF9000F007C117D /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
249021D3217E4FDB00AE95B9 /* Profile */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
name = Profile;
};
249021D4217E4FDB00AE95B9 /* Profile */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.example.day34;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_VERSION = 5.0;
VERSIONING_SYSTEM = "apple-generic";
};
name = Profile;
};
97C147031CF9000F007C117D /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
97C147041CF9000F007C117D /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
97C147061CF9000F007C117D /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.example.day34;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 5.0;
VERSIONING_SYSTEM = "apple-generic";
};
name = Debug;
};
97C147071CF9000F007C117D /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.example.day34;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_VERSION = 5.0;
VERSIONING_SYSTEM = "apple-generic";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
isa = XCConfigurationList;
buildConfigurations = (
97C147031CF9000F007C117D /* Debug */,
97C147041CF9000F007C117D /* Release */,
249021D3217E4FDB00AE95B9 /* Profile */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
isa = XCConfigurationList;
buildConfigurations = (
97C147061CF9000F007C117D /* Debug */,
97C147071CF9000F007C117D /* Release */,
249021D4217E4FDB00AE95B9 /* Profile */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 97C146E61CF9000F007C117D /* Project object */;
}
================================================
FILE: ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
================================================
IDEDidComputeMac32BitWarning
================================================
FILE: ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
================================================
PreviewsEnabled
================================================
FILE: ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
================================================
================================================
FILE: ios/Runner.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
================================================
IDEDidComputeMac32BitWarning
================================================
FILE: ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
================================================
PreviewsEnabled
================================================
FILE: lib/animation/FadeAnimation.dart
================================================
import 'package:flutter/material.dart';
import 'package:simple_animations/simple_animations.dart';
class FadeAnimation extends StatelessWidget {
final double delay;
final Widget child;
FadeAnimation(this.delay, this.child);
@override
Widget build(BuildContext context) {
final tween = MultiTrackTween([
Track("opacity").add(Duration(milliseconds: 500), Tween(begin: 0.0, end: 1.0)),
Track("translateY").add(
Duration(milliseconds: 500), Tween(begin: -30.0, end: 0.0),
curve: Curves.easeOut)
]);
return ControlledAnimation(
delay: Duration(milliseconds: (500 * delay).round()),
duration: tween.duration,
tween: tween,
child: child,
builderWithChild: (context, child, animation) => Opacity(
opacity: (animation as Map)["opacity"],
child: Transform.translate(
offset: Offset(0, (animation as Map)["translateY"]),
child: child
),
),
);
}
}
================================================
FILE: lib/main.dart
================================================
import 'package:day34/pages/cart.dart';
import 'package:day34/pages/explore.dart';
import 'package:day34/pages/notification.dart';
import 'package:day34/pages/profile.dart';
import 'package:day34/pages/search.dart';
import 'package:flashy_tab_bar/flashy_tab_bar.dart';
import 'package:flutter/material.dart';
void main() {
runApp(MaterialApp(
home: HomePage(),
debugShowCheckedModeBanner: false,
));
}
class HomePage extends StatefulWidget {
const HomePage({ Key? key }) : super(key: key);
@override
_HomePageState createState() => _HomePageState();
}
class _HomePageState extends State {
late PageController _pageController;
int _selectedPage = 0;
List pages = [
ExplorePage(),
SearchPage(),
CartPage(),
ProfilePage()
];
void _onItemTapped(int index) {
setState(() {
_selectedPage = index;
_pageController.jumpToPage(index);
});
}
@override
void initState() {
// TODO: implement initState
_pageController = PageController(initialPage: 0);
super.initState();
}
@override
Widget build(BuildContext context) {
return Scaffold(
body: PageView(
onPageChanged: (index) => setState(() { _selectedPage = index; }),
controller: _pageController,
children: [
...pages
],
),
bottomNavigationBar: FlashyTabBar(
selectedIndex: _selectedPage,
showElevation: false,
onItemSelected: (index) => _onItemTapped(index),
items: [
FlashyTabBarItem(
icon: Icon(Icons.home_outlined, size: 23),
title: Text('Home'),
),
FlashyTabBarItem(
icon: Icon(Icons.search, size: 23),
title: Text('Search'),
),
FlashyTabBarItem(
icon: Icon(Icons.shopping_bag_outlined, size: 23),
title: Text('Cart'),
),
FlashyTabBarItem(
icon: Icon(Icons.account_circle_outlined, size: 23,),
title: Text('Profile'),
),
],
),
);
}
}
================================================
FILE: lib/models/product.dart
================================================
class Product {
final String name;
final String brand;
final String imageURL;
final int price;
Product(this.name, this.brand, this.imageURL, this.price);
factory Product.fromJson(Map json) {
return new Product(
json["name"],
json["brand"],
json["imageURL"],
json["price"]
);
}
}
================================================
FILE: lib/pages/cart.dart
================================================
import 'dart:convert';
import 'package:day34/animation/FadeAnimation.dart';
import 'package:day34/models/product.dart';
import 'package:day34/pages/payment.dart';
import 'package:day34/pages/product_view.dart';
import 'package:dotted_border/dotted_border.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:flutter_slidable/flutter_slidable.dart';
class CartPage extends StatefulWidget {
const CartPage({ Key? key }) : super(key: key);
@override
_CartPageState createState() => _CartPageState();
}
class _CartPageState extends State with TickerProviderStateMixin {
late List cartItems = [];
List cartItemCount = [1, 1, 1, 1];
int totalPrice = 0;
Future fetchItems() async {
final String response = await rootBundle.loadString('assets/products.json');
final data = await json.decode(response);
cartItems = data['products']
.map((data) => Product.fromJson(data)).toList();
sumTotal();
}
sumTotal() {
cartItems.forEach((item) {
totalPrice = item.price + totalPrice;
});
}
@override
void initState() {
// TODO: implement initState
super.initState();
fetchItems().whenComplete(() => setState(() {}));
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
elevation: 0,
backgroundColor: Colors.transparent,
title: Text('My Cart', style: TextStyle(color: Colors.black)),
),
body: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
padding: EdgeInsets.symmetric(horizontal: 20),
height: MediaQuery.of(context).size.height * 0.53,
child: cartItems.length > 0 ? FadeAnimation(1.4,
AnimatedList(
scrollDirection: Axis.vertical,
initialItemCount: cartItems.length,
itemBuilder: (context, index, animation) {
return Slidable(
actionPane: SlidableDrawerActionPane(),
secondaryActions: [
MaterialButton(
color: Colors.red.withOpacity(0.15),
elevation: 0,
height: 60,
minWidth: 60,
shape: CircleBorder(),
child: Icon(Icons.delete, color: Colors.red, size: 30,),
onPressed: () {
setState(() {
totalPrice = totalPrice - (int.parse(cartItems[index].price.toString()) * cartItemCount[index]);
AnimatedList.of(context).removeItem(index, (context, animation) {
return cartItem(cartItems[index], index, animation);
});
cartItems.removeAt(index);
cartItemCount.removeAt(index);
});
},
),
],
child: cartItem(cartItems[index], index, animation),
);
}
),
) : Container(),
),
SizedBox(height: 30),
FadeAnimation(1.2,
Container(
padding: EdgeInsets.symmetric(horizontal: 20),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Shipping', style: TextStyle(fontSize: 20)),
Text('\$5.99', style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold))
],
),
),
),
FadeAnimation(1.3, Padding(
padding: EdgeInsets.all(20.0),
child: DottedBorder(
color: Colors.grey.shade400,
dashPattern: [10, 10],
padding: EdgeInsets.all(0),
child: Container()
),
)),
FadeAnimation(1.3, Container(
padding: EdgeInsets.symmetric(horizontal: 20),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Total', style: TextStyle(fontSize: 20)),
Text('\$${totalPrice + 5.99}', style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold))
],
),
)),
SizedBox(height: 10),
FadeAnimation(1.4, Padding(
padding: EdgeInsets.all(20.0),
child: MaterialButton(
onPressed: () {
Navigator.push(context, MaterialPageRoute(builder: (context) => PaymentPage()));
},
height: 50,
elevation: 0,
splashColor: Colors.yellow[700],
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
color: Colors.yellow[800],
child: Center(
child: Text("Checkout", style: TextStyle(color: Colors.white, fontSize: 18),),
),
),
))
]
)
);
}
cartItem(Product product, int index, animation) {
return GestureDetector(
onTap: () {
Navigator.push(context, MaterialPageRoute(builder: (context) => ProductViewPage(product: product)));
},
child: SlideTransition(
position: Tween(
begin: const Offset(-1, 0),
end: Offset.zero
).animate(animation),
child: Container(
margin: EdgeInsets.only(bottom: 20),
padding: EdgeInsets.symmetric(horizontal: 10),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(10),
boxShadow: [
BoxShadow(
color: Colors.grey.shade200,
offset: Offset(0, 2),
blurRadius: 6,
),
],
),
child: Row(
children: [
Container(
margin: EdgeInsets.only(right: 10),
child: ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Image.network(
product.imageURL,
fit: BoxFit.cover,
height: 100,
width: 100,
),
),
),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(product.brand, style: TextStyle(color: Colors.orange.shade400, fontSize: 14,),),
SizedBox(height: 5,),
Text(product.name,
style: TextStyle(
fontSize: 18,
fontWeight: FontWeight.w600,
),
),
SizedBox(height: 15),
Text(
'\$${product.price}',
style: TextStyle(
fontSize: 20,
color: Colors.grey.shade800,
),
),
SizedBox(height: 10),
]
),
),
Column(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
MaterialButton(
minWidth: 10,
padding: EdgeInsets.all(0),
onPressed: () {
setState(() {
if (cartItemCount[index] > 1) {
cartItemCount[index]--;
totalPrice = totalPrice - product.price;
}
});
},
shape: CircleBorder(),
child: Icon(Icons.remove_circle_outline, color: Colors.grey.shade400, size: 30,),
),
Container(child: Center(child: Text(cartItemCount[index].toString(), style: TextStyle(fontSize: 20, color: Colors.grey.shade800),),),),
MaterialButton(
padding: EdgeInsets.all(0),
minWidth: 10,
splashColor: Colors.yellow[700],
onPressed: () {
setState(() {
cartItemCount[index]++;
totalPrice = totalPrice + product.price;
});
},
shape: CircleBorder(),
child: Icon(Icons.add_circle, size: 30,),
),
],
),
]
),
),
),
);
}
}
================================================
FILE: lib/pages/explore.dart
================================================
import 'dart:convert';
import 'package:day34/animation/FadeAnimation.dart';
import 'package:day34/models/product.dart';
import 'package:day34/pages/product_view.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
class ExplorePage extends StatefulWidget {
const ExplorePage({ Key? key }) : super(key: key);
@override
_ExplorePageState createState() => _ExplorePageState();
}
class _ExplorePageState extends State with TickerProviderStateMixin {
late ScrollController _scrollController;
bool _isScrolled = false;
List productList = [];
List size = [
"S",
"M",
"L",
"XL",
];
List colors = [
Colors.black,
Colors.purple,
Colors.orange.shade200,
Colors.blueGrey,
Color(0xFFFFC1D9),
];
int _selectedColor = 0;
int _selectedSize = 1;
var selectedRange = RangeValues(150.00, 1500.00);
@override
void initState() {
_scrollController = ScrollController();
_scrollController.addListener(_listenToScrollChange);
products();
super.initState();
}
void _listenToScrollChange() {
if (_scrollController.offset >= 100.0) {
setState(() {
_isScrolled = true;
});
} else {
setState(() {
_isScrolled = false;
});
}
}
@override
Widget build(BuildContext context) {
return CustomScrollView(
controller: _scrollController,
slivers: [
SliverAppBar(
expandedHeight: 300.0,
elevation: 0,
pinned: true,
floating: true,
stretch: true,
backgroundColor: Colors.grey.shade50,
flexibleSpace: FlexibleSpaceBar(
collapseMode: CollapseMode.pin,
titlePadding: EdgeInsets.only(left: 20, right: 30, bottom: 100),
stretchModes: [
StretchMode.zoomBackground,
// StretchMode.fadeTitle
],
title: AnimatedOpacity(
opacity: _isScrolled ? 0.0 : 1.0,
duration: Duration(milliseconds: 500),
child: FadeAnimation(1, Text("Find your 2021 Collections",
style: TextStyle(
color: Colors.black,
fontSize: 28.0,
))),
),
background: Image.asset("assets/images/background.png", fit: BoxFit.cover,)
),
bottom: AppBar(
toolbarHeight: 70,
elevation: 0,
backgroundColor: Colors.transparent,
title: Row(
children: [
Expanded(
child: FadeAnimation(1.4, Container(
height: 50,
child: TextField(
readOnly: true,
cursorColor: Colors.grey,
decoration: InputDecoration(
contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 20),
filled: true,
fillColor: Colors.white,
prefixIcon: Icon(Icons.search, color: Colors.black),
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(10),
borderSide: BorderSide.none
),
hintText: "Search e.g Cotton Sweatshirt",
hintStyle: TextStyle(fontSize: 14, color: Colors.black),
),
),
)),
),
SizedBox(width: 10),
FadeAnimation(1.5, Container(
height: 50,
width: 50,
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(10)
),
child: IconButton(
onPressed: () {
showFilterModal();
},
icon: Icon(Icons.filter_list, color: Colors.black, size: 30,),
),
))
],
),
),
),
SliverList(
delegate: SliverChildListDelegate([
Container(
padding: EdgeInsets.only(top: 20, left: 20),
height: 330,
child: Column(
children: [
FadeAnimation(1.4, Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Popular Products', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Text('See all ', style: TextStyle(color: Colors.black, fontSize: 14),),
),
],
)),
SizedBox(height: 10,),
Expanded(
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: productList.length,
itemBuilder: (context, index) {
return productCart(productList[index]);
}
)
)
]
)
),
Container(
padding: EdgeInsets.only(top: 20, left: 20),
height: 180,
child: Column(
children: [
FadeAnimation(1.4, Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('For You', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Text('See all ', style: TextStyle(color: Colors.black, fontSize: 14),),
),
],
)),
SizedBox(height: 10,),
Expanded(
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: productList.length,
itemBuilder: (context, index) {
return forYou(productList[index]);
}
)
)
]
)
),
Container(
padding: EdgeInsets.only(top: 20, left: 20),
height: 330,
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Winter Collection', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Text('See all ', style: TextStyle(color: Colors.black, fontSize: 14),),
),
],
),
SizedBox(height: 10,),
Expanded(
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: productList.length,
itemBuilder: (context, index) {
return productCart(productList[index]);
}
)
)
]
)
),
Container(
padding: EdgeInsets.only(top: 20, left: 20),
height: 330,
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Cotton Collection', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
Padding(
padding: EdgeInsets.only(right: 20.0),
child: Text('See all ', style: TextStyle(color: Colors.black, fontSize: 14),),
),
],
),
SizedBox(height: 10,),
Expanded(
child: ListView.builder(
reverse: true,
scrollDirection: Axis.horizontal,
itemCount: productList.length,
itemBuilder: (context, index) {
return productCart(productList[index]);
}
)
)
]
)
),
]),
)
]
);
}
Future products() async {
final String response = await rootBundle.loadString('assets/products.json');
final data = await json.decode(response);
setState(() {
productList = data['products']
.map((data) => Product.fromJson(data)).toList();
});
}
productCart(Product product) {
return AspectRatio(
aspectRatio: 1 / 1,
child: FadeAnimation(1.5, GestureDetector(
onTap: () {
Navigator.push(context, MaterialPageRoute(builder: (context) => ProductViewPage(product: product,)));
},
child: Container(
margin: EdgeInsets.only(right: 20, bottom: 25),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20),
color: Colors.white,
boxShadow: [BoxShadow(
offset: Offset(5, 10),
blurRadius: 15,
color: Colors.grey.shade200,
)],
),
padding: EdgeInsets.all(10),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
height: 150,
child: Stack(
children: [
Container(
width: double.infinity,
child: ClipRRect(
borderRadius: BorderRadius.circular(15),
child: Image.network(product.imageURL, fit: BoxFit.cover)
),
),
// Add to cart button
Positioned(
right: 5,
bottom: 5,
child: MaterialButton(
color: Colors.black,
minWidth: 45,
height: 45,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(50)
),
onPressed: () {
addToCartModal();
},
padding: EdgeInsets.all(5),
child: Center(child: Icon(Icons.shopping_cart, color: Colors.white, size: 20,)),
),
)
],
),
),
SizedBox(height: 20,),
Text(product.name,
style: TextStyle(color: Colors.black, fontSize: 18,),
),
SizedBox(height: 10,),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text(product.brand, style: TextStyle(color: Colors.orange.shade400, fontSize: 14,),),
Text("\$ " +product.price.toString() + '.00',
style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.w800),
),
],
),
],
),
),
)),
);
}
forYou(Product product) {
return AspectRatio(
aspectRatio: 3 / 1,
child: FadeAnimation(1.5, Container(
margin: EdgeInsets.only(right: 20, bottom: 25),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20),
color: Colors.white,
boxShadow: [BoxShadow(
offset: Offset(5, 10),
blurRadius: 15,
color: Colors.grey.shade200,
)],
),
padding: EdgeInsets.all(10),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
width: 100,
child: ClipRRect(
borderRadius: BorderRadius.circular(15),
child: Image.network(product.imageURL, fit: BoxFit.cover)),
),
SizedBox(width: 10,),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(product.name,
style: TextStyle(color: Colors.black, fontSize: 18,),
),
SizedBox(height: 5,),
Text(product.brand, style: TextStyle(color: Colors.orange.shade400, fontSize: 13,),),
SizedBox(height: 10,),
Text("\$ " +product.price.toString() + '.00',
style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.w800),
),
]
),
)
],
),
)),
);
}
showFilterModal() {
showModalBottomSheet(
context: context,
backgroundColor: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.only(topLeft: Radius.circular(20), topRight: Radius.circular(20))
),
builder: (context) {
return StatefulBuilder(
builder: (context, setState) {
return Container(
padding: EdgeInsets.only(top: 20, left: 20, right: 20, bottom: 20),
height: MediaQuery.of(context).size.height * 0.8,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Filter', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
MaterialButton(
onPressed: () {
Navigator.pop(context);
},
minWidth: 40,
height: 40,
color: Colors.grey.shade300,
elevation: 0,
padding: EdgeInsets.all(0),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(50)
),
child: Icon(Icons.close, color: Colors.black,),
)
],
),
SizedBox(height: 20,),
Text("Color", style: TextStyle(fontWeight: FontWeight.bold, fontSize: 20),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: colors.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedColor = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 300),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedColor == index ? colors[index] : colors[index].withOpacity(0.5),
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: _selectedColor == index ? Icon(Icons.check, color: Colors.white,) : Container(),
),
),
);
},
),
),
SizedBox(height: 20,),
Text('Size', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: size.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedSize = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 500),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedSize == index ? Colors.yellow[800] : Colors.grey.shade200,
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: Text(size[index], style: TextStyle(color: _selectedSize == index ? Colors.white : Colors.black, fontSize: 15),),
),
),
);
},
),
),
// Slider Price Renge filter
SizedBox(height: 20,),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text('Price Range', style: TextStyle(color: Colors.black, fontSize: 18, fontWeight: FontWeight.bold),),
Row(
mainAxisAlignment: MainAxisAlignment.end,
children: [
Text('\$ ${selectedRange.start.toStringAsFixed(2)}', style: TextStyle(color: Colors.grey.shade500, fontSize: 12),),
Text(" - ", style: TextStyle(color: Colors.grey.shade500)),
Text('\$ ${selectedRange.end.toStringAsFixed(2)}', style: TextStyle(color: Colors.grey.shade500, fontSize: 12),),
],
),
],
),
SizedBox(height: 10,),
RangeSlider(
values: selectedRange,
min: 0.00,
max: 2000.00,
divisions: 100,
inactiveColor: Colors.grey.shade300,
activeColor: Colors.yellow[800],
labels: RangeLabels('\$ ${selectedRange.start.toStringAsFixed(2)}', '\$ ${selectedRange.end.toStringAsFixed(2)}',),
onChanged: (RangeValues values) {
setState(() => selectedRange = values);
}
),
SizedBox(height: 20,),
button('Filter', () {})
],
),
);
}
);
},
);
}
addToCartModal() {
return showModalBottomSheet(
context: context,
transitionAnimationController: AnimationController(duration: Duration(milliseconds: 400), vsync: this),
builder: (context) => StatefulBuilder(
builder: (context, setState) {
return Container(
height: 350,
padding: EdgeInsets.all(20),
decoration: BoxDecoration(
color: Colors.white,
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text("Color", style: TextStyle(fontWeight: FontWeight.bold, fontSize: 20),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: colors.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedColor = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 300),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedColor == index ? colors[index] : colors[index].withOpacity(0.5),
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: _selectedColor == index ? Icon(Icons.check, color: Colors.white,) : Container(),
),
),
);
},
),
),
SizedBox(height: 20,),
Text("Size", style: TextStyle(fontWeight: FontWeight.bold, fontSize: 20),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: size.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedSize = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 500),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedSize == index ? Colors.yellow[800] : Colors.grey.shade200,
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: Text(size[index], style: TextStyle(color: _selectedSize == index ? Colors.white : Colors.black, fontSize: 15),),
),
),
);
},
),
),
SizedBox(height: 20,),
button('Add to Cart', () {
Navigator.pop(context);
// Let's show a snackbar when an item is added to the cart
final snackbar = SnackBar(
content: Text("Item added to cart"),
duration: Duration(seconds: 5),
action: SnackBarAction(
label: 'Undo',
onPressed: () {},
),
);
ScaffoldMessenger.of(context).showSnackBar(snackbar);
})
],
),
);
},
)
);
}
button(String text, Function onPressed) {
return MaterialButton(
onPressed: () => onPressed(),
height: 50,
elevation: 0,
splashColor: Colors.yellow[700],
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
color: Colors.yellow[800],
child: Center(
child: Text(text, style: TextStyle(color: Colors.white, fontSize: 18),),
),
);
}
}
================================================
FILE: lib/pages/notification.dart
================================================
import 'package:flutter/material.dart';
class NotificationPage extends StatefulWidget {
const NotificationPage({ Key? key }) : super(key: key);
@override
_NotificationPageState createState() => _NotificationPageState();
}
class _NotificationPageState extends State {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
elevation: 0,
backgroundColor: Colors.transparent,
title: Text('Notification Page', style: TextStyle(color: Colors.black)),
),
body: Center(
child: Text('Notification Page')
),
);
}
}
================================================
FILE: lib/pages/payment.dart
================================================
import 'dart:async';
import 'package:day34/animation/FadeAnimation.dart';
import 'package:day34/pages/payment_success.dart';
import 'package:flutter/material.dart';
class PaymentPage extends StatefulWidget {
const PaymentPage({ Key? key }) : super(key: key);
@override
_PaymentPageState createState() => _PaymentPageState();
}
class _PaymentPageState extends State {
int activeCard = 0;
bool _isLoading = false;
late Timer _timer;
pay() {
setState(() {
_isLoading = true;
});
const oneSec = const Duration(seconds: 2);
_timer = new Timer.periodic(
oneSec,
(Timer timer) {
setState(() {
_isLoading = false;
timer.cancel();
Navigator.push(context, MaterialPageRoute(builder: (context) => PaymentSuccess()));
});
},
);
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
backgroundColor: Colors.transparent,
elevation: 0,
title: Text('Payment', style: TextStyle(color: Colors.black),),
leading: BackButton(color: Colors.black,),
),
body: SingleChildScrollView(
child: Padding(
padding: EdgeInsets.all(20.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
activeCard == 0 ?
FadeAnimation(1.2, AnimatedOpacity(
duration: Duration(milliseconds: 500),
opacity: activeCard == 0 ? 1 : 0,
child: Container(
width: double.infinity,
height: 200,
padding: EdgeInsets.all(20.0),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(30),
gradient: LinearGradient(
colors: [
Colors.orange,
Colors.yellow.shade800,
Colors.yellow.shade900,
],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
)
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("Credit Card", style: TextStyle(color: Colors.white),),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text("**** **** **** 7890", style: TextStyle(color: Colors.white, fontSize: 30),),
SizedBox(height: 5,),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("theflutterlover", style: TextStyle(color: Colors.white),),
Image.network('https://img.icons8.com/color/2x/mastercard-logo.png', height: 50),
],
)
],
)
]
),
),
)) :
FadeAnimation(1.2, AnimatedOpacity(
duration: Duration(milliseconds: 500),
opacity: activeCard == 1 ? 1 : 0,
child: Container(
width: double.infinity,
height: 200,
padding: EdgeInsets.all(30.0),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(30),
// color: Colors.grey.shade200
gradient: LinearGradient(
colors: [
Colors.grey.shade200,
Colors.grey.shade100,
Colors.grey.shade200,
Colors.grey.shade300,
],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
)
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Image.network('https://img.icons8.com/ios/2x/mac-os.png', height: 50),
SizedBox(height: 30,),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Text("The Flutter Lover", style: TextStyle(color: Colors.black, fontSize: 18),),
Image.network('https://img.icons8.com/ios/2x/sim-card-chip.png', height: 35,),
],
)
],
)
]
),
),
)),
SizedBox(height: 50,),
FadeAnimation(1.2, Text("Payment Method", style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold),)),
SizedBox(height: 20,),
FadeAnimation(1.3, Row(
children: [
GestureDetector(
onTap: () {
setState(() {
activeCard = 0;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 300),
margin: EdgeInsets.only(right: 10),
padding: EdgeInsets.symmetric(horizontal: 20),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(18),
border: activeCard == 0 ? Border.all(color: Colors.grey.shade300, width: 1)
: Border.all(color: Colors.grey.shade300.withOpacity(0), width: 1),
),
child: Image.network('https://img.icons8.com/color/2x/mastercard-logo.png', height: 50,),
),
),
GestureDetector(
onTap: () {
setState(() {
activeCard = 1;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 300),
margin: EdgeInsets.only(right: 10),
padding: EdgeInsets.symmetric(horizontal: 20),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(18),
border: activeCard == 1 ? Border.all(color: Colors.grey.shade300, width: 1)
: Border.all(color: Colors.grey.shade300.withOpacity(0), width: 1),
),
child: Image.network('https://img.icons8.com/ios-filled/2x/apple-pay.png', height: 50,),
),
),
]
)),
SizedBox(height: 30,),
FadeAnimation(1.4, Container(
height: 50,
padding: EdgeInsets.only(left: 20,),
width: double.infinity,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10),
color: Colors.white
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("Offers", style: TextStyle(fontSize: 15, fontWeight: FontWeight.w600),),
TextButton(
onPressed: () {},
child: Text("Add a code")
)
],
),
)),
SizedBox(height: 20,),
FadeAnimation(1.5, Container(
height: 50,
padding: EdgeInsets.only(left: 20,),
width: double.infinity,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10),
color: Colors.white
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("Address", style: TextStyle(fontSize: 15, fontWeight: FontWeight.w600),),
TextButton(
onPressed: () {},
child: Row(
children: [
Text("E-75, Diamond Dis..."),
Icon(Icons.keyboard_arrow_down, size: 20,)
],
)
)
],
),
)),
SizedBox(height: 100,),
FadeAnimation(1.5, Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("Total Payment", style: TextStyle(fontSize: 20, fontWeight: FontWeight.w600),),
Text("\$240.00", style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold))
],
)),
SizedBox(height: 30),
FadeAnimation(1.4,
MaterialButton(
onPressed: _isLoading ? null : () { pay(); },
height: 50,
elevation: 0,
splashColor: Colors.yellow[700],
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
color: Colors.yellow[800],
child: Center(
child: _isLoading ? Container(
width: 20,
height: 20,
child: CircularProgressIndicator(
backgroundColor: Colors.white,
strokeWidth: 3,
color: Colors.black,
),
) : Text("Pay", style: TextStyle(color: Colors.white, fontSize: 18),),
),
),
),
SizedBox(height: 100),
],
),
),
)
);
}
}
================================================
FILE: lib/pages/payment_success.dart
================================================
import 'package:day34/animation/FadeAnimation.dart';
import 'package:day34/main.dart';
import 'package:flutter/material.dart';
class PaymentSuccess extends StatefulWidget {
const PaymentSuccess({ Key? key }) : super(key: key);
@override
_PaymentSuccessState createState() => _PaymentSuccessState();
}
class _PaymentSuccessState extends State {
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.white,
body: Container(
padding: EdgeInsets.all(40.0),
width: double.infinity,
child: Column(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
FadeAnimation(1, Image.network('https://ouch-cdn2.icons8.com/7fkWk5J2YcodnqGn62xOYYfkl6qhmsCfT2033W-FjaA/rs:fit:784:784/czM6Ly9pY29uczgu/b3VjaC1wcm9kLmFz/c2V0cy9zdmcvMjU5/LzRkM2MyNzJlLWFh/MmQtNDA3Ni04YzU0/LTY0YjNiMzQ4NzQw/OS5zdmc.png',
width: 250,)),
SizedBox(height: 50.0,),
FadeAnimation(1.2, Text('Payment Success! 🥳', style: TextStyle(fontSize: 25.0, fontWeight: FontWeight.bold),)),
SizedBox(height: 20.0,),
FadeAnimation(1.3, Text('Hooray! Your payment proccess has \n been completed successfully..', textAlign: TextAlign.center, style: TextStyle(fontSize: 16.0, color: Colors.grey.shade700),)),
SizedBox(height: 140.0,),
FadeAnimation(1.4,
MaterialButton(
onPressed: () {
Navigator.push(context, MaterialPageRoute(builder: (context) => HomePage()));
},
height: 50,
elevation: 0,
splashColor: Colors.yellow[700],
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
color: Colors.yellow[800],
child: Center(
child: Text("Back to Home", style: TextStyle(color: Colors.white, fontSize: 16),),
),
),
),
SizedBox(height: 20.0,),
FadeAnimation(1.4, Text('Thank you for shopping with us.', style: TextStyle(fontSize: 14.0, color: Colors.grey),)),
],
),
)
);
}
}
================================================
FILE: lib/pages/product_view.dart
================================================
import 'package:day34/models/product.dart';
import 'package:flutter/material.dart';
class ProductViewPage extends StatefulWidget {
final Product product;
const ProductViewPage({ Key? key, required this.product }) : super(key: key);
@override
_ProductViewPageState createState() => _ProductViewPageState();
}
class _ProductViewPageState extends State {
List productList = [];
List size = [
"S",
"M",
"L",
"XL",
];
List colors = [
Colors.black,
Colors.purple,
Colors.orange.shade200,
Colors.blueGrey,
Color(0xFFFFC1D9),
];
int _selectedColor = 0;
int _selectedSize = 1;
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.white,
body: CustomScrollView(
slivers: [
SliverAppBar(
expandedHeight: MediaQuery.of(context).size.height * 0.6,
elevation: 0,
snap: true,
floating: true,
stretch: true,
backgroundColor: Colors.grey.shade50,
flexibleSpace: FlexibleSpaceBar(
stretchModes: [
StretchMode.zoomBackground,
],
background: Image.network(widget.product.imageURL, fit: BoxFit.cover,)
),
bottom: PreferredSize(
preferredSize: Size.fromHeight(45),
child: Transform.translate(
offset: Offset(0, 1),
child: Container(
height: 45,
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.only(
topLeft: Radius.circular(30),
topRight: Radius.circular(30),
),
),
child: Center(
child: Container(
width: 50,
height: 8,
decoration: BoxDecoration(
color: Colors.grey.shade300,
borderRadius: BorderRadius.circular(10),
),
)
),
),
)
),
),
SliverList(
delegate: SliverChildListDelegate([
Container(
height: MediaQuery.of(context).size.height * 0.55,
color: Colors.white,
padding: EdgeInsets.symmetric(horizontal: 20, vertical: 5),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(widget.product.name,
style: TextStyle(color: Colors.black, fontSize: 22, fontWeight: FontWeight.bold,),
),
SizedBox(height: 5,),
Text(widget.product.brand, style: TextStyle(color: Colors.orange.shade400, fontSize: 14,),),
],
),
Text("\$ " +widget.product.price.toString() + '.00',
style: TextStyle(color: Colors.black, fontSize: 16),
),
],
),
SizedBox(height: 20,),
Text("Take a break from jeans with the parker long straight pant. These lightweight, pleat front pants feature a flattering high waist and loose, straight legs.",
style: TextStyle(height: 1.5, color: Colors.grey.shade800, fontSize: 15,),
),
SizedBox(height: 30,),
Text("Color", style: TextStyle(color: Colors.grey.shade400, fontSize: 18),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: colors.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedColor = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 300),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedColor == index ? colors[index] : colors[index].withOpacity(0.5),
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: _selectedColor == index ? Icon(Icons.check, color: Colors.white,) : Container(),
),
),
);
},
),
),
SizedBox(height: 20,),
Text('Size', style: TextStyle(color: Colors.grey.shade400, fontSize: 18),),
SizedBox(height: 10,),
Container(
height: 60,
child: ListView.builder(
scrollDirection: Axis.horizontal,
itemCount: size.length,
itemBuilder: (context, index) {
return GestureDetector(
onTap: () {
setState(() {
_selectedSize = index;
});
},
child: AnimatedContainer(
duration: Duration(milliseconds: 500),
margin: EdgeInsets.only(right: 10),
decoration: BoxDecoration(
color: _selectedSize == index ? Colors.yellow[800] : Colors.grey.shade200,
shape: BoxShape.circle
),
width: 40,
height: 40,
child: Center(
child: Text(size[index], style: TextStyle(color: _selectedSize == index ? Colors.white : Colors.black, fontSize: 15),),
),
),
);
},
),
),
SizedBox(height: 20,),
MaterialButton(
onPressed: () {
Navigator.pop(context);
},
height: 50,
elevation: 0,
splashColor: Colors.yellow[700],
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
color: Colors.yellow[800],
child: Center(
child: Text("Add to Cart", style: TextStyle(color: Colors.white, fontSize: 18),),
),
)
],
)
)
])
),
]
),
);
}
}
================================================
FILE: lib/pages/profile.dart
================================================
import 'package:flutter/material.dart';
class ProfilePage extends StatefulWidget {
const ProfilePage({ Key? key }) : super(key: key);
@override
_ProfilePageState createState() => _ProfilePageState();
}
class _ProfilePageState extends State {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
elevation: 0,
backgroundColor: Colors.transparent,
title: Text('Profile Page', style: TextStyle(color: Colors.black)),
),
body: Center(
child: Text('Profile Page')
),
);
}
}
================================================
FILE: lib/pages/search.dart
================================================
import 'package:flutter/material.dart';
class SearchPage extends StatefulWidget {
const SearchPage({ Key? key }) : super(key: key);
@override
_SearchPageState createState() => _SearchPageState();
}
class _SearchPageState extends State {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
backgroundColor: Colors.transparent,
elevation: 0,
title: Container(
height: 45,
child: TextField(
autofocus: true,
cursorColor: Colors.grey,
decoration: InputDecoration(
contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 0),
filled: true,
fillColor: Colors.white,
prefixIcon: Icon(Icons.search, color: Colors.black),
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(50),
borderSide: BorderSide.none
),
hintText: "Search e.g Sweatshirt",
hintStyle: TextStyle(fontSize: 14, color: Colors.black),
),
),
),
),
body: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Opacity(
opacity: .7,
child: Container(
width: double.infinity,
height: 250,
child: Image( image: AssetImage("assets/images/search.png")),
)
),
SizedBox(height: 40,),
Text("Type to search ...", style: TextStyle(fontSize: 20),)
],
)
);
}
}
================================================
FILE: pubspec.yaml
================================================
name: day34
description: A new Flutter project.
# The following line prevents the package from being accidentally published to
# pub.dev using `pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
# followed by an optional build number separated by a +.
# Both the version and the builder number may be overridden in flutter
# build by specifying --build-name and --build-number, respectively.
# In Android, build-name is used as versionName while build-number used as versionCode.
# Read more about Android versioning at https://developer.android.com/studio/publish/versioning
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 1.0.0+1
environment:
sdk: ">=2.12.0 <3.0.0"
dependencies:
flutter:
sdk: flutter
# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: ^1.0.2
flashy_tab_bar: ^0.0.3
simple_animations: ^1.3.3
dotted_border: ^2.0.0+1
flutter_slidable: ^0.6.0
dev_dependencies:
flutter_test:
sdk: flutter
# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec
# The following section is specific to Flutter.
flutter:
# The following line ensures that the Material Icons font is
# included with your application, so that you can use the icons in
# the material Icons class.
uses-material-design: true
# To add assets to your application, add an assets section, like this:
assets:
- assets/
- assets/images/
# - images/a_dot_ham.jpeg
# An image asset can refer to one or more resolution-specific "variants", see
# https://flutter.dev/assets-and-images/#resolution-aware.
# For details regarding adding assets from package dependencies, see
# https://flutter.dev/assets-and-images/#from-packages
# To add custom fonts to your application, add a fonts section here,
# in this "flutter" section. Each entry in this list should have a
# "family" key with the font family name, and a "fonts" key with a
# list giving the asset and other descriptors for the font. For
# example:
# fonts:
# - family: Schyler
# fonts:
# - asset: fonts/Schyler-Regular.ttf
# - asset: fonts/Schyler-Italic.ttf
# style: italic
# - family: Trajan Pro
# fonts:
# - asset: fonts/TrajanPro.ttf
# - asset: fonts/TrajanPro_Bold.ttf
# weight: 700
#
# For details regarding fonts from package dependencies,
# see https://flutter.dev/custom-fonts/#from-packages
================================================
FILE: test/widget_test.dart
================================================
// This is a basic Flutter widget test.
//
// To perform an interaction with a widget in your test, use the WidgetTester
// utility that Flutter provides. For example, you can send tap and scroll
// gestures. You can also use WidgetTester to find child widgets in the widget
// tree, read text, and verify that the values of widget properties are correct.
import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:day34/main.dart';
void main() {
testWidgets('Counter increments smoke test', (WidgetTester tester) async {
// Build our app and trigger a frame.
await tester.pumpWidget(MyApp());
// Verify that our counter starts at 0.
expect(find.text('0'), findsOneWidget);
expect(find.text('1'), findsNothing);
// Tap the '+' icon and trigger a frame.
await tester.tap(find.byIcon(Icons.add));
await tester.pump();
// Verify that our counter has incremented.
expect(find.text('0'), findsNothing);
expect(find.text('1'), findsOneWidget);
});
}
================================================
FILE: web/index.html
================================================
day34
================================================
FILE: web/manifest.json
================================================
{
"name": "day34",
"short_name": "day34",
"start_url": ".",
"display": "standalone",
"background_color": "#0175C2",
"theme_color": "#0175C2",
"description": "A new Flutter project.",
"orientation": "portrait-primary",
"prefer_related_applications": false,
"icons": [
{
"src": "icons/Icon-192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "icons/Icon-512.png",
"sizes": "512x512",
"type": "image/png"
}
]
}