diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..b5edf30 --- /dev/null +++ b/.env.example @@ -0,0 +1 @@ +GEMINI_API= \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000..3b2e402 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,56 @@ +name: Bug report 🐞 +description: File a bug report +title: "[Bug]: " +body: + - type: checkboxes + id: existing-issue + attributes: + label: Is there an existing issue for this? + description: Please search to see if an issue already exists for the bug you encountered. + options: + - label: I have searched the existing issues + required: true + - type: textarea + id: what-happened + attributes: + label: Describe the bug + description: A concise description of what you are experiencing. + placeholder: Tell us what you see! + validations: + required: true + - type: textarea + id: expected-behaviour + attributes: + label: Expected behavior + description: A clear and concise description of what you expected to happen. + validations: + required: true + - type: textarea + id: screenshots + attributes: + label: Add ScreenShots + description: Add sufficient ScreenShots to explain your issue. + - type: dropdown + id: devices + attributes: + label: On which device are you experiencing this bug? + multiple: true + options: + - Android + - iPhone + - Linux + - Chrome + - Windows + - type: checkboxes + id: terms + attributes: + label: Record + options: + - label: "I have read the Contributing Guidelines" + required: true + - label: "I'm a GSSOC Ext'24 contributor" + required: False + - label: "I'm a Hacktoberfest 2024 contributor" + required: False + - label: "I have starred the repository" + required: true diff --git a/.github/ISSUE_TEMPLATE/documentation_update.yml b/.github/ISSUE_TEMPLATE/documentation_update.yml new file mode 100644 index 0000000..d13fafa --- /dev/null +++ b/.github/ISSUE_TEMPLATE/documentation_update.yml @@ -0,0 +1,61 @@ +name: 📝 Documentation Update +description: Improve Documentation +title: "[Documentation Update]: " +body: + - type: checkboxes + id: existing-issue + attributes: + label: Is there an existing issue for this? + description: Please search to see if an issue already exists for the updates you want to make. + options: + - label: I have searched the existing issues + required: true + - type: textarea + id: issue-description + attributes: + label: Issue Description + description: Please provide a clear description of the documentation update you are suggesting. + placeholder: Describe the improvement or correction you'd like to see in the documentation. + validations: + required: true + - type: textarea + id: suggested-change + attributes: + label: Suggested Change + description: Provide details of the proposed change to the documentation. + placeholder: Explain how the documentation should be updated or corrected. + validations: + required: true + - type: textarea + id: rationale + attributes: + label: Rationale + description: Why is this documentation update necessary or beneficial? + placeholder: Explain the importance or reasoning behind the suggested change. + validations: + required: False + - type: dropdown + id: urgency + attributes: + label: Urgency + description: How urgently do you believe this documentation update is needed? + options: + - High + - Medium + - Low + default: 0 + validations: + required: true + - type: checkboxes + id: terms + attributes: + label: Record + options: + - label: "I have read the Contributing Guidelines" + required: true + - label: "I'm a GSSOC Ext'24 contributor" + required: false + - label: "I'm a Hacktoberfest 2024 contributor" + required: false + - label: "I have starred the repository" + required: true diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 0000000..4d8b351 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,64 @@ +name: ✨ Feature Request or Module +description: Suggest a feature or Module +title: "[Feature Request]: " +body: + - type: checkboxes + id: existing-issue + attributes: + label: Is there an existing issue for this? + description: Please search to see if an issue already exists for this feature. + options: + - label: I have searched the existing issues + required: true + - type: textarea + id: feature-description + attributes: + label: Feature Description + description: Please provide a detailed description of the feature you are requesting. + placeholder: Describe the new feature or enhancement you'd like to see. + validations: + required: true + - type: textarea + id: use-case + attributes: + label: Use Case + description: How would this feature enhance your use of the project? + placeholder: Describe a specific use case or scenario where this feature would be beneficial. + validations: + required: true + - type: textarea + id: benefits + attributes: + label: Benefits + description: What benefits would this feature bring to the project or community? + placeholder: Explain the advantages of implementing this feature. + - type: textarea + id: screenShots + attributes: + label: Add ScreenShots + description: If any... + - type: dropdown + id: priority + attributes: + label: Priority + description: How important is this feature to you? + options: + - High + - Medium + - Low + default: 0 + validations: + required: true + - type: checkboxes + id: terms + attributes: + label: Record + options: + - label: "I have read the Contributing Guidelines" + required: true + - label: "I'm a GSSOC Ext'24 contributor" + required: false + - label: "I'm a Hacktoberfest 2024 contributor" + required: False + - label: "I have starred the repository" + required: true diff --git a/.github/scripts/update_structure.py b/.github/scripts/update_structure.py new file mode 100644 index 0000000..fdf8db3 --- /dev/null +++ b/.github/scripts/update_structure.py @@ -0,0 +1,101 @@ +import os +import github +from github import Github + +# Helper function to recursively build the repo structure and include file extensions +def get_repo_structure(path='.', prefix=''): + structure = [] + try: + items = sorted(os.listdir(path)) + except FileNotFoundError: + print(f"Path not found: {path}") + return structure + + for i, item in enumerate(items): + if item.startswith('.'): + continue # Skip hidden files and directories + item_path = os.path.join(path, item) + is_last = i == len(items) - 1 + current_prefix = '└── ' if is_last else '├── ' + + if os.path.isdir(item_path): + # Directory case + structure.append(f"{prefix}{current_prefix}{item}/") + next_prefix = prefix + (' ' if is_last else '│ ') + structure.extend(get_repo_structure(item_path, next_prefix)) + else: + # File case with extension + file_name, file_extension = os.path.splitext(item) + structure.append(f"{prefix}{current_prefix}{file_name}{file_extension}") + + return structure + +# Function to update the repo_structure.txt file +def update_structure_file(structure): + try: + with open('repo_structure.txt', 'w') as f: + f.write('\n'.join(structure)) + print("repo_structure.txt updated successfully.") + except IOError as e: + print(f"Error writing to repo_structure.txt: {e}") + +# Function to update the README.md with the new structure +def update_README(structure): + try: + with open('PROJECT_STRUCTURE.md', 'r') as f: + content = f.read() + except FileNotFoundError: + print("PROJECT_STRUCTURE.md not found.") + return + + start_marker = '' + end_marker = '' + + start_index = content.find(start_marker) + end_index = content.find(end_marker) + + if start_index != -1 and end_index != -1: + new_content = ( + content[:start_index + len(start_marker)] + + '\n```\n' + '\n'.join(structure) + '\n```\n' + + content[end_index:] + ) + try: + with open('PROJECT_STRUCTURE.md', 'w') as f: + f.write(new_content) + print("PROJECT_STRUCTURE.md updated with new structure.") + except IOError as e: + print(f"Error writing to PROJECT_STRUCTURE.md: {e}") + else: + print("Markers not found in PROJECT_STRUCTURE.md. Structure not updated.") + +# Main function to compare and update repository structure +def main(): + gh_token = os.getenv('GH_TOKEN') + gh_repo = os.getenv('GITHUB_REPOSITORY') + + if not gh_token or not gh_repo: + print("Environment variables GH_TOKEN and GITHUB_REPOSITORY must be set.") + return + + g = Github(gh_token) + repo = g.get_repo(gh_repo) + + current_structure = get_repo_structure() + + try: + # Fetch the contents of repo_structure.txt from GitHub + contents = repo.get_contents("repo_structure.txt") + existing_structure = contents.decoded_content.decode().split('\n') + except github.GithubException: + existing_structure = None + + if current_structure != existing_structure: + update_structure_file(current_structure) + update_README(current_structure) + print("Repository structure updated.") + else: + print("No changes in repository structure.") + +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/.github/workflows/build_apk.yml b/.github/workflows/build_apk.yml new file mode 100644 index 0000000..8abb940 --- /dev/null +++ b/.github/workflows/build_apk.yml @@ -0,0 +1,41 @@ +name: Build APK on Merge to Main + +on: + push: + branches: + - main + +jobs: + build-apk: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Set up Java + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'temurin' + + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + flutter-version: '3.19.5' + channel: stable + + - name: Install dependencies + run: flutter pub get + continue-on-error: true + + - name: Build APK + run: flutter build apk --release + continue-on-error: true + + - name: Upload APK as artifact + uses: actions/upload-artifact@v3 + with: + name: apk + path: build/app/outputs/flutter-apk/app-release.apk + continue-on-error: true diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml new file mode 100644 index 0000000..0b02291 --- /dev/null +++ b/.github/workflows/greetings.yml @@ -0,0 +1,16 @@ +name: Greetings + +on: [pull_request_target, issues] + +jobs: + greeting: + runs-on: ubuntu-latest + permissions: + issues: write + pull-requests: write + steps: + - uses: actions/first-interaction@v1 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + issue-message: "👋 Thank you @${{ github.actor }} for raising an issue! We appreciate your effort in helping us improve. Our team will review it shortly. Stay tuned!" + pr-message: " 🎉 Thank you @${{ github.actor }} for your contribution! Your pull request has been submitted successfully. A maintainer will review it as soon as possible. We appreciate your support in making this project better" diff --git a/.github/workflows/update-readme.yml b/.github/workflows/update-readme.yml new file mode 100644 index 0000000..d42be2a --- /dev/null +++ b/.github/workflows/update-readme.yml @@ -0,0 +1,38 @@ +name: Update Repository structure + +on: + schedule: + - cron: '0 * * * *' # Run every hour + workflow_dispatch: # Allow manual triggering + push: + branches: + - main + +jobs: + detect-and-update-structure: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: 3.12 + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install PyGithub + + - name: Run update script + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: python .github/scripts/update_structure.py + + - name: Commit and push if changed + run: | + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + git config user.name "github-actions[bot]" + git add . + git diff --quiet && git diff --staged --quiet || (git commit -m "Update repo structure" && git push) \ No newline at end of file diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e8bcb3c --- /dev/null +++ b/.gitignore @@ -0,0 +1,53 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ +migrate_working_dir/ + +# 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 +.pub-cache/ +.pub/ +/build/ + +# 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 + +# Features +/Feature_Functionality.md + +# firebase +# /firebase.json +# /lib/firebase_options.dart +# /android/app/google-services.json + +.env diff --git a/.metadata b/.metadata new file mode 100644 index 0000000..d2765fc --- /dev/null +++ b/.metadata @@ -0,0 +1,45 @@ +# 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: "54e66469a933b60ddf175f858f82eaeb97e48c8d" + channel: "stable" + +project_type: app + +# Tracks metadata for the flutter migrate command +migration: + platforms: + - platform: root + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: android + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: ios + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: linux + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: macos + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: web + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + - platform: windows + create_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + base_revision: 54e66469a933b60ddf175f858f82eaeb97e48c8d + + # User provided section + + # List of Local paths (relative to this file) that should be + # ignored by the migrate tool. + # + # Files that are not part of the templates will be ignored by default. + unmanaged_files: + - 'lib/main.dart' + - 'ios/Runner.xcodeproj/project.pbxproj' diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json new file mode 100644 index 0000000..f912847 --- /dev/null +++ b/.vscode/c_cpp_properties.json @@ -0,0 +1,18 @@ +{ + "configurations": [ + { + "name": "windows-gcc-x86", + "includePath": [ + "${workspaceFolder}/**" + ], + "compilerPath": "C:/MinGW/bin/gcc.exe", + "cStandard": "${default}", + "cppStandard": "${default}", + "intelliSenseMode": "windows-gcc-x86", + "compilerArgs": [ + "" + ] + } + ], + "version": 4 +} \ No newline at end of file diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..ec4d5c8 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,24 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "C/C++ Runner: Debug Session", + "type": "cppdbg", + "request": "launch", + "args": [], + "stopAtEntry": false, + "externalConsole": true, + "cwd": "c:/Users/conta/OneDrive/Documents/Desktop/donorconnect/lib/views/pages/search/widgets", + "program": "c:/Users/conta/OneDrive/Documents/Desktop/donorconnect/lib/views/pages/search/widgets/build/Debug/outDebug", + "MIMode": "gdb", + "miDebuggerPath": "gdb", + "setupCommands": [ + { + "description": "Enable pretty-printing for gdb", + "text": "-enable-pretty-printing", + "ignoreFailures": true + } + ] + } + ] +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..27870d7 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,60 @@ +{ + "C_Cpp_Runner.cCompilerPath": "gcc", + "C_Cpp_Runner.cppCompilerPath": "g++", + "C_Cpp_Runner.debuggerPath": "gdb", + "C_Cpp_Runner.cStandard": "", + "C_Cpp_Runner.cppStandard": "", + "C_Cpp_Runner.msvcBatchPath": "C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Auxiliary/Build/vcvarsall.bat", + "C_Cpp_Runner.useMsvc": false, + "C_Cpp_Runner.warnings": [ + "-Wall", + "-Wextra", + "-Wpedantic", + "-Wshadow", + "-Wformat=2", + "-Wcast-align", + "-Wconversion", + "-Wsign-conversion", + "-Wnull-dereference" + ], + "C_Cpp_Runner.msvcWarnings": [ + "/W4", + "/permissive-", + "/w14242", + "/w14287", + "/w14296", + "/w14311", + "/w14826", + "/w44062", + "/w44242", + "/w14905", + "/w14906", + "/w14263", + "/w44265", + "/w14928" + ], + "C_Cpp_Runner.enableWarnings": true, + "C_Cpp_Runner.warningsAsError": false, + "C_Cpp_Runner.compilerArgs": [], + "C_Cpp_Runner.linkerArgs": [], + "C_Cpp_Runner.includePaths": [], + "C_Cpp_Runner.includeSearch": [ + "*", + "**/*" + ], + "C_Cpp_Runner.excludeSearch": [ + "**/build", + "**/build/**", + "**/.*", + "**/.*/**", + "**/.vscode", + "**/.vscode/**" + ], + "C_Cpp_Runner.useAddressSanitizer": false, + "C_Cpp_Runner.useUndefinedSanitizer": false, + "C_Cpp_Runner.useLeakSanitizer": false, + "C_Cpp_Runner.showCompilationTime": false, + "C_Cpp_Runner.useLinkTimeOptimization": false, + "C_Cpp_Runner.msvcSecureNoWarnings": false, + "cmake.sourceDirectory": "/home/om-dixit/Desktop/Dev/Flutter Projects/debugathon_flutter/linux" +} \ No newline at end of file diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..84ebebd --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,128 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +We as members, contributors, and leaders pledge to make participation in our +community a harassment-free experience for everyone, regardless of age, body +size, visible or invisible disability, ethnicity, sex characteristics, gender +identity and expression, level of experience, education, socio-economic status, +nationality, personal appearance, race, religion, or sexual identity +and orientation. + +We pledge to act and interact in ways that contribute to an open, welcoming, +diverse, inclusive, and healthy community. + +## Our Standards + +Examples of behavior that contributes to a positive environment for our +community include: + +- Demonstrating empathy and kindness toward other people +- Being respectful of differing opinions, viewpoints, and experiences +- Giving and gracefully accepting constructive feedback +- Accepting responsibility and apologizing to those affected by our mistakes, + and learning from the experience +- Focusing on what is best not just for us as individuals, but for the + overall community + +Examples of unacceptable behavior include: + +- The use of sexualized language or imagery, and sexual attention or + advances of any kind +- Trolling, insulting or derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or email + address, without their explicit permission +- Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Enforcement Responsibilities + +Community leaders are responsible for clarifying and enforcing our standards of +acceptable behavior and will take appropriate and fair corrective action in +response to any behavior that they deem inappropriate, threatening, offensive, +or harmful. + +Community leaders have the right and responsibility to remove, edit, or reject +comments, commits, code, wiki edits, issues, and other contributions that are +not aligned to this Code of Conduct, and will communicate reasons for moderation +decisions when appropriate. + +## Scope + +This Code of Conduct applies within all community spaces, and also applies when +an individual is officially representing the community in public spaces. +Examples of representing our community include using an official e-mail address, +posting via an official social media account, or acting as an appointed +representative at an online or offline event. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported to the community leaders responsible for enforcement at +hetgoraj@gmail.com . +All complaints will be reviewed and investigated promptly and fairly. + +All community leaders are obligated to respect the privacy and security of the +reporter of any incident. + +## Enforcement Guidelines + +Community leaders will follow these Community Impact Guidelines in determining +the consequences for any action they deem in violation of this Code of Conduct: + +### 1. Correction + +**Community Impact**: Use of inappropriate language or other behavior deemed +unprofessional or unwelcome in the community. + +**Consequence**: A private, written warning from community leaders, providing +clarity around the nature of the violation and an explanation of why the +behavior was inappropriate. A public apology may be requested. + +### 2. Warning + +**Community Impact**: A violation through a single incident or series +of actions. + +**Consequence**: A warning with consequences for continued behavior. No +interaction with the people involved, including unsolicited interaction with +those enforcing the Code of Conduct, for a specified period of time. This +includes avoiding interactions in community spaces as well as external channels +like social media. Violating these terms may lead to a temporary or +permanent ban. + +### 3. Temporary Ban + +**Community Impact**: A serious violation of community standards, including +sustained inappropriate behavior. + +**Consequence**: A temporary ban from any sort of interaction or public +communication with the community for a specified period of time. No public or +private interaction with the people involved, including unsolicited interaction +with those enforcing the Code of Conduct, is allowed during this period. +Violating these terms may lead to a permanent ban. + +### 4. Permanent Ban + +**Community Impact**: Demonstrating a pattern of violation of community +standards, including sustained inappropriate behavior, harassment of an +individual, or aggression toward or disparagement of classes of individuals. + +**Consequence**: A permanent ban from any sort of public interaction within +the community. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], +version 2.0, available at +https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. + +Community Impact Guidelines were inspired by [Mozilla's code of conduct +enforcement ladder](https://github.com/mozilla/diversity). + +[homepage]: https://www.contributor-covenant.org + +For answers to common questions about this code of conduct, see the FAQ at +https://www.contributor-covenant.org/faq. Translations are available at +https://www.contributor-covenant.org/translations. diff --git a/Contributors.md b/Contributors.md new file mode 100644 index 0000000..30b5197 --- /dev/null +++ b/Contributors.md @@ -0,0 +1,152 @@ +# 🌟Thank you for your interest in contributing to **DonorConnect!**🌟 + +Before you start contributing, please take a moment to review our guidelines below. If you have any questions, feel free to open an issue, and we'll be happy to assist you. 🚀 + +--- +# 📊 Project Overview +DonorConnect is a platform designed to simplify the process of connecting donors with those in need of critical donations, including blood, organs, and resources. Your contributions will help make a difference in people's lives by improving features, fixing issues, and adding new functionalities. + +--- +# 🛠️ How to contribute: +- Follow these steps to contribute to DonorConnect: +1. **Fork this Repository** 🍴: + Click the fork button at the top of the repository page to create a copy in your GitHub account. + +2. **Clone the Repository to Your Local Machine** 🧩: + Open your terminal and clone the repo: + +```bash + +git clone https://github.com/Your-Username/DonorConnect.git + +``` + +3. **Create a New Branch** 🌿: + Work on a separate branch for your feature or fix: + ```bash + git branch -c "Feature-Name" + git checkout Feature-Name + ``` +4. **Make Your Changes** 🛠️: + Add your code, test it locally, and ensure everything works. + +5. **Add and Commit Your Changes** 💬: + Save your progress and commit with a meaningful message: + + ```bash + git commit -m "Brief Description of Changes" + ``` +7. **Push Your Changes** 🚢: + Push your feature branch to your remote repository: + + ```bash + git push origin Feature-Name + ``` +9. **Submit a Pull Request** 🔥: + Go to GitHub and create a Pull Request (PR) for review. + +--- + + +# 🎉 Welcome, Contributors! +We’re excited to have you on board. Whether you're fixing bugs 🐞, improving the UI 🎨, or adding new features 🆕, your contributions will help improve DonorConnect for users worldwide. + +- **Here’s how you can start contributing:** + +- Fork the Repository. +- Create a New Feature Branch. +- Make Meaningful Commits. +- Push to GitHub. +- Open a Pull Request (PR). +- No contribution is too small! We appreciate every effort. + +--- +# 📜 Contribution Guidelines: +To maintain the quality of contributions to DonorConnect, please adhere to these guidelines: + +1.**Code Style:** +Ensure consistent code formatting and readability. +Write clear, concise comments where needed. + +2.**Commit Messages:** +Use descriptive and meaningful messages. +Briefly summarize the changes made. + +3.**Pull Requests:** +PRs should focus on a specific issue or feature. +Provide detailed descriptions and reference any relevant issues. + +4.**Testing:** +Test your changes locally before submitting a PR. +Ensure no existing features are broken. + +5.**Issue Tracker:** +Check the issue tracker before starting work to avoid duplicating efforts. +Reference issues in your PRs to link relevant work. + +--- +# 💻 Technologies We Use +DonorConnect is built using modern technologies to ensure reliability and scalability: + +**Frontend:** React ⚛️, JavaScript 🌐, HTML, CSS 🎨 +**Flutter & Dart:** For cross-platform mobile development. +**Firebase:** For authentication and backend services. +**Dart Cubit:** For state management. +**Version Control:** Git & GitHub 🛠️ + +--- +# 🔄 Opening a Pull Request +To submit your PR: + +- Fork the repository. +- Clone the repository to your local system. +```bash +git clone https://github.com/Your-Username/DonorConnect.git +``` +- Set up the project as detailed in Readme.md. +- Make changes and test your code. +- Follow the commit message and PR guidelines. +- Submit your PR and await approval for merging. + +--- +# 🐞Issue Report Process +Encountered a bug or have a suggestion? Follow these steps to report it: + +1.**Check for Existing Issues:** Review the Issue Tracker to see if it’s already reported. +2.**Open a New Issue:** If it hasn’t been raised, click "New Issue" and provide a detailed description. +3.**Be Specific:** Share clear steps to reproduce the issue and include screenshots/logs where applicable. 🖼️ + +--- +# ✨Guidelines +- Contributions such as low-code improvements, UI enhancements, feature implementations, or bug fixes are all valuable. +- Ensure your fork is up-to-date with the main branch before making changes. +- Interact courteously with other developers—be respectful and supportive. +- Always test your code before submitting. +- Use meaningful commit messages, prefixed with feat or fix. +- Use separate branches for each PR you create. +```bash + +git checkout -b +``` +- For PRs related to issues, mention the issue number in the title. +- Provide a clear and descriptive title for your PR summarizing the changes. +- Avoid spam PRs—contribute thoughtfully and follow the Code of Conduct. + +--- +# 🌐 Community and Communication +Feel free to engage with other contributors through GitHub Issues or Discussions for questions, feedback, or feature requests. 💬 + +--- +# 📂 Project Structure +We follow a structured approach to ensure maintainability. If you make changes that impact the structure, be sure to document them. + +--- +# 💡 Need Inspiration? +Looking for ideas on what to contribute? Check the "Issues" tab for open tasks or suggest features that align with our mission. 🔍 + +--- +# ✨ Join the Mission +We’re always looking for passionate contributors. Help us revolutionize donation management and make a positive impact in the world! 🌍 + +--- +![Contributors](https://contrib.rocks/image?repo=prajapatihet/donorconnect) diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 0000000..1ff7c86 --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Hetkumar Prajapati + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/PROJECT_STRUCTURE.md b/PROJECT_STRUCTURE.md new file mode 100644 index 0000000..64cc198 --- /dev/null +++ b/PROJECT_STRUCTURE.md @@ -0,0 +1,409 @@ +## Project Structure + + +``` +├── CODE_OF_CONDUCT.md +├── Contributors.md +├── LICENSE.md +├── PROJECT_STRUCTURE.md +├── README.md +├── analysis_options.yaml +├── android/ +│ ├── app/ +│ │ ├── build.gradle +│ │ ├── google-services.json +│ │ └── src/ +│ │ ├── debug/ +│ │ │ └── AndroidManifest.xml +│ │ ├── main/ +│ │ │ ├── AndroidManifest.xml +│ │ │ ├── ic_launcher-playstore.png +│ │ │ ├── kotlin/ +│ │ │ │ └── com/ +│ │ │ │ └── example/ +│ │ │ │ └── donorconnect/ +│ │ │ │ └── MainActivity.kt +│ │ │ └── res/ +│ │ │ ├── drawable/ +│ │ │ │ ├── background.png +│ │ │ │ └── launch_background.xml +│ │ │ ├── drawable-hdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-hdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-mdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-mdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-hdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-hdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-mdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-mdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xxhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xxxhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xxxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-v21/ +│ │ │ │ ├── background.png +│ │ │ │ └── launch_background.xml +│ │ │ ├── drawable-xhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-xxhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-xxxhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xxxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── mipmap-hdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-mdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xxhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xxxhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── values/ +│ │ │ │ └── styles.xml +│ │ │ ├── values-night/ +│ │ │ │ └── styles.xml +│ │ │ ├── values-night-v31/ +│ │ │ │ └── styles.xml +│ │ │ └── values-v31/ +│ │ │ └── styles.xml +│ │ └── profile/ +│ │ └── AndroidManifest.xml +│ ├── build.gradle +│ ├── gradle/ +│ │ └── wrapper/ +│ │ └── gradle-wrapper.properties +│ ├── gradle.properties +│ └── settings.gradle +├── assets/ +│ └── images/ +│ ├── OnBoarding1.jpg +│ ├── OnBoarding2.jpg +│ ├── OnBoarding3.jpg +│ ├── donorConnect.png +│ ├── donorConnect1.png +│ ├── empty_calendar.png +│ ├── google.png +│ ├── home.png +│ ├── home_image1.png +│ ├── home_image2.png +│ ├── launcher_icon.png +│ ├── launcher_icon1.png +│ ├── login.jpg +│ ├── logo.png +│ ├── logo1.png +│ └── signup.jpg +├── devtools_options.yaml +├── firebase.json +├── ios/ +│ ├── Flutter/ +│ │ ├── AppFrameworkInfo.plist +│ │ ├── Debug.xcconfig +│ │ └── Release.xcconfig +│ ├── Podfile +│ ├── Podfile.lock +│ ├── Runner/ +│ │ ├── AppDelegate.swift +│ │ ├── Assets.xcassets/ +│ │ │ ├── AppIcon.appiconset/ +│ │ │ │ ├── Contents.json +│ │ │ │ ├── Icon-App-1024x1024@1x.png +│ │ │ │ ├── Icon-App-20x20@1x.png +│ │ │ │ ├── Icon-App-20x20@2x.png +│ │ │ │ ├── Icon-App-20x20@3x.png +│ │ │ │ ├── Icon-App-29x29@1x.png +│ │ │ │ ├── Icon-App-29x29@2x.png +│ │ │ │ ├── Icon-App-29x29@3x.png +│ │ │ │ ├── Icon-App-38x38@2x.png +│ │ │ │ ├── Icon-App-38x38@3x.png +│ │ │ │ ├── Icon-App-40x40@1x.png +│ │ │ │ ├── Icon-App-40x40@2x.png +│ │ │ │ ├── Icon-App-40x40@3x.png +│ │ │ │ ├── Icon-App-60x60@2x.png +│ │ │ │ ├── Icon-App-60x60@3x.png +│ │ │ │ ├── Icon-App-64x64@2x.png +│ │ │ │ ├── Icon-App-64x64@3x.png +│ │ │ │ ├── Icon-App-68x68@2x.png +│ │ │ │ ├── Icon-App-76x76@1x.png +│ │ │ │ ├── Icon-App-76x76@2x.png +│ │ │ │ └── Icon-App-83.5x83.5@2x.png +│ │ │ ├── BrandingImage.imageset/ +│ │ │ │ ├── BrandingImage.png +│ │ │ │ ├── BrandingImage@2x.png +│ │ │ │ ├── BrandingImage@3x.png +│ │ │ │ └── Contents.json +│ │ │ ├── LaunchBackground.imageset/ +│ │ │ │ ├── Contents.json +│ │ │ │ └── background.png +│ │ │ └── LaunchImage.imageset/ +│ │ │ ├── Contents.json +│ │ │ ├── LaunchImage.png +│ │ │ ├── LaunchImage@2x.png +│ │ │ ├── LaunchImage@3x.png +│ │ │ └── README.md +│ │ ├── Base.lproj/ +│ │ │ ├── LaunchScreen.storyboard +│ │ │ └── Main.storyboard +│ │ ├── GoogleService-Info.plist +│ │ ├── 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 +│ └── RunnerTests/ +│ └── RunnerTests.swift +├── l10n.yaml +├── lib/ +│ ├── Utils/ +│ │ ├── Textbox.dart +│ │ ├── constants/ +│ │ │ ├── images_string.dart +│ │ │ └── text_string.dart +│ │ ├── show_snackbar.dart +│ │ └── validation_helpers.dart +│ ├── cubit/ +│ │ ├── auth/ +│ │ │ ├── auth_cubit.dart +│ │ │ └── auth_state.dart +│ │ ├── forgot_password/ +│ │ │ ├── forgot_password_cubit.dart +│ │ │ └── forgot_password_state.dart +│ │ ├── locate_blood_banks/ +│ │ │ └── locate_blood_banks_cubit.dart +│ │ ├── profile/ +│ │ │ ├── profile_cubit.dart +│ │ │ └── profile_state.dart +│ │ └── theme_toggle/ +│ │ ├── theme_cubit.dart +│ │ └── theme_state.dart +│ ├── firebase_options.dart +│ ├── l10n/ +│ │ ├── intl_en.arb +│ │ ├── intl_gu.arb +│ │ └── intl_hi.arb +│ ├── language/ +│ │ ├── cubit/ +│ │ │ └── language_cubit.dart +│ │ ├── helper/ +│ │ │ ├── langauge_popup.dart +│ │ │ ├── language.dart +│ │ │ └── language_extention.dart +│ │ └── services/ +│ │ └── language_repositoty.dart +│ ├── main.dart +│ ├── models/ +│ │ ├── user_model.dart +│ │ └── verification_status.dart +│ ├── secrets.dart +│ ├── services/ +│ │ ├── blood_bank_service.dart +│ │ └── verification_service.dart +│ └── views/ +│ ├── common_widgets/ +│ │ ├── donor_card.dart +│ │ ├── events_card.dart +│ │ ├── home_card.dart +│ │ ├── home_card_form.dart +│ │ ├── rounded_conatiner.dart +│ │ ├── rounded_image.dart +│ │ └── toggle_button.dart +│ ├── controllers/ +│ │ └── onboarding/ +│ │ └── onboarding_controller.dart +│ ├── pages/ +│ │ ├── Required/ +│ │ │ ├── required_screen.dart +│ │ │ └── widgets/ +│ │ │ └── choice_chip.dart +│ │ ├── camps/ +│ │ │ ├── calendarPage.dart +│ │ │ └── campsPage.dart +│ │ ├── forgot_password/ +│ │ │ ├── change-password.dart +│ │ │ └── forgot-password.dart +│ │ ├── learn_about_donation/ +│ │ │ └── learn_about_donation.dart +│ │ ├── locate_blood_banks/ +│ │ │ └── locate_blood_banks.dart +│ │ ├── login/ +│ │ │ └── login.dart +│ │ ├── main_home/ +│ │ │ ├── bottom_nav.dart +│ │ │ ├── chatbot.dart +│ │ │ ├── home_pages/ +│ │ │ │ └── home_screen.dart +│ │ │ └── homepage.dart +│ │ ├── onboarding/ +│ │ │ ├── onboarding.dart +│ │ │ └── widgets/ +│ │ │ ├── onboarding_dot_navigation.dart +│ │ │ ├── onboarding_next_button.dart +│ │ │ ├── onboarding_page.dart +│ │ │ └── onboarding_skip.dart +│ │ ├── profile/ +│ │ │ └── profile_screen.dart +│ │ ├── register/ +│ │ │ └── signup.dart +│ │ ├── search/ +│ │ │ ├── search_screen.dart +│ │ │ └── widgets/ +│ │ │ ├── blood_bank_form.dart +│ │ │ └── blood_donor_form.dart +│ │ └── welcome/ +│ │ └── welcome_screen.dart +│ └── verificationform.dart +├── linux/ +│ ├── CMakeLists.txt +│ ├── flutter/ +│ │ ├── CMakeLists.txt +│ │ ├── generated_plugin_registrant.cc +│ │ ├── generated_plugin_registrant.h +│ │ └── generated_plugins.cmake +│ ├── main.cc +│ ├── my_application.cc +│ └── my_application.h +├── macos/ +│ ├── Flutter/ +│ │ ├── Flutter-Debug.xcconfig +│ │ ├── Flutter-Release.xcconfig +│ │ └── GeneratedPluginRegistrant.swift +│ ├── Podfile +│ ├── Runner/ +│ │ ├── AppDelegate.swift +│ │ ├── Assets.xcassets/ +│ │ │ └── AppIcon.appiconset/ +│ │ │ ├── Contents.json +│ │ │ ├── app_icon_1024.png +│ │ │ ├── app_icon_128.png +│ │ │ ├── app_icon_16.png +│ │ │ ├── app_icon_256.png +│ │ │ ├── app_icon_32.png +│ │ │ ├── app_icon_512.png +│ │ │ └── app_icon_64.png +│ │ ├── Base.lproj/ +│ │ │ └── MainMenu.xib +│ │ ├── Configs/ +│ │ │ ├── AppInfo.xcconfig +│ │ │ ├── Debug.xcconfig +│ │ │ ├── Release.xcconfig +│ │ │ └── Warnings.xcconfig +│ │ ├── DebugProfile.entitlements +│ │ ├── GoogleService-Info.plist +│ │ ├── Info.plist +│ │ ├── MainFlutterWindow.swift +│ │ └── Release.entitlements +│ ├── Runner.xcodeproj/ +│ │ ├── project.pbxproj +│ │ ├── project.xcworkspace/ +│ │ │ └── xcshareddata/ +│ │ │ └── IDEWorkspaceChecks.plist +│ │ └── xcshareddata/ +│ │ └── xcschemes/ +│ │ └── Runner.xcscheme +│ ├── Runner.xcworkspace/ +│ │ ├── contents.xcworkspacedata +│ │ └── xcshareddata/ +│ │ └── IDEWorkspaceChecks.plist +│ └── RunnerTests/ +│ └── RunnerTests.swift +├── native_splash.yaml +├── pubspec.lock +├── pubspec.yaml +├── readme/ +│ └── gssoc_ext_2024.png +├── repo_structure.txt +├── test/ +│ └── widget_test.dart +├── web/ +│ ├── favicon.png +│ ├── icons/ +│ │ ├── Icon-192.png +│ │ ├── Icon-512.png +│ │ ├── Icon-maskable-192.png +│ │ └── Icon-maskable-512.png +│ ├── index.html +│ ├── manifest.json +│ └── splash/ +│ └── img/ +│ ├── branding-1x.png +│ ├── branding-2x.png +│ ├── branding-3x.png +│ ├── branding-4x.png +│ ├── branding-dark-1x.png +│ ├── branding-dark-2x.png +│ ├── branding-dark-3x.png +│ ├── branding-dark-4x.png +│ ├── dark-1x.png +│ ├── dark-2x.png +│ ├── dark-3x.png +│ ├── dark-4x.png +│ ├── light-1x.png +│ ├── light-2x.png +│ ├── light-3x.png +│ └── light-4x.png +└── windows/ + ├── CMakeLists.txt + ├── flutter/ + │ ├── CMakeLists.txt + │ ├── generated_plugin_registrant.cc + │ ├── generated_plugin_registrant.h + │ └── generated_plugins.cmake + └── runner/ + ├── CMakeLists.txt + ├── Runner.rc + ├── flutter_window.cpp + ├── flutter_window.h + ├── main.cpp + ├── resource.h + ├── resources/ + │ └── app_icon.ico + ├── runner.exe.manifest + ├── utils.cpp + ├── utils.h + ├── win32_window.cpp + └── win32_window.h +``` + \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..22d5463 --- /dev/null +++ b/README.md @@ -0,0 +1,191 @@ +
+ +
+ +**DonorConnect**, an application designed to connect donors and organizations for life-saving contributions. This guide will help you contribute to the project. + +## Project Structure + +Check the project structure here [Project Structure](PROJECT_STRUCTURE.md) + +## Table of Contents +- [📂 Project Overview](#-project-overview) +- [🏆 Featured in](#-featured-in) +- [🚀 Features](##-features) +- [🚀 Let's Get Started](#-lets-get-started) +- [Contributing using GitHub Desktop](#alternatively-contribute-using-github-desktop) +- [Code of Conduct](#code-of-conduct) +- [Contributing Guidelines](#contributing-guidelines) +- [❤️ Our Valuable Contributors](#️-our-valuable-contributors) +- [License](#license) + +## 📂 Project Overview + +**DonorConnect** is a Flutter-based application that provides a platform for people to donate blood and organs. Users can search and filter donors by location, blood group, and availability, as well as connect with relevant organizations. + +## 🏆 Featured in: + + + + + + + + + + + + + + + + +
Event LogoEvent NameEvent Description
GirlScript Summer of Code 2024 LogoGirlScript Summer of Code Extd 2024GirlScript Summer of Code is a three-month-long Open Source Program conducted every summer by GirlScript Foundation. It is an initiative to bring more beginners to Open-Source Software Development.
+ +--- + +## 🚀 Features +- Search for donors by location and blood group. +- Filter donors based on availability. +- Connect with organizations for organ donation. +- Real-time notifications for donor availability. +- Secure login and profile management for both donors and organizations. +- Analytics and insights on donation trends. + +--- + + +
+

Let's Get Started

+
+ +

Welcome to the DonorConnect! If you're interested in contributing, here's how you can get started:

+ +1. **Fork the repository:** Click on the "Fork" button at the top-right corner of this page. This will create a copy of this repository in your account. + +2. **Clone the repository:** After forking, clone the repository to your local machine using the following command in your terminal: + + ```bash + git clone https://github.com//donorconnect.git + ``` + +3. **Change the directory:** Change to the repository directory on your computer (if you are not already there): + +```bash + cd .\donorconnect\ +``` + +4. **Add a remote upstream:** Set up a remote upstream to the original repository by running the following command in your terminal: + + ```bash + git remote add upstream https://github.com//donorconnect + ``` + +5. **Create a new branch:** Switch to a new branch for your contributions: + + ```bash + git switch -c + ``` + +6. **Setup Environment:** + + ```bash + flutter clean + flutter pub get + ``` + +7. **Add your changes:** Stage your changes for commit: + + ```bash + git add ... + ``` + + or simply run + + ```bash + git add . + ``` + +8. **Commit your changes:** Commit your changes with a descriptive message: + + ```bash + git commit -m "" + ``` + +9. **Push your changes:** Push your changes to the forked repository: + + ```bash + git push -u origin + ``` + +10. **Create a Pull Request:** Go to the GitHub repository, select your branch, and click on the "New pull request" button to create a new pull request. + +### Alternatively contribute using GitHub Desktop + +1. **Open GitHub Desktop:** + Launch GitHub Desktop and log in to your GitHub account if you haven't already. + +2. **Clone the Repository:** + + - If you haven't cloned the donorconnect repository yet, you can do so by clicking on the "File" menu and selecting "Clone Repository." + - Choose the donorconnect repository from the list of repositories on GitHub and clone it to your local machine. + +3. **Switch to the Correct Branch:** + + - Ensure you are on the branch that you want to submit a pull request for. + - If you need to switch branches, you can do so by clicking on the "Current Branch" dropdown menu and selecting the desired branch. + +4. **Make Changes:** + Make your changes to the code or files in the repository using your preferred code editor. + +5. **Commit Changes:** + + - In GitHub Desktop, you'll see a list of the files you've changed. Check the box next to each file you want to include in the commit. + - Enter a summary and description for your changes in the "Summary" and "Description" fields, respectively. Click the "Commit to " button to commit your changes to the local branch. + +6. **Push Changes to GitHub:** + After committing your changes, click the "Push origin" button in the top right corner of GitHub Desktop to push your changes to your forked repository on GitHub. + +7. **Create a Pull Request:** + +- Go to the GitHub website and navigate to your fork of the repository. +- You should see a button to "Compare & pull request" between your fork and the original repository. Click on it. + +8. **Review and Submit:** + + - On the pull request page, review your changes and add any additional information, such as a title and description, that you want to include with your pull request. + - Once you're satisfied, click the "Create pull request" button to submit your pull request. + +9. **Wait for Review:** + Your pull request will now be available for review by the project maintainers. They may provide feedback or ask for changes before merging your pull request into the main branch of the repository. + +--- + +### Code of Conduct + +Please note that this project is released with a [Contributor Code of Conduct](CODE_OF_CONDUCT.md). By participating in this project you agree to abide by its terms. + +--- + +### Contributing Guidelines + +We believe in the power of collaboration. If you have ideas to improve, feel free to contribute! + +--- + +⭐️ Support the Project +If you find this project helpful, please consider giving it a star on GitHub! Your support helps to grow the project and reach more contributors. + +## ❤️ Our Valuable Contributors +![Contributors](https://contrib.rocks/image?repo=prajapatihet/donorconnect) + +# License + +To know more [Click Here](LICENSE.md) +[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) + + + + +# debugathon_flutter +# debugathon_flutter diff --git a/analysis_options.yaml b/analysis_options.yaml new file mode 100644 index 0000000..0d29021 --- /dev/null +++ b/analysis_options.yaml @@ -0,0 +1,28 @@ +# This file configures the analyzer, which statically analyzes Dart code to +# check for errors, warnings, and lints. +# +# The issues identified by the analyzer are surfaced in the UI of Dart-enabled +# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be +# invoked from the command line by running `flutter analyze`. + +# The following line activates a set of recommended lints for Flutter apps, +# packages, and plugins designed to encourage good coding practices. +include: package:flutter_lints/flutter.yaml + +linter: + # The lint rules applied to this project can be customized in the + # section below to disable rules from the `package:flutter_lints/flutter.yaml` + # included above or to enable additional rules. A list of all available lints + # and their documentation is published at https://dart.dev/lints. + # + # Instead of disabling a lint rule for the entire project in the + # section below, it can also be suppressed for a single line of code + # or a specific dart file by using the `// ignore: name_of_lint` and + # `// ignore_for_file: name_of_lint` syntax on the line or in the file + # producing the lint. + rules: + # avoid_print: false # Uncomment to disable the `avoid_print` rule + # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule + +# Additional information about this file can be found at +# https://dart.dev/guides/language/analysis-options diff --git a/android/.gitignore b/android/.gitignore new file mode 100644 index 0000000..55afd91 --- /dev/null +++ b/android/.gitignore @@ -0,0 +1,13 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java + +# Remember to never publicly share your keystore. +# See https://flutter.dev/to/reference-keystore +key.properties +**/*.keystore +**/*.jks diff --git a/android/app/build.gradle b/android/app/build.gradle new file mode 100644 index 0000000..797315d --- /dev/null +++ b/android/app/build.gradle @@ -0,0 +1,48 @@ +plugins { + id "com.android.application" + // START: FlutterFire Configuration + id 'com.google.gms.google-services' + // END: FlutterFire Configuration + id "kotlin-android" + // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins. + id "dev.flutter.flutter-gradle-plugin" +} + +android { + namespace = "com.example.donorconnect" + compileSdk = flutter.compileSdkVersion + ndkVersion = flutter.ndkVersion + + compileOptions { + sourceCompatibility = JavaVersion.VERSION_1_8 + targetCompatibility = JavaVersion.VERSION_1_8 + } + + kotlinOptions { + jvmTarget = JavaVersion.VERSION_1_8 + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId = "com.example.donorconnect" + // You can update the following values to match your application needs. + // For more information, see: https://flutter.dev/to/review-gradle-config. + minSdk = 23 + targetSdk = flutter.targetSdkVersion + versionCode 1 + versionName "1.0" + + } + + 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 = "../.." +} diff --git a/android/app/google-services.json b/android/app/google-services.json new file mode 100644 index 0000000..8b7451f --- /dev/null +++ b/android/app/google-services.json @@ -0,0 +1,29 @@ +{ + "project_info": { + "project_number": "445023469277", + "project_id": "donor-connect-project", + "storage_bucket": "donor-connect-project.appspot.com" + }, + "client": [ + { + "client_info": { + "mobilesdk_app_id": "1:445023469277:android:867d6fc40fb1d859a52534", + "android_client_info": { + "package_name": "com.example.donorconnect" + } + }, + "oauth_client": [], + "api_key": [ + { + "current_key": "AIzaSyDprpAsw0AkuQmFG1Iczpb9N2gghyAFmqo" + } + ], + "services": { + "appinvite_service": { + "other_platform_oauth_client": [] + } + } + } + ], + "configuration_version": "1" +} \ No newline at end of file diff --git a/android/app/src/debug/AndroidManifest.xml b/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 0000000..399f698 --- /dev/null +++ b/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml new file mode 100644 index 0000000..8da2168 --- /dev/null +++ b/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/android/app/src/main/ic_launcher-playstore.png b/android/app/src/main/ic_launcher-playstore.png new file mode 100644 index 0000000..e3589d5 Binary files /dev/null and b/android/app/src/main/ic_launcher-playstore.png differ diff --git a/android/app/src/main/kotlin/com/example/donorconnect/MainActivity.kt b/android/app/src/main/kotlin/com/example/donorconnect/MainActivity.kt new file mode 100644 index 0000000..9580048 --- /dev/null +++ b/android/app/src/main/kotlin/com/example/donorconnect/MainActivity.kt @@ -0,0 +1,5 @@ +package com.example.donorconnect + +import io.flutter.embedding.android.FlutterActivity + +class MainActivity: FlutterActivity() diff --git a/android/app/src/main/res/drawable-hdpi-v31/android12branding.png b/android/app/src/main/res/drawable-hdpi-v31/android12branding.png new file mode 100644 index 0000000..e50a006 Binary files /dev/null and b/android/app/src/main/res/drawable-hdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-hdpi/android12splash.png b/android/app/src/main/res/drawable-hdpi/android12splash.png new file mode 100644 index 0000000..6bc0596 Binary files /dev/null and b/android/app/src/main/res/drawable-hdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-hdpi/branding.png b/android/app/src/main/res/drawable-hdpi/branding.png new file mode 100644 index 0000000..e50a006 Binary files /dev/null and b/android/app/src/main/res/drawable-hdpi/branding.png differ diff --git a/android/app/src/main/res/drawable-hdpi/splash.png b/android/app/src/main/res/drawable-hdpi/splash.png new file mode 100644 index 0000000..6bc0596 Binary files /dev/null and b/android/app/src/main/res/drawable-hdpi/splash.png differ diff --git a/android/app/src/main/res/drawable-mdpi-v31/android12branding.png b/android/app/src/main/res/drawable-mdpi-v31/android12branding.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/android/app/src/main/res/drawable-mdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-mdpi/android12splash.png b/android/app/src/main/res/drawable-mdpi/android12splash.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/android/app/src/main/res/drawable-mdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-mdpi/branding.png b/android/app/src/main/res/drawable-mdpi/branding.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/android/app/src/main/res/drawable-mdpi/branding.png differ diff --git a/android/app/src/main/res/drawable-mdpi/splash.png b/android/app/src/main/res/drawable-mdpi/splash.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/android/app/src/main/res/drawable-mdpi/splash.png differ diff --git a/android/app/src/main/res/drawable-night-hdpi-v31/android12branding.png b/android/app/src/main/res/drawable-night-hdpi-v31/android12branding.png new file mode 100644 index 0000000..e50a006 Binary files /dev/null and b/android/app/src/main/res/drawable-night-hdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-night-hdpi/android12splash.png b/android/app/src/main/res/drawable-night-hdpi/android12splash.png new file mode 100644 index 0000000..6bc0596 Binary files /dev/null and b/android/app/src/main/res/drawable-night-hdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-night-mdpi-v31/android12branding.png b/android/app/src/main/res/drawable-night-mdpi-v31/android12branding.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/android/app/src/main/res/drawable-night-mdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-night-mdpi/android12splash.png b/android/app/src/main/res/drawable-night-mdpi/android12splash.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/android/app/src/main/res/drawable-night-mdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-night-xhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-night-xhdpi-v31/android12branding.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/android/app/src/main/res/drawable-night-xhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-night-xhdpi/android12splash.png b/android/app/src/main/res/drawable-night-xhdpi/android12splash.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/android/app/src/main/res/drawable-night-xhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-night-xxhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-night-xxhdpi-v31/android12branding.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/android/app/src/main/res/drawable-night-xxhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-night-xxhdpi/android12splash.png b/android/app/src/main/res/drawable-night-xxhdpi/android12splash.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/android/app/src/main/res/drawable-night-xxhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-night-xxxhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-night-xxxhdpi-v31/android12branding.png new file mode 100644 index 0000000..e588bb8 Binary files /dev/null and b/android/app/src/main/res/drawable-night-xxxhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-night-xxxhdpi/android12splash.png b/android/app/src/main/res/drawable-night-xxxhdpi/android12splash.png new file mode 100644 index 0000000..8760919 Binary files /dev/null and b/android/app/src/main/res/drawable-night-xxxhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-v21/background.png b/android/app/src/main/res/drawable-v21/background.png new file mode 100644 index 0000000..3107d37 Binary files /dev/null and b/android/app/src/main/res/drawable-v21/background.png differ diff --git a/android/app/src/main/res/drawable-v21/launch_background.xml b/android/app/src/main/res/drawable-v21/launch_background.xml new file mode 100644 index 0000000..5367a88 --- /dev/null +++ b/android/app/src/main/res/drawable-v21/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/android/app/src/main/res/drawable-xhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-xhdpi-v31/android12branding.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/android/app/src/main/res/drawable-xhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-xhdpi/android12splash.png b/android/app/src/main/res/drawable-xhdpi/android12splash.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/android/app/src/main/res/drawable-xhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-xhdpi/branding.png b/android/app/src/main/res/drawable-xhdpi/branding.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/android/app/src/main/res/drawable-xhdpi/branding.png differ diff --git a/android/app/src/main/res/drawable-xhdpi/splash.png b/android/app/src/main/res/drawable-xhdpi/splash.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/android/app/src/main/res/drawable-xhdpi/splash.png differ diff --git a/android/app/src/main/res/drawable-xxhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-xxhdpi-v31/android12branding.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/android/app/src/main/res/drawable-xxhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-xxhdpi/android12splash.png b/android/app/src/main/res/drawable-xxhdpi/android12splash.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/android/app/src/main/res/drawable-xxhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-xxhdpi/branding.png b/android/app/src/main/res/drawable-xxhdpi/branding.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/android/app/src/main/res/drawable-xxhdpi/branding.png differ diff --git a/android/app/src/main/res/drawable-xxhdpi/splash.png b/android/app/src/main/res/drawable-xxhdpi/splash.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/android/app/src/main/res/drawable-xxhdpi/splash.png differ diff --git a/android/app/src/main/res/drawable-xxxhdpi-v31/android12branding.png b/android/app/src/main/res/drawable-xxxhdpi-v31/android12branding.png new file mode 100644 index 0000000..e588bb8 Binary files /dev/null and b/android/app/src/main/res/drawable-xxxhdpi-v31/android12branding.png differ diff --git a/android/app/src/main/res/drawable-xxxhdpi/android12splash.png b/android/app/src/main/res/drawable-xxxhdpi/android12splash.png new file mode 100644 index 0000000..8760919 Binary files /dev/null and b/android/app/src/main/res/drawable-xxxhdpi/android12splash.png differ diff --git a/android/app/src/main/res/drawable-xxxhdpi/branding.png b/android/app/src/main/res/drawable-xxxhdpi/branding.png new file mode 100644 index 0000000..e588bb8 Binary files /dev/null and b/android/app/src/main/res/drawable-xxxhdpi/branding.png differ diff --git a/android/app/src/main/res/drawable-xxxhdpi/splash.png b/android/app/src/main/res/drawable-xxxhdpi/splash.png new file mode 100644 index 0000000..8760919 Binary files /dev/null and b/android/app/src/main/res/drawable-xxxhdpi/splash.png differ diff --git a/android/app/src/main/res/drawable/background.png b/android/app/src/main/res/drawable/background.png new file mode 100644 index 0000000..3107d37 Binary files /dev/null and b/android/app/src/main/res/drawable/background.png differ diff --git a/android/app/src/main/res/drawable/launch_background.xml b/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 0000000..5367a88 --- /dev/null +++ b/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 0000000..f46b1bd Binary files /dev/null and b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 0000000..2390c06 Binary files /dev/null and b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 0000000..f9cc328 Binary files /dev/null and b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 0000000..3ae6cb7 Binary files /dev/null and b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 0000000..5dcd8c7 Binary files /dev/null and b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/values-night-v31/styles.xml b/android/app/src/main/res/values-night-v31/styles.xml new file mode 100644 index 0000000..6fa3c86 --- /dev/null +++ b/android/app/src/main/res/values-night-v31/styles.xml @@ -0,0 +1,22 @@ + + + + + + + diff --git a/android/app/src/main/res/values-night/styles.xml b/android/app/src/main/res/values-night/styles.xml new file mode 100644 index 0000000..dbc9ea9 --- /dev/null +++ b/android/app/src/main/res/values-night/styles.xml @@ -0,0 +1,22 @@ + + + + + + + diff --git a/android/app/src/main/res/values-v31/styles.xml b/android/app/src/main/res/values-v31/styles.xml new file mode 100644 index 0000000..a0e12b2 --- /dev/null +++ b/android/app/src/main/res/values-v31/styles.xml @@ -0,0 +1,22 @@ + + + + + + + diff --git a/android/app/src/main/res/values/styles.xml b/android/app/src/main/res/values/styles.xml new file mode 100644 index 0000000..0d1fa8f --- /dev/null +++ b/android/app/src/main/res/values/styles.xml @@ -0,0 +1,22 @@ + + + + + + + diff --git a/android/app/src/profile/AndroidManifest.xml b/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 0000000..399f698 --- /dev/null +++ b/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/android/build.gradle b/android/build.gradle new file mode 100644 index 0000000..d2ffbff --- /dev/null +++ b/android/build.gradle @@ -0,0 +1,18 @@ +allprojects { + repositories { + google() + mavenCentral() + } +} + +rootProject.buildDir = "../build" +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(":app") +} + +tasks.register("clean", Delete) { + delete rootProject.buildDir +} diff --git a/android/gradle.properties b/android/gradle.properties new file mode 100644 index 0000000..2597170 --- /dev/null +++ b/android/gradle.properties @@ -0,0 +1,3 @@ +org.gradle.jvmargs=-Xmx4G -XX:MaxMetaspaceSize=2G -XX:+HeapDumpOnOutOfMemoryError +android.useAndroidX=true +android.enableJetifier=true diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..7bb2df6 --- /dev/null +++ b/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,5 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip diff --git a/android/settings.gradle b/android/settings.gradle new file mode 100644 index 0000000..457e343 --- /dev/null +++ b/android/settings.gradle @@ -0,0 +1,28 @@ +pluginManagement { + def flutterSdkPath = { + def properties = new Properties() + file("local.properties").withInputStream { properties.load(it) } + def flutterSdkPath = properties.getProperty("flutter.sdk") + assert flutterSdkPath != null, "flutter.sdk not set in local.properties" + return flutterSdkPath + }() + + includeBuild("$flutterSdkPath/packages/flutter_tools/gradle") + + repositories { + google() + mavenCentral() + gradlePluginPortal() + } +} + +plugins { + id "dev.flutter.flutter-plugin-loader" version "1.0.0" + id "com.android.application" version "7.3.0" apply false + // START: FlutterFire Configuration + id "com.google.gms.google-services" version "4.3.15" apply false + // END: FlutterFire Configuration + id "org.jetbrains.kotlin.android" version "1.9.0" apply false +} + +include ":app" diff --git a/assets/images/OnBoarding1.jpg b/assets/images/OnBoarding1.jpg new file mode 100644 index 0000000..1dd703a Binary files /dev/null and b/assets/images/OnBoarding1.jpg differ diff --git a/assets/images/OnBoarding2.jpg b/assets/images/OnBoarding2.jpg new file mode 100644 index 0000000..835409a Binary files /dev/null and b/assets/images/OnBoarding2.jpg differ diff --git a/assets/images/OnBoarding3.jpg b/assets/images/OnBoarding3.jpg new file mode 100644 index 0000000..74b3a36 Binary files /dev/null and b/assets/images/OnBoarding3.jpg differ diff --git a/assets/images/donorConnect.png b/assets/images/donorConnect.png new file mode 100644 index 0000000..364996a Binary files /dev/null and b/assets/images/donorConnect.png differ diff --git a/assets/images/donorConnect1.png b/assets/images/donorConnect1.png new file mode 100644 index 0000000..2f50937 Binary files /dev/null and b/assets/images/donorConnect1.png differ diff --git a/assets/images/empty_calendar.png b/assets/images/empty_calendar.png new file mode 100644 index 0000000..34072f8 Binary files /dev/null and b/assets/images/empty_calendar.png differ diff --git a/assets/images/google.png b/assets/images/google.png new file mode 100644 index 0000000..494aced Binary files /dev/null and b/assets/images/google.png differ diff --git a/assets/images/home.png b/assets/images/home.png new file mode 100644 index 0000000..eb186bd Binary files /dev/null and b/assets/images/home.png differ diff --git a/assets/images/home_image1.png b/assets/images/home_image1.png new file mode 100644 index 0000000..bfdb539 Binary files /dev/null and b/assets/images/home_image1.png differ diff --git a/assets/images/home_image2.png b/assets/images/home_image2.png new file mode 100644 index 0000000..aa83fa2 Binary files /dev/null and b/assets/images/home_image2.png differ diff --git a/assets/images/launcher_icon.png b/assets/images/launcher_icon.png new file mode 100644 index 0000000..0e3f3ed Binary files /dev/null and b/assets/images/launcher_icon.png differ diff --git a/assets/images/launcher_icon1.png b/assets/images/launcher_icon1.png new file mode 100644 index 0000000..b2b6e76 Binary files /dev/null and b/assets/images/launcher_icon1.png differ diff --git a/assets/images/login.jpg b/assets/images/login.jpg new file mode 100644 index 0000000..ad6059d Binary files /dev/null and b/assets/images/login.jpg differ diff --git a/assets/images/logo.png b/assets/images/logo.png new file mode 100644 index 0000000..cea9149 Binary files /dev/null and b/assets/images/logo.png differ diff --git a/assets/images/logo1.png b/assets/images/logo1.png new file mode 100644 index 0000000..c6cb591 Binary files /dev/null and b/assets/images/logo1.png differ diff --git a/assets/images/signup.jpg b/assets/images/signup.jpg new file mode 100644 index 0000000..1eb2e64 Binary files /dev/null and b/assets/images/signup.jpg differ diff --git a/devtools_options.yaml b/devtools_options.yaml new file mode 100644 index 0000000..fa0b357 --- /dev/null +++ b/devtools_options.yaml @@ -0,0 +1,3 @@ +description: This file stores settings for Dart & Flutter DevTools. +documentation: https://docs.flutter.dev/tools/devtools/extensions#configure-extension-enablement-states +extensions: diff --git a/firebase.json b/firebase.json new file mode 100644 index 0000000..6fae7de --- /dev/null +++ b/firebase.json @@ -0,0 +1 @@ +{"flutter":{"platforms":{"android":{"default":{"projectId":"donor-connect-project","appId":"1:445023469277:android:867d6fc40fb1d859a52534","fileOutput":"android/app/google-services.json"}},"dart":{"lib/firebase_options.dart":{"projectId":"donor-connect-project","configurations":{"android":"1:445023469277:android:867d6fc40fb1d859a52534","ios":"1:445023469277:ios:9a17b6ec582928d9a52534","macos":"1:445023469277:ios:9a17b6ec582928d9a52534","web":"1:445023469277:web:38f1cccfd07af2b9a52534","windows":"1:445023469277:web:b05ec49f21bb5355a52534"}}},"ios":{"default":{"projectId":"donor-connect-project","appId":"1:445023469277:ios:9a17b6ec582928d9a52534","uploadDebugSymbols":false,"fileOutput":"ios/Runner/GoogleService-Info.plist"}},"macos":{"default":{"projectId":"donor-connect-project","appId":"1:445023469277:ios:9a17b6ec582928d9a52534","uploadDebugSymbols":false,"fileOutput":"macos/Runner/GoogleService-Info.plist"}}}}} \ No newline at end of file diff --git a/ios/.gitignore b/ios/.gitignore new file mode 100644 index 0000000..7a7f987 --- /dev/null +++ b/ios/.gitignore @@ -0,0 +1,34 @@ +**/dgph +*.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 diff --git a/ios/Flutter/AppFrameworkInfo.plist b/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 0000000..7c56964 --- /dev/null +++ b/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 12.0 + + diff --git a/ios/Flutter/Debug.xcconfig b/ios/Flutter/Debug.xcconfig new file mode 100644 index 0000000..ec97fc6 --- /dev/null +++ b/ios/Flutter/Debug.xcconfig @@ -0,0 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" +#include "Generated.xcconfig" diff --git a/ios/Flutter/Release.xcconfig b/ios/Flutter/Release.xcconfig new file mode 100644 index 0000000..c4855bf --- /dev/null +++ b/ios/Flutter/Release.xcconfig @@ -0,0 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" +#include "Generated.xcconfig" diff --git a/ios/Podfile b/ios/Podfile new file mode 100644 index 0000000..f3ad085 --- /dev/null +++ b/ios/Podfile @@ -0,0 +1,46 @@ +# Uncomment this line to define a global platform for your project + +platform :ios, '13.0' + + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_ios_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) + target 'RunnerTests' do + inherit! :search_paths + end +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_ios_build_settings(target) + end +end diff --git a/ios/Podfile.lock b/ios/Podfile.lock new file mode 100644 index 0000000..d0aa4c7 --- /dev/null +++ b/ios/Podfile.lock @@ -0,0 +1,1490 @@ +PODS: + - abseil/algorithm (1.20240116.2): + - abseil/algorithm/algorithm (= 1.20240116.2) + - abseil/algorithm/container (= 1.20240116.2) + - abseil/algorithm/algorithm (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/algorithm/container (1.20240116.2): + - abseil/algorithm/algorithm + - abseil/base/core_headers + - abseil/base/nullability + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/base (1.20240116.2): + - abseil/base/atomic_hook (= 1.20240116.2) + - abseil/base/base (= 1.20240116.2) + - abseil/base/base_internal (= 1.20240116.2) + - abseil/base/config (= 1.20240116.2) + - abseil/base/core_headers (= 1.20240116.2) + - abseil/base/cycleclock_internal (= 1.20240116.2) + - abseil/base/dynamic_annotations (= 1.20240116.2) + - abseil/base/endian (= 1.20240116.2) + - abseil/base/errno_saver (= 1.20240116.2) + - abseil/base/fast_type_id (= 1.20240116.2) + - abseil/base/log_severity (= 1.20240116.2) + - abseil/base/malloc_internal (= 1.20240116.2) + - abseil/base/no_destructor (= 1.20240116.2) + - abseil/base/nullability (= 1.20240116.2) + - abseil/base/prefetch (= 1.20240116.2) + - abseil/base/pretty_function (= 1.20240116.2) + - abseil/base/raw_logging_internal (= 1.20240116.2) + - abseil/base/spinlock_wait (= 1.20240116.2) + - abseil/base/strerror (= 1.20240116.2) + - abseil/base/throw_delegate (= 1.20240116.2) + - abseil/base/atomic_hook (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/base/base (1.20240116.2): + - abseil/base/atomic_hook + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/cycleclock_internal + - abseil/base/dynamic_annotations + - abseil/base/log_severity + - abseil/base/nullability + - abseil/base/raw_logging_internal + - abseil/base/spinlock_wait + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/base/base_internal (1.20240116.2): + - abseil/base/config + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/base/config (1.20240116.2): + - abseil/xcprivacy + - abseil/base/core_headers (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/base/cycleclock_internal (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/xcprivacy + - abseil/base/dynamic_annotations (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/base/endian (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/nullability + - abseil/xcprivacy + - abseil/base/errno_saver (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/base/fast_type_id (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/base/log_severity (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/base/malloc_internal (1.20240116.2): + - abseil/base/base + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/base/no_destructor (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/base/nullability (1.20240116.2): + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/base/prefetch (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/base/pretty_function (1.20240116.2): + - abseil/xcprivacy + - abseil/base/raw_logging_internal (1.20240116.2): + - abseil/base/atomic_hook + - abseil/base/config + - abseil/base/core_headers + - abseil/base/errno_saver + - abseil/base/log_severity + - abseil/xcprivacy + - abseil/base/spinlock_wait (1.20240116.2): + - abseil/base/base_internal + - abseil/base/core_headers + - abseil/base/errno_saver + - abseil/xcprivacy + - abseil/base/strerror (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/errno_saver + - abseil/xcprivacy + - abseil/base/throw_delegate (1.20240116.2): + - abseil/base/config + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/cleanup/cleanup (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/cleanup/cleanup_internal + - abseil/xcprivacy + - abseil/cleanup/cleanup_internal (1.20240116.2): + - abseil/base/base_internal + - abseil/base/core_headers + - abseil/utility/utility + - abseil/xcprivacy + - abseil/container/common (1.20240116.2): + - abseil/meta/type_traits + - abseil/types/optional + - abseil/xcprivacy + - abseil/container/common_policy_traits (1.20240116.2): + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/container/compressed_tuple (1.20240116.2): + - abseil/utility/utility + - abseil/xcprivacy + - abseil/container/container_memory (1.20240116.2): + - abseil/base/config + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/utility/utility + - abseil/xcprivacy + - abseil/container/fixed_array (1.20240116.2): + - abseil/algorithm/algorithm + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/throw_delegate + - abseil/container/compressed_tuple + - abseil/memory/memory + - abseil/xcprivacy + - abseil/container/flat_hash_map (1.20240116.2): + - abseil/algorithm/container + - abseil/base/core_headers + - abseil/container/container_memory + - abseil/container/hash_function_defaults + - abseil/container/raw_hash_map + - abseil/memory/memory + - abseil/xcprivacy + - abseil/container/flat_hash_set (1.20240116.2): + - abseil/algorithm/container + - abseil/base/core_headers + - abseil/container/container_memory + - abseil/container/hash_function_defaults + - abseil/container/raw_hash_set + - abseil/memory/memory + - abseil/xcprivacy + - abseil/container/hash_function_defaults (1.20240116.2): + - abseil/base/config + - abseil/hash/hash + - abseil/strings/cord + - abseil/strings/strings + - abseil/xcprivacy + - abseil/container/hash_policy_traits (1.20240116.2): + - abseil/container/common_policy_traits + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/container/hashtable_debug_hooks (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/container/hashtablez_sampler (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/debugging/stacktrace + - abseil/memory/memory + - abseil/profiling/exponential_biased + - abseil/profiling/sample_recorder + - abseil/synchronization/synchronization + - abseil/time/time + - abseil/utility/utility + - abseil/xcprivacy + - abseil/container/inlined_vector (1.20240116.2): + - abseil/algorithm/algorithm + - abseil/base/core_headers + - abseil/base/throw_delegate + - abseil/container/inlined_vector_internal + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/container/inlined_vector_internal (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/container/compressed_tuple + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/types/span + - abseil/xcprivacy + - abseil/container/layout (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/debugging/demangle_internal + - abseil/meta/type_traits + - abseil/strings/strings + - abseil/types/span + - abseil/utility/utility + - abseil/xcprivacy + - abseil/container/raw_hash_map (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/throw_delegate + - abseil/container/container_memory + - abseil/container/raw_hash_set + - abseil/xcprivacy + - abseil/container/raw_hash_set (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/endian + - abseil/base/prefetch + - abseil/base/raw_logging_internal + - abseil/container/common + - abseil/container/compressed_tuple + - abseil/container/container_memory + - abseil/container/hash_policy_traits + - abseil/container/hashtable_debug_hooks + - abseil/container/hashtablez_sampler + - abseil/hash/hash + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/utility/utility + - abseil/xcprivacy + - abseil/crc/cpu_detect (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/xcprivacy + - abseil/crc/crc32c (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/prefetch + - abseil/crc/cpu_detect + - abseil/crc/crc_internal + - abseil/crc/non_temporal_memcpy + - abseil/strings/str_format + - abseil/strings/strings + - abseil/xcprivacy + - abseil/crc/crc_cord_state (1.20240116.2): + - abseil/base/config + - abseil/crc/crc32c + - abseil/numeric/bits + - abseil/strings/strings + - abseil/xcprivacy + - abseil/crc/crc_internal (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/prefetch + - abseil/base/raw_logging_internal + - abseil/crc/cpu_detect + - abseil/memory/memory + - abseil/numeric/bits + - abseil/xcprivacy + - abseil/crc/non_temporal_arm_intrinsics (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/crc/non_temporal_memcpy (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/crc/non_temporal_arm_intrinsics + - abseil/xcprivacy + - abseil/debugging/debugging_internal (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/errno_saver + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/debugging/demangle_internal (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/debugging/examine_stack (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/debugging/stacktrace + - abseil/debugging/symbolize + - abseil/xcprivacy + - abseil/debugging/stacktrace (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/raw_logging_internal + - abseil/debugging/debugging_internal + - abseil/xcprivacy + - abseil/debugging/symbolize (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/malloc_internal + - abseil/base/raw_logging_internal + - abseil/debugging/debugging_internal + - abseil/debugging/demangle_internal + - abseil/strings/strings + - abseil/xcprivacy + - abseil/flags/commandlineflag (1.20240116.2): + - abseil/base/config + - abseil/base/fast_type_id + - abseil/flags/commandlineflag_internal + - abseil/strings/strings + - abseil/types/optional + - abseil/xcprivacy + - abseil/flags/commandlineflag_internal (1.20240116.2): + - abseil/base/config + - abseil/base/fast_type_id + - abseil/xcprivacy + - abseil/flags/config (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/flags/path_util + - abseil/flags/program_name + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/xcprivacy + - abseil/flags/flag (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/flags/config + - abseil/flags/flag_internal + - abseil/flags/reflection + - abseil/strings/strings + - abseil/xcprivacy + - abseil/flags/flag_internal (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/flags/commandlineflag + - abseil/flags/commandlineflag_internal + - abseil/flags/config + - abseil/flags/marshalling + - abseil/flags/reflection + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/utility/utility + - abseil/xcprivacy + - abseil/flags/marshalling (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/numeric/int128 + - abseil/strings/str_format + - abseil/strings/strings + - abseil/types/optional + - abseil/xcprivacy + - abseil/flags/path_util (1.20240116.2): + - abseil/base/config + - abseil/strings/strings + - abseil/xcprivacy + - abseil/flags/private_handle_accessor (1.20240116.2): + - abseil/base/config + - abseil/flags/commandlineflag + - abseil/flags/commandlineflag_internal + - abseil/strings/strings + - abseil/xcprivacy + - abseil/flags/program_name (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/flags/path_util + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/xcprivacy + - abseil/flags/reflection (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/no_destructor + - abseil/container/flat_hash_map + - abseil/flags/commandlineflag + - abseil/flags/commandlineflag_internal + - abseil/flags/config + - abseil/flags/private_handle_accessor + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/xcprivacy + - abseil/functional/any_invocable (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/utility/utility + - abseil/xcprivacy + - abseil/functional/bind_front (1.20240116.2): + - abseil/base/base_internal + - abseil/container/compressed_tuple + - abseil/meta/type_traits + - abseil/utility/utility + - abseil/xcprivacy + - abseil/functional/function_ref (1.20240116.2): + - abseil/base/base_internal + - abseil/base/core_headers + - abseil/functional/any_invocable + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/hash/city (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/xcprivacy + - abseil/hash/hash (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/container/fixed_array + - abseil/functional/function_ref + - abseil/hash/city + - abseil/hash/low_level_hash + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/strings/strings + - abseil/types/optional + - abseil/types/variant + - abseil/utility/utility + - abseil/xcprivacy + - abseil/hash/low_level_hash (1.20240116.2): + - abseil/base/config + - abseil/base/endian + - abseil/base/prefetch + - abseil/numeric/int128 + - abseil/xcprivacy + - abseil/log/absl_check (1.20240116.2): + - abseil/log/internal/check_impl + - abseil/xcprivacy + - abseil/log/absl_log (1.20240116.2): + - abseil/log/internal/log_impl + - abseil/xcprivacy + - abseil/log/absl_vlog_is_on (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/log/internal/vlog_config + - abseil/strings/strings + - abseil/xcprivacy + - abseil/log/check (1.20240116.2): + - abseil/log/internal/check_impl + - abseil/log/internal/check_op + - abseil/log/internal/conditions + - abseil/log/internal/log_message + - abseil/log/internal/strip + - abseil/xcprivacy + - abseil/log/globals (1.20240116.2): + - abseil/base/atomic_hook + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/base/raw_logging_internal + - abseil/hash/hash + - abseil/log/internal/vlog_config + - abseil/strings/strings + - abseil/xcprivacy + - abseil/log/internal/append_truncated (1.20240116.2): + - abseil/base/config + - abseil/strings/strings + - abseil/types/span + - abseil/xcprivacy + - abseil/log/internal/check_impl (1.20240116.2): + - abseil/base/core_headers + - abseil/log/internal/check_op + - abseil/log/internal/conditions + - abseil/log/internal/log_message + - abseil/log/internal/strip + - abseil/xcprivacy + - abseil/log/internal/check_op (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/log/internal/nullguard + - abseil/log/internal/nullstream + - abseil/log/internal/strip + - abseil/strings/strings + - abseil/xcprivacy + - abseil/log/internal/conditions (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/log/internal/voidify + - abseil/xcprivacy + - abseil/log/internal/config (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/log/internal/fnmatch (1.20240116.2): + - abseil/base/config + - abseil/strings/strings + - abseil/xcprivacy + - abseil/log/internal/format (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/log/internal/append_truncated + - abseil/log/internal/config + - abseil/log/internal/globals + - abseil/strings/str_format + - abseil/strings/strings + - abseil/time/time + - abseil/types/span + - abseil/xcprivacy + - abseil/log/internal/globals (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/base/raw_logging_internal + - abseil/strings/strings + - abseil/time/time + - abseil/xcprivacy + - abseil/log/internal/log_impl (1.20240116.2): + - abseil/log/absl_vlog_is_on + - abseil/log/internal/conditions + - abseil/log/internal/log_message + - abseil/log/internal/strip + - abseil/xcprivacy + - abseil/log/internal/log_message (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/errno_saver + - abseil/base/log_severity + - abseil/base/raw_logging_internal + - abseil/base/strerror + - abseil/container/inlined_vector + - abseil/debugging/examine_stack + - abseil/log/globals + - abseil/log/internal/append_truncated + - abseil/log/internal/format + - abseil/log/internal/globals + - abseil/log/internal/log_sink_set + - abseil/log/internal/nullguard + - abseil/log/internal/proto + - abseil/log/log_entry + - abseil/log/log_sink + - abseil/log/log_sink_registry + - abseil/memory/memory + - abseil/strings/strings + - abseil/time/time + - abseil/types/span + - abseil/xcprivacy + - abseil/log/internal/log_sink_set (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/base/no_destructor + - abseil/base/raw_logging_internal + - abseil/cleanup/cleanup + - abseil/log/globals + - abseil/log/internal/config + - abseil/log/internal/globals + - abseil/log/log_entry + - abseil/log/log_sink + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/types/span + - abseil/xcprivacy + - abseil/log/internal/nullguard (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/log/internal/nullstream (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/strings/strings + - abseil/xcprivacy + - abseil/log/internal/proto (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/strings/strings + - abseil/types/span + - abseil/xcprivacy + - abseil/log/internal/strip (1.20240116.2): + - abseil/base/log_severity + - abseil/log/internal/log_message + - abseil/log/internal/nullstream + - abseil/xcprivacy + - abseil/log/internal/vlog_config (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/no_destructor + - abseil/log/internal/fnmatch + - abseil/memory/memory + - abseil/strings/strings + - abseil/synchronization/synchronization + - abseil/types/optional + - abseil/xcprivacy + - abseil/log/internal/voidify (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/log/log (1.20240116.2): + - abseil/log/internal/log_impl + - abseil/log/vlog_is_on + - abseil/xcprivacy + - abseil/log/log_entry (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/log_severity + - abseil/log/internal/config + - abseil/strings/strings + - abseil/time/time + - abseil/types/span + - abseil/xcprivacy + - abseil/log/log_sink (1.20240116.2): + - abseil/base/config + - abseil/log/log_entry + - abseil/xcprivacy + - abseil/log/log_sink_registry (1.20240116.2): + - abseil/base/config + - abseil/log/internal/log_sink_set + - abseil/log/log_sink + - abseil/xcprivacy + - abseil/log/vlog_is_on (1.20240116.2): + - abseil/log/absl_vlog_is_on + - abseil/xcprivacy + - abseil/memory (1.20240116.2): + - abseil/memory/memory (= 1.20240116.2) + - abseil/memory/memory (1.20240116.2): + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/meta (1.20240116.2): + - abseil/meta/type_traits (= 1.20240116.2) + - abseil/meta/type_traits (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/numeric/bits (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/numeric/int128 (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/numeric/bits + - abseil/xcprivacy + - abseil/numeric/representation (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/profiling/exponential_biased (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/xcprivacy + - abseil/profiling/sample_recorder (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/synchronization/synchronization + - abseil/time/time + - abseil/xcprivacy + - abseil/random/bit_gen_ref (1.20240116.2): + - abseil/base/core_headers + - abseil/base/fast_type_id + - abseil/meta/type_traits + - abseil/random/internal/distribution_caller + - abseil/random/internal/fast_uniform_bits + - abseil/random/random + - abseil/xcprivacy + - abseil/random/distributions (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/random/internal/distribution_caller + - abseil/random/internal/fast_uniform_bits + - abseil/random/internal/fastmath + - abseil/random/internal/generate_real + - abseil/random/internal/iostream_state_saver + - abseil/random/internal/traits + - abseil/random/internal/uniform_helper + - abseil/random/internal/wide_multiply + - abseil/strings/strings + - abseil/xcprivacy + - abseil/random/internal/distribution_caller (1.20240116.2): + - abseil/base/config + - abseil/base/fast_type_id + - abseil/utility/utility + - abseil/xcprivacy + - abseil/random/internal/fast_uniform_bits (1.20240116.2): + - abseil/base/config + - abseil/meta/type_traits + - abseil/random/internal/traits + - abseil/xcprivacy + - abseil/random/internal/fastmath (1.20240116.2): + - abseil/numeric/bits + - abseil/xcprivacy + - abseil/random/internal/generate_real (1.20240116.2): + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/random/internal/fastmath + - abseil/random/internal/traits + - abseil/xcprivacy + - abseil/random/internal/iostream_state_saver (1.20240116.2): + - abseil/meta/type_traits + - abseil/numeric/int128 + - abseil/xcprivacy + - abseil/random/internal/nonsecure_base (1.20240116.2): + - abseil/base/core_headers + - abseil/container/inlined_vector + - abseil/meta/type_traits + - abseil/random/internal/pool_urbg + - abseil/random/internal/salted_seed_seq + - abseil/random/internal/seed_material + - abseil/types/span + - abseil/xcprivacy + - abseil/random/internal/pcg_engine (1.20240116.2): + - abseil/base/config + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/random/internal/fastmath + - abseil/random/internal/iostream_state_saver + - abseil/xcprivacy + - abseil/random/internal/platform (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/random/internal/pool_urbg (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/raw_logging_internal + - abseil/random/internal/randen + - abseil/random/internal/seed_material + - abseil/random/internal/traits + - abseil/random/seed_gen_exception + - abseil/types/span + - abseil/xcprivacy + - abseil/random/internal/randen (1.20240116.2): + - abseil/base/raw_logging_internal + - abseil/random/internal/platform + - abseil/random/internal/randen_hwaes + - abseil/random/internal/randen_slow + - abseil/xcprivacy + - abseil/random/internal/randen_engine (1.20240116.2): + - abseil/base/endian + - abseil/meta/type_traits + - abseil/random/internal/iostream_state_saver + - abseil/random/internal/randen + - abseil/xcprivacy + - abseil/random/internal/randen_hwaes (1.20240116.2): + - abseil/base/config + - abseil/random/internal/platform + - abseil/random/internal/randen_hwaes_impl + - abseil/xcprivacy + - abseil/random/internal/randen_hwaes_impl (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/numeric/int128 + - abseil/random/internal/platform + - abseil/xcprivacy + - abseil/random/internal/randen_slow (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/numeric/int128 + - abseil/random/internal/platform + - abseil/xcprivacy + - abseil/random/internal/salted_seed_seq (1.20240116.2): + - abseil/container/inlined_vector + - abseil/meta/type_traits + - abseil/random/internal/seed_material + - abseil/types/optional + - abseil/types/span + - abseil/xcprivacy + - abseil/random/internal/seed_material (1.20240116.2): + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/raw_logging_internal + - abseil/random/internal/fast_uniform_bits + - abseil/strings/strings + - abseil/types/optional + - abseil/types/span + - abseil/xcprivacy + - abseil/random/internal/traits (1.20240116.2): + - abseil/base/config + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/xcprivacy + - abseil/random/internal/uniform_helper (1.20240116.2): + - abseil/base/config + - abseil/meta/type_traits + - abseil/numeric/int128 + - abseil/random/internal/traits + - abseil/xcprivacy + - abseil/random/internal/wide_multiply (1.20240116.2): + - abseil/base/config + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/random/internal/traits + - abseil/xcprivacy + - abseil/random/random (1.20240116.2): + - abseil/random/distributions + - abseil/random/internal/nonsecure_base + - abseil/random/internal/pcg_engine + - abseil/random/internal/pool_urbg + - abseil/random/internal/randen_engine + - abseil/random/seed_sequences + - abseil/xcprivacy + - abseil/random/seed_gen_exception (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/random/seed_sequences (1.20240116.2): + - abseil/base/config + - abseil/random/internal/pool_urbg + - abseil/random/internal/salted_seed_seq + - abseil/random/internal/seed_material + - abseil/random/seed_gen_exception + - abseil/types/span + - abseil/xcprivacy + - abseil/status/status (1.20240116.2): + - abseil/base/atomic_hook + - abseil/base/config + - abseil/base/core_headers + - abseil/base/no_destructor + - abseil/base/nullability + - abseil/base/raw_logging_internal + - abseil/base/strerror + - abseil/container/inlined_vector + - abseil/debugging/stacktrace + - abseil/debugging/symbolize + - abseil/functional/function_ref + - abseil/memory/memory + - abseil/strings/cord + - abseil/strings/str_format + - abseil/strings/strings + - abseil/types/optional + - abseil/types/span + - abseil/xcprivacy + - abseil/status/statusor (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/nullability + - abseil/base/raw_logging_internal + - abseil/meta/type_traits + - abseil/status/status + - abseil/strings/has_ostream_operator + - abseil/strings/str_format + - abseil/strings/strings + - abseil/types/variant + - abseil/utility/utility + - abseil/xcprivacy + - abseil/strings/charset (1.20240116.2): + - abseil/base/core_headers + - abseil/strings/string_view + - abseil/xcprivacy + - abseil/strings/cord (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/nullability + - abseil/base/raw_logging_internal + - abseil/container/inlined_vector + - abseil/crc/crc32c + - abseil/crc/crc_cord_state + - abseil/functional/function_ref + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/strings/cord_internal + - abseil/strings/cordz_functions + - abseil/strings/cordz_info + - abseil/strings/cordz_statistics + - abseil/strings/cordz_update_scope + - abseil/strings/cordz_update_tracker + - abseil/strings/internal + - abseil/strings/strings + - abseil/types/optional + - abseil/types/span + - abseil/xcprivacy + - abseil/strings/cord_internal (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/raw_logging_internal + - abseil/base/throw_delegate + - abseil/container/compressed_tuple + - abseil/container/container_memory + - abseil/container/inlined_vector + - abseil/container/layout + - abseil/crc/crc_cord_state + - abseil/functional/function_ref + - abseil/meta/type_traits + - abseil/strings/strings + - abseil/types/span + - abseil/xcprivacy + - abseil/strings/cordz_functions (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/profiling/exponential_biased + - abseil/xcprivacy + - abseil/strings/cordz_handle (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/raw_logging_internal + - abseil/synchronization/synchronization + - abseil/xcprivacy + - abseil/strings/cordz_info (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/container/inlined_vector + - abseil/debugging/stacktrace + - abseil/strings/cord_internal + - abseil/strings/cordz_functions + - abseil/strings/cordz_handle + - abseil/strings/cordz_statistics + - abseil/strings/cordz_update_tracker + - abseil/synchronization/synchronization + - abseil/time/time + - abseil/types/span + - abseil/xcprivacy + - abseil/strings/cordz_statistics (1.20240116.2): + - abseil/base/config + - abseil/strings/cordz_update_tracker + - abseil/xcprivacy + - abseil/strings/cordz_update_scope (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/strings/cord_internal + - abseil/strings/cordz_info + - abseil/strings/cordz_update_tracker + - abseil/xcprivacy + - abseil/strings/cordz_update_tracker (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/strings/has_ostream_operator (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/strings/internal (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/raw_logging_internal + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/strings/str_format (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/nullability + - abseil/strings/str_format_internal + - abseil/strings/string_view + - abseil/types/span + - abseil/xcprivacy + - abseil/strings/str_format_internal (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/container/fixed_array + - abseil/container/inlined_vector + - abseil/functional/function_ref + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/numeric/representation + - abseil/strings/strings + - abseil/types/optional + - abseil/types/span + - abseil/utility/utility + - abseil/xcprivacy + - abseil/strings/string_view (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/nullability + - abseil/base/throw_delegate + - abseil/xcprivacy + - abseil/strings/strings (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/endian + - abseil/base/nullability + - abseil/base/raw_logging_internal + - abseil/base/throw_delegate + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/numeric/bits + - abseil/numeric/int128 + - abseil/strings/charset + - abseil/strings/internal + - abseil/strings/string_view + - abseil/xcprivacy + - abseil/synchronization/graphcycles_internal (1.20240116.2): + - abseil/base/base + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/malloc_internal + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/synchronization/kernel_timeout_internal (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/time/time + - abseil/xcprivacy + - abseil/synchronization/synchronization (1.20240116.2): + - abseil/base/atomic_hook + - abseil/base/base + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/dynamic_annotations + - abseil/base/malloc_internal + - abseil/base/raw_logging_internal + - abseil/debugging/stacktrace + - abseil/debugging/symbolize + - abseil/synchronization/graphcycles_internal + - abseil/synchronization/kernel_timeout_internal + - abseil/time/time + - abseil/xcprivacy + - abseil/time (1.20240116.2): + - abseil/time/internal (= 1.20240116.2) + - abseil/time/time (= 1.20240116.2) + - abseil/time/internal (1.20240116.2): + - abseil/time/internal/cctz (= 1.20240116.2) + - abseil/time/internal/cctz (1.20240116.2): + - abseil/time/internal/cctz/civil_time (= 1.20240116.2) + - abseil/time/internal/cctz/time_zone (= 1.20240116.2) + - abseil/time/internal/cctz/civil_time (1.20240116.2): + - abseil/base/config + - abseil/xcprivacy + - abseil/time/internal/cctz/time_zone (1.20240116.2): + - abseil/base/config + - abseil/time/internal/cctz/civil_time + - abseil/xcprivacy + - abseil/time/time (1.20240116.2): + - abseil/base/base + - abseil/base/config + - abseil/base/core_headers + - abseil/base/raw_logging_internal + - abseil/numeric/int128 + - abseil/strings/strings + - abseil/time/internal/cctz/civil_time + - abseil/time/internal/cctz/time_zone + - abseil/types/optional + - abseil/xcprivacy + - abseil/types (1.20240116.2): + - abseil/types/any (= 1.20240116.2) + - abseil/types/bad_any_cast (= 1.20240116.2) + - abseil/types/bad_any_cast_impl (= 1.20240116.2) + - abseil/types/bad_optional_access (= 1.20240116.2) + - abseil/types/bad_variant_access (= 1.20240116.2) + - abseil/types/compare (= 1.20240116.2) + - abseil/types/optional (= 1.20240116.2) + - abseil/types/span (= 1.20240116.2) + - abseil/types/variant (= 1.20240116.2) + - abseil/types/any (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/base/fast_type_id + - abseil/meta/type_traits + - abseil/types/bad_any_cast + - abseil/utility/utility + - abseil/xcprivacy + - abseil/types/bad_any_cast (1.20240116.2): + - abseil/base/config + - abseil/types/bad_any_cast_impl + - abseil/xcprivacy + - abseil/types/bad_any_cast_impl (1.20240116.2): + - abseil/base/config + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/types/bad_optional_access (1.20240116.2): + - abseil/base/config + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/types/bad_variant_access (1.20240116.2): + - abseil/base/config + - abseil/base/raw_logging_internal + - abseil/xcprivacy + - abseil/types/compare (1.20240116.2): + - abseil/base/config + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/types/optional (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/base/nullability + - abseil/memory/memory + - abseil/meta/type_traits + - abseil/types/bad_optional_access + - abseil/utility/utility + - abseil/xcprivacy + - abseil/types/span (1.20240116.2): + - abseil/algorithm/algorithm + - abseil/base/core_headers + - abseil/base/nullability + - abseil/base/throw_delegate + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/types/variant (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/base/core_headers + - abseil/meta/type_traits + - abseil/types/bad_variant_access + - abseil/utility/utility + - abseil/xcprivacy + - abseil/utility/utility (1.20240116.2): + - abseil/base/base_internal + - abseil/base/config + - abseil/meta/type_traits + - abseil/xcprivacy + - abseil/xcprivacy (1.20240116.2) + - AppAuth (1.7.5): + - AppAuth/Core (= 1.7.5) + - AppAuth/ExternalUserAgent (= 1.7.5) + - AppAuth/Core (1.7.5) + - AppAuth/ExternalUserAgent (1.7.5): + - AppAuth/Core + - BoringSSL-GRPC (0.0.36): + - BoringSSL-GRPC/Implementation (= 0.0.36) + - BoringSSL-GRPC/Interface (= 0.0.36) + - BoringSSL-GRPC/Implementation (0.0.36): + - BoringSSL-GRPC/Interface (= 0.0.36) + - BoringSSL-GRPC/Interface (0.0.36) + - cloud_firestore (5.4.4): + - Firebase/Firestore (= 11.2.0) + - firebase_core + - Flutter + - Firebase/Auth (11.2.0): + - Firebase/CoreOnly + - FirebaseAuth (~> 11.2.0) + - Firebase/CoreOnly (11.2.0): + - FirebaseCore (= 11.2.0) + - Firebase/Firestore (11.2.0): + - Firebase/CoreOnly + - FirebaseFirestore (~> 11.2.0) + - Firebase/Storage (11.2.0): + - Firebase/CoreOnly + - FirebaseStorage (~> 11.2.0) + - firebase_auth (5.3.1): + - Firebase/Auth (= 11.2.0) + - firebase_core + - Flutter + - firebase_core (3.6.0): + - Firebase/CoreOnly (= 11.2.0) + - Flutter + - firebase_storage (12.3.3): + - Firebase/Storage (= 11.2.0) + - firebase_core + - Flutter + - FirebaseAppCheckInterop (11.3.0) + - FirebaseAuth (11.2.0): + - FirebaseAppCheckInterop (~> 11.0) + - FirebaseAuthInterop (~> 11.0) + - FirebaseCore (~> 11.0) + - FirebaseCoreExtension (~> 11.0) + - GoogleUtilities/AppDelegateSwizzler (~> 8.0) + - GoogleUtilities/Environment (~> 8.0) + - GTMSessionFetcher/Core (~> 3.4) + - RecaptchaInterop (~> 100.0) + - FirebaseAuthInterop (11.3.0) + - FirebaseCore (11.2.0): + - FirebaseCoreInternal (~> 11.0) + - GoogleUtilities/Environment (~> 8.0) + - GoogleUtilities/Logger (~> 8.0) + - FirebaseCoreExtension (11.3.0): + - FirebaseCore (~> 11.0) + - FirebaseCoreInternal (11.3.0): + - "GoogleUtilities/NSData+zlib (~> 8.0)" + - FirebaseFirestore (11.2.0): + - FirebaseCore (~> 11.0) + - FirebaseCoreExtension (~> 11.0) + - FirebaseFirestoreInternal (= 11.2.0) + - FirebaseSharedSwift (~> 11.0) + - FirebaseFirestoreInternal (11.2.0): + - abseil/algorithm (~> 1.20240116.1) + - abseil/base (~> 1.20240116.1) + - abseil/container/flat_hash_map (~> 1.20240116.1) + - abseil/memory (~> 1.20240116.1) + - abseil/meta (~> 1.20240116.1) + - abseil/strings/strings (~> 1.20240116.1) + - abseil/time (~> 1.20240116.1) + - abseil/types (~> 1.20240116.1) + - FirebaseAppCheckInterop (~> 11.0) + - FirebaseCore (~> 11.0) + - "gRPC-C++ (~> 1.65.0)" + - gRPC-Core (~> 1.65.0) + - leveldb-library (~> 1.22) + - nanopb (~> 3.30910.0) + - FirebaseSharedSwift (11.3.0) + - FirebaseStorage (11.2.0): + - FirebaseAppCheckInterop (~> 11.0) + - FirebaseAuthInterop (~> 11.0) + - FirebaseCore (~> 11.0) + - FirebaseCoreExtension (~> 11.0) + - GoogleUtilities/Environment (~> 8.0) + - GTMSessionFetcher/Core (~> 3.4) + - Flutter (1.0.0) + - flutter_native_splash (0.0.1): + - Flutter + - geolocator_apple (1.2.0): + - Flutter + - google_sign_in_ios (0.0.1): + - AppAuth (>= 1.7.4) + - Flutter + - FlutterMacOS + - GoogleSignIn (~> 7.1) + - GTMSessionFetcher (>= 3.4.0) + - GoogleSignIn (7.1.0): + - AppAuth (< 2.0, >= 1.7.3) + - GTMAppAuth (< 5.0, >= 4.1.1) + - GTMSessionFetcher/Core (~> 3.3) + - GoogleUtilities/AppDelegateSwizzler (8.0.2): + - GoogleUtilities/Environment + - GoogleUtilities/Logger + - GoogleUtilities/Network + - GoogleUtilities/Privacy + - GoogleUtilities/Environment (8.0.2): + - GoogleUtilities/Privacy + - GoogleUtilities/Logger (8.0.2): + - GoogleUtilities/Environment + - GoogleUtilities/Privacy + - GoogleUtilities/Network (8.0.2): + - GoogleUtilities/Logger + - "GoogleUtilities/NSData+zlib" + - GoogleUtilities/Privacy + - GoogleUtilities/Reachability + - "GoogleUtilities/NSData+zlib (8.0.2)": + - GoogleUtilities/Privacy + - GoogleUtilities/Privacy (8.0.2) + - GoogleUtilities/Reachability (8.0.2): + - GoogleUtilities/Logger + - GoogleUtilities/Privacy + - "gRPC-C++ (1.65.5)": + - "gRPC-C++/Implementation (= 1.65.5)" + - "gRPC-C++/Interface (= 1.65.5)" + - "gRPC-C++/Implementation (1.65.5)": + - abseil/algorithm/container (~> 1.20240116.2) + - abseil/base/base (~> 1.20240116.2) + - abseil/base/config (~> 1.20240116.2) + - abseil/base/core_headers (~> 1.20240116.2) + - abseil/base/log_severity (~> 1.20240116.2) + - abseil/base/no_destructor (~> 1.20240116.2) + - abseil/cleanup/cleanup (~> 1.20240116.2) + - abseil/container/flat_hash_map (~> 1.20240116.2) + - abseil/container/flat_hash_set (~> 1.20240116.2) + - abseil/container/inlined_vector (~> 1.20240116.2) + - abseil/flags/flag (~> 1.20240116.2) + - abseil/flags/marshalling (~> 1.20240116.2) + - abseil/functional/any_invocable (~> 1.20240116.2) + - abseil/functional/bind_front (~> 1.20240116.2) + - abseil/functional/function_ref (~> 1.20240116.2) + - abseil/hash/hash (~> 1.20240116.2) + - abseil/log/absl_check (~> 1.20240116.2) + - abseil/log/absl_log (~> 1.20240116.2) + - abseil/log/check (~> 1.20240116.2) + - abseil/log/globals (~> 1.20240116.2) + - abseil/log/log (~> 1.20240116.2) + - abseil/memory/memory (~> 1.20240116.2) + - abseil/meta/type_traits (~> 1.20240116.2) + - abseil/random/bit_gen_ref (~> 1.20240116.2) + - abseil/random/distributions (~> 1.20240116.2) + - abseil/random/random (~> 1.20240116.2) + - abseil/status/status (~> 1.20240116.2) + - abseil/status/statusor (~> 1.20240116.2) + - abseil/strings/cord (~> 1.20240116.2) + - abseil/strings/str_format (~> 1.20240116.2) + - abseil/strings/strings (~> 1.20240116.2) + - abseil/synchronization/synchronization (~> 1.20240116.2) + - abseil/time/time (~> 1.20240116.2) + - abseil/types/optional (~> 1.20240116.2) + - abseil/types/span (~> 1.20240116.2) + - abseil/types/variant (~> 1.20240116.2) + - abseil/utility/utility (~> 1.20240116.2) + - "gRPC-C++/Interface (= 1.65.5)" + - "gRPC-C++/Privacy (= 1.65.5)" + - gRPC-Core (= 1.65.5) + - "gRPC-C++/Interface (1.65.5)" + - "gRPC-C++/Privacy (1.65.5)" + - gRPC-Core (1.65.5): + - gRPC-Core/Implementation (= 1.65.5) + - gRPC-Core/Interface (= 1.65.5) + - gRPC-Core/Implementation (1.65.5): + - abseil/algorithm/container (~> 1.20240116.2) + - abseil/base/base (~> 1.20240116.2) + - abseil/base/config (~> 1.20240116.2) + - abseil/base/core_headers (~> 1.20240116.2) + - abseil/base/log_severity (~> 1.20240116.2) + - abseil/base/no_destructor (~> 1.20240116.2) + - abseil/cleanup/cleanup (~> 1.20240116.2) + - abseil/container/flat_hash_map (~> 1.20240116.2) + - abseil/container/flat_hash_set (~> 1.20240116.2) + - abseil/container/inlined_vector (~> 1.20240116.2) + - abseil/flags/flag (~> 1.20240116.2) + - abseil/flags/marshalling (~> 1.20240116.2) + - abseil/functional/any_invocable (~> 1.20240116.2) + - abseil/functional/bind_front (~> 1.20240116.2) + - abseil/functional/function_ref (~> 1.20240116.2) + - abseil/hash/hash (~> 1.20240116.2) + - abseil/log/check (~> 1.20240116.2) + - abseil/log/globals (~> 1.20240116.2) + - abseil/log/log (~> 1.20240116.2) + - abseil/memory/memory (~> 1.20240116.2) + - abseil/meta/type_traits (~> 1.20240116.2) + - abseil/random/bit_gen_ref (~> 1.20240116.2) + - abseil/random/distributions (~> 1.20240116.2) + - abseil/random/random (~> 1.20240116.2) + - abseil/status/status (~> 1.20240116.2) + - abseil/status/statusor (~> 1.20240116.2) + - abseil/strings/cord (~> 1.20240116.2) + - abseil/strings/str_format (~> 1.20240116.2) + - abseil/strings/strings (~> 1.20240116.2) + - abseil/synchronization/synchronization (~> 1.20240116.2) + - abseil/time/time (~> 1.20240116.2) + - abseil/types/optional (~> 1.20240116.2) + - abseil/types/span (~> 1.20240116.2) + - abseil/types/variant (~> 1.20240116.2) + - abseil/utility/utility (~> 1.20240116.2) + - BoringSSL-GRPC (= 0.0.36) + - gRPC-Core/Interface (= 1.65.5) + - gRPC-Core/Privacy (= 1.65.5) + - gRPC-Core/Interface (1.65.5) + - gRPC-Core/Privacy (1.65.5) + - GTMAppAuth (4.1.1): + - AppAuth/Core (~> 1.7) + - GTMSessionFetcher/Core (< 4.0, >= 3.3) + - GTMSessionFetcher (3.5.0): + - GTMSessionFetcher/Full (= 3.5.0) + - GTMSessionFetcher/Core (3.5.0) + - GTMSessionFetcher/Full (3.5.0): + - GTMSessionFetcher/Core + - image_picker_ios (0.0.1): + - Flutter + - leveldb-library (1.22.5) + - nanopb (3.30910.0): + - nanopb/decode (= 3.30910.0) + - nanopb/encode (= 3.30910.0) + - nanopb/decode (3.30910.0) + - nanopb/encode (3.30910.0) + - path_provider_foundation (0.0.1): + - Flutter + - FlutterMacOS + - RecaptchaInterop (100.0.0) + - shared_preferences_foundation (0.0.1): + - Flutter + - FlutterMacOS + - url_launcher_ios (0.0.1): + - Flutter + +DEPENDENCIES: + - cloud_firestore (from `.symlinks/plugins/cloud_firestore/ios`) + - firebase_auth (from `.symlinks/plugins/firebase_auth/ios`) + - firebase_core (from `.symlinks/plugins/firebase_core/ios`) + - firebase_storage (from `.symlinks/plugins/firebase_storage/ios`) + - Flutter (from `Flutter`) + - flutter_native_splash (from `.symlinks/plugins/flutter_native_splash/ios`) + - geolocator_apple (from `.symlinks/plugins/geolocator_apple/ios`) + - google_sign_in_ios (from `.symlinks/plugins/google_sign_in_ios/darwin`) + - image_picker_ios (from `.symlinks/plugins/image_picker_ios/ios`) + - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`) + - shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`) + - url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`) + +SPEC REPOS: + trunk: + - abseil + - AppAuth + - BoringSSL-GRPC + - Firebase + - FirebaseAppCheckInterop + - FirebaseAuth + - FirebaseAuthInterop + - FirebaseCore + - FirebaseCoreExtension + - FirebaseCoreInternal + - FirebaseFirestore + - FirebaseFirestoreInternal + - FirebaseSharedSwift + - FirebaseStorage + - GoogleSignIn + - GoogleUtilities + - "gRPC-C++" + - gRPC-Core + - GTMAppAuth + - GTMSessionFetcher + - leveldb-library + - nanopb + - RecaptchaInterop + +EXTERNAL SOURCES: + cloud_firestore: + :path: ".symlinks/plugins/cloud_firestore/ios" + firebase_auth: + :path: ".symlinks/plugins/firebase_auth/ios" + firebase_core: + :path: ".symlinks/plugins/firebase_core/ios" + firebase_storage: + :path: ".symlinks/plugins/firebase_storage/ios" + Flutter: + :path: Flutter + flutter_native_splash: + :path: ".symlinks/plugins/flutter_native_splash/ios" + geolocator_apple: + :path: ".symlinks/plugins/geolocator_apple/ios" + google_sign_in_ios: + :path: ".symlinks/plugins/google_sign_in_ios/darwin" + image_picker_ios: + :path: ".symlinks/plugins/image_picker_ios/ios" + path_provider_foundation: + :path: ".symlinks/plugins/path_provider_foundation/darwin" + shared_preferences_foundation: + :path: ".symlinks/plugins/shared_preferences_foundation/darwin" + url_launcher_ios: + :path: ".symlinks/plugins/url_launcher_ios/ios" + +SPEC CHECKSUMS: + abseil: d121da9ef7e2ff4cab7666e76c5a3e0915ae08c3 + AppAuth: 501c04eda8a8d11f179dbe8637b7a91bb7e5d2fa + BoringSSL-GRPC: ca6a8e5d04812fce8ffd6437810c2d46f925eaeb + cloud_firestore: 5cb927f1a8c9d748d6fdbf16c6b267956cb82c53 + Firebase: 98e6bf5278170668a7983e12971a66b2cd57fc8c + firebase_auth: 0c77e299a8f2d1c74d1b1f6b78b3d4d802c19f47 + firebase_core: 2bedc3136ec7c7b8561c6123ed0239387b53f2af + firebase_storage: 65d4aea1e6a42b153b738412f7ac8b1c9bfa6206 + FirebaseAppCheckInterop: 7789a8adfb09e905ce02a76540b94b059029ea81 + FirebaseAuth: 2a198b8cdbbbd457f08d74df7040feb0a0e7777a + FirebaseAuthInterop: c453b7ba7c49b88b2f519bb8d2e29edf7ada4a2a + FirebaseCore: a282032ae9295c795714ded2ec9c522fc237f8da + FirebaseCoreExtension: 30bb063476ef66cd46925243d64ad8b2c8ac3264 + FirebaseCoreInternal: ac26d09a70c730e497936430af4e60fb0c68ec4e + FirebaseFirestore: 62708adbc1dfcd6d165a7c0a202067b441912dc9 + FirebaseFirestoreInternal: ad9b9ee2d3d430c8f31333a69b3b6737a7206232 + FirebaseSharedSwift: d39c2ad64a11a8d936ce25a42b00df47078bb59c + FirebaseStorage: 9353f926690b2329957860abfcbc8b4074fe45e8 + Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7 + flutter_native_splash: edf599c81f74d093a4daf8e17bd7a018854bc778 + geolocator_apple: 6cbaf322953988e009e5ecb481f07efece75c450 + google_sign_in_ios: 07375bfbf2620bc93a602c0e27160d6afc6ead38 + GoogleSignIn: d4281ab6cf21542b1cfaff85c191f230b399d2db + GoogleUtilities: 26a3abef001b6533cf678d3eb38fd3f614b7872d + "gRPC-C++": 2fa52b3141e7789a28a737f251e0c45b4cb20a87 + gRPC-Core: a27c294d6149e1c39a7d173527119cfbc3375ce4 + GTMAppAuth: f69bd07d68cd3b766125f7e072c45d7340dea0de + GTMSessionFetcher: 5aea5ba6bd522a239e236100971f10cb71b96ab6 + image_picker_ios: c560581cceedb403a6ff17f2f816d7fea1421fc1 + leveldb-library: e8eadf9008a61f9e1dde3978c086d2b6d9b9dc28 + nanopb: fad817b59e0457d11a5dfbde799381cd727c1275 + path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46 + RecaptchaInterop: 7d1a4a01a6b2cb1610a47ef3f85f0c411434cb21 + shared_preferences_foundation: fcdcbc04712aee1108ac7fda236f363274528f78 + url_launcher_ios: 5334b05cef931de560670eeae103fd3e431ac3fe + +PODFILE CHECKSUM: 8012376785340ccabb170e4f14d0f15eb57b90e2 + +COCOAPODS: 1.15.2 diff --git a/ios/Runner.xcodeproj/project.pbxproj b/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 0000000..6acb12e --- /dev/null +++ b/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,750 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 54; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 331C808B294A63AB00263BE5 /* RunnerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 331C807B294A618700263BE5 /* RunnerTests.swift */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 924D1AFD4A5760DB8941FC73 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3FA8CA87A595C741686651FD /* Pods_Runner.framework */; }; + 961B0DA9AA95845D38770970 /* Pods_RunnerTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2935B523949F0072F1FCAEB6 /* Pods_RunnerTests.framework */; }; + 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 */; }; + DB7D1C3064DBB55B34F287DF /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 9474E3A41549165E87B32720 /* GoogleService-Info.plist */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 331C8085294A63A400263BE5 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 97C146E61CF9000F007C117D /* Project object */; + proxyType = 1; + remoteGlobalIDString = 97C146ED1CF9000F007C117D; + remoteInfo = Runner; + }; +/* End PBXContainerItemProxy 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 */ + 02139DF39A9A314FD9E0DC6C /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; + 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 = ""; }; + 2935B523949F0072F1FCAEB6 /* Pods_RunnerTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_RunnerTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 331C807B294A618700263BE5 /* RunnerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunnerTests.swift; sourceTree = ""; }; + 331C8081294A63A400263BE5 /* RunnerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RunnerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 3D44B24BAAF188C294DFE1F6 /* Pods-RunnerTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.debug.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.debug.xcconfig"; sourceTree = ""; }; + 3FA8CA87A595C741686651FD /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 6BD21CC9B0A89F0FA5CF8491 /* Pods-RunnerTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.release.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.release.xcconfig"; 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 = ""; }; + 884606D453C3A8BEF868944F /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; }; + 9474E3A41549165E87B32720 /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; 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 = ""; }; + B41A181F17AD4C9191EEB37A /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; + C44BFF0291F6D1BE5075266D /* Pods-RunnerTests.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.profile.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.profile.xcconfig"; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 924D1AFD4A5760DB8941FC73 /* Pods_Runner.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + D939761CA295904CFD257836 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 961B0DA9AA95845D38770970 /* Pods_RunnerTests.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 2B19EE781D45E8B26024024E /* Pods */ = { + isa = PBXGroup; + children = ( + B41A181F17AD4C9191EEB37A /* Pods-Runner.debug.xcconfig */, + 02139DF39A9A314FD9E0DC6C /* Pods-Runner.release.xcconfig */, + 884606D453C3A8BEF868944F /* Pods-Runner.profile.xcconfig */, + 3D44B24BAAF188C294DFE1F6 /* Pods-RunnerTests.debug.xcconfig */, + 6BD21CC9B0A89F0FA5CF8491 /* Pods-RunnerTests.release.xcconfig */, + C44BFF0291F6D1BE5075266D /* Pods-RunnerTests.profile.xcconfig */, + ); + name = Pods; + path = Pods; + sourceTree = ""; + }; + 331C8082294A63A400263BE5 /* RunnerTests */ = { + isa = PBXGroup; + children = ( + 331C807B294A618700263BE5 /* RunnerTests.swift */, + ); + path = RunnerTests; + sourceTree = ""; + }; + 3A80F58C55AA81E2C8F3F1F1 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 3FA8CA87A595C741686651FD /* Pods_Runner.framework */, + 2935B523949F0072F1FCAEB6 /* Pods_RunnerTests.framework */, + ); + name = Frameworks; + sourceTree = ""; + }; + 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 */, + 331C8082294A63A400263BE5 /* RunnerTests */, + 2B19EE781D45E8B26024024E /* Pods */, + 3A80F58C55AA81E2C8F3F1F1 /* Frameworks */, + 9474E3A41549165E87B32720 /* GoogleService-Info.plist */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + 331C8081294A63A400263BE5 /* RunnerTests.xctest */, + ); + 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 */ + 331C8080294A63A400263BE5 /* RunnerTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 331C8087294A63A400263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */; + buildPhases = ( + 6FBB51F26E4A646A4CB533F7 /* [CP] Check Pods Manifest.lock */, + 331C807D294A63A400263BE5 /* Sources */, + 331C807F294A63A400263BE5 /* Resources */, + D939761CA295904CFD257836 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + 331C8086294A63A400263BE5 /* PBXTargetDependency */, + ); + name = RunnerTests; + productName = RunnerTests; + productReference = 331C8081294A63A400263BE5 /* RunnerTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + ECEC902E71AE875EEEC6F168 /* [CP] Check Pods Manifest.lock */, + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + 21291158BF4324DCBC539C28 /* [CP] Embed Pods Frameworks */, + 27BE65335B8C962174D3D705 /* [CP] Copy Pods Resources */, + ); + 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 = { + BuildIndependentTargetsInParallel = YES; + LastUpgradeCheck = 1510; + ORGANIZATIONNAME = ""; + TargetAttributes = { + 331C8080294A63A400263BE5 = { + CreatedOnToolsVersion = 14.0; + TestTargetID = 97C146ED1CF9000F007C117D; + }; + 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 */, + 331C8080294A63A400263BE5 /* RunnerTests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 331C807F294A63A400263BE5 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 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 */, + DB7D1C3064DBB55B34F287DF /* GoogleService-Info.plist in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 21291158BF4324DCBC539C28 /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Embed Pods Frameworks"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; + 27BE65335B8C962174D3D705 /* [CP] Copy Pods Resources */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Copy Pods Resources"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources.sh\"\n"; + showEnvVarsInLog = 0; + }; + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}", + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; + }; + 6FBB51F26E4A646A4CB533F7 /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-RunnerTests-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; + 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"; + }; + ECEC902E71AE875EEEC6F168 /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 331C807D294A63A400263BE5 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 331C808B294A63AB00263BE5 /* RunnerTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 331C8086294A63A400263BE5 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 97C146ED1CF9000F007C117D /* Runner */; + targetProxy = 331C8085294A63A400263BE5 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency 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; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + 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; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + 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 = 12.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.donorconnect; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 331C8088294A63A400263BE5 /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 3D44B24BAAF188C294DFE1F6 /* Pods-RunnerTests.debug.xcconfig */; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner"; + }; + name = Debug; + }; + 331C8089294A63A400263BE5 /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 6BD21CC9B0A89F0FA5CF8491 /* Pods-RunnerTests.release.xcconfig */; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner"; + }; + name = Release; + }; + 331C808A294A63A400263BE5 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = C44BFF0291F6D1BE5075266D /* Pods-RunnerTests.profile.xcconfig */; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + 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; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + 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 = 12.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; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + 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; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + 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 = 12.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + 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.donorconnect; + 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.donorconnect; + 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 */ + 331C8087294A63A400263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 331C8088294A63A400263BE5 /* Debug */, + 331C8089294A63A400263BE5 /* Release */, + 331C808A294A63A400263BE5 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 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 */; +} diff --git a/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..919434a --- /dev/null +++ b/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 0000000..f9b0d7c --- /dev/null +++ b/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 0000000..8e3ca5d --- /dev/null +++ b/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,98 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ios/Runner.xcworkspace/contents.xcworkspacedata b/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..21a3cc1 --- /dev/null +++ b/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,10 @@ + + + + + + + diff --git a/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 0000000..f9b0d7c --- /dev/null +++ b/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/ios/Runner/AppDelegate.swift b/ios/Runner/AppDelegate.swift new file mode 100644 index 0000000..6266644 --- /dev/null +++ b/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import Flutter +import UIKit + +@main +@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) + } +} diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..d807305 --- /dev/null +++ b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,120 @@ +{ + "images": [ + { + "filename": "Icon-App-20x20@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "20x20", + "platform": "ios" + }, + { + "filename": "Icon-App-20x20@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "20x20", + "platform": "ios" + }, + { + "filename": "Icon-App-29x29@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "29x29", + "platform": "ios" + }, + { + "filename": "Icon-App-29x29@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "29x29", + "platform": "ios" + }, + { + "filename": "Icon-App-38x38@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "38x38", + "platform": "ios" + }, + { + "filename": "Icon-App-38x38@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "38x38", + "platform": "ios" + }, + { + "filename": "Icon-App-40x40@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "40x40", + "platform": "ios" + }, + { + "filename": "Icon-App-40x40@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "40x40", + "platform": "ios" + }, + { + "filename": "Icon-App-60x60@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "60x60", + "platform": "ios" + }, + { + "filename": "Icon-App-60x60@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "60x60", + "platform": "ios" + }, + { + "filename": "Icon-App-64x64@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "64x64", + "platform": "ios" + }, + { + "filename": "Icon-App-64x64@3x.png", + "idiom": "universal", + "scale": "3x", + "size": "64x64", + "platform": "ios" + }, + { + "filename": "Icon-App-68x68@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "68x68", + "platform": "ios" + }, + { + "filename": "Icon-App-76x76@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "76x76", + "platform": "ios" + }, + { + "filename": "Icon-App-83.5x83.5@2x.png", + "idiom": "universal", + "scale": "2x", + "size": "83.5x83.5", + "platform": "ios" + }, + { + "filename": "Icon-App-1024x1024@1x.png", + "idiom": "universal", + "scale": "1x", + "size": "1024x1024", + "platform": "ios" + } + ], + "info": { + "author": "icons_launcher", + "version": 1 + } +} \ No newline at end of file diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 0000000..ad361e6 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 0000000..7353c41 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 0000000..ffebcab Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 0000000..e677f7a Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 0000000..4cd7b00 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 0000000..f0bae23 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 0000000..a56ce7c Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@2x.png new file mode 100644 index 0000000..06751aa Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@3x.png new file mode 100644 index 0000000..ff9bb58 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-38x38@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 0000000..797d452 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 0000000..4195236 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 0000000..d4f64bf Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 0000000..d4f64bf Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 0000000..4eeddac Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@2x.png new file mode 100644 index 0000000..3da2ec0 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@3x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@3x.png new file mode 100644 index 0000000..cec9be3 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-64x64@3x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-68x68@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-68x68@2x.png new file mode 100644 index 0000000..9c7909e Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-68x68@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 0000000..84ac32a Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 0000000..e96e38e Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 0000000..1519216 Binary files /dev/null and b/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage.png b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage.png differ diff --git a/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@2x.png b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@2x.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@2x.png differ diff --git a/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@3x.png b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@3x.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/ios/Runner/Assets.xcassets/BrandingImage.imageset/BrandingImage@3x.png differ diff --git a/ios/Runner/Assets.xcassets/BrandingImage.imageset/Contents.json b/ios/Runner/Assets.xcassets/BrandingImage.imageset/Contents.json new file mode 100644 index 0000000..1271227 --- /dev/null +++ b/ios/Runner/Assets.xcassets/BrandingImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "BrandingImage.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "BrandingImage@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "BrandingImage@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ios/Runner/Assets.xcassets/LaunchBackground.imageset/Contents.json b/ios/Runner/Assets.xcassets/LaunchBackground.imageset/Contents.json new file mode 100644 index 0000000..9f447e1 --- /dev/null +++ b/ios/Runner/Assets.xcassets/LaunchBackground.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "background.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ios/Runner/Assets.xcassets/LaunchBackground.imageset/background.png b/ios/Runner/Assets.xcassets/LaunchBackground.imageset/background.png new file mode 100644 index 0000000..3107d37 Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchBackground.imageset/background.png differ diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 0000000..00cabce --- /dev/null +++ b/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "LaunchImage.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "LaunchImage@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "LaunchImage@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 0000000..89c2725 --- /dev/null +++ b/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# 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. \ No newline at end of file diff --git a/ios/Runner/Base.lproj/LaunchScreen.storyboard b/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 0000000..b299d95 --- /dev/null +++ b/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ios/Runner/Base.lproj/Main.storyboard b/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 0000000..f3c2851 --- /dev/null +++ b/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ios/Runner/GoogleService-Info.plist b/ios/Runner/GoogleService-Info.plist new file mode 100644 index 0000000..66f73ae --- /dev/null +++ b/ios/Runner/GoogleService-Info.plist @@ -0,0 +1,30 @@ + + + + + API_KEY + AIzaSyDSUZ2WdRgNAIgom1T74_8mg-4kutgrmi4 + GCM_SENDER_ID + 445023469277 + PLIST_VERSION + 1 + BUNDLE_ID + com.example.donorconnect + PROJECT_ID + donor-connect-project + STORAGE_BUCKET + donor-connect-project.appspot.com + IS_ADS_ENABLED + + IS_ANALYTICS_ENABLED + + IS_APPINVITE_ENABLED + + IS_GCM_ENABLED + + IS_SIGNIN_ENABLED + + GOOGLE_APP_ID + 1:445023469277:ios:9a17b6ec582928d9a52534 + + \ No newline at end of file diff --git a/ios/Runner/Info.plist b/ios/Runner/Info.plist new file mode 100644 index 0000000..b636033 --- /dev/null +++ b/ios/Runner/Info.plist @@ -0,0 +1,53 @@ + + + + + NSLocationWhenInUseUsageDescription + This app needs access to location when open. + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + Donorconnect + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + donorconnect + 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 + + CADisableMinimumFrameDurationOnPhone + + UIApplicationSupportsIndirectInputEvents + + UIStatusBarHidden + + + diff --git a/ios/Runner/Runner-Bridging-Header.h b/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 0000000..308a2a5 --- /dev/null +++ b/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" diff --git a/ios/RunnerTests/RunnerTests.swift b/ios/RunnerTests/RunnerTests.swift new file mode 100644 index 0000000..86a7c3b --- /dev/null +++ b/ios/RunnerTests/RunnerTests.swift @@ -0,0 +1,12 @@ +import Flutter +import UIKit +import XCTest + +class RunnerTests: XCTestCase { + + func testExample() { + // If you add code to the Runner application, consider adding tests here. + // See https://developer.apple.com/documentation/xctest for more information about using XCTest. + } + +} diff --git a/l10n.yaml b/l10n.yaml new file mode 100644 index 0000000..665f071 --- /dev/null +++ b/l10n.yaml @@ -0,0 +1,4 @@ +arb-dir: lib/l10n +template-arb-file: intl_en.arb +output-localization-file: app_localizations.dart +nullable-getter: false \ No newline at end of file diff --git a/lib/Utils/Textbox.dart b/lib/Utils/Textbox.dart new file mode 100644 index 0000000..6cf9339 --- /dev/null +++ b/lib/Utils/Textbox.dart @@ -0,0 +1,64 @@ +import 'package:flutter/material.dart'; + +class Textbox extends StatelessWidget { + final String name; + final TextEditingController controller; + final IconData icons; + final String? errormsg; + final bool obscureText; + final Widget? suffixIcon; //optional suffix icon for visibility toggle + + Textbox({ + super.key, + required this.name, + required this.controller, + required this.obscureText, + required this.icons, + this.errormsg, + this.suffixIcon, // Accepting the optional suffic icon + + }); + + @override + Widget build(BuildContext context) { + return ClipRRect( + borderRadius: BorderRadius.circular(10), + child: TextFormField( + obscureText: obscureText, + cursorColor: const Color.fromRGBO(18, 79, 43, 1), + style: const TextStyle( + color: Color.fromARGB(255, 18, 79, 43), + fontSize: 16, + fontWeight: FontWeight.w500, + ), + controller: controller, + decoration: InputDecoration( + hintText: name, + hintStyle: const TextStyle( + color: Color.fromARGB(255, 18, 79, 43), + fontSize: 16, + fontWeight: FontWeight.w500, + ), + errorText: errormsg, + errorBorder: InputBorder.none, + errorStyle: const TextStyle( + fontWeight: FontWeight.w400, + fontSize: 14, + ), + errorMaxLines: 3, // Allows error text to wrap to 3 lines + focusedErrorBorder: InputBorder.none, + prefixIcon: Icon( + icons, + size: 20, + ), + prefixIconColor: const Color.fromARGB(255, 18, 79, 43), + suffixIcon: suffixIcon, + focusedBorder: InputBorder.none, + enabledBorder: InputBorder.none, + fillColor: Colors.white60, + filled: true, + ), + ), + ); + } +} diff --git a/lib/Utils/constants/images_string.dart b/lib/Utils/constants/images_string.dart new file mode 100644 index 0000000..66cf874 --- /dev/null +++ b/lib/Utils/constants/images_string.dart @@ -0,0 +1,8 @@ + +class TImages{ + // onBoarding Images + static const String onBoardingImage1 = "assets/images/OnBoarding1.jpg"; + static const String onBoardingImage2 = "assets/images/OnBoarding2.jpg"; + static const String onBoardingImage3 = "assets/images/OnBoarding3.jpg"; + +} \ No newline at end of file diff --git a/lib/Utils/constants/text_string.dart b/lib/Utils/constants/text_string.dart new file mode 100644 index 0000000..148475d --- /dev/null +++ b/lib/Utils/constants/text_string.dart @@ -0,0 +1,12 @@ + +class TTexts{ + //-- OnBoarding Texts + static const String onBoardingTitle1 ="Locate Donors Around You"; + static const String onBoardingTitle2 ="Discover Donors Based on Blood Type"; + static const String onBoardingTitle3 ="Real Time Donor Availability"; + + static const String onBoardingSubTitle1 ="Quickly Find the donors around you!"; + static const String onBoardingSubTitle2 ="Search relevant donors quickly based on your need!"; + static const String onBoardingSubTitle3 ="Quickly Search active donors around you based on your needs and requirements!"; + +} \ No newline at end of file diff --git a/lib/Utils/show_snackbar.dart b/lib/Utils/show_snackbar.dart new file mode 100644 index 0000000..024b157 --- /dev/null +++ b/lib/Utils/show_snackbar.dart @@ -0,0 +1,11 @@ +import 'package:flutter/material.dart'; + +void showSnackBar(BuildContext context, String message) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar( + content: Text( + message, + ), + ), + ); +} diff --git a/lib/Utils/validation_helpers.dart b/lib/Utils/validation_helpers.dart new file mode 100644 index 0000000..d3b59c1 --- /dev/null +++ b/lib/Utils/validation_helpers.dart @@ -0,0 +1,63 @@ +class ValidationHelpers { + // Validate if a file is uploaded + static String? validateFileUpload(String? filePath) { + if (filePath == null || filePath.isEmpty) { + return 'Please upload the required document.'; + } + return null; + } + + // Validate if the ID document meets criteria (e.g., file extension) + static String? validateIDDocument(String? filePath) { + if (filePath == null || filePath.isEmpty) { + return 'Please upload your ID document.'; + } + if (!_isValidFileFormat(filePath, allowedExtensions: ['jpg', 'jpeg', 'png', 'pdf'])) { + return 'Invalid file format. Allowed formats: jpg, jpeg, png, pdf.'; + } + return null; + } + + // Validate if the medical certificate meets criteria (e.g., file extension) + static String? validateMedicalCertificate(String? filePath) { + if (filePath == null || filePath.isEmpty) { + return 'Please upload your medical certificate.'; + } + if (!_isValidFileFormat(filePath, allowedExtensions: ['jpg', 'jpeg', 'png', 'pdf'])) { + return 'Invalid file format. Allowed formats: jpg, jpeg, png, pdf.'; + } + return null; + } + + // Check if the file has an allowed extension + static bool _isValidFileFormat(String filePath, {required List allowedExtensions}) { + String fileExtension = filePath.split('.').last.toLowerCase(); + return allowedExtensions.contains(fileExtension); + } + + // Optional: Validate other fields like name or phone number for recipient/donor + static String? validateName(String? name) { + if (name == null || name.isEmpty) { + return 'Name is required.'; + } + if (name.length < 2) { + return 'Name must be at least 2 characters long.'; + } + return null; + } + + static String? validatePhoneNumber(String? phoneNumber) { + if (phoneNumber == null || phoneNumber.isEmpty) { + return 'Phone number is required.'; + } + if (!_isValidPhoneNumber(phoneNumber)) { + return 'Please enter a valid phone number.'; + } + return null; + } + + static bool _isValidPhoneNumber(String phoneNumber) { + final phoneRegex = RegExp(r'^[0-9]{10}$'); + return phoneRegex.hasMatch(phoneNumber); + } +} diff --git a/lib/cubit/auth/auth_cubit.dart b/lib/cubit/auth/auth_cubit.dart new file mode 100644 index 0000000..6979d08 --- /dev/null +++ b/lib/cubit/auth/auth_cubit.dart @@ -0,0 +1,218 @@ +import 'package:donorconnect/views/pages/welcome/welcome_screen.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:donorconnect/cubit/auth/auth_state.dart'; +import 'package:donorconnect/models/user_model.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:cloud_firestore/cloud_firestore.dart'; +import 'package:google_sign_in/google_sign_in.dart'; +import 'package:shared_preferences/shared_preferences.dart'; + +class AuthCubit extends Cubit { + final FirebaseAuth _auth; + final FirebaseFirestore _firestore; + + AuthCubit(this._auth, this._firestore) : super(AuthInitial()) { + _auth.authStateChanges().listen((User? user) { + if (user != null) { + _getUserData(user.uid); + } else { + emit(Unauthenticated()); + } + }); + } + Route _createRoute(Widget page) { + return PageRouteBuilder( + pageBuilder: (context, animation, secondaryAnimation) => page, + transitionsBuilder: (context, animation, secondaryAnimation, child) { + const begin = 0.0; + const end = 6.0; + const curve = Curves.easeInOut; + + var tween = + Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); + return FadeTransition( + opacity: animation.drive(tween), + child: child, + ); + }, + transitionDuration: + const Duration(milliseconds: 700), // Increase the duration to 700ms + ); + } + + Future loginUser(String email, String password) async { + emit(AuthLoading()); + try { + UserCredential userCredential = await _auth.signInWithEmailAndPassword( + email: email, password: password); + // After signing in, get the user data + _getUserData(userCredential.user!.uid); + } on FirebaseAuthException catch (e) { + if (e.code == 'user-not-found') { + emit(const AuthError("No User Found for that Email")); + } else if (e.code == 'invalid-credential') { + emit(const AuthError("Invalid mail or password Provided by User")); + } else { + emit(AuthError(e.toString())); + } + } + } + + Future signInWithGoogle() async { + GoogleSignInAccount? googleUser = await GoogleSignIn().signIn(); + GoogleSignInAuthentication? googleAuth = await googleUser?.authentication; + try { + AuthCredential credential = GoogleAuthProvider.credential( + accessToken: googleAuth?.accessToken, + idToken: googleAuth?.idToken, + ); + + await FirebaseAuth.instance + .signInWithCredential(credential) + .whenComplete(() {}); + UserModel userModel = UserModel( + uid: FirebaseAuth.instance.currentUser!.uid, + name: FirebaseAuth.instance.currentUser!.displayName!, + email: FirebaseAuth.instance.currentUser!.email!, + phone: FirebaseAuth.instance.currentUser!.phoneNumber ?? '', + isOrganDonor: false, + isBloodDonor: false, + ); + _firestore + .collection('users') + .doc(FirebaseAuth.instance.currentUser!.uid) + .snapshots() + .listen( + (DocumentSnapshot snapshot) { + if (snapshot.exists) { + UserModel user = + UserModel.fromMap(snapshot.data() as Map); + emit(Authenticated(user)); + print(user.name); + print(user.email); + // Save user name to SharedPreferences + _saveUserToPrefs(FirebaseAuth.instance.currentUser!.uid, user); + } else { + _firestore + .collection('users') + .doc(FirebaseAuth.instance.currentUser!.uid) + .set(userModel.toMap()); + // Save user data to SharedPreferences + _saveUserToPrefs(FirebaseAuth.instance.currentUser!.uid, userModel); + emit(Authenticated(userModel)); + } + }, + onError: (error) { + emit(AuthError(error.toString())); + }, + ); + emit(Authenticated(userModel)); + } catch (e) { + print(e); + } + } + + Future registerUser({ + required String email, + required String password, + required String name, + required String phone, + required bool isOrganDonor, + required bool isBloodDonor, + }) async { + emit(AuthLoading()); + try { + UserCredential userCredential = + await _auth.createUserWithEmailAndPassword( + email: email, + password: password, + ); + + UserModel userModel = UserModel( + uid: userCredential.user!.uid, + name: name, + email: email, + phone: phone, + isOrganDonor: isOrganDonor, + isBloodDonor: isBloodDonor, + ); + + await _firestore + .collection('users') + .doc(userCredential.user!.uid) + .set(userModel.toMap()); + + // Save user data to SharedPreferences + await _saveUserToPrefs(userCredential.user!.uid, userModel); + + emit( + Authenticated(userModel)); // Emit authenticated state with user model + } on FirebaseAuthException catch (e) { + if (e.code == 'weak-password') { + emit(const AuthError("Password Provided is too Weak")); + } else if (e.code == 'email-already-in-use') { + emit(const AuthError("User with this credential already exists")); + } else { + print(e.code); + emit(AuthError(e.toString())); + } + } + } + + Future signOut(BuildContext context) async { + emit(AuthLoading()); + try { + await _auth.signOut(); + emit(Unauthenticated()); + Navigator.pushReplacement( + context, + MaterialPageRoute( + builder: (context) => const FrontPage(), + ), + ); + } catch (e) { + emit(AuthError(e.toString())); + } + } + + void _getUserData(String uid) { + _firestore.collection('users').doc(uid).snapshots().listen( + (DocumentSnapshot snapshot) { + if (snapshot.exists) { + UserModel user = + UserModel.fromMap(snapshot.data() as Map); + emit(Authenticated(user)); + print(user.name); + print(user.email); + // Save user name to SharedPreferences + _saveUserNameToPrefs(user.uid, user.name); + } else { + emit(const AuthError('User data not found')); + } + }, + onError: (error) { + emit(AuthError(error.toString())); + }, + ); + } + + Future _saveUserNameToPrefs(String userId, String name) async { + final prefs = await SharedPreferences.getInstance(); + + print(name); + await prefs.setString('${userId}_name', name); + } + + Future _saveUserToPrefs(String userId, UserModel userModel) async { + final prefs = await SharedPreferences.getInstance(); + + print(userModel.name); + await prefs.setString('${userId}_name', userModel.name); + await prefs.setString('${userId}_email', userModel.email); + await prefs.setString('${userId}_phone', userModel.phone); + await prefs.setBool('${userId}_isOrganDonor', userModel.isOrganDonor); + await prefs.setBool('${userId}_isBloodDonor', userModel.isBloodDonor); + } +} diff --git a/lib/cubit/auth/auth_state.dart b/lib/cubit/auth/auth_state.dart new file mode 100644 index 0000000..b2115ea --- /dev/null +++ b/lib/cubit/auth/auth_state.dart @@ -0,0 +1,33 @@ +import 'package:donorconnect/models/user_model.dart'; +import 'package:equatable/equatable.dart'; + +abstract class AuthState extends Equatable { + const AuthState(); + + @override + List get props => []; +} + +class AuthInitial extends AuthState {} + +class AuthLoading extends AuthState {} + +class Authenticated extends AuthState { + final UserModel user; + + const Authenticated(this.user); + + @override + List get props => [user]; +} + +class Unauthenticated extends AuthState {} + +class AuthError extends AuthState { + final String message; + + const AuthError(this.message); + + @override + List get props => [message]; +} \ No newline at end of file diff --git a/lib/cubit/forgot_password/forgot_password_cubit.dart b/lib/cubit/forgot_password/forgot_password_cubit.dart new file mode 100644 index 0000000..32b11de --- /dev/null +++ b/lib/cubit/forgot_password/forgot_password_cubit.dart @@ -0,0 +1,26 @@ +import 'package:bloc/bloc.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:equatable/equatable.dart'; + +// ForgotPasswordState Definitions +part 'forgot_password_state.dart'; + +class ForgotPasswordCubit extends Cubit { + final FirebaseAuth _auth; + + ForgotPasswordCubit(this._auth) : super(ForgotPasswordInitial()); + + Future resetPassword(String email) async { + emit(ForgotPasswordLoading()); + try { + await _auth.sendPasswordResetEmail(email: email); + emit(ForgotPasswordSuccess()); + } on FirebaseAuthException catch (e) { + if (e.code == 'user-not-found') { + emit(const ForgotPasswordError('No user found for that email.')); + } else { + emit(ForgotPasswordError(e.message ?? 'An unknown error occurred.')); + } + } + } +} diff --git a/lib/cubit/forgot_password/forgot_password_state.dart b/lib/cubit/forgot_password/forgot_password_state.dart new file mode 100644 index 0000000..1db3517 --- /dev/null +++ b/lib/cubit/forgot_password/forgot_password_state.dart @@ -0,0 +1,23 @@ +part of 'forgot_password_cubit.dart'; + +abstract class ForgotPasswordState extends Equatable { + const ForgotPasswordState(); + + @override + List get props => []; +} + +class ForgotPasswordInitial extends ForgotPasswordState {} + +class ForgotPasswordLoading extends ForgotPasswordState {} + +class ForgotPasswordSuccess extends ForgotPasswordState {} + +class ForgotPasswordError extends ForgotPasswordState { + final String errorMessage; + + const ForgotPasswordError(this.errorMessage); + + @override + List get props => [errorMessage]; +} diff --git a/lib/cubit/locate_blood_banks/locate_blood_banks_cubit.dart b/lib/cubit/locate_blood_banks/locate_blood_banks_cubit.dart new file mode 100644 index 0000000..8e3a20d --- /dev/null +++ b/lib/cubit/locate_blood_banks/locate_blood_banks_cubit.dart @@ -0,0 +1,70 @@ +// Define States +import 'package:donorconnect/services/blood_bank_service.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +@immutable +abstract class LocateBloodBanksState {} + +class LocateBloodBanksInitial extends LocateBloodBanksState {} + +class LocateBloodBanksLoading extends LocateBloodBanksState {} + +class LocateBloodBanksLoaded extends LocateBloodBanksState { + final List bloodBanks; + LocateBloodBanksLoaded(this.bloodBanks); +} + +class LocateBloodBanksFiltered extends LocateBloodBanksState { + final List filteredBloodBanks; + LocateBloodBanksFiltered(this.filteredBloodBanks); +} + +class LocateBloodBanksError extends LocateBloodBanksState { + final String error; + LocateBloodBanksError(this.error); +} + +// Define Cubit +class LocateBloodBanksCubit extends Cubit { + final BloodBankService bloodBankService; + List bloodBanks = []; // Store original data for filtering + + LocateBloodBanksCubit(this.bloodBankService) + : super(LocateBloodBanksInitial()); + + // Fetch all blood banks + void fetchBloodBanks() async { + try { + emit(LocateBloodBanksLoading()); + bloodBanks = await bloodBankService.getBloodBanks(); + emit(LocateBloodBanksLoaded(bloodBanks)); + } catch (e) { + emit(LocateBloodBanksError(e.toString())); + } + } + + // Filter blood banks based on search criteria + void filterBloodBanks({String? city, String? district, String? state}) { + final filteredBloodBanks = bloodBanks.where((bloodBank) { + final matchesCity = city == null || + bloodBank['_city'] + .toString() + .toLowerCase() + .contains(city.toLowerCase()); + final matchesDistrict = district == null || + bloodBank['_district'] + .toString() + .toLowerCase() + .contains(district.toLowerCase()); + final matchesState = state == null || + bloodBank['_state'] + .toString() + .toLowerCase() + .contains(state.toLowerCase()); + return matchesCity && matchesDistrict && matchesState; + }).toList(); + + emit(LocateBloodBanksFiltered(filteredBloodBanks)); + } +} diff --git a/lib/cubit/profile/profile_cubit.dart b/lib/cubit/profile/profile_cubit.dart new file mode 100644 index 0000000..cb1e410 --- /dev/null +++ b/lib/cubit/profile/profile_cubit.dart @@ -0,0 +1,69 @@ +import 'package:donorconnect/cubit/profile/profile_state.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:shared_preferences/shared_preferences.dart'; + +// ProfileCubit definition (part of cubit/profile_cubit.dart) +class ProfileCubit extends Cubit { + ProfileCubit() : super(ProfileState()); + + // Call this when loading profile data + // Call this to load profile data for a specific user + Future loadProfile(String userId) async { + final prefs = await SharedPreferences.getInstance(); + emit(ProfileState( + name: prefs.getString('${userId}_name') ?? '', + medicalHistory: prefs.getString('${userId}_medicalHistory') ?? '', + currentMedications: prefs.getString('${userId}_currentMedications') ?? '', + allergies: prefs.getString('${userId}_allergies') ?? '', + bloodType: prefs.getString('${userId}_bloodType') ?? '', + isOrganDonor: prefs.getBool('${userId}_isOrganDonor') ?? false, + isBloodDonor: prefs.getBool('${userId}_isBloodDonor') ?? false, + notificationsEnabled: + prefs.getBool('${userId}_notificationsEnabled') ?? false, + )); + } + + // Update methods + void updateMedicalHistory(String history) { + emit(state.copyWith(medicalHistory: history)); + } + + void updateCurrentMedications(String medications) { + emit(state.copyWith(currentMedications: medications)); + } + + void updateAllergies(String allergies) { + emit(state.copyWith(allergies: allergies)); + } + + void updateBloodType(String bloodType) { + emit(state.copyWith(bloodType: bloodType)); + } + + void updateOrganDonorStatus(bool isOrganDonor) { + emit(state.copyWith(isOrganDonor: isOrganDonor)); + } + + void updateBloodDonorStatus(bool isBloodDonor) { + emit(state.copyWith(isBloodDonor: isBloodDonor)); + } + + void toggleNotifications(bool enabled) { + emit(state.copyWith(notificationsEnabled: enabled)); + } + + // Save profile data to shared preferences + Future saveProfile(String userId) async { + final prefs = await SharedPreferences.getInstance(); + await prefs.setString('${userId}_name', state.name); + await prefs.setString('${userId}_medicalHistory', state.medicalHistory); + await prefs.setString( + '${userId}_currentMedications', state.currentMedications); + await prefs.setString('${userId}_allergies', state.allergies); + await prefs.setString('${userId}_bloodType', state.bloodType); + await prefs.setBool('${userId}_isOrganDonor', state.isOrganDonor); + await prefs.setBool('${userId}_isBloodDonor', state.isBloodDonor); + await prefs.setBool( + '${userId}_notificationsEnabled', state.notificationsEnabled); + } +} diff --git a/lib/cubit/profile/profile_state.dart b/lib/cubit/profile/profile_state.dart new file mode 100644 index 0000000..29f65ba --- /dev/null +++ b/lib/cubit/profile/profile_state.dart @@ -0,0 +1,68 @@ +// profile_state.dart +import 'package:equatable/equatable.dart'; + +class ProfileState extends Equatable { + final String name; + final String medicalHistory; + final String currentMedications; + final String allergies; + final String bloodType; + final bool isOrganDonor; + final bool isBloodDonor; + final bool notificationsEnabled; + final String errorMessage; + + const ProfileState({ + this.name = '', + this.medicalHistory = '', + this.currentMedications = '', + this.allergies = '', + this.bloodType = '', + this.isOrganDonor = false, + this.isBloodDonor = false, + this.notificationsEnabled = false, + this.errorMessage = '', + }); + + // Adding a copyWith method to update the state with new data + ProfileState copyWith({ + String? name, + String? medicalHistory, + String? currentMedications, + String? allergies, + String? bloodType, + bool? isOrganDonor, + bool? isBloodDonor, + bool? notificationsEnabled, + String? errorMessage, + }) { + return ProfileState( + name: name ?? this.name, + medicalHistory: medicalHistory ?? this.medicalHistory, + currentMedications: currentMedications ?? this.currentMedications, + allergies: allergies ?? this.allergies, + bloodType: bloodType ?? this.bloodType, + isOrganDonor: isOrganDonor ?? this.isOrganDonor, + isBloodDonor: isBloodDonor ?? this.isBloodDonor, + notificationsEnabled: notificationsEnabled ?? this.notificationsEnabled, + errorMessage: errorMessage ?? this.errorMessage, + ); + } + + @override + List get props => [ + name, + medicalHistory, + currentMedications, + allergies, + bloodType, + isOrganDonor, + isBloodDonor, + notificationsEnabled, + errorMessage, + ]; + + static ProfileState error({required String message}) { + return ProfileState(errorMessage: message); + } +} diff --git a/lib/cubit/theme_toggle/theme_cubit.dart b/lib/cubit/theme_toggle/theme_cubit.dart new file mode 100644 index 0000000..f44f30e --- /dev/null +++ b/lib/cubit/theme_toggle/theme_cubit.dart @@ -0,0 +1,34 @@ +import 'package:donorconnect/cubit/theme_toggle/theme_state.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:shared_preferences/shared_preferences.dart'; + +class ThemeCubit extends Cubit { + static final ThemeData _light = ThemeData.light(); + static final ThemeData _dark = ThemeData.dark(); + + ThemeCubit() : super(Themestate(_light)) { + setInitialTheme(); // Load saved theme on startup + } + + void toggle(bool isDark) { + final themeData = isDark ? _light : _dark; + emit(Themestate(themeData)); + } + + Future _savetheme(bool isDark) async { + final prefs = await SharedPreferences.getInstance(); + await prefs.setBool('isDark', isDark); + } + + static Future _loadTheme() async { + final prefs = await SharedPreferences.getInstance(); + return prefs.getBool('isDark') ?? false; + } + + Future setInitialTheme() async { + final isDark = await _loadTheme(); + final themeData = isDark ? _dark : _light; + emit(Themestate(themeData)); + } +} diff --git a/lib/cubit/theme_toggle/theme_state.dart b/lib/cubit/theme_toggle/theme_state.dart new file mode 100644 index 0000000..6e87a3d --- /dev/null +++ b/lib/cubit/theme_toggle/theme_state.dart @@ -0,0 +1,6 @@ +import 'package:flutter/material.dart'; + +class Themestate{ + final ThemeData themeData; + Themestate(this.themeData); +} \ No newline at end of file diff --git a/lib/firebase_options.dart b/lib/firebase_options.dart new file mode 100644 index 0000000..c6075cd --- /dev/null +++ b/lib/firebase_options.dart @@ -0,0 +1,87 @@ +// File generated by FlutterFire CLI. +// ignore_for_file: type=lint +import 'package:firebase_core/firebase_core.dart' show FirebaseOptions; +import 'package:flutter/foundation.dart' + show defaultTargetPlatform, kIsWeb, TargetPlatform; + +/// Default [FirebaseOptions] for use with your Firebase apps. +/// +/// Example: +/// ```dart +/// import 'firebase_options.dart'; +/// // ... +/// await Firebase.initializeApp( +/// options: DefaultFirebaseOptions.currentPlatform, +/// ); +/// ``` +class DefaultFirebaseOptions { + static FirebaseOptions get currentPlatform { + if (kIsWeb) { + return web; + } + switch (defaultTargetPlatform) { + case TargetPlatform.android: + return android; + case TargetPlatform.iOS: + return ios; + case TargetPlatform.macOS: + return macos; + case TargetPlatform.windows: + return windows; + case TargetPlatform.linux: + throw UnsupportedError( + 'DefaultFirebaseOptions have not been configured for linux - ' + 'you can reconfigure this by running the FlutterFire CLI again.', + ); + default: + throw UnsupportedError( + 'DefaultFirebaseOptions are not supported for this platform.', + ); + } + } + + static const FirebaseOptions web = FirebaseOptions( + apiKey: 'AIzaSyAbi2F2bIntslQpVVBxi7EgSygC2A_NawY', + appId: '1:445023469277:web:38f1cccfd07af2b9a52534', + messagingSenderId: '445023469277', + projectId: 'donor-connect-project', + authDomain: 'donor-connect-project.firebaseapp.com', + storageBucket: 'donor-connect-project.appspot.com', + ); + + static const FirebaseOptions android = FirebaseOptions( + apiKey: 'AIzaSyDprpAsw0AkuQmFG1Iczpb9N2gghyAFmqo', + appId: '1:445023469277:android:867d6fc40fb1d859a52534', + messagingSenderId: '445023469277', + projectId: 'donor-connect-project', + storageBucket: 'donor-connect-project.appspot.com', + ); + + static const FirebaseOptions ios = FirebaseOptions( + apiKey: 'AIzaSyDSUZ2WdRgNAIgom1T74_8mg-4kutgrmi4', + appId: '1:445023469277:ios:9a17b6ec582928d9a52534', + messagingSenderId: '445023469277', + projectId: 'donor-connect-project', + storageBucket: 'donor-connect-project.appspot.com', + iosBundleId: 'com.example.donorconnect', + ); + + static const FirebaseOptions macos = FirebaseOptions( + apiKey: 'AIzaSyDSUZ2WdRgNAIgom1T74_8mg-4kutgrmi4', + appId: '1:445023469277:ios:9a17b6ec582928d9a52534', + messagingSenderId: '445023469277', + projectId: 'donor-connect-project', + storageBucket: 'donor-connect-project.appspot.com', + iosBundleId: 'com.example.donorconnect', + ); + + static const FirebaseOptions windows = FirebaseOptions( + apiKey: 'AIzaSyAbi2F2bIntslQpVVBxi7EgSygC2A_NawY', + appId: '1:445023469277:web:b05ec49f21bb5355a52534', + messagingSenderId: '445023469277', + projectId: 'donor-connect-project', + authDomain: 'donor-connect-project.firebaseapp.com', + storageBucket: 'donor-connect-project.appspot.com', + ); + +} \ No newline at end of file diff --git a/lib/l10n/intl_en.arb b/lib/l10n/intl_en.arb new file mode 100644 index 0000000..614a383 --- /dev/null +++ b/lib/l10n/intl_en.arb @@ -0,0 +1,59 @@ +{ + "how_can_we_help": "How can we help you?", + "donate": "Donate", + "required": "Required", + "locate_nearby_bloodbank": "Locate Nearby Bloodbanks", + "find_nearby_bloodbank": "Find Nearby BloodBank.", + "learn_about_donating": "Learn About Donating", + "learn_more_about_donating": "Learn more about blood & platelet donation.", + "locate_blood_bank": "Locate Blood Banks", + "city": "City", + "district": "District", + "state": "State", + "contact": "Contact", + "email": "Email", + "nodal_officer": "Nodal Officer", + "contact_nodal_officer": "Contact Nodal Officer", + "category": "Category", + "no_data_available": "No data available.", + "error": "Error", + "home": "Home", + "search": "Search", + "camps": "Camps", + "profile": "Profile", + "welcome_to_your_profile": "Welcome to your profile", + "medical_history": "Medical History", + "current_medications": "Current Medications", + "allergies": "Allergies", + "blood_type": "Blood Type", + "organ_donor": "Organ Donor", + "blood_donor": "Blood Donor", + "enable_donation_notifications": "Enable Donation Notifications", + "profile_saved": "Profile Saved", + "save_profile": "Save Profile", + "please_enter_your_email_and_password": "Please enter your email and password", + "welcome_back": "Welcome Back", + "log_in_to_your_account": "Log in to your account", + "please_enter_email": "Please enter Email", + "password": "Password", + "please_enter_password": "Please enter Password", + "forget_password": "Forgot password?", + "login": "Login", + "signup": "Sign up", + "do_not_have_account": "Do not have the account?", + "password_dont_match": "Passwords do not match", + "full_name": "Full name", + "phone_number": "Phone number", + "create_password": "Create Password", + "confirm_password": "Confirm Password", + "availabel_for_organ_donation": "Available for Organ Donation", + "avilabel_for_blood_donation": "Available for Blood Donation", + "by_sign_your_account_you_agree_terms_and": "By signing you agree to terms and", + "use_and_the_privacy_notice": "use and the privacy notice", + "password_error_text": "Password must be 8 character long and must have aleast 1 uppercase,1 Lowercase,1 digit,1 special character", + "phone_number_error_text": "Phone number must be of 10 Digit", + "name_field_error_text": "Name can not be Empty", + "email_field_error_text": "Email is Wrong or Blank, Kindly Enter correct Email", + "create_account": "Create your new account", + "register": "Register" +} diff --git a/lib/l10n/intl_gu.arb b/lib/l10n/intl_gu.arb new file mode 100644 index 0000000..ff55839 --- /dev/null +++ b/lib/l10n/intl_gu.arb @@ -0,0 +1,59 @@ +{ + "how_can_we_help": "અમે તમને કેવી રીતે મદદ કરી શકીએ?", + "donate": "દાન કરો", + "required": "જરૂરી", + "locate_nearby_bloodbank": "નજીકની બ્લડ બેંક શોધો.", + "find_nearby_bloodbank": "નજીકની બ્લડ બેંક શોધો.", + "learn_about_donating": "જાણો દાન વિશે", + "learn_more_about_donating": "રક્ત અને પ્લેટલેટ દાન વિશે વધુ જાણો.", + "locate_blood_bank": "તમારી બ્લડ બેંક શોધો", + "city": "શહેર", + "district": "જિલ્લો", + "state": "રાજ્ય", + "contact": "સંપર્ક", + "email": "ઇમેઇલ", + "nodal_officer": "નોડલ અધિકારી", + "contact_nodal_officer": "નોડલ અધિકારીનો સંપર્ક કરો.", + "no_data_available": "ડેટા અસ્તિત્વમાં નથી.", + "error": "ભૂલ", + "home": "હોમ પેજ", + "search": "શોધો", + "camps": "શિબિર", + "profile": "પ્રોફાઇલ", + "welcome_to_your_profile": "તમારી પ્રોફાઇલમાં આપનું સ્વાગત છે.", + "medical_history": "તબીબી ઇતિહાસ", + "current_medications": "હાલની દવાઓ", + "allergies": "એલર્જી", + "blood_type": "લોહીનો પ્રકાર", + "organ_donor": "અંગ દાતા", + "blood_donor": "રક્તદાતા", + "enable_donation_notifications": "દાન સૂચનાઓ સક્રિય કરો", + "profile_saved": "રૂપરેખા સાચવવામાં આવી", + "save_profile": "પ્રોફાઇલ સાચવો", + "please_enter_your_email_and_password": "કૃપા કરીને તમારું ઈ-મેલ અને પાસવર્ડ દાખલ કરો.", + "welcome_back": "ફરી સ્વાગત છે", + "log_in_to_your_account": "તમારા એકાઉન્ટમાં લોગ ઇન કરો", + "please_enter_email": "ઇમેઇલ સબમિટ કરો", + "password": "પાસવર્ડ", + "please_enter_password": "મહેરબાની કરીને પાસવર્ડ દાખલ કરો", + "forget_password": "તમારો પાસવર્ડ ભૂલી ગયા છો?", + "login": "પ્રવેશ કરો", + "signup": "સાઇન અપ કરો", + "do_not_have_account": "ખાતું નથી?", + "password_dont_match": "પાસવર્ડ મેળ ખાતો નથી", + "full_name": "સંપૂર્ણ નામ", + "phone_number": "ફોન નંબર", + "create_password": "પાસવર્ડ નંબર", + "confirm_password": "પાસવર્ડની પુષ્ટિ કરો", + "availabel_for_organ_donation": "દાન માટે ઉપલબ્ધ", + "avilabel_for_blood_donation": "રક્તદાન માટે ઉપલબ્ધ", + "by_sign_your_account_you_agree_terms_and": "કરાર પર હસ્તાક્ષર કરીને, તમે શરતોથી સંમત થાઓ છો અને", + "use_and_the_privacy_notice": "ઉપયોગ અને ગોપનીયતા સૂચના", + "password_error_text": "પાસવર્ડ 8 અક્ષરો લાંબો હોવો જોઈએ અને તેમાં 1 અપરકેસ, 1 લોઅરકેસ, 1 અંક, 1 વિશેષ અક્ષર હોવો જોઈએ.", + "phone_number_error_text": "ફોન નંબર 10 અંકોનો હોવો જોઈએ.", + "name_field_error_text": "નામ ખાલી ન હોઈ શકે.", + "email_field_error_text": "ઈ-મેલ ખોટો અથવા ખાલી છે. મહેરબાની કરીને સાચો ઈ-મેલ દાખલ કરો.", + "create_account": "નવું ખાતું બનાવો", + "register": "નોંધણી કરો", + "category":"શ્રેણી" +} diff --git a/lib/l10n/intl_hi.arb b/lib/l10n/intl_hi.arb new file mode 100644 index 0000000..fe76f34 --- /dev/null +++ b/lib/l10n/intl_hi.arb @@ -0,0 +1,60 @@ +{ + "how_can_we_help": "हम आपकी मदद कैसे कर सकते हैं?", + "donate": "दान करें", + "required": "आवश्यक", + "locate_nearby_bloodbank": "पास के ब्लडबैंक का पता लगाएं", + "find_nearby_bloodbank": "नजदीकी ब्लडबैंक खोजें.", + "learn_about_donating": "दान के बारे में जानिए", + "learn_more_about_donating": "रक्त और प्लेटलेट दान के बारे में अधिक जानें।", + "locate_blood_bank": "ब्लड बैंकों का पता लगाएं", + "city": "शहर", + "district": "ज़िला", + "state": "राज्य", + "contact": "संपर्क", + "email": "ईमेल", + "nodal_officer": "नोडल अधिकारी", + "contact_nodal_officer": "नोडल अधिकारी से संपर्क करें", + "no_data_available": "कोई डेटा मौजूद नहीं.", + "error": "एरर", + "home": "होम", + "search": "खोज", + "camps": "शिविर", + "profile": "प्रोफ़ाइल", + "welcome_to_your_profile": "अपने प्रोफाइल में आपका स्वागत है", + "medical_history": "मेडिकल हिस्ट्री", + "current_medications": "वर्तमान दवाएं", + "allergies": "एलर्जी", + "blood_type": "रक्त प्रकार", + "category":"वर्ग", + "organ_donor": "अंग दान करने वाला", + "blood_donor": "रक्तदाता", + "enable_donation_notifications": "दान सूचनाएं सक्षम करें", + "profile_saved": "प्रोफ़ाइल सहेजी गई", + "save_profile": "प्रोफ़ाइल सहेजें", + "please_enter_your_email_and_password": "कृपया अपना ईमेल और पासवर्ड दर्ज करें", + "welcome_back": "वापस स्वागत है", + "log_in_to_your_account": "अपने अकाउंट में लॉग इन करें", + "please_enter_email": "ईमेल दाखिल करें", + "password": "पासवर्ड", + "please_enter_password": "कृपया पासवर्ड भरें", + "forget_password": "पासवर्ड भूल गया?", + "login": "लॉगइन", + "signup": "साइन अप करें", + "do_not_have_account": "खाता नहीं है?", + "password_dont_match": "पासवर्ड मेल नहीं खाता", + "full_name": "पूरा नाम", + "phone_number": "फोन नंबर", + "create_password": "पासवर्ड संख्या", + "confirm_password": "पासवर्ड की पुष्टि करें", + "availabel_for_organ_donation": "अंगदान के लिए उपलब्ध", + "avilabel_for_blood_donation": "रक्तदान के लिए उपलब्ध", + "by_sign_your_account_you_agree_terms_and": "हस्ताक्षर करके आप शर्तों पर सहमत हैं और", + "use_and_the_privacy_notice": "उपयोग और गोपनीयता नोटिस", + "password_error_text": "पासवर्ड 8 अक्षर लंबा होना चाहिए और इसमें 1 अपर केस, 1 लोअरकेस, 1 अंक, 1 विशेष अक्षर होना चाहिए", + "phone_number_error_text":"फोन नंबर 10 अंकों का होना चाहिए", + "name_field_error_text":"नाम रिक्त नहीं हो सकता", + "email_field_error_text":"ईमेल गलत या खाली है, कृपया सही ईमेल दर्ज करें", + "create_account":"नया खाता बनाएँ", + "register":"रजिस्टर" + } + \ No newline at end of file diff --git a/lib/language/cubit/language_cubit.dart b/lib/language/cubit/language_cubit.dart new file mode 100644 index 0000000..99e0b2d --- /dev/null +++ b/lib/language/cubit/language_cubit.dart @@ -0,0 +1,17 @@ +import 'package:donorconnect/language/helper/language.dart'; +import 'package:donorconnect/language/services/language_repositoty.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +// part ''; +class LanguageCubit extends Cubit { + LanguageCubit() : super(Language.english); + + void initilize() { + emit(LanguageRepository.getPrefferedLanguge()); + } + + // set + void changeLanguage(Language getlanguageFromUser) { + emit(getlanguageFromUser); + LanguageRepository.addPreferredLanguage(getlanguageFromUser); + } +} diff --git a/lib/language/helper/langauge_popup.dart b/lib/language/helper/langauge_popup.dart new file mode 100644 index 0000000..e85319c --- /dev/null +++ b/lib/language/helper/langauge_popup.dart @@ -0,0 +1,45 @@ +import 'package:donorconnect/language/cubit/language_cubit.dart'; +import 'package:donorconnect/language/helper/language.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +class LanguagePopup extends StatelessWidget { + const LanguagePopup({super.key}); + + @override + Widget build(BuildContext context) { + return BlocBuilder( + builder: (context, currentLangaugeState) { + return PopupMenuButton( + onSelected: (languageFromUser) { + context.read().changeLanguage(languageFromUser); + }, + itemBuilder: (context) => [ + for (var values in Language.values) + PopupMenuItem( + value: values, + child: Row( + children: [ + Text(values.countryFlag), + SizedBox(width: 16.0), + Text(values.languageName), + ], + ), + ) + ], + child: BlocBuilder( + builder: (context, currentLanguage) { + return Row( + children: [ + Text(currentLanguage.countryFlag), + SizedBox(width: 16.0), + Text(currentLanguage.languageName), + Icon(Icons.arrow_drop_down_sharp), + ], + ); + }, + ), + ); + }); + } +} diff --git a/lib/language/helper/language.dart b/lib/language/helper/language.dart new file mode 100644 index 0000000..4a15a82 --- /dev/null +++ b/lib/language/helper/language.dart @@ -0,0 +1,15 @@ +enum Language { + english(countryFlag: "🇮🇳", languageName: "English", languageCode: "en"), + hindi(countryFlag: "🇮🇳", languageName: "हिंदी", languageCode: "hi"), + gujarati(countryFlag: "🇮🇳", languageName: "ગુજરાતી ‍", languageCode: "gu"); + + final String countryFlag; + final String languageName; + final String languageCode; + + const Language({ + required this.countryFlag, + required this.languageName, + required this.languageCode, + }); +} diff --git a/lib/language/helper/language_extention.dart b/lib/language/helper/language_extention.dart new file mode 100644 index 0000000..c2447fd --- /dev/null +++ b/lib/language/helper/language_extention.dart @@ -0,0 +1,6 @@ +import 'package:flutter/material.dart' show BuildContext; +import 'package:flutter_gen/gen_l10n/app_localizations.dart'; + +extension AppLocalizationExtention on BuildContext { + AppLocalizations get localizedString => AppLocalizations.of(this); +} diff --git a/lib/language/services/language_repositoty.dart b/lib/language/services/language_repositoty.dart new file mode 100644 index 0000000..91db10c --- /dev/null +++ b/lib/language/services/language_repositoty.dart @@ -0,0 +1,24 @@ +import 'package:donorconnect/language/helper/language.dart'; +import 'package:shared_preferences/shared_preferences.dart'; + +class LanguageRepository { + static late SharedPreferences _prefs; + static Future init() async { + _prefs = await SharedPreferences.getInstance(); + } + + // store language in local storage + static void addPreferredLanguage(Language language) { + _prefs.setString("language_key", language.languageCode); + } + + // get stored language + static Language getPrefferedLanguge() { + final code = _prefs.getString("language_key"); + for (var values in Language.values) { + if (values.languageCode == code) return values; + } + return Language + .english; // default to English if not found in stored languages + } +} diff --git a/lib/main.dart b/lib/main.dart new file mode 100644 index 0000000..9c418cb --- /dev/null +++ b/lib/main.dart @@ -0,0 +1,106 @@ +import 'package:cloud_firestore/cloud_firestore.dart'; +import 'package:donorconnect/cubit/auth/auth_cubit.dart'; +import 'package:donorconnect/cubit/locate_blood_banks/locate_blood_banks_cubit.dart'; +import 'package:donorconnect/cubit/profile/profile_cubit.dart'; +import 'package:donorconnect/cubit/theme_toggle/theme_cubit.dart'; +import 'package:donorconnect/cubit/theme_toggle/theme_state.dart'; +import 'package:donorconnect/firebase_options.dart'; +import 'package:donorconnect/language/cubit/language_cubit.dart'; +import 'package:donorconnect/language/helper/language.dart'; +import 'package:donorconnect/language/services/language_repositoty.dart'; +import 'package:donorconnect/services/blood_bank_service.dart'; +import 'package:donorconnect/views/pages/main_home/homepage.dart'; +import 'package:donorconnect/views/pages/onboarding/onboarding.dart'; +import 'package:donorconnect/views/pages/welcome/welcome_screen.dart'; +import 'package:donorconnect/views/verificationform.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:firebase_core/firebase_core.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/services.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:get/get_navigation/src/root/get_material_app.dart'; +import 'package:shared_preferences/shared_preferences.dart'; +import 'package:jwt_decoder/jwt_decoder.dart'; +import 'package:flutter_gen/gen_l10n/app_localizations.dart'; +// import 'package:riverpod/riverpod.dart'; +import 'package:flutter_dotenv/flutter_dotenv.dart'; + +void main() async { + WidgetsFlutterBinding.ensureInitialized(); + await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform); + await LanguageRepository.init(); + SharedPreferences prefs = await SharedPreferences.getInstance(); + ErrorWidget.builder = (FlutterErrorDetails details) { + return const Material(); + }; + // await dotenv.load(fileName: '.env'); + SystemChrome.setPreferredOrientations([ + DeviceOrientation.portraitUp, + DeviceOrientation.portraitDown, + ]); + runApp(MyApp( + token: prefs.getString('token'), + )); +} + +class MyApp extends StatelessWidget { + final String? token; + + const MyApp({ + required this.token, + super.key, + }); + + @override + Widget build(BuildContext context) { + return MultiBlocProvider( + providers: [ + BlocProvider( + create: (context) => ProfileCubit(), + ), + BlocProvider( + create: (context) => AuthCubit( + FirebaseAuth.instance, + FirebaseFirestore.instance, + ), + ), + BlocProvider( + create: (context) => LocateBloodBanksCubit(BloodBankService()), + ), + BlocProvider( + create: (context) => LanguageCubit()..initilize(), + ), + BlocProvider( + create: (context) => ThemeCubit()..setInitialTheme(), + ), + ], + child: BlocBuilder( + builder: (context, themeState) { + return BlocBuilder( + builder: (context, languageState) { + return GetMaterialApp( + localizationsDelegates: AppLocalizations.localizationsDelegates, + supportedLocales: AppLocalizations.supportedLocales, + locale: Locale(languageState.languageCode), + //theme + // themeMode: themeState.themeData, + theme: themeState.themeData, + darkTheme: ThemeData.dark(), + debugShowCheckedModeBanner: false, + // Main route selection + home: (token != null && !JwtDecoder.isExpired(token!)) + ? HomePage(token: token!) + : const OnBoardingScreen(), + // You can add routes for the verification form + routes: { + '/verification': (context) => + const VerificationForm(), // Add route for verification form + }, + + ); + }); + }, + ), + ); + } +} \ No newline at end of file diff --git a/lib/models/user_model.dart b/lib/models/user_model.dart new file mode 100644 index 0000000..a9e972c --- /dev/null +++ b/lib/models/user_model.dart @@ -0,0 +1,90 @@ +import 'dart:convert'; + +class UserModel { + final String uid; + final String name; + final String email; + final String phone; + final bool isOrganDonor; + final bool isBloodDonor; + UserModel({ + required this.uid, + required this.name, + required this.email, + required this.phone, + required this.isOrganDonor, + required this.isBloodDonor, + }); + + UserModel copyWith({ + String? uid, + String? name, + String? email, + String? phone, + bool? isOrganDonor, + bool? isBloodDonor, + }) { + return UserModel( + uid: uid ?? this.uid, + name: name ?? this.name, + email: email ?? this.email, + phone: phone ?? this.phone, + isOrganDonor: isOrganDonor ?? this.isOrganDonor, + isBloodDonor: isBloodDonor ?? this.isBloodDonor, + ); + } + + Map toMap() { + return { + 'uid': uid, + 'name': name, + 'email': email, + 'phone': phone, + 'isOrganDonor': isOrganDonor, + 'isBloodDonor': isBloodDonor, + }; + } + + factory UserModel.fromMap(Map map) { + return UserModel( + uid: map['uid'] ?? '', + name: map['name'] ?? '', + email: map['email'] ?? '', + phone: map['phone'] ?? '', + isOrganDonor: map['isOrganDonor'] ?? false, + isBloodDonor: map['isBloodDonor'] ?? false, + ); + } + + String toJson() => json.encode(toMap()); + + factory UserModel.fromJson(String source) => UserModel.fromMap(json.decode(source)); + + @override + String toString() { + return 'UserModel(uid: $uid, name: $name, email: $email, phone: $phone, isOrganDonor: $isOrganDonor, isBloodDonor: $isBloodDonor)'; + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) return true; + + return other is UserModel && + other.uid == uid && + other.name == name && + other.email == email && + other.phone == phone && + other.isOrganDonor == isOrganDonor && + other.isBloodDonor == isBloodDonor; + } + + @override + int get hashCode { + return uid.hashCode ^ + name.hashCode ^ + email.hashCode ^ + phone.hashCode ^ + isOrganDonor.hashCode ^ + isBloodDonor.hashCode; + } +} diff --git a/lib/models/verification_status.dart b/lib/models/verification_status.dart new file mode 100644 index 0000000..fff0299 --- /dev/null +++ b/lib/models/verification_status.dart @@ -0,0 +1,39 @@ +import 'package:cloud_firestore/cloud_firestore.dart'; + +class VerificationStatus { + final String userId; + final String idDocumentUrl; + final String medicalCertificateUrl; + final String status; // "pending", "verified", "rejected" + final DateTime submittedAt; + + VerificationStatus({ + required this.userId, + required this.idDocumentUrl, + required this.medicalCertificateUrl, + required this.status, + required this.submittedAt, + }); + + // Factory constructor to create an instance from Firestore data + factory VerificationStatus.fromMap(Map map) { + return VerificationStatus( + userId: map['userId'] ?? '', + idDocumentUrl: map['idDocumentUrl'] ?? '', + medicalCertificateUrl: map['medicalCertificateUrl'] ?? '', + status: map['status'] ?? 'pending', // Default to pending + submittedAt: (map['submittedAt'] as Timestamp).toDate(), + ); + } + + // Convert instance to a map for Firestore storage + Map toMap() { + return { + 'userId': userId, + 'idDocumentUrl': idDocumentUrl, + 'medicalCertificateUrl': medicalCertificateUrl, + 'status': status, + 'submittedAt': submittedAt, + }; + } +} diff --git a/lib/secrets.dart b/lib/secrets.dart new file mode 100644 index 0000000..8202bc8 --- /dev/null +++ b/lib/secrets.dart @@ -0,0 +1,2 @@ +const String apiKey = + "579b464db66ec23bdd00000163b9abb70e404aca75573c10a5468e4b"; diff --git a/lib/services/blood_bank_service.dart b/lib/services/blood_bank_service.dart new file mode 100644 index 0000000..c061260 --- /dev/null +++ b/lib/services/blood_bank_service.dart @@ -0,0 +1,21 @@ +import 'dart:convert'; +import 'package:http/http.dart' as http; + +const String apiKey = + "579b464db66ec23bdd00000163b9abb70e404aca75573c10a5468e4b"; + +class BloodBankService { + final String apiUrl = + 'https://api.data.gov.in/resource/fced6df9-a360-4e08-8ca0-f283fc74ce15?api-key=$apiKey&format=json&offset=0&limit=3000'; + + Future> getBloodBanks() async { + final response = await http.get(Uri.parse(apiUrl)); + + if (response.statusCode == 200) { + final data = jsonDecode(response.body); + return data['records']; // Modify as per the API response structure + } else { + return []; + } + } +} diff --git a/lib/services/verification_service.dart b/lib/services/verification_service.dart new file mode 100644 index 0000000..1c1c643 --- /dev/null +++ b/lib/services/verification_service.dart @@ -0,0 +1,65 @@ +import 'dart:io'; +import 'package:firebase_storage/firebase_storage.dart'; +import 'package:cloud_firestore/cloud_firestore.dart'; +import 'package:firebase_auth/firebase_auth.dart'; + +class VerificationService { + final FirebaseStorage _storage = FirebaseStorage.instance; + final FirebaseFirestore _firestore = FirebaseFirestore.instance; + final FirebaseAuth _auth = FirebaseAuth.instance; + + // Upload the documents to Firebase Storage and update the Firestore with verification status + Future submitVerification({ + required File idDocument, + required File medicalCertificate, + }) async { + try { + // Get current user + User? user = _auth.currentUser; + if (user == null) { + throw Exception('No authenticated user found.'); + } + + // Create a unique path for each document + String userId = user.uid; + String idDocumentPath = 'verifications/$userId/id_document.jpg'; + String medicalCertificatePath = 'verifications/$userId/medical_certificate.jpg'; + + // Upload the ID document + await _uploadFile(idDocument, idDocumentPath); + + // Upload the medical certificate + await _uploadFile(medicalCertificate, medicalCertificatePath); + + // Save verification details to Firestore + await _firestore.collection('verifications').doc(userId).set({ + 'userId': userId, + 'idDocumentUrl': await _getDownloadUrl(idDocumentPath), + 'medicalCertificateUrl': await _getDownloadUrl(medicalCertificatePath), + 'status': 'pending', // Verification starts as pending + 'submittedAt': FieldValue.serverTimestamp(), + }); + } catch (e) { + throw Exception('Error submitting verification: $e'); + } + } + + // Helper method to upload a file to Firebase Storage + Future _uploadFile(File file, String filePath) async { + try { + await _storage.ref(filePath).putFile(file); + } catch (e) { + throw Exception('Error uploading file: $e'); + } + } + + // Get the download URL of an uploaded file + Future _getDownloadUrl(String filePath) async { + try { + String downloadUrl = await _storage.ref(filePath).getDownloadURL(); + return downloadUrl; + } catch (e) { + throw Exception('Error fetching file URL: $e'); + } + } +} diff --git a/lib/views/common_widgets/donor_card.dart b/lib/views/common_widgets/donor_card.dart new file mode 100644 index 0000000..27e7581 --- /dev/null +++ b/lib/views/common_widgets/donor_card.dart @@ -0,0 +1,73 @@ +import 'package:donorconnect/Utils/constants/images_string.dart'; +import 'package:donorconnect/views/common_widgets/rounded_conatiner.dart'; +import 'package:donorconnect/views/common_widgets/rounded_image.dart'; +import 'package:flutter/material.dart'; +import 'package:iconsax/iconsax.dart'; + +class TDonorCardHorizontal extends StatelessWidget { + const TDonorCardHorizontal({super.key}); + + @override + Widget build(BuildContext context) { + return Container( + width: 370, + padding: const EdgeInsets.all(1), + decoration: BoxDecoration( + + borderRadius: BorderRadius.circular(16), + color:const Color.fromARGB(255, 250, 237, 237), + ), + child: Row( + children: [ + ///Thumbnail + const TRoundedContainer( + height: 120, + padding: EdgeInsets.all(8), + backgroundColor:Color.fromARGB(255, 236, 225, 225), + child: Stack( + children: [ + /// --- Thumbnail Image + SizedBox( + height:170, + width: 100, + child: TRoundedImage(imageUrl: TImages.onBoardingImage1,applyImageRadius: true,), + ), + ], + ), + ), + SizedBox(width: 20,), + /// Details + SizedBox( + width: 172, + child: Padding( + padding: const EdgeInsets.only(top: 8,left: 8), + child: Column( + children: [ + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(40, 10, 40, 15), + ), + onPressed: (){}, child: Text('Book Now', style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + ),)) + ], + ), + + + ], + ), + ), + ) + ], + ), + ); + } +} diff --git a/lib/views/common_widgets/events_card.dart b/lib/views/common_widgets/events_card.dart new file mode 100644 index 0000000..b6e6fb6 --- /dev/null +++ b/lib/views/common_widgets/events_card.dart @@ -0,0 +1,95 @@ +import 'package:flutter/material.dart'; +import 'package:url_launcher/url_launcher.dart'; + +class EventsCard extends StatelessWidget { + final Map event; + const EventsCard({super.key, required this.event}); + + @override + Widget build(BuildContext context) { + return Container( + margin: const EdgeInsets.all(10), + padding: const EdgeInsets.all(10), + decoration: BoxDecoration( + color: Colors.white, + borderRadius: BorderRadius.circular(10), + boxShadow: [ + BoxShadow( + color: Colors.grey.withOpacity(0.5), + spreadRadius: 1, + blurRadius: 7, + offset: const Offset(0, 3), + ), + ], + ), + child: Column( + children: [ + Row( + children: [ + const Icon(Icons.calendar_today), + const SizedBox(width: 10), + Text( + event['campName'], + style: const TextStyle( + fontSize: 18, + fontWeight: FontWeight.bold, + ), + ), + ], + ), + const SizedBox(height: 10), + Row( + children: [ + const Icon(Icons.location_on), + const SizedBox(width: 10), + ElevatedButton( + onPressed: () { + if (event['latitude'] != null && + event['longitude'] != null) { + final Uri googleMapsUrl = Uri.parse( + 'https://www.google.com/maps/search/?api=1&query=${event['latitude']},${event['longitude']}'); + launchUrl(googleMapsUrl); + } else { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Invalid coordinates.")), + ); + } + }, + child: Row( + children: [ + Text('Find Route'), + ], + )) + ], + ), + const SizedBox(height: 10), + Row( + children: [ + const Icon(Icons.access_time), + const SizedBox(width: 10), + Text( + event['time'], + style: const TextStyle( + fontSize: 16, + ), + ), + ], + ), + const SizedBox(height: 10), + Row( + children: [ + const Icon(Icons.people), + const SizedBox(width: 10), + Text( + event['organizer'], + style: const TextStyle( + fontSize: 16, + ), + ), + ], + ), + ], + ), + ); + } +} diff --git a/lib/views/common_widgets/home_card.dart b/lib/views/common_widgets/home_card.dart new file mode 100644 index 0000000..9fbca6b --- /dev/null +++ b/lib/views/common_widgets/home_card.dart @@ -0,0 +1,83 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:google_fonts/google_fonts.dart'; + +class HomeCard extends StatelessWidget { + final String title, description, button, image; + final VoidCallback? onPressed; + final Icon icon; + const HomeCard({ + super.key, + required this.title, + required this.description, + required this.button, + required this.image, + required this.onPressed, + required this.icon, + }); + + @override + Widget build(BuildContext context) { + var height = MediaQuery.of(context).size.height; + var width = MediaQuery.of(context).size.width; + return InkWell( + onTap: onPressed, + child: Card( + semanticContainer: true, + clipBehavior: Clip.antiAliasWithSaveLayer, + elevation: 0.4, + surfaceTintColor: const Color.fromARGB(255, 255, 152, 145), + child: Padding( + padding: const EdgeInsets.all(6.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Center( + child: Image.asset( + image, + ), + ), + SizedBox( + height: height * 0.005, + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceAround, + children: [ + SizedBox( + width: width * 0.6, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + title, + style: GoogleFonts.montserrat( + fontSize: 14.0, + fontWeight: FontWeight.bold, + ), + ), + SizedBox( + height: height * 0.001, + ), + Text( + description, + style: GoogleFonts.montserrat( + fontSize: 13.0, + fontWeight: FontWeight.w400, + ), + ), + ], + ), + ), + CupertinoButton( + onPressed: onPressed, + child: icon, + ), + ], + ), + ], + ), + ), + ), + ); + } +} diff --git a/lib/views/common_widgets/home_card_form.dart b/lib/views/common_widgets/home_card_form.dart new file mode 100644 index 0000000..1abcc84 --- /dev/null +++ b/lib/views/common_widgets/home_card_form.dart @@ -0,0 +1,40 @@ +import 'package:flutter/cupertino.dart'; +import 'package:google_fonts/google_fonts.dart'; + +class HomeCardConst extends StatelessWidget { + final String title; + final VoidCallback onPressed; + final Color col; + + const HomeCardConst({ + super.key, + required this.title, + required this.onPressed, + required this.col, + }); + + @override + Widget build(BuildContext context) { + var width = MediaQuery.of(context).size.width; + //var height = MediaQuery.of(context).size.height; + return Padding( + padding: const EdgeInsets.all(10.0), + child: SizedBox( + width: width * 0.40, + child: CupertinoButton( + borderRadius: BorderRadius.circular(30), + color: col, + onPressed: onPressed, + padding: const EdgeInsets.all(4), + child: Text( + title, + style: GoogleFonts.montserrat( + fontSize: 14, + fontWeight: FontWeight.w800, + ), + ), + ), + ), + ); + } +} diff --git a/lib/views/common_widgets/rounded_conatiner.dart b/lib/views/common_widgets/rounded_conatiner.dart new file mode 100644 index 0000000..5d729ad --- /dev/null +++ b/lib/views/common_widgets/rounded_conatiner.dart @@ -0,0 +1,42 @@ +import 'package:flutter/material.dart'; + +class TRoundedContainer extends StatelessWidget { + const TRoundedContainer({ + super.key, + this.width, + this.height, + this.radius = 16, + this.child, + this.shadowBorder = false, + this.borderColor = Colors.black, + this.padding, + this.margin, + this.backgroundColor = Colors.white, + }); + + final double? width; + final double? height; + final double radius; + final Widget? child; + final bool shadowBorder; + final Color borderColor; + final Color backgroundColor; + final EdgeInsetsGeometry? padding; + final EdgeInsetsGeometry? margin; + + + @override + Widget build(BuildContext context) { + return Container( + width:width, + height: height, + padding: padding, + decoration: BoxDecoration( + color: backgroundColor, + borderRadius: BorderRadius.circular(radius), + border: shadowBorder ? Border.all(color: borderColor) : null, + ), + child: child, + ); + } +} diff --git a/lib/views/common_widgets/rounded_image.dart b/lib/views/common_widgets/rounded_image.dart new file mode 100644 index 0000000..2a8d80b --- /dev/null +++ b/lib/views/common_widgets/rounded_image.dart @@ -0,0 +1,58 @@ + +import 'package:flutter/material.dart'; + +class TRoundedImage extends StatelessWidget { + const TRoundedImage({ + super.key, + this.border, + this.onPressed, + this.width , + this.height, + required this.imageUrl, + this.applyImageRadius = true, + this.fit = BoxFit.contain, + this.padding, + this.isNetworkImage = false, + this.backgroundColor, + this.borderRadius = 12, + }); + + final double? width, height; + final String imageUrl; + final bool applyImageRadius; + final BoxBorder? border; + final Color? backgroundColor; + final BoxFit fit; + final EdgeInsetsGeometry? padding; + final bool isNetworkImage; + final VoidCallback? onPressed; + final double borderRadius; + + + @override + Widget build(BuildContext context) { + return GestureDetector( + child: Container( + height: height, + width: width, + decoration: BoxDecoration( + border: border, + color: backgroundColor, + borderRadius: BorderRadius.circular(borderRadius)), + child: ClipRRect( + borderRadius: applyImageRadius + ? BorderRadius.circular(borderRadius) + : BorderRadius.zero, + child: Image( + fit: fit, + image: isNetworkImage + ? NetworkImage(imageUrl) + : AssetImage(imageUrl) as ImageProvider), + + ), + ), + + ); + + } +} \ No newline at end of file diff --git a/lib/views/common_widgets/toggle_button.dart b/lib/views/common_widgets/toggle_button.dart new file mode 100644 index 0000000..c066784 --- /dev/null +++ b/lib/views/common_widgets/toggle_button.dart @@ -0,0 +1,75 @@ +import 'package:animated_toggle_switch/animated_toggle_switch.dart'; +import 'package:donorconnect/cubit/theme_toggle/theme_cubit.dart'; +import 'package:donorconnect/cubit/theme_toggle/theme_state.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +class ThemeToggleButton extends StatelessWidget { + const ThemeToggleButton({super.key, required this.switchValue}); + final bool switchValue; + + @override + Widget build(BuildContext context) { + return BlocBuilder( + builder: (context, themeState) { + return Padding( + padding: const EdgeInsets.only(left: 8.0, right: 8.0), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + const Text( + "Change App Theme", + style: TextStyle(fontSize: 20), + ), + SizedBox( + height: 42, + width: 140, + child: AnimatedToggleSwitch.dual( + current: switchValue, + first: false, + second: true, + height: 40, + onChanged: (value) { + // Toggle the theme based on the switch value + context.read().toggle(value); + }, + styleBuilder: (value) => ToggleStyle( + indicatorColor: + value ? Colors.purple.shade300 : Colors.yellow, + backgroundGradient: value + ? const LinearGradient( + colors: [Colors.purpleAccent, Colors.deepPurple]) + : LinearGradient(colors: [ + Colors.yellow.shade300, + Colors.yellow.shade900 + ]), + ), + iconBuilder: (value) => value + ? const Icon( + Icons.nights_stay_rounded, + color: Colors.white, + ) + : const Icon( + Icons.sunny, + color: Colors.black, + ), + textBuilder: (value) => value + ? const Center( + child: Text( + "Dark Mode", + style: TextStyle(color: Colors.white), + ), + ) + : const Center( + child: Text("Light Mode"), + ), + ), + ) + ], + ), + ); + }, + ); + } + +} diff --git a/lib/views/controllers/onboarding/onboarding_controller.dart b/lib/views/controllers/onboarding/onboarding_controller.dart new file mode 100644 index 0000000..9f61987 --- /dev/null +++ b/lib/views/controllers/onboarding/onboarding_controller.dart @@ -0,0 +1,55 @@ + +import 'package:flutter/cupertino.dart'; +import 'package:flutter/foundation.dart'; +import 'package:get/get.dart'; +import 'package:get_storage/get_storage.dart'; + +import '../../pages/login/login.dart'; + + +class OnBoardingController extends GetxController { + static OnBoardingController get instance => Get.find(); + + /// Variable + final pageController = PageController(); + // final currentPageIndex = 0.obs; alternate method below + Rx currentPageIndex = 0.obs; +/// Update Current Index when page Scroll + void updatePageIndicator(index) => currentPageIndex.value = index; + +/// Jump to the specific dot selected page. +void dotNavigationClick(index) { + currentPageIndex.value = index; + pageController.jumpTo(index); +} + +/// Update Current Index & jump to next page +void nextPage() { + if(currentPageIndex.value == 2){ + final storage = GetStorage(); + + if(kDebugMode){ + print('===================== GET STORAGE =============='); + print(storage.read('IsFirstTime')); + } + + storage.write('IsFirstTime', false); + + if(kDebugMode){ + print('===================== GET STORAGE =============='); + print(storage.read('IsFirstTime')); + } + + Get.offAll(const LoginPage()); + } else{ + int page = currentPageIndex.value + 1; + pageController.jumpToPage(page); + } +} + +/// Update current index & jump to the last Page +void skipPage() { + currentPageIndex.value = 2; + pageController.jumpTo(2); +} +} \ No newline at end of file diff --git a/lib/views/pages/Required/required_screen.dart b/lib/views/pages/Required/required_screen.dart new file mode 100644 index 0000000..74c2f05 --- /dev/null +++ b/lib/views/pages/Required/required_screen.dart @@ -0,0 +1,44 @@ +import 'package:donorconnect/views/common_widgets/donor_card.dart'; +import 'package:donorconnect/views/pages/Required/widgets/choice_chip.dart'; +import 'package:flutter/material.dart'; + +class RequiredScreen extends StatelessWidget { + const RequiredScreen({super.key,}); + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: const Text('Pick Your Blood'), + actions: const [ + Chip( + label: Icon(Icons.question_mark), + shape: CircleBorder(eccentricity: BorderSide.strokeAlignCenter), + ) + ], + ), + body: Column( + children: [ + const ChipApp(), + + const SizedBox(height: 30,), + Padding( + padding: const EdgeInsets.fromLTRB(0, 0, 180, 0), + child: Text('Available Donner',style: TextStyle( + fontSize: 20, + color: Theme.of(context).colorScheme.onSurface, + fontWeight: FontWeight.bold, + ),), + ), + const SizedBox(height: 20), + const TDonorCardHorizontal(), + const SizedBox(height: 20,), + const TDonorCardHorizontal(), + const SizedBox(height: 20,), + const TDonorCardHorizontal() + ], + ) + + ); + + } +} diff --git a/lib/views/pages/Required/widgets/choice_chip.dart b/lib/views/pages/Required/widgets/choice_chip.dart new file mode 100644 index 0000000..470dead --- /dev/null +++ b/lib/views/pages/Required/widgets/choice_chip.dart @@ -0,0 +1,54 @@ +import 'package:flutter/material.dart'; + +class ChipApp extends StatelessWidget { + const ChipApp({super.key}); + + @override + Widget build(BuildContext context) { + return const ActionChoiceExample(); + + } +} +class ActionChoiceExample extends StatefulWidget { + const ActionChoiceExample({super.key}); + + @override + State createState() => _ActionChoiceExampleState(); +} + +class _ActionChoiceExampleState extends State { + int? _value = 1; + @override + Widget build(BuildContext context) { + final TextTheme textTheme = Theme.of(context).textTheme; + + return Center( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Choose a blood group', style: textTheme.labelLarge), + const SizedBox(height: 20.0), + Wrap( + spacing: 10.0, + children: List.generate( + 4, + (int index) { + return ChoiceChip( + padding: const EdgeInsets.all(15), + label: Text('O+ $index'), + selected: _value == index, + onSelected: (bool selected) { + setState(() { + _value = selected ? index : null; + }); + }, + ); + }, + ).toList(), + ), + ], + ), + ); + } +} \ No newline at end of file diff --git a/lib/views/pages/camps/calendarPage.dart b/lib/views/pages/camps/calendarPage.dart new file mode 100644 index 0000000..d29d592 --- /dev/null +++ b/lib/views/pages/camps/calendarPage.dart @@ -0,0 +1,138 @@ +import 'package:donorconnect/views/common_widgets/events_card.dart'; +import 'package:flutter/material.dart'; +import 'package:geolocator/geolocator.dart'; +import 'package:intl/intl.dart'; +import 'package:mongo_dart/mongo_dart.dart' as mongo; + +class CalendarPage extends StatefulWidget { + const CalendarPage({super.key}); + + @override + State createState() => _CalendarPageState(); +} + +class _CalendarPageState extends State { + List> _events = []; + DateTime _selectedDate = DateTime.now(); + List> _camps = []; + Position? _currentPosition; + bool _isLoading = true; + + @override + void initState() { + // TODO: implement initState + _getCurrentLocation(); + _fetchCamps(); + super.initState(); + } + + void _getCurrentLocation() async { + LocationPermission permission = await Geolocator.checkPermission(); + if (permission == LocationPermission.denied) { + permission = await Geolocator.requestPermission(); + } + + if (permission == LocationPermission.denied || + permission == LocationPermission.deniedForever) { + setState(() { + _isLoading = false; + }); + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Location permissions are denied.")), + ); + return; + } + + Position position = await Geolocator.getCurrentPosition( + desiredAccuracy: LocationAccuracy.high); + setState(() { + _currentPosition = position; + }); + } + + Future _fetchCamps() async { + try { + var db = await mongo.Db.create( + 'mongo url'); + await db.open(); + var collection = db.collection('BloodDonationCamps'); + List> camps = await collection.find().toList(); + + double distanceThreshold = 25 * 1000; + _camps = camps.where((camp) { + double campLatitude = camp['latitude']; + double campLongitude = camp['longitude']; + double distanceInMeters = Geolocator.distanceBetween( + _currentPosition!.latitude, + _currentPosition!.longitude, + campLatitude, + campLongitude); + return camp['date'] == DateFormat('yyyy-MM-dd').format(_selectedDate) && + distanceInMeters <= distanceThreshold; + }).toList(); + _isLoading = false; + if(_camps.isEmpty){ + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("No events scheduled for the selected date.")), + ); + } + setState(() {}); + await db.close(); + } catch (e) { + setState(() { + _isLoading = false; + }); + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Error fetching donation camps: $e")), + ); + } + } + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text('Events Calendar'), + ), + body: Container( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + CalendarDatePicker( + initialDate: DateTime.now(), + firstDate: DateTime.now(), + lastDate: DateTime.now().add(Duration(days: 60)), + onDateChanged: (value) { + setState(() { + _isLoading = true; + _selectedDate = value; + _fetchCamps(); + }); + }, + ), + Divider( + height: 20, + thickness: 2, + ), + // Text( + // "Events Scheduled", + // style: TextStyle(), + // textAlign: TextAlign.start, + // ), + Flexible( + child: _isLoading + ? Center( + child: CircularProgressIndicator( + ), + ) + : _camps.isEmpty ?Image.asset('assets/images/empty_calendar.png') :ListView.builder( + itemCount: _camps.length, + itemBuilder: (context, index) { + return EventsCard(event: _camps[index],); + }, + )) + ], + )), + ); + } +} diff --git a/lib/views/pages/camps/campsPage.dart b/lib/views/pages/camps/campsPage.dart new file mode 100644 index 0000000..d0db398 --- /dev/null +++ b/lib/views/pages/camps/campsPage.dart @@ -0,0 +1,563 @@ +import 'package:donorconnect/views/pages/camps/calendarPage.dart'; +import 'package:flutter/material.dart'; +import 'package:geolocator/geolocator.dart'; +import 'package:mongo_dart/mongo_dart.dart' as mongo; +import 'package:url_launcher/url_launcher.dart'; +import 'package:intl/intl.dart'; + +class Camps extends StatefulWidget { + const Camps({super.key}); + + @override + _Camps createState() => _Camps(); +} + +class _Camps extends State with SingleTickerProviderStateMixin { + Position? _currentPosition; + List> _upcomingCamps = []; + List> _pastCamps = []; + List> _registeredCamps = []; + bool _isLoading = true; + late TabController _tabController; + + @override + void initState() { + super.initState(); + _getCurrentLocation(); + _fetchDonationCamps(); + _tabController = TabController(length: 3, vsync: this); + } + + void _getCurrentLocation() async { + LocationPermission permission = await Geolocator.checkPermission(); + if (permission == LocationPermission.denied) { + permission = await Geolocator.requestPermission(); + } + + if (permission == LocationPermission.denied || + permission == LocationPermission.deniedForever) { + setState(() { + _isLoading = false; + }); + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Location permissions are denied.")), + ); + return; + } + + Position position = await Geolocator.getCurrentPosition( + desiredAccuracy: LocationAccuracy.high); + // setState(() { + // _currentPosition = position; + // }); + } + + Future _fetchDonationCamps() async { + try { + var db = await mongo.Db.create( + 'mongo url'); + await db.open(); + var collection = db.collection('BloodDonationCamps'); + List> camps = await collection.find().toList(); + + double distanceThreshold = 25 * 1000; + // setState(() { + _upcomingCamps = camps.where((camp) { + double campLatitude = camp['latitude']; + double campLongitude = camp['longitude']; + double distanceInMeters = Geolocator.distanceBetween( + _currentPosition!.latitude, + _currentPosition!.longitude, + campLatitude, + campLongitude); + return DateTime.parse(camp['date']).isAfter(DateTime.now()) && + distanceInMeters <= distanceThreshold; + }).toList(); + _pastCamps = camps.where((camp) { + double campLatitude = camp['latitude']; + double campLongitude = camp['longitude']; + double distanceInMeters = Geolocator.distanceBetween( + _currentPosition!.latitude, + _currentPosition!.longitude, + campLatitude, + campLongitude); + return DateTime.parse(camp['date']).isBefore(DateTime.now()) && + distanceInMeters <= distanceThreshold; + }).toList(); + _isLoading = false; + // }); + setState(() { + + }); + await _fetchRegisteredCamps(db); + await db.close(); + } catch (e) { + setState(() { + _isLoading = false; + }); + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Error fetching donation camps: $e")), + ); + } + } + + Future _fetchRegisteredCamps(mongo.Db db) async { + var registrationCollection = db.collection('CampRegistrations'); + String userId = 'testUser@gmail.com'; // Example user ID + + List> registeredCamps = + await registrationCollection.find({'userId': userId}).toList(); + + setState(() { + _registeredCamps = registeredCamps; + }); + } + + void _showCampDetailsDialog(Map camp) { + showDialog( + context: context, + builder: (BuildContext context) { + return Dialog( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(15.0), + ), + child: Container( + padding: const EdgeInsets.all(15.0), + constraints: BoxConstraints(maxHeight: 400), + child: Column( + mainAxisSize: MainAxisSize.min, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text(camp['campName'] ?? 'No Name', + style: + TextStyle(fontWeight: FontWeight.bold, fontSize: 20)), + SizedBox(height: 8), + Text("Date: ${camp['date'] ?? 'Unknown'}"), + Text("Time: ${camp['time'] ?? 'Unknown'}"), + Text("Location: ${camp['location'] ?? 'Unknown'}"), + Text("Organizer: ${camp['organizer'] ?? 'Unknown'}"), + Text("Verified: ${camp['isVerified'] ?? false ? 'Yes' : 'No'}"), + Text("Rating: ${camp['rating'] ?? 'Not Rated'}"), + SizedBox(height: 15), + Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + ElevatedButton( + onPressed: () { + _navigateToMap(camp['latitude'], camp['longitude']); + }, + child: Text("Navigate"), + ), + ElevatedButton( + onPressed: () { + _registerForCamp(camp); + Navigator.of(context).pop(); + }, + child: Text("Register"), + ), + ], + ), + ], + ), + ), + ); + }, + ); + } + + void _navigateToMap(double? latitude, double? longitude) async { + if (latitude != null && longitude != null) { + final Uri googleMapsUrl = Uri.parse( + 'https://www.google.com/maps/search/?api=1&query=$latitude,$longitude'); + + launchUrl(googleMapsUrl); + } else { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Invalid coordinates.")), + ); + } + } + + Future _registerForCamp(Map camp) async { + try { + var db = await mongo.Db.create( + 'mongo url'); + await db.open(); + var registrationCollection = db.collection('CampRegistrations'); + + String userId = 'testUser@gmail.com'; // Example user ID + + var existingRegistration = await registrationCollection.findOne({ + 'userId': userId, + 'campId': camp['_id'], + }); + + if (existingRegistration != null) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("You are already registered for this camp.")), + ); + } else { + await registrationCollection.insert({ + 'userId': userId, + 'campId': camp['_id'], + 'campName': camp['campName'], + 'date': camp['date'], + 'time': camp['time'], + 'location': camp['location'], + 'registeredAt': DateTime.now().toIso8601String(), + 'organizer': camp['organizer'], + }); + + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Registration successful.")), + ); + } + + await db.close(); + } catch (e) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Error registering for camp: $e")), + ); + } + } + + void _showAddCampForm() { + Navigator.of(context) + .push(MaterialPageRoute(builder: (context) => AddCampForm())); + } + + @override + void dispose() { + _tabController.dispose(); + super.dispose(); + } + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text("Camps"), + bottom: TabBar( + controller: _tabController, + tabs: [ + Tab(text: "Upcoming"), + Tab(text: "Past"), + Tab(text: "Registered"), + ], + ), + actions:[ + IconButton( + icon: Icon(Icons.calendar_month), + onPressed: () { + print("hello"); + Navigator.of(context).push(MaterialPageRoute(builder: (context) => CalendarPage())); + }, + ), + ], + automaticallyImplyLeading: false, + ), + body: _currentPosition == null + ? Center(child: CircularProgressIndicator()) + : _isLoading + ? Center(child: CircularProgressIndicator()) + : TabBarView( + controller: _tabController, + children: [ + _buildCampList(_upcomingCamps), + _buildCampList(_pastCamps), + _buildCampList(_registeredCamps), + ], + ), + floatingActionButton: FloatingActionButton( + onPressed: _showAddCampForm, + child: Icon(Icons.add), + ), + ); + } + + Widget _buildCampList(List> camps) { + return ListView( + padding: EdgeInsets.all(15), + children: camps.isEmpty + ? [Center(child: Text("No camps available."))] + : camps.map((camp) => _buildCampCard(camp)).toList(), + ); + } + + Widget _buildCampCard(Map camp) { + return Card( + margin: EdgeInsets.symmetric(vertical: 10), + child: Padding( + padding: EdgeInsets.all(15), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + camp['campName'] ?? 'No Name', + style: TextStyle(fontWeight: FontWeight.bold, fontSize: 18), + ), + SizedBox(height: 8), + Text("Date: ${camp['date'] ?? 'Unknown'}"), + Text("Time: ${camp['time'] ?? 'Unknown'}"), + ElevatedButton( + onPressed: () { + _showCampDetailsDialog(camp); + }, + child: Text("View Details"), + ), + ], + ), + ), + ); + } +} + +class AddCampForm extends StatefulWidget { + @override + _AddCampFormState createState() => _AddCampFormState(); +} + +class _AddCampFormState extends State { + final _formKey = GlobalKey(); + String _name = ''; + String _organizer = ''; + String _description = ''; + String _address = ''; + String _location = ''; + DateTime? _selectedDate; + TimeOfDay? _selectedTime; + double? _latitude=0; + double? _longitude=0; + + @override + void initState() { + super.initState(); + _selectLocation(); // Automatically trigger location selection when the page opens + } + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text("Add Blood Donation Camp"), + ), + body: Padding( + padding: const EdgeInsets.all(16.0), + child: Form( + key: _formKey, + child: SingleChildScrollView( + child: Column( + children: [ + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: 'Camp Name'), + validator: (value) { + if (value == null || value.isEmpty) { + return 'Please enter camp name'; + } + return null; + }, + onSaved: (value) { + _name = value!; + }, + ), + SizedBox(height: 10), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: 'Organizer Name', + ), + validator: (value) { + if (value == null || value.isEmpty) { + return 'Please enter organizer name'; + } + return null; + }, + onSaved: (value) { + _organizer = value!; + }, + ), + SizedBox(height: 10), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: 'Description'), + maxLines: 3, + validator: (value) { + if (value == null || value.isEmpty) { + return 'Please enter a description'; + } + return null; + }, + onSaved: (value) { + _description = value!; + }, + ), + SizedBox(height: 10), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: 'Address'), + validator: (value) { + if (value == null || value.isEmpty) { + return 'Please enter address'; + } + return null; + }, + onSaved: (value) { + _address = value!; + }, + ), + SizedBox(height: 10), + // Date picker with ListTile + ListTile( + title: Text( + _selectedDate == null + ? 'Select Date' + : 'Date: ${DateFormat('yyyy-MM-dd').format(_selectedDate!)}', + style: TextStyle(fontSize: 16), + ), + leading: Icon(Icons.calendar_today), + onTap: _selectDate, + ), + // Time picker with ListTile + ListTile( + title: Text( + _selectedTime == null + ? 'Select Time' + : 'Time: ${_selectedTime!.format(context)}', + style: TextStyle(fontSize: 16), + ), + leading: Icon(Icons.access_time), + onTap: _selectTime, + ), + SizedBox(height: 10), + if (_location.isNotEmpty) ...[ + Text("Location: $_location"), + ], + SizedBox(height: 10), + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(112, 10, 140, 15), + ), + onPressed: _submitForm, + child: Text("Add Camp", style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + ),), + ), + ], + ), + ), + ), + ), + ); + } + + Future _selectLocation() async { + try { + // Check for location permission + LocationPermission permission = await Geolocator.checkPermission(); + if (permission == LocationPermission.denied || + permission == LocationPermission.deniedForever) { + permission = await Geolocator.requestPermission(); + } + + if (permission == LocationPermission.denied || + permission == LocationPermission.deniedForever) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Location permission denied")), + ); + return; + } + + // Get the current location + Position position = await Geolocator.getCurrentPosition( + desiredAccuracy: LocationAccuracy.high); + + // Update the latitude and longitude with the current location + _latitude = position.latitude; + _longitude = position.longitude; + + // Optionally, you can update the location name using reverse geocoding (not implemented here) + _location = 'Current Location: Lat: ${_latitude}, Long: ${_longitude}'; + + setState(() {}); + } catch (e) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Error fetching location: $e")), + ); + } + } + + Future _selectDate() async { + DateTime? pickedDate = await showDatePicker( + context: context, + initialDate: DateTime.now(), + firstDate: DateTime(2020), + lastDate: DateTime(2100), + ); + + if (pickedDate != null && pickedDate != _selectedDate) { + setState(() { + _selectedDate = pickedDate; // Store the selected date + }); + } + } + + // Function to select a time + Future _selectTime() async { + TimeOfDay? pickedTime = await showTimePicker( + context: context, + initialTime: TimeOfDay.now(), + ); + + if (pickedTime != null && pickedTime != _selectedTime) { + setState(() { + _selectedTime = pickedTime; // Store the selected time + }); + } + } + + Future _submitForm() async { + if (_formKey.currentState!.validate()) { + _formKey.currentState!.save(); + + try { + var db = await mongo.Db.create( + 'mongo url'); + await db.open(); + var collection = db.collection('BloodDonationCamps'); + await collection.insert({ + 'campName': _name, + 'organizer': _organizer, + 'description': _description, + 'date': DateFormat('yyyy-MM-dd').format(_selectedDate!), + 'time': _selectedTime!.format(context), + 'address': _address, + 'location': _location, + 'latitude': _latitude, + 'longitude': _longitude, + 'isVerified': false, + 'rating': 0, + }); + + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Camp added successfully.")), + ); + + await db.close(); + Navigator.of(context).pop(); + } catch (e) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text("Error adding camp: $e")), + ); + } + } + } +} diff --git a/lib/views/pages/forgot_password/change-password.dart b/lib/views/pages/forgot_password/change-password.dart new file mode 100644 index 0000000..2fa9a6b --- /dev/null +++ b/lib/views/pages/forgot_password/change-password.dart @@ -0,0 +1,77 @@ +import 'package:flutter/material.dart'; + +import '../login/login.dart'; + +class ChangePasswordScreen extends StatefulWidget { + const ChangePasswordScreen({super.key}); + + @override + State createState() => _ChangePasswordScreenState(); +} + +class _ChangePasswordScreenState extends State { + @override + Widget build(BuildContext context) { + final screen = MediaQuery.of(context).size; + return Scaffold( + body: Padding( + padding: EdgeInsets.only( + left: screen.width * 0.075, + right: screen.width * 0.075, + ), + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + const Text( + 'Email Verification', + style: TextStyle( + fontSize: 25, + fontWeight: FontWeight.bold, + ), + ), + SizedBox(height: screen.height * 0.025), + const Text( + 'Check your mail inbox to change password', + style: TextStyle( + fontSize: 15, + ), + ), + SizedBox(height: screen.height * 0.025), + SizedBox( + width: double.infinity, + child: ElevatedButton( + style:ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(12, 18, 14, 18), + ), + onPressed: () { + Navigator.pushAndRemoveUntil( + context, + MaterialPageRoute( + builder: (context) => const LoginPage(), + ), + (Route route) => false, + ); + }, + child: Text( + 'Back to Login In Page', + style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + fontSize: 16 + ), + ), + ), + ), + ], + ), + ), + ); + } +} + + + diff --git a/lib/views/pages/forgot_password/forgot-password.dart b/lib/views/pages/forgot_password/forgot-password.dart new file mode 100644 index 0000000..1289b09 --- /dev/null +++ b/lib/views/pages/forgot_password/forgot-password.dart @@ -0,0 +1,153 @@ + + +import 'package:donorconnect/views/pages/forgot_password/change-password.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:donorconnect/cubit/forgot_password/forgot_password_cubit.dart'; + +class ForgotPasswordScreen extends StatelessWidget { + ForgotPasswordScreen({super.key}); + + final TextEditingController emailController = TextEditingController(); + + + @override + Widget build(BuildContext context) { + + const style1 = TextStyle( + color: Colors.black, + fontSize: 25, + fontWeight: FontWeight.bold); + return Scaffold( + // backgroundColor: const Color.fromARGB(255, 244, 208, 208), + body: Center( + child: Padding( + padding: const EdgeInsets.all(16.0), + child: BlocConsumer( + listener: (context, state) { + if (state is ForgotPasswordSuccess) { + ScaffoldMessenger.of(context).showSnackBar( + const SnackBar(content: Text('Password reset email sent!')), + ); + } else if (state is ForgotPasswordError) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text(state.errorMessage)), + ); + } + }, + builder: (context, state) { + if (state is ForgotPasswordLoading) { + return const Center(child: CircularProgressIndicator()); + } + + return Column( + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + const Text( + 'Set New Password', + style: style1, + ), + const SizedBox(height: 30), + // // Email text form field + ClipRRect( + borderRadius: BorderRadius.circular(10), + child: TextFormField( + + controller: emailController, + decoration: const InputDecoration( + label:Text('Email'), + hintText: 'Email', + hintStyle: TextStyle( + color: Colors.black, + fontSize: 16, + fontWeight: FontWeight.w500, + ), + focusedErrorBorder: InputBorder.none, + prefixIcon: Icon( + Icons.email, + size: 20, + ), + prefixIconColor: Colors.black, + + focusedBorder: InputBorder.none, + enabledBorder: InputBorder.none, + fillColor: Color.fromARGB(153, 243, 233, 233), + filled: true, + ), + validator: validateEmail, + ), + ), + + const SizedBox(height: 40), + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(90, 16, 90, 20), + ), + onPressed: () { + final email = emailController.text.trim(); + if (email.isNotEmpty) { + context.read().resetPassword(email).then( + (value) => Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const ChangePasswordScreen(), + ), +) + ); + } else { + ScaffoldMessenger.of(context).showSnackBar( + const SnackBar( + content: Text('Please enter a valid email')), + ); + } + }, + child: GestureDetector( + + child: Center( + child: Container( + + decoration: const BoxDecoration( + + borderRadius: + BorderRadius.all(Radius.circular(30)), + ), + child: Center( + child: Text( + 'Send Reset Email', + style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + fontSize: 16 + ), + + ), + ), + ), + ), + ), + ), + ], + ); + }, + ), + ), + ), + ); + } + String? validateEmail(String? formEmail) { + if (formEmail == null || formEmail.isEmpty) { + return 'E-Mail Address is required'; + } + String pattern = r'\w+@\w+\.\w+'; + RegExp regex = RegExp(pattern); + if (!regex.hasMatch(formEmail)) { + return 'Invalid E-Mail Address Format'; + } + return null; + } +} diff --git a/lib/views/pages/learn_about_donation/learn_about_donation.dart b/lib/views/pages/learn_about_donation/learn_about_donation.dart new file mode 100644 index 0000000..d37de99 --- /dev/null +++ b/lib/views/pages/learn_about_donation/learn_about_donation.dart @@ -0,0 +1,203 @@ +import 'package:flutter/material.dart'; +import 'package:url_launcher/url_launcher.dart'; + +class LearnAboutDonation extends StatelessWidget { + const LearnAboutDonation({super.key}); + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: const Text( + "Learn More About Donation", + style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), + ), + backgroundColor: Colors.redAccent, + ), + body: const DonationInfoBody(), + ); + } +} + +class DonationInfoBody extends StatelessWidget { + const DonationInfoBody({super.key}); + + @override + Widget build(BuildContext context) { + return SingleChildScrollView( + child: Column( + children: [ + _buildHeaderSection(), + _buildInfoCardSection(context), + _buildLinksSection(), + ], + ), + ); + } + + Widget _buildHeaderSection() { + return Container( + width: double.infinity, + padding: const EdgeInsets.all(16.0), + decoration: const BoxDecoration( + gradient: LinearGradient( + colors: [Colors.redAccent, Colors.pinkAccent], + begin: Alignment.topLeft, + end: Alignment.bottomRight, + ), + ), + child: const Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + "Why Donate Blood or Platelets?", + style: TextStyle( + fontSize: 24.0, + fontWeight: FontWeight.bold, + color: Colors.white, + ), + ), + SizedBox(height: 8.0), + Text( + "Your donation can save lives, provide critical help during emergencies, and support medical treatments.", + style: TextStyle(fontSize: 16.0, color: Colors.white), + ), + ], + ), + ); + } + + Widget _buildInfoCardSection(BuildContext context) { + return Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + children: [ + _buildInfoCard( + title: "Humanitarian Benefits", + content: + "Donating blood helps save lives during emergencies, surgeries, and treatments. Platelets are vital for cancer patients, trauma victims, and those with chronic illnesses.", + icon: Icons.favorite, + ), + const SizedBox(height: 12), + _buildInfoCard( + title: "Best Practices for Donation", + content: + "Stay hydrated, eat a healthy meal before donating, and avoid alcohol. After donating, rest, drink fluids, and avoid strenuous activity.", + icon: Icons.local_hospital, + ), + const SizedBox(height: 12), + _buildInfoCard( + title: "Precautions & Cautions", + content: + "Ensure you meet donation eligibility criteria. After donating, rest and avoid lifting heavy objects. Seek medical advice if you feel unwell post-donation.", + icon: Icons.warning, + ), + ], + ), + ); + } + + Widget _buildLinksSection() { + return Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + const Text( + "Learn More", + style: TextStyle(fontSize: 20.0, fontWeight: FontWeight.bold), + ), + const SizedBox(height: 8.0), + _buildLinkItem( + title: "E-RaktKosh: India's Online Blood Bank", + url: "https://eraktkosh.mohfw.gov.in/BLDAHIMS/bloodbank/about.cnt", + ), + _buildLinkItem( + title: "Post-donation advice to blood donors", + url: "https://www.ncbi.nlm.nih.gov/books/NBK310568/", + ), + _buildLinkItem( + title: "American Red Cross: Blood Donation", + url: "https://www.redcross.org/give-blood.html", + ), + _buildLinkItem( + title: "WHO Guidelines on Blood Donation", + url: + "https://www.who.int/news-room/fact-sheets/detail/blood-safety-and-availability", + ), + _buildLinkItem( + title: "National Blood Transfusion Council (NBTC) India", + url: "http://nbtc.naco.gov.in/page/aboutus/", + ), + _buildLinkItem( + title: "NHS Blood and Transplant", + url: "https://www.blood.co.uk", + ), + ], + ), + ); + } + + Widget _buildInfoCard( + {required String title, + required String content, + required IconData icon}) { + return Card( + elevation: 5, + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(12)), + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Row( + children: [ + Icon(icon, size: 40, color: Colors.redAccent), + const SizedBox(width: 16), + Expanded( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + title, + style: const TextStyle( + fontSize: 18.0, fontWeight: FontWeight.bold), + ), + const SizedBox(height: 8.0), + Text( + content, + style: const TextStyle(fontSize: 16.0), + ), + ], + ), + ), + ], + ), + ), + ); + } + + Widget _buildLinkItem({required String title, required String url}) { + Uri uri = Uri.parse(url); + return GestureDetector( + onTap: () async { + if (await canLaunchUrl(uri)) { + await launchUrl(uri); + } + }, + child: Padding( + padding: const EdgeInsets.symmetric(vertical: 4.0), + child: Row( + children: [ + const Icon(Icons.link, color: Colors.blueAccent), + const SizedBox(width: 8.0), + Expanded( + child: Text( + title, + style: + const TextStyle(fontSize: 15.0, color: Colors.blueAccent), + ), + ), + ], + ), + ), + ); + } +} diff --git a/lib/views/pages/locate_blood_banks/locate_blood_banks.dart b/lib/views/pages/locate_blood_banks/locate_blood_banks.dart new file mode 100644 index 0000000..476d069 --- /dev/null +++ b/lib/views/pages/locate_blood_banks/locate_blood_banks.dart @@ -0,0 +1,143 @@ +import 'package:donorconnect/cubit/locate_blood_banks/locate_blood_banks_cubit.dart'; +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +class LocateBloodBanks extends StatefulWidget { + const LocateBloodBanks({super.key}); + + @override + State createState() => _LocateBloodBanksState(); +} + +class _LocateBloodBanksState extends State { + TextEditingController cityController = TextEditingController(); + TextEditingController districtController = TextEditingController(); + TextEditingController stateController = TextEditingController(); + + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + // Fetch data when the page is built + context.read().fetchBloodBanks(); + + return Scaffold( + appBar: AppBar( + title: Text(_text.locate_blood_bank), + ), + body: Column( + children: [ + Padding( + padding: const EdgeInsets.all(8.0), + child: Row( + children: [ + Expanded( + child: TextField( + controller: cityController, + decoration: InputDecoration(labelText: _text.city), + onChanged: (value) => _filterBloodBanks(), + ), + ), + const SizedBox(width: 10), + Expanded( + child: TextField( + controller: districtController, + decoration: InputDecoration(labelText: _text.district), + onChanged: (value) => _filterBloodBanks(), + ), + ), + const SizedBox(width: 10), + Expanded( + child: TextField( + controller: stateController, + decoration: InputDecoration(labelText: _text.state), + onChanged: (value) => _filterBloodBanks(), + ), + ), + ], + ), + ), + Expanded( + child: BlocBuilder( + builder: (context, state) { + if (state is LocateBloodBanksLoading) { + return const Center(child: CircularProgressIndicator()); + } else if (state is LocateBloodBanksLoaded || + state is LocateBloodBanksFiltered) { + final bloodBanks = state is LocateBloodBanksLoaded + ? state.bloodBanks + : (state as LocateBloodBanksFiltered).filteredBloodBanks; + + return ListView.builder( + itemCount: bloodBanks.length, + itemBuilder: (context, index) { + final bloodBank = bloodBanks[index]; + return Card( + margin: const EdgeInsets.all(10), + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + bloodBank['_blood_bank_name'] ?? 'N/A', + style: const TextStyle( + fontSize: 18, fontWeight: FontWeight.bold), + ), + const SizedBox(height: 8), + Text( + '${_text.state}: ${bloodBank['_state'] ?? 'N/A'}'), + Text( + '${_text.district}: ${bloodBank['_district'] ?? 'N/A'}'), + Text( + '${_text.city}: ${bloodBank['_city'] ?? 'N/A'}'), + Text( + '${_text.contact}: ${bloodBank['_contact_no'] ?? 'N/A'}'), + Text( + '${_text.email}: ${bloodBank['_email'] ?? 'N/A'}'), + Text( + '${_text.nodal_officer}: ${bloodBank['_nodal_officer_'] ?? 'N/A'}'), + Text( + '${_text.contact_nodal_officer}: ${bloodBank['_mobile_nodal_officer'] ?? 'N/A'}'), + Text( + '${_text.category}: ${bloodBank['_category'] ?? 'N/A'}'), + ], + ), + ), + ); + }, + ); + } else if (state is LocateBloodBanksError) { + return Center(child: Text('Error: ${state.error}')); + } else { + return Center(child: Text(_text.no_data_available)); + } + }, + ), + ), + ], + ), + ); + } + + // Call the filter function in Cubit + void _filterBloodBanks() { + final city = cityController.text; + final district = districtController.text; + final state = stateController.text; + + context.read().filterBloodBanks( + city: city.isEmpty ? null : city, + district: district.isEmpty ? null : district, + state: state.isEmpty ? null : state, + ); + } + + @override + void dispose() { + cityController.dispose(); + districtController.dispose(); + stateController.dispose(); + super.dispose(); + } +} diff --git a/lib/views/pages/login/login.dart b/lib/views/pages/login/login.dart new file mode 100644 index 0000000..c00425f --- /dev/null +++ b/lib/views/pages/login/login.dart @@ -0,0 +1,287 @@ +import 'package:donorconnect/Utils/show_snackbar.dart'; +import 'package:donorconnect/cubit/auth/auth_cubit.dart'; +import 'package:donorconnect/cubit/auth/auth_state.dart'; + +import 'package:donorconnect/language/helper/language_extention.dart'; + +import 'package:donorconnect/views/pages/main_home/homepage.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:shared_preferences/shared_preferences.dart'; + +import '../../../Utils/Textbox.dart'; +import '../../../cubit/forgot_password/forgot_password_cubit.dart'; +import '../forgot_password/forgot-password.dart'; +import '../register/signup.dart'; + +class LoginPage extends StatefulWidget { + const LoginPage({super.key}); + + @override + State createState() => _LoginPageState(); +} + +class _LoginPageState extends State { + // Controllers + TextEditingController emailController = TextEditingController(); + TextEditingController passwordController = TextEditingController(); + +//variable to control password visibility + bool _isPasswordVisible = false; + // VALIDATION + bool _isValidate = false; + late SharedPreferences prefs; + + @override + void initState() { + super.initState(); + initSharedPref(); + } + + Future initSharedPref() async { + prefs = await SharedPreferences.getInstance(); + } + + Future loginUser() async { + if (emailController.text.isNotEmpty && passwordController.text.isNotEmpty) { + context + .read() + .loginUser(emailController.text, passwordController.text); + } else { + showSnackBar( + context, + context.localizedString.please_enter_your_email_and_password, + ); + setState(() { + _isValidate = true; + }); + } + } + + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + var screenWidth = MediaQuery.of(context).size.width; + var screenHeight = MediaQuery.of(context).size.height; + + const style = TextStyle( + color: Colors.black, fontSize: 40, fontWeight: FontWeight.w600); + + const style1 = TextStyle( + color: Color.fromARGB(255, 18, 79, 43), + fontSize: 20, + fontWeight: FontWeight.w400); + + return Scaffold( + resizeToAvoidBottomInset: false, + body: BlocConsumer( + listener: (context, state) { + if (state is Authenticated) { + Navigator.pushReplacement( + context, + PageRouteBuilder( + pageBuilder: (context, animation, secondaryAnimation) => + HomePage( + email: emailController.text, + name: state.user.name, + ), + transitionsBuilder: + (context, animation, secondaryAnimation, child) { + return FadeTransition( + opacity: animation, + child: child, + ); + }, + transitionDuration: const Duration( + milliseconds: 900), // Adjust duration as needed + ), + ); + } + if (state is AuthError) { + showSnackBar(context, state.message); + } + }, + builder: (context, state) { + if (state is AuthLoading) { + return const Center( + child: CircularProgressIndicator(), + ); + } + return Stack( + children: [ + // BACKGROUND IMAGE + Image.asset( + 'assets/images/login.jpg', + width: double.infinity, + height: 670, + fit: BoxFit.cover, + ), + + // WELCOME TEXT + SingleChildScrollView( + child: Padding( + padding: EdgeInsets.only( + top: screenHeight * 0.34, + left: screenHeight * 0.03, + right: screenHeight * 0.03), + child: Column( + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Text(_text.welcome_back, style: style), + Text(_text.log_in_to_your_account, style: style1), + SizedBox( + height: screenHeight * 0.03, + ), + + // Name + Column( + children: [ + Textbox( + controller: emailController, + obscureText: false, + icons: Icons.email, + name: _text.email, + errormsg: _isValidate + ? _text.email_field_error_text + : null, + ), + + // PASSWORD + SizedBox( + height: screenHeight * 0.02, + ), + Textbox( + controller: passwordController, + obscureText: !_isPasswordVisible, + icons: Icons.lock, + name: _text.password, + errormsg: + _isValidate ? _text.password_error_text : null, + suffixIcon: IconButton( + icon: Icon( + _isPasswordVisible + ? Icons.visibility + : Icons.visibility_off, + ), + onPressed: () { + setState(() { + _isPasswordVisible = !_isPasswordVisible; + }); + }, + ), + ), + ], + ), + + // FORGOT PASSWORD BUTTON + Padding( + padding: EdgeInsets.only(left: screenWidth * 0.45), + child: TextButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => BlocProvider( + create: (context) => ForgotPasswordCubit( + FirebaseAuth.instance), + child: ForgotPasswordScreen(), + ), + ), + ); + }, + child: Text( + _text.forget_password, + style: TextStyle( + color: Color(0xff092414), + fontSize: 16, + fontWeight: FontWeight.w500), + ), + ), + ), + + // LOGIN BUTTON + SizedBox( + height: screenHeight * 0.12, + ), + GestureDetector( + onTap: loginUser, + child: Center( + child: Container( + height: screenHeight * 0.06, + width: screenWidth * 0.85, + decoration: BoxDecoration( + color: Colors.green.shade900, + borderRadius: + const BorderRadius.all(Radius.circular(30)), + ), + child: Center( + child: Text( + _text.login, + style: TextStyle( + color: Colors.white, + fontSize: 22, + fontWeight: FontWeight.w500), + ), + ), + ), + ), + ), + + //Google Login + SizedBox( + height: screenHeight * 0.02, + ), + Container( + height: 50, + alignment: Alignment.center, + child: IconButton( + icon: Image.asset('assets/images/google.png'), + iconSize: 50, + onPressed: () { + context.read().signInWithGoogle(); + }, + ), + ), + // FINAL TEXT + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text( + _text.do_not_have_account, + style: TextStyle( + color: Colors.black54, + fontSize: 16, + fontWeight: FontWeight.w400), + ), + + // SIGNUP BUTTON + TextButton( + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const Signuppage(), + )); + }, + child: Text( + _text.signup, + style: TextStyle( + color: Color(0xff092414), + fontSize: 16, + fontWeight: FontWeight.w500), + ), + ) + ], + ) + ], + ), + ), + ) + ], + ); + }, + ), + ); + } +} diff --git a/lib/views/pages/main_home/bottom_nav.dart b/lib/views/pages/main_home/bottom_nav.dart new file mode 100644 index 0000000..81c4623 --- /dev/null +++ b/lib/views/pages/main_home/bottom_nav.dart @@ -0,0 +1,20 @@ +import 'package:donorconnect/views/pages/main_home/home_pages/home_screen.dart'; +import 'package:donorconnect/views/pages/profile/profile_screen.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; + +class NavigationController extends GetxController { + final Rx selectedIndex = 0.obs; + final String name; + final String email; + NavigationController(this.name, this.email); + + List getScreens() { + return [ + const HomeScreen(), + const HomeScreen(), + const HomeScreen(), + ProfileScreen(name: name,userId: email,), + ]; + } +} diff --git a/lib/views/pages/main_home/chatbot.dart b/lib/views/pages/main_home/chatbot.dart new file mode 100644 index 0000000..4876267 --- /dev/null +++ b/lib/views/pages/main_home/chatbot.dart @@ -0,0 +1,201 @@ +import 'dart:convert'; +import 'dart:io'; + +import 'package:flutter/material.dart'; +import 'package:flutter_dotenv/flutter_dotenv.dart'; +import 'package:http/http.dart' as http; +import 'package:google_generative_ai/google_generative_ai.dart'; + +// Access your API key as an environment variable (see "Set up your API key" above) + +class ChatBot extends StatefulWidget { + const ChatBot({super.key}); + + @override + State createState() => _ChatBotState(); +} + +class _ChatBotState extends State { + // final apiKey = dotenv.env['GEMINI_API'] ?? ""; + final apiKey="Your Gemini API key"; + final TextEditingController _chatController = TextEditingController(); + final ScrollController _scrollController = ScrollController(); + List> _chatHistory = []; + late final GenerativeModel _model; + late final ChatSession _chat; + @override + void initState() { + _model = GenerativeModel(model: 'gemini-pro', apiKey: apiKey); + _chat = _model.startChat(); + _chat.sendMessage(Content.text("This is a organ and blood blood donation application.This application includes fetches the blood and organ donors and the blood banks in the city. Guide me in case of any queries.")); + super.initState(); + } + void getAnswer() async { + final model = GenerativeModel( + model: 'gemini-1.5-flash', + apiKey: apiKey, + ); + print(_chatController.text); + final prompt = _chatController.text; + + // final response = await model.generateContent([Content.text(prompt)]); + final response = await _chat.sendMessage(Content.text(prompt)); + print(response); + setState(() { + _chatHistory.add({ + "time": DateTime.now(), + // "message": json.decode(response.body)["candidates"][0]["content"] + // ["parts"][0]["text"], + "message": response.text, + "isSender": false, + }); + }); + } + + + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: const Text( + "Chat", + style: TextStyle(fontWeight: FontWeight.bold), + ), + ), + body: Stack( + children: [ + Container( + //get max height + height: MediaQuery.of(context).size.height - 160, + child: ListView.builder( + itemCount: _chatHistory.length, + shrinkWrap: false, + controller: _scrollController, + padding: const EdgeInsets.only(top: 10, bottom: 10), + physics: const BouncingScrollPhysics(), + itemBuilder: (context, index) { + return Container( + padding: + EdgeInsets.only(left: 14, right: 14, top: 10, bottom: 10), + child: Align( + alignment: (_chatHistory[index]["isSender"] + ? Alignment.topRight + : Alignment.topLeft), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(20), + boxShadow: [ + BoxShadow( + color: Colors.grey.withOpacity(0.5), + spreadRadius: 2, + blurRadius: 5, + offset: const Offset(0, 3), + ), + ], + color: (_chatHistory[index]["isSender"] + ? Color(0xFFF69170) + : Colors.white), + ), + padding: EdgeInsets.all(16), + child: Text(_chatHistory[index]["message"].toString(), + style: TextStyle( + fontSize: 15, + color: _chatHistory[index]["isSender"] + ? Colors.white + : Colors.black)), + ), + ), + ); + }, + ), + ), + Align( + alignment: Alignment.bottomCenter, + child: Container( + padding: + const EdgeInsets.symmetric(horizontal: 16.0, vertical: 8.0), + height: 60, + width: double.infinity, + color: Colors.white, + child: Row( + children: [ + Expanded( + child: Container( + decoration: const BoxDecoration( + border: Border.fromBorderSide( + BorderSide(color: Colors.grey)), + borderRadius: BorderRadius.all(Radius.circular(50.0)), + ), + child: Padding( + padding: const EdgeInsets.all(4.0), + child: TextField( + decoration: const InputDecoration( + hintText: "Type a message", + border: InputBorder.none, + contentPadding: EdgeInsets.all(8.0), + ), + controller: _chatController, + ), + ), + ), + ), + const SizedBox( + width: 4.0, + ), + MaterialButton( + onPressed: () { + setState(() { + if (_chatController.text.isNotEmpty) { + _chatHistory.add({ + "time": DateTime.now(), + "message": _chatController.text, + "isSender": true, + }); + _scrollController.jumpTo( + _scrollController.position.maxScrollExtent, + ); + getAnswer(); + } + _scrollController.jumpTo( + _scrollController.position.maxScrollExtent, + ); + }); + + _chatController.clear(); + }, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(80.0)), + padding: const EdgeInsets.all(0.0), + child: Ink( + decoration: const BoxDecoration( + gradient: LinearGradient( + begin: Alignment.topLeft, + end: Alignment.bottomRight, + colors: [ + Color(0xFFF69170), + Color(0xFF7D96E6), + ]), + borderRadius: BorderRadius.all(Radius.circular(50.0)), + ), + child: Container( + constraints: const BoxConstraints( + minWidth: 88.0, + minHeight: + 36.0), // min sizes for Material buttons + alignment: Alignment.center, + child: const Icon( + Icons.send, + color: Colors.white, + )), + ), + ) + ], + ), + ), + ) + ], + ), + ); + } +} diff --git a/lib/views/pages/main_home/home_pages/home_screen.dart b/lib/views/pages/main_home/home_pages/home_screen.dart new file mode 100644 index 0000000..ffe191b --- /dev/null +++ b/lib/views/pages/main_home/home_pages/home_screen.dart @@ -0,0 +1,133 @@ +// import 'package:donorconnect/cubit/auth/auth_cubit.dart'; +// import 'package:donorconnect/language/cubit/language_cubit.dart'; +import 'package:donorconnect/language/helper/langauge_popup.dart'; +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:donorconnect/views/common_widgets/home_card.dart'; +import 'package:donorconnect/views/common_widgets/home_card_form.dart'; +import 'package:donorconnect/views/pages/Required/required_screen.dart'; +import 'package:donorconnect/views/pages/learn_about_donation/learn_about_donation.dart'; +import 'package:donorconnect/views/pages/locate_blood_banks/locate_blood_banks.dart'; +import 'package:donorconnect/views/pages/main_home/chatbot.dart'; +import 'package:flutter/material.dart'; +// import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:google_fonts/google_fonts.dart'; +// import 'package:flutter_gen/gen_l10n/app_localizations.dart'; + +class HomeScreen extends StatefulWidget { + const HomeScreen({super.key}); + + @override + State createState() => _HomeScreenState(); +} + +class _HomeScreenState extends State { + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + var height = MediaQuery.of(context).size.height; + // var width = MediaQuery.of(context).size.width; + return Scaffold( + appBar: AppBar( + title: Padding( + padding: const EdgeInsets.only( + top: 16.0, + ), + child: Text( + _text.how_can_we_help, + maxLines: 3, + style: GoogleFonts.montserrat( + fontSize: 20, + fontWeight: FontWeight.w700, + letterSpacing: 1, + ), + ), + ), + actions: const [ + // IconButton( + // onPressed: () { + // LangaugePopup(); + // }, + // icon: const Icon(Icons.language_rounded)) + + Padding( + padding: EdgeInsets.only(left: 16.0, right: 16.0), + child: LanguagePopup(), + ) + ], + toolbarHeight: 65, + toolbarOpacity: 0.8, + automaticallyImplyLeading: false, + surfaceTintColor: Colors.transparent, + ), + body: SafeArea( + child: SingleChildScrollView( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + HomeCardConst( + title: _text.donate, + col: const Color.fromARGB(255, 255, 122, 122), + onPressed: () {}, + ), + HomeCardConst( + title: _text.required, + col: const Color.fromARGB(255, 167, 165, 252), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (ctx)=> RequiredScreen())); + }, + ), + ], + ), + HomeCard( + title: _text.locate_nearby_bloodbank, + description: _text.find_nearby_bloodbank, + button: "Search", + image: 'assets/images/home_image1.png', + icon: const Icon( + Icons.search, + size: 23, + ), + onPressed: (){}, + + ), + HomeCard( + title: _text.learn_about_donating, + description: _text.learn_more_about_donating, + button: "Learn", + image: 'assets/images/home_image2.png', + icon: const Icon(Icons.menu_book_outlined), + onPressed: () { + Navigator.push( + context, + PageRouteBuilder( + pageBuilder: (context, animation, secondaryAnimation) => + const LearnAboutDonation(), + transitionsBuilder: + (context, animation, secondaryAnimation, child) { + return FadeTransition( + opacity: animation, + child: child, + ); + }, + transitionDuration: const Duration( + milliseconds: 900), // Adjust duration as needed + ), + ); + }, + ), + SizedBox(height: height * 0.1) + ], + ), + ), + ), + floatingActionButton: FloatingActionButton(onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => ChatBot())); + }, + child: const Icon(Icons.chat), + ), + ); + } +} diff --git a/lib/views/pages/main_home/homepage.dart b/lib/views/pages/main_home/homepage.dart new file mode 100644 index 0000000..cd8f3de --- /dev/null +++ b/lib/views/pages/main_home/homepage.dart @@ -0,0 +1,119 @@ +import 'package:custom_navigation_bar/custom_navigation_bar.dart'; +import 'package:donorconnect/views/pages/camps/campsPage.dart'; +import 'package:donorconnect/views/pages/search/search_screen.dart'; +import 'package:flutter/material.dart'; +import '../profile/profile_screen.dart'; +import 'home_pages/home_screen.dart'; +import 'package:donorconnect/language/helper/language_extention.dart'; + +class HomePage extends StatefulWidget { + final token; + final String? name; + final String? email; + + const HomePage({super.key, this.token, this.name, this.email}); + + @override + State createState() => _HomePageState(); +} + +class _HomePageState extends State { + // @override + // void dispose() { + // Get.delete(); + // super.dispose(); + // } + // late ScrollController controller; + // + /// variables + int _currentIndex = 0; + // + // @override + // void initState() { + // super.initState(); + // controller = ScrollController(); + // } + // + // @override + // void dispose() { + // controller.dispose; + // super.dispose(); + // } + + @override + Widget build(BuildContext context) { + final PageController pageController = PageController(initialPage: 0); + final _text = context.localizedString; + final pages = [ + const HomeScreen(), + const SearchScreen(), + const Camps(), + ProfileScreen( + name: widget.name ?? "No Name", + userId: widget.email!, + ), + ]; + + return Scaffold( + bottomNavigationBar: CustomNavigationBar( + scaleFactor: 0.2, + strokeColor: Colors.blueGrey, + iconSize: 24, + elevation: 0, + backgroundColor: Colors.transparent, + selectedColor: Colors.blue, + unSelectedColor: Colors.blue.withOpacity(0.4), + isFloating: false, + currentIndex: _currentIndex, + scaleCurve: Curves.bounceOut, + bubbleCurve: Curves.easeInOut, + onTap: (int newIndex) { + setState(() { + _currentIndex = newIndex; + pageController.animateToPage(newIndex, + duration: const Duration(milliseconds: 500), + curve: Curves.fastOutSlowIn); + }); + }, + items: [ + CustomNavigationBarItem( + icon: const Icon(Icons.home), + title: Text( + _text.home, + style: const TextStyle(fontSize: 12), + ), + ), + CustomNavigationBarItem( + icon: const Icon(Icons.search), + title: Text( + _text.search, + style: const TextStyle(fontSize: 12), + )), + CustomNavigationBarItem( + icon: const Icon(Icons.event), + title: Text( + _text.camps, + style: const TextStyle(fontSize: 12), + )), + CustomNavigationBarItem( + icon: const Icon(Icons.person), + title: Text( + _text.profile, + style: const TextStyle(fontSize: 12), + )), + ], + ), + body: PageView.builder( + controller: pageController, + onPageChanged: (int newIndex) { + setState(() { + _currentIndex = newIndex; + }); + }, + itemCount: 4, + itemBuilder: (BuildContext context, int index) { + return pages[index]; + }), + ); + } +} diff --git a/lib/views/pages/onboarding/onboarding.dart b/lib/views/pages/onboarding/onboarding.dart new file mode 100644 index 0000000..1593a2c --- /dev/null +++ b/lib/views/pages/onboarding/onboarding.dart @@ -0,0 +1,57 @@ +import 'package:donorconnect/views/pages/onboarding/widgets/onboarding_dot_navigation.dart'; +import 'package:donorconnect/views/pages/onboarding/widgets/onboarding_next_button.dart'; +import 'package:donorconnect/views/pages/onboarding/widgets/onboarding_skip.dart'; +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; +import '../../../Utils/constants/images_string.dart'; +import '../../../Utils/constants/text_string.dart'; +import '../../controllers/onboarding/onboarding_controller.dart'; +import 'widgets/onboarding_page.dart'; + + +class OnBoardingScreen extends StatelessWidget { + const OnBoardingScreen({super.key}); + + @override + Widget build(BuildContext context) { + final controller = Get.put(OnBoardingController()); + + return Scaffold( + body: Stack( + children: [ + /// Horizontal Scrollable Pages + PageView( + controller: controller.pageController, + onPageChanged: controller.updatePageIndicator, + children: const [ + OnBoardingPage( + image: TImages.onBoardingImage1, + title: TTexts.onBoardingTitle1, + subtitle:TTexts.onBoardingSubTitle1, + ), + OnBoardingPage( + image: TImages.onBoardingImage2, + title: TTexts.onBoardingTitle2, + subtitle:TTexts.onBoardingSubTitle2, + ), + OnBoardingPage( + image: TImages.onBoardingImage3, + title: TTexts.onBoardingTitle3, + subtitle:TTexts.onBoardingSubTitle3, + ), + ], + ), + + /// Skip Button + const OnBoardingSkip(), + + /// Dot Navigation SmoothPageIndicator + const OnBoardingDotNavigation(), + + /// Circular Button + const OnBoardingNextButton(), + ], + ), + ); + } +} diff --git a/lib/views/pages/onboarding/widgets/onboarding_dot_navigation.dart b/lib/views/pages/onboarding/widgets/onboarding_dot_navigation.dart new file mode 100644 index 0000000..aa73181 --- /dev/null +++ b/lib/views/pages/onboarding/widgets/onboarding_dot_navigation.dart @@ -0,0 +1,26 @@ +import 'package:flutter/material.dart'; +import 'package:smooth_page_indicator/smooth_page_indicator.dart'; +import '../../../controllers/onboarding/onboarding_controller.dart'; + +class OnBoardingDotNavigation extends StatelessWidget { + const OnBoardingDotNavigation({ + super.key, + }); + + @override + Widget build(BuildContext context) { + final controller = OnBoardingController.instance; + + return Positioned( + bottom: kBottomNavigationBarHeight + 25, + left: 154, + child: SmoothPageIndicator( + count: 3, + controller: controller.pageController, + onDotClicked: controller.dotNavigationClick, + effect: const ExpandingDotsEffect( + activeDotColor: Color.fromARGB(255, 194, 4, 4), + dotHeight: 6), + ),); + } + } \ No newline at end of file diff --git a/lib/views/pages/onboarding/widgets/onboarding_next_button.dart b/lib/views/pages/onboarding/widgets/onboarding_next_button.dart new file mode 100644 index 0000000..70e8b1c --- /dev/null +++ b/lib/views/pages/onboarding/widgets/onboarding_next_button.dart @@ -0,0 +1,23 @@ +import 'package:flutter/material.dart'; +import 'package:iconsax/iconsax.dart'; +import '../../../controllers/onboarding/onboarding_controller.dart'; + +class OnBoardingNextButton extends StatelessWidget { + const OnBoardingNextButton({ + super.key, + }); + + @override + Widget build(BuildContext context) { + + return Positioned( + right: 24, + bottom: kBottomNavigationBarHeight, + child: ElevatedButton( + onPressed:() => OnBoardingController.instance.nextPage(), + style: ElevatedButton.styleFrom(shape: const CircleBorder(), backgroundColor: Color.fromARGB(255, 194, 4, 4),) , + child: const Icon(Iconsax.arrow_right_3,color: Colors.white,) , + ) + ); + } +} diff --git a/lib/views/pages/onboarding/widgets/onboarding_page.dart b/lib/views/pages/onboarding/widgets/onboarding_page.dart new file mode 100644 index 0000000..e1e2495 --- /dev/null +++ b/lib/views/pages/onboarding/widgets/onboarding_page.dart @@ -0,0 +1,47 @@ +import 'package:flutter/material.dart'; +import 'package:get/get.dart'; + + +class OnBoardingPage extends StatelessWidget { + const OnBoardingPage({ + super.key, + required this.image, + required this.title, + required this.subtitle, + }); + + final String image, title, subtitle; + + @override + Widget build(BuildContext context) { + return Padding( + padding: const EdgeInsets.all(24), + child: Column( + children: [ + Image( + width:double.infinity, + height: 500, + image: AssetImage(image), + ), + Text( + title, + style: Theme + .of(context) + .textTheme + .headlineMedium, + textAlign: TextAlign.center, + ), + const SizedBox(height: 24), + Text( + subtitle, + style: Theme + .of(context) + .textTheme + .bodyMedium, + textAlign: TextAlign.center, + ), + ], + ) + ); + } +} \ No newline at end of file diff --git a/lib/views/pages/onboarding/widgets/onboarding_skip.dart b/lib/views/pages/onboarding/widgets/onboarding_skip.dart new file mode 100644 index 0000000..bebb66e --- /dev/null +++ b/lib/views/pages/onboarding/widgets/onboarding_skip.dart @@ -0,0 +1,25 @@ + +import 'package:flutter/material.dart'; + +import '../../../controllers/onboarding/onboarding_controller.dart'; + +class OnBoardingSkip extends StatelessWidget { + const OnBoardingSkip({ + super.key, + }); + + @override + Widget build(BuildContext context) { + return Positioned( + bottom: 60, + left: 24, + child: TextButton( + onPressed: () => OnBoardingController.instance.skipPage(), + child: Text('Skip', style: TextStyle( + color: Theme.of(context).colorScheme.onSurface, + fontWeight: FontWeight.bold, + fontSize: 16 + ), ), + )); + } +} diff --git a/lib/views/pages/profile/profile_screen.dart b/lib/views/pages/profile/profile_screen.dart new file mode 100644 index 0000000..da1da51 --- /dev/null +++ b/lib/views/pages/profile/profile_screen.dart @@ -0,0 +1,226 @@ +import 'package:donorconnect/cubit/auth/auth_cubit.dart'; +import 'package:donorconnect/cubit/profile/profile_cubit.dart'; +import 'package:donorconnect/cubit/profile/profile_state.dart'; +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:donorconnect/views/common_widgets/toggle_button.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +import '../../../cubit/theme_toggle/theme_cubit.dart'; +import '../../../cubit/theme_toggle/theme_state.dart'; + +class ProfileScreen extends StatefulWidget { + final String name; + final String userId; + const ProfileScreen({super.key, required this.name, required this.userId}); + + @override + State createState() => _ProfileScreenState(); +} + +class _ProfileScreenState extends State { + final _formKey = GlobalKey(); + + @override + void initState() { + super.initState(); + // Load profile data from storage when screen is initialized + loadProfile(); + } + + void loadProfile() async { + await context.read().loadProfile(widget.userId); + } + + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + return Scaffold( + appBar: AppBar( + title: Text(_text.profile), + actions: [ + IconButton( + onPressed: () { + + }, + icon: const Icon( + Icons.logout, + ), + ), + ], + ), + body: BlocBuilder( + builder: (context, state) { + return Padding( + padding: const EdgeInsets.all(16.0), + child: Form( + key: _formKey, + child: ListView( + children: [ + Column( + children: [ + Text( + "ALICE", + style: const TextStyle( + fontSize: 24, + fontWeight: FontWeight.bold, + ), + ), + const SizedBox(height: 4), + Text( + _text.welcome_to_your_profile, + style: TextStyle( + fontSize: 16, + color: Colors.grey[600], + ), + ), + ], + ), + const SizedBox(height: 24), + + // Medical History + TextFormField( + initialValue: state.medicalHistory, + decoration: InputDecoration( + border: OutlineInputBorder( + borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: _text.medical_history, + ), + onChanged: (value) => context + .read() + .updateMedicalHistory(value), + ), + const SizedBox(height: 16), + + // Current Medications + TextFormField( + initialValue: state.currentMedications, + decoration: InputDecoration( + border: OutlineInputBorder( + borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: _text.current_medications, + ), + onChanged: (value) => context + .read() + .updateCurrentMedications(value), + ), + + const SizedBox(height: 16), + + // Allergies + TextFormField( + initialValue: state.allergies, + decoration: InputDecoration( + border: OutlineInputBorder( + borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: _text.allergies, + ), + onChanged: (value) => + context.read().updateAllergies(value), + ), + const SizedBox(height: 16), + + // Blood Type + DropdownButtonFormField( + value: state.bloodType.isEmpty ? null : state.bloodType, + items: const [ + DropdownMenuItem(value: 'A+', child: Text('A+')), + DropdownMenuItem(value: 'A-', child: Text('A-')), + DropdownMenuItem(value: 'B+', child: Text('B+')), + DropdownMenuItem(value: 'B-', child: Text('B-')), + DropdownMenuItem(value: 'AB+', child: Text('AB+')), + DropdownMenuItem(value: 'AB-', child: Text('AB-')), + DropdownMenuItem(value: 'O+', child: Text('O+')), + DropdownMenuItem(value: 'O-', child: Text('O-')), + ], + onChanged: (value) { + context.read().updateBloodType(value ?? ''); + }, + decoration: InputDecoration( + border: OutlineInputBorder( + borderRadius: BorderRadius.all(Radius.circular(9))), + labelText: _text.blood_type, + ), + ), + const SizedBox(height: 16), + + // Organ Donor + SwitchListTile( + title: Text(_text.organ_donor), + value: state.isOrganDonor, + onChanged: (value) { + context + .read() + .updateOrganDonorStatus(value); + }, + ), + + // Blood Donor + SwitchListTile( + title: Text(_text.blood_donor), + value: state.isBloodDonor, + onChanged: (value) { + context + .read() + .updateBloodDonorStatus(value); + }, + ), + const SizedBox(height: 16), + + // Notification Settings + SwitchListTile( + title: Text(_text.enable_donation_notifications), + value: state.notificationsEnabled, + onChanged: (value) { + context.read().toggleNotifications(value); + }, + ), + const SizedBox(height: 16), + // theme-toggle button + BlocBuilder( + builder: (context, themeState) { + final isDarkMode = themeState.themeData.brightness == Brightness.dark; + return ThemeToggleButton( + switchValue: isDarkMode, + ); + }, + ), + + // const SizedBox(height: 24), + // Save Button + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(112, 10, 140, 15), + ), + onPressed: () async { + if (_formKey.currentState!.validate()) { + // Save the profile using userId + await context + .read() + .saveProfile(widget.userId); + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text(_text.profile_saved)), + ); + } + }, + child: Text( + _text.save_profile, + style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + ), + ), + ), + ], + ), + ), + ); + }, + ), + ); + } +} diff --git a/lib/views/pages/register/signup.dart b/lib/views/pages/register/signup.dart new file mode 100644 index 0000000..6bc0691 --- /dev/null +++ b/lib/views/pages/register/signup.dart @@ -0,0 +1,389 @@ +import 'package:donorconnect/Utils/show_snackbar.dart'; +import 'package:donorconnect/cubit/auth/auth_cubit.dart'; +import 'package:donorconnect/cubit/auth/auth_state.dart'; +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:donorconnect/views/pages/main_home/homepage.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; + +import '../../../Utils/Textbox.dart'; + +class Signuppage extends StatefulWidget { + const Signuppage({super.key}); + + @override + State createState() => _SignuppageState(); +} + +class _SignuppageState extends State { + // CONTROLLERS + TextEditingController emailController = TextEditingController(); + TextEditingController numberController = TextEditingController(); + TextEditingController nameController = TextEditingController(); + TextEditingController passwordController = TextEditingController(); + TextEditingController confirmPasswordController = TextEditingController(); + bool? check1 = false, check2 = false; + + bool _isEmailValid = false; + bool _isNameValid = false; + bool _isPhoneValid = false; + bool _isPasswordValid = false; + bool _isConfirmPasswordValid = false; + + //variable to control password visibility + bool _isPasswordVisible =false; + bool _isConfirmPasswordVisible = false; + + bool isValidEmail(String email) { + final RegExp emailRegExp = RegExp( + r'^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$', + ); + return emailRegExp.hasMatch(email); + } + + bool isPhoneValid() { + return numberController.text.isNotEmpty && + (numberController.text.length == 10); + } + + bool validatePassword(String password) { + // Regular expression to validate the password + String pattern = + r'^(?=.*[A-Z])(?=.*[a-z])(?=.*\d)(?=.*[@$!%*?&])[A-Za-z\d@$!%*?&]{8,}$'; + RegExp regex = RegExp(pattern); + + if (password.isEmpty) { + return false; // Password cannot be empty + } else if (!regex.hasMatch(password)) { + return false; // Password doesn't match the pattern + } else { + return true; // Password is valid + } + } + + validate() { + _isEmailValid = + isValidEmail(emailController.text) && emailController.text.isNotEmpty; + _isNameValid = nameController.text.isNotEmpty; + _isPhoneValid = isPhoneValid(); + _isPasswordValid = validatePassword(passwordController.text); + _isConfirmPasswordValid = confirmPasswordController.text.isNotEmpty; + if (_isEmailValid && + _isNameValid && + _isPhoneValid && + _isPasswordValid && + _isConfirmPasswordValid) { + if (passwordController.text == confirmPasswordController.text) { + setState(() { + _isPasswordValid = false; + _isConfirmPasswordValid = false; // Reset validation flag + }); + context.read().registerUser( + email: emailController.text, + password: passwordController.text, + name: nameController.text, + phone: numberController.text, + isOrganDonor: check1 ?? false, + isBloodDonor: check2 ?? false, + ); + } else { + showDialog( + context: context, + builder: (context) { + return AlertDialog( + title: Center( + child: Text( + context.localizedString.password_dont_match, + style: const TextStyle(fontSize: 16, fontWeight: FontWeight.w500), + )), + ); + }); + _isConfirmPasswordValid = true; + } + } else { + setState(() { + if (isValidEmail(emailController.text) == false) { + _isEmailValid = true; + } else { + _isEmailValid = false; + } + // _isEmailValid = true; + if (nameController.text.isNotEmpty == false) { + _isNameValid = true; + } else { + _isNameValid = false; + } + + if (isPhoneValid() == false) { + _isPhoneValid = true; + } else { + _isPhoneValid = false; + } + + if (validatePassword(passwordController.text) == false) { + _isPasswordValid = true; + } else { + _isPasswordValid = false; + _isConfirmPasswordValid = false; + } + + if (passwordController.text != confirmPasswordController.text) { + _isConfirmPasswordValid = true; + } else { + _isConfirmPasswordValid = false; + } + }); + } + } + + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + var screenWidth = MediaQuery.of(context).size.width; + var screenHeight = MediaQuery.of(context).size.height; + + // CONSTANTS + const style = TextStyle( + color: Colors.black, fontSize: 40, fontWeight: FontWeight.w600); + + const style1 = TextStyle( + color: Color.fromARGB(255, 18, 79, 43), + fontSize: 18, + fontWeight: FontWeight.w500); + return Scaffold( + body: BlocConsumer( + listener: (context, state) { + if (state is AuthError) { + showSnackBar(context, state.message); + setState(() { + _isEmailValid = false; + _isNameValid = false; + _isPhoneValid = false; + _isPasswordValid = false; + _isConfirmPasswordValid = false; + }); + } + if (state is Authenticated) { + Navigator.pushReplacement( + context, + PageRouteBuilder( + pageBuilder: (context, animation, secondaryAnimation) => + HomePage( + name: nameController.text, + email: emailController.text.trim(), + ), + transitionsBuilder: + (context, animation, secondaryAnimation, child) { + return FadeTransition( + opacity: animation, + child: child, + ); + }, + transitionDuration: const Duration( + milliseconds: 900), // Adjust duration as needed + ), + ); + } + }, + builder: (context, state) { + if (state is AuthLoading) { + return const Center( + child: CircularProgressIndicator(), + ); + } + return Stack( + children: [ + // BACKGROUND IMAGE + Image.asset( + 'assets/images/signup.jpg', + fit: BoxFit.cover, + height: double.infinity, + width: double.infinity, + ), + // FORM CONTAINER + SizedBox( + height: screenHeight * 0.02, + ), + SingleChildScrollView( + child: Padding( + padding: EdgeInsets.only( + top: screenHeight * 0.03, + left: screenHeight * 0.03, + right: screenHeight * 0.03), + child: Column( + children: [ + // BACK BUTTON TO NAVIGATE BACK TO FRONT PAGE + Align( + alignment: Alignment.topLeft, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + shape: const CircleBorder(), + padding: const EdgeInsets.all(10), + ), + onPressed: () { + Navigator.pop(context); + }, + child: const Icon(Icons.arrow_back), + ), + ), + Text( + _text.register, + style: style, + ), + Text( + _text.create_account, + style: style1, + ), + SizedBox(height: screenHeight * 0.02), + + // EMAIL TEXTBOX + Textbox( + controller: emailController, + obscureText: false, + icons: Icons.mail, + name: _text.email, + errormsg: + _isEmailValid ? _text.email_field_error_text : null, + ), + SizedBox(height: screenHeight * 0.02), + + // FULL NAME TEXTBOX + Textbox( + controller: nameController, + obscureText: false, + icons: Icons.person, + name: _text.full_name, + errormsg: + _isNameValid ? _text.name_field_error_text : null, + ), + SizedBox(height: screenHeight * 0.02), + + // PHONE NUMBER TEXTBOX + Textbox( + controller: numberController, + obscureText: false, + icons: Icons.call, + name: _text.phone_number, + errormsg: _isPhoneValid + ? _text.phone_number_error_text + : null, + ), + SizedBox(height: screenHeight * 0.02), + + // PASSWORD TEXTBOX + Textbox( + controller: passwordController, + obscureText: ! _isPasswordVisible, + icons: Icons.lock, + name: _text.create_password, + errormsg: + _isPasswordValid ? _text.password_error_text : null, + suffixIcon: IconButton( + icon: Icon( + _isPasswordVisible ? Icons.visibility : Icons.visibility_off, + ), + onPressed: () { + setState(() { + _isPasswordVisible = !_isPasswordVisible; + }); + }, + ), + + ), + SizedBox(height: screenHeight * 0.02), + + // CONFIRM PASSWORD + Textbox( + controller: confirmPasswordController, + obscureText: ! _isConfirmPasswordVisible, + icons: Icons.lock, + name: _text.confirm_password, + errormsg: _isConfirmPasswordValid + ? _text.password_dont_match + : null, + suffixIcon: IconButton( + icon: Icon( + _isConfirmPasswordVisible ? Icons.visibility : Icons.visibility_off, + ), + onPressed: () { + setState(() { + _isConfirmPasswordVisible = !_isConfirmPasswordVisible; + }); + }, + ), + ), + + Row( + children: [ + Checkbox( + //checkbox positioned at left + value: check1, + onChanged: (bool? value) { + setState(() { + check1 = value; + }); + }, + ), + Text(_text.availabel_for_organ_donation), + ], + ), + Row( + children: [ + Checkbox( + //checkbox positioned at left + value: check2, + onChanged: (bool? value) { + setState(() { + check2 = value; + }); + }, + ), + Text(_text.avilabel_for_blood_donation), + ], + ), + + SizedBox(height: screenHeight * 0.05), + + InkWell( + onTap: validate, + child: Center( + child: Container( + height: screenHeight * 0.06, + width: screenWidth * 0.85, + decoration: const BoxDecoration( + color: Color.fromARGB(255, 12, 48, 26), + borderRadius: + BorderRadius.all(Radius.circular(30))), + child: Center( + child: Text( + _text.signup, + style: const TextStyle( + color: Colors.white, + fontSize: 22, + fontWeight: FontWeight.w500), + ), + ), + ), + ), + ), + SizedBox(height: screenHeight * 0.01), + + // FINAL TEXT + Text( + " ${_text.by_sign_your_account_you_agree_terms_and} \n ${_text.use_and_the_privacy_notice}", + style: TextStyle( + fontSize: screenHeight * 0.018, + fontWeight: FontWeight.w400, + color: Colors.black87), + ) + ], + ), + ), + ), + ], + ); + }, + ), + ); + } +} diff --git a/lib/views/pages/search/search_screen.dart b/lib/views/pages/search/search_screen.dart new file mode 100644 index 0000000..84ad9db --- /dev/null +++ b/lib/views/pages/search/search_screen.dart @@ -0,0 +1,87 @@ +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:donorconnect/views/common_widgets/home_card.dart'; +import 'package:donorconnect/views/pages/search/widgets/blood_bank_form.dart'; +import 'package:donorconnect/views/pages/search/widgets/blood_donor_form.dart'; +import 'package:flutter/material.dart'; +import 'package:google_fonts/google_fonts.dart'; +class SearchScreen extends StatefulWidget{ + const SearchScreen({super.key}); + + @override + State createState() => _SearchScreenState(); +} + +class _SearchScreenState extends State { + @override + Widget build(BuildContext context) { + final _text = context.localizedString; + return Scaffold( + appBar: AppBar( + title: Padding( + padding: const EdgeInsets.only( + top: 16.0, + ), + child: Text( + _text.locate_nearby_bloodbank, + maxLines: 3, + style: GoogleFonts.montserrat( + fontSize: 20, + fontWeight: FontWeight.w700, + letterSpacing: 1, + ), + ), + ), + + ), + body: SingleChildScrollView( + child: Column( + children: [ + Padding( + padding: EdgeInsets.all(30), + child: Container( + height: 50, + width: double.infinity, + decoration: BoxDecoration( + border: Border.all(color: Colors.black),borderRadius: BorderRadius.all(Radius.circular(19)), + ), + child: Padding( + padding: EdgeInsets.all(9), + child: Row( + children: [ + Icon(Icons.search, color: Colors.grey), + const SizedBox(width: 20), + Text('Search nearby bloodbanks', style: Theme.of(context).textTheme.bodySmall), + ], + ), + ), + ), + ), + SizedBox(height: 15), + HomeCard( + title: 'Blood Bank', + description: 'Search near by blood bank', + button: 'Find', + image: 'assets/images/home_image1.png', + onPressed:(){Navigator.push( + context,MaterialPageRoute( + builder: (ctx)=> const BloodBankForm()) + );} , + icon: Icon(Icons.local_hospital),), + SizedBox(height: 15), + HomeCard( + title: 'Blood Donors', + description: 'Find nearby donor if available and acc.to blood type', + button: 'explore', + image: 'assets/images/home_image2.png', + onPressed: (){ + Navigator.push(context, MaterialPageRoute( + builder:(ctx)=>const BloodDonorForm())); + }, + icon: Icon(Icons.bloodtype)) + ], + ), + ), + ); + + } +} \ No newline at end of file diff --git a/lib/views/pages/search/widgets/blood_bank_form.dart b/lib/views/pages/search/widgets/blood_bank_form.dart new file mode 100644 index 0000000..8eb87f2 --- /dev/null +++ b/lib/views/pages/search/widgets/blood_bank_form.dart @@ -0,0 +1,139 @@ +import 'package:dropdown_textfield/dropdown_textfield.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/widgets.dart'; + +class BloodBankForm extends StatelessWidget{ + const BloodBankForm({super.key}); + @override + Widget build(BuildContext context) { + + return Scaffold( + + body: + + Container( + height: double.infinity, + width: double.infinity, + decoration: BoxDecoration( + gradient: LinearGradient( + colors: [ + const Color.fromARGB(255, 221, 45, 45).withOpacity(0.6), + const Color.fromARGB(255, 232, 62, 50).withOpacity(0.6), + const Color.fromARGB(255, 240, 62, 39), + const Color.fromARGB(255, 222, 69, 69) + ], + begin: Alignment.bottomCenter, + end: Alignment.topCenter, + ), + ), + + child: Padding( + padding: EdgeInsets.fromLTRB(30, 150, 30, 90), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(30)), + color:Colors.white + ), + child: Padding( + padding: EdgeInsets.all(16.0), + child: Form( + child:Column( + children: [ + Text('Blood Bank',style: TextStyle( + color: Theme.of(context).colorScheme.onSurface, + fontWeight: FontWeight.bold, + fontSize: 30, + ), + ), + + SizedBox(height: 50,), + const DropdownMenu(dropdownMenuEntries: [ + DropdownMenuEntry(value: '1', label: 'Agra'), + DropdownMenuEntry(value: '2', label: 'Delhi'), + DropdownMenuEntry(value: '3', label: 'Chandigarh'), + DropdownMenuEntry(value: '4', label: 'Banglore'), + DropdownMenuEntry(value: '5', label: 'Pune'), + DropdownMenuEntry(value: '6', label: 'Noida'), + DropdownMenuEntry(value: '7', label: 'Mumbai'), + DropdownMenuEntry(value: '8', label: 'Kolkata'), + + ], + width: 600, + + label: Text('Select City'), + ), + SizedBox(height: 30,), + const DropdownMenu(dropdownMenuEntries: [ + DropdownMenuEntry(value: '1', label: 'xx'), + DropdownMenuEntry(value: '2', label: 'zx'), + DropdownMenuEntry(value: '3', label: 'xy'), + DropdownMenuEntry(value: '4', label: 'xm'), + DropdownMenuEntry(value: '5', label: 'xk'), + ], + width: 600, + + label: Text('Select Taluka/Zila'), + ), + SizedBox(height: 30,), + const DropdownMenu(dropdownMenuEntries: [ + DropdownMenuEntry(value: '1', label: 'AIIMS'), + DropdownMenuEntry(value: '2', label: 'City Hospital'), + DropdownMenuEntry(value: '3', label: 'General Hospital'), + DropdownMenuEntry(value: '4', label: 'Trama center'), + + + ], + width: 600, + + label: Text('Select Hospital'), + ), + + + SizedBox(height: 30,), + + const DropdownMenu(dropdownMenuEntries: [ + DropdownMenuEntry(value: '1', label: 'A'), + DropdownMenuEntry(value: '2', label: 'A+'), + DropdownMenuEntry(value: '3', label: 'AB'), + DropdownMenuEntry(value: '4', label: 'AB+'), + DropdownMenuEntry(value: '5', label: 'B'), + DropdownMenuEntry(value: '6', label: 'B+'), + DropdownMenuEntry(value: '7', label: 'O'), + DropdownMenuEntry(value: '8', label: 'O+'), + ], + width: 600, + label: Text('Needed blood group'), + ), + SizedBox(height: 30), + + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(112, 10, 140, 15), + ), + onPressed: () {}, + child: Text(maxLines: 1, + 'Search', + style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + + ), + ), + + ), + ] + ), + ), + ), + ), + ) + ) + ); + } + +} + diff --git a/lib/views/pages/search/widgets/blood_donor_form.dart b/lib/views/pages/search/widgets/blood_donor_form.dart new file mode 100644 index 0000000..5b58989 --- /dev/null +++ b/lib/views/pages/search/widgets/blood_donor_form.dart @@ -0,0 +1,97 @@ +import 'package:flutter/material.dart'; +import 'package:flutter/widgets.dart'; + +class BloodDonorForm extends StatelessWidget{ + const BloodDonorForm({super.key}); + @override + Widget build(BuildContext context) { + + return Scaffold( + + body: SingleChildScrollView( + child: Padding( + padding: EdgeInsets.fromLTRB(30, 150, 30, 80), + child: Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(30)), + color:Colors.white + ), + child: Padding( + padding: EdgeInsets.all(16.0), + child: Form( + child:Column( + children: [ + Text('Search Donors',style: TextStyle( + color: Theme.of(context).colorScheme.onSurface, + fontWeight: FontWeight.bold, + fontSize: 30, + ), + ), + + SizedBox(height: 50,), + + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + label: Text('Enter the blood group') + ), + + ), + const SizedBox(height: 20), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + label: Text('Enter District') + ), + + ), + const SizedBox(height: 20), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + label: Text('Enter the blood group') + ), + + ), + const SizedBox(height: 20), + TextFormField( + decoration: InputDecoration( + border: OutlineInputBorder(borderRadius: BorderRadius.all(Radius.circular(9))), + label: Text('Enter Pin Code') + ), + + ), + const SizedBox(height: 20), + + ElevatedButton( + style: ElevatedButton.styleFrom( + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(30), + ), + backgroundColor: Theme.of(context).colorScheme.primary, + padding: const EdgeInsets.fromLTRB(112, 10, 140, 15), + ), + onPressed: () {}, + child: Text(maxLines: 1, + 'Search', + style: TextStyle( + color: Theme.of(context).colorScheme.onPrimary, + fontWeight: FontWeight.bold, + + ), + ), + + ), + const SizedBox(height: 30), + ] + ), + ), + ), + ), + ) + ) + + + ); + } +} \ No newline at end of file diff --git a/lib/views/pages/welcome/welcome_screen.dart b/lib/views/pages/welcome/welcome_screen.dart new file mode 100644 index 0000000..6146626 --- /dev/null +++ b/lib/views/pages/welcome/welcome_screen.dart @@ -0,0 +1,129 @@ +import 'package:donorconnect/language/helper/language_extention.dart'; +import 'package:donorconnect/views/pages/login/login.dart'; +import 'package:donorconnect/views/pages/main_home/homepage.dart'; +import 'package:donorconnect/views/pages/register/signup.dart'; +import 'package:firebase_auth/firebase_auth.dart'; +import 'package:flutter/material.dart'; + +class FrontPage extends StatelessWidget { + const FrontPage({super.key}); + + @override + Widget build(BuildContext context) { + var screenWidth = MediaQuery.of(context).size.width; + var screenHeight = MediaQuery.of(context).size.height; + + // Define the transition effect function + Route _createRoute(Widget page) { + return PageRouteBuilder( + pageBuilder: (context, animation, secondaryAnimation) => page, + transitionsBuilder: (context, animation, secondaryAnimation, child) { + const begin = 0.0; + const end = 6.0; + const curve = Curves.easeInOut; + + var tween = + Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); + return FadeTransition( + opacity: animation.drive(tween), + child: child, + ); + }, + transitionDuration: + const Duration(milliseconds: 700), // Increase the duration to 700ms + ); + } + + return Scaffold( + body: FutureBuilder( + future: FirebaseAuth.instance.authStateChanges().first, + builder: (context, snapshot) { + if (snapshot.connectionState == ConnectionState.waiting) { + // While waiting for the authentication state, show a loading indicator + return const Center(child: CircularProgressIndicator()); + } + + if (snapshot.hasData && snapshot.data != null) { + // User is logged in, navigate to HomePage + Future.delayed(Duration.zero, () { + Navigator.of(context).pushReplacement( + _createRoute(HomePage( + email: snapshot.data!.email ?? "No email", + name: snapshot.data!.displayName ?? "No name")), + ); + }); + return Container(); // Return an empty container while navigating + } + + // User is not logged in, show the signup/login options + return Stack( + children: [ + // IMAGE + Image.asset( + 'assets/images/home.png', + fit: BoxFit.cover, + height: double.infinity, + width: double.infinity, + ), + Column( + mainAxisAlignment: MainAxisAlignment.end, + children: [ + InkWell( + onTap: () => Navigator.of(context) + .push(_createRoute(const Signuppage())), + child: Center( + child: Container( + height: screenHeight * 0.07, + width: screenWidth * 0.85, + decoration: const BoxDecoration( + color: Colors.red, + borderRadius: + BorderRadius.all(Radius.circular(30))), + child: Center( + child: Text( + context.localizedString.signup, + style: const TextStyle( + color: Colors.black, + fontSize: 25, + fontWeight: FontWeight.w500), + ), + ), + ), + ), + ), + const SizedBox(height: 20), + Padding( + padding: EdgeInsets.only(bottom: screenHeight * 0.04), + child: InkWell( + onTap: () => Navigator.of(context) + .pushReplacement(_createRoute(const LoginPage())), + child: Center( + child: Container( + height: screenHeight * 0.07, + width: screenWidth * 0.85, + decoration: BoxDecoration( + color: Colors.green.shade900, + borderRadius: + const BorderRadius.all(Radius.circular(30))), + child: Center( + child: Text( + context.localizedString.login, + style: const TextStyle( + color: Colors.white, + fontSize: 25, + fontWeight: FontWeight.w500), + ), + ), + ), + ), + ), + ), + ], + ) + ], + ); + }, + ), + ); + } +} diff --git a/lib/views/verificationform.dart b/lib/views/verificationform.dart new file mode 100644 index 0000000..da1d768 --- /dev/null +++ b/lib/views/verificationform.dart @@ -0,0 +1,123 @@ +import 'package:flutter/material.dart'; +import 'package:image_picker/image_picker.dart'; // For picking images/documents +import 'dart:io'; // For handling file uploads +import '../services/verification_service.dart'; // Firebase service for verification + +class VerificationForm extends StatefulWidget { + const VerificationForm({super.key}); + + @override + State createState() => _VerificationFormState(); +} + +class _VerificationFormState extends State { + final _formKey = GlobalKey(); + + File? _idDocument; + File? _medicalCertificate; + final picker = ImagePicker(); + + bool _isSubmitting = false; + + // Pick an image for ID document + Future _pickIdDocument() async { + final pickedFile = await picker.pickImage(source: ImageSource.gallery); + if (pickedFile != null) { + setState(() { + _idDocument = File(pickedFile.path); + }); + } + } + + // Pick an image for Medical Certificate + Future _pickMedicalCertificate() async { + final pickedFile = await picker.pickImage(source: ImageSource.gallery); + if (pickedFile != null) { + setState(() { + _medicalCertificate = File(pickedFile.path); + }); + } + } + + // Submit the verification documents + Future _submitVerification() async { + if (_formKey.currentState!.validate()) { + if (_idDocument == null || _medicalCertificate == null) { + ScaffoldMessenger.of(context).showSnackBar( + const SnackBar(content: Text('Please upload both documents.')), + ); + return; + } + + setState(() { + _isSubmitting = true; + }); + + // Call the service to handle document upload and verification + try { + await VerificationService().submitVerification( + idDocument: _idDocument!, + medicalCertificate: _medicalCertificate!, + ); + + ScaffoldMessenger.of(context).showSnackBar( + const SnackBar(content: Text('Documents submitted successfully!')), + ); + } catch (e) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar(content: Text('Error submitting documents: $e')), + ); + } finally { + setState(() { + _isSubmitting = false; + }); + } + } + } + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: const Text('Donor/Recipient Verification'), + ), + body: Padding( + padding: const EdgeInsets.all(16.0), + child: Form( + key: _formKey, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + const Text('Upload ID Document'), + const SizedBox(height: 10), + _idDocument == null + ? const Text('No document selected.') + : Image.file(_idDocument!, height: 100), + ElevatedButton( + onPressed: _pickIdDocument, + child: const Text('Select ID Document'), + ), + const SizedBox(height: 20), + const Text('Upload Medical Certificate'), + const SizedBox(height: 10), + _medicalCertificate == null + ? const Text('No document selected.') + : Image.file(_medicalCertificate!, height: 100), + ElevatedButton( + onPressed: _pickMedicalCertificate, + child: const Text('Select Medical Certificate'), + ), + const SizedBox(height: 30), + _isSubmitting + ? const Center(child: CircularProgressIndicator()) + : ElevatedButton( + onPressed: _submitVerification, + child: const Text('Submit Verification'), + ), + ], + ), + ), + ), + ); + } +} diff --git a/linux/.gitignore b/linux/.gitignore new file mode 100644 index 0000000..d3896c9 --- /dev/null +++ b/linux/.gitignore @@ -0,0 +1 @@ +flutter/ephemeral diff --git a/linux/CMakeLists.txt b/linux/CMakeLists.txt new file mode 100644 index 0000000..c0e0668 --- /dev/null +++ b/linux/CMakeLists.txt @@ -0,0 +1,145 @@ +# Project-level configuration. +cmake_minimum_required(VERSION 3.10) +project(runner LANGUAGES CXX) + +# The name of the executable created for the application. Change this to change +# the on-disk name of your application. +set(BINARY_NAME "donorconnect") +# The unique GTK application identifier for this application. See: +# https://wiki.gnome.org/HowDoI/ChooseApplicationID +set(APPLICATION_ID "com.example.donorconnect") + +# Explicitly opt in to modern CMake behaviors to avoid warnings with recent +# versions of CMake. +cmake_policy(SET CMP0063 NEW) + +# Load bundled libraries from the lib/ directory relative to the binary. +set(CMAKE_INSTALL_RPATH "$ORIGIN/lib") + +# Root filesystem for cross-building. +if(FLUTTER_TARGET_PLATFORM_SYSROOT) + set(CMAKE_SYSROOT ${FLUTTER_TARGET_PLATFORM_SYSROOT}) + set(CMAKE_FIND_ROOT_PATH ${CMAKE_SYSROOT}) + set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) + set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) + set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) + set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) +endif() + +# Define build configuration options. +if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) + set(CMAKE_BUILD_TYPE "Debug" CACHE + STRING "Flutter build mode" FORCE) + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS + "Debug" "Profile" "Release") +endif() + +# Compilation settings that should be applied to most targets. +# +# Be cautious about adding new options here, as plugins use this function by +# default. In most cases, you should add new options to specific targets instead +# of modifying this function. +function(APPLY_STANDARD_SETTINGS TARGET) + target_compile_features(${TARGET} PUBLIC cxx_std_14) + target_compile_options(${TARGET} PRIVATE -Wall -Werror) + target_compile_options(${TARGET} PRIVATE "$<$>:-O3>") + target_compile_definitions(${TARGET} PRIVATE "$<$>:NDEBUG>") +endfunction() + +# Flutter library and tool build rules. +set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter") +add_subdirectory(${FLUTTER_MANAGED_DIR}) + +# System-level dependencies. +find_package(PkgConfig REQUIRED) +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) + +add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}") + +# Define the application target. To change its name, change BINARY_NAME above, +# not the value here, or `flutter run` will no longer work. +# +# Any new source files that you add to the application should be added here. +add_executable(${BINARY_NAME} + "main.cc" + "my_application.cc" + "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" +) + +# Apply the standard set of build settings. This can be removed for applications +# that need different build settings. +apply_standard_settings(${BINARY_NAME}) + +# Add dependency libraries. Add any application-specific dependencies here. +target_link_libraries(${BINARY_NAME} PRIVATE flutter) +target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK) + +# Run the Flutter tool portions of the build. This must not be removed. +add_dependencies(${BINARY_NAME} flutter_assemble) + +# Only the install-generated bundle's copy of the executable will launch +# correctly, since the resources must in the right relative locations. To avoid +# people trying to run the unbundled copy, put it in a subdirectory instead of +# the default top-level location. +set_target_properties(${BINARY_NAME} + PROPERTIES + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/intermediates_do_not_run" +) + + +# Generated plugin build rules, which manage building the plugins and adding +# them to the application. +include(flutter/generated_plugins.cmake) + + +# === Installation === +# By default, "installing" just makes a relocatable bundle in the build +# directory. +set(BUILD_BUNDLE_DIR "${PROJECT_BINARY_DIR}/bundle") +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) + set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE) +endif() + +# Start with a clean build bundle directory every time. +install(CODE " + file(REMOVE_RECURSE \"${BUILD_BUNDLE_DIR}/\") + " COMPONENT Runtime) + +set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data") +set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib") + +install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}" + COMPONENT Runtime) + +install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" + COMPONENT Runtime) + +install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) + +foreach(bundled_library ${PLUGIN_BUNDLED_LIBRARIES}) + install(FILES "${bundled_library}" + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) +endforeach(bundled_library) + +# Copy the native assets provided by the build.dart from all packages. +set(NATIVE_ASSETS_DIR "${PROJECT_BUILD_DIR}native_assets/linux/") +install(DIRECTORY "${NATIVE_ASSETS_DIR}" + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) + +# Fully re-copy the assets directory on each build to avoid having stale files +# from a previous install. +set(FLUTTER_ASSET_DIR_NAME "flutter_assets") +install(CODE " + file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") + " COMPONENT Runtime) +install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" + DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) + +# Install the AOT library on non-Debug builds only. +if(NOT CMAKE_BUILD_TYPE MATCHES "Debug") + install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) +endif() diff --git a/linux/flutter/CMakeLists.txt b/linux/flutter/CMakeLists.txt new file mode 100644 index 0000000..d5bd016 --- /dev/null +++ b/linux/flutter/CMakeLists.txt @@ -0,0 +1,88 @@ +# This file controls Flutter-level build steps. It should not be edited. +cmake_minimum_required(VERSION 3.10) + +set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") + +# Configuration provided via flutter tool. +include(${EPHEMERAL_DIR}/generated_config.cmake) + +# TODO: Move the rest of this into files in ephemeral. See +# https://github.com/flutter/flutter/issues/57146. + +# Serves the same purpose as list(TRANSFORM ... PREPEND ...), +# which isn't available in 3.10. +function(list_prepend LIST_NAME PREFIX) + set(NEW_LIST "") + foreach(element ${${LIST_NAME}}) + list(APPEND NEW_LIST "${PREFIX}${element}") + endforeach(element) + set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE) +endfunction() + +# === Flutter Library === +# System-level dependencies. +find_package(PkgConfig REQUIRED) +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) +pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0) +pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0) + +set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so") + +# Published to parent scope for install step. +set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) +set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) +set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) +set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE) + +list(APPEND FLUTTER_LIBRARY_HEADERS + "fl_basic_message_channel.h" + "fl_binary_codec.h" + "fl_binary_messenger.h" + "fl_dart_project.h" + "fl_engine.h" + "fl_json_message_codec.h" + "fl_json_method_codec.h" + "fl_message_codec.h" + "fl_method_call.h" + "fl_method_channel.h" + "fl_method_codec.h" + "fl_method_response.h" + "fl_plugin_registrar.h" + "fl_plugin_registry.h" + "fl_standard_message_codec.h" + "fl_standard_method_codec.h" + "fl_string_codec.h" + "fl_value.h" + "fl_view.h" + "flutter_linux.h" +) +list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/") +add_library(flutter INTERFACE) +target_include_directories(flutter INTERFACE + "${EPHEMERAL_DIR}" +) +target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}") +target_link_libraries(flutter INTERFACE + PkgConfig::GTK + PkgConfig::GLIB + PkgConfig::GIO +) +add_dependencies(flutter flutter_assemble) + +# === Flutter tool backend === +# _phony_ is a non-existent file to force this command to run every time, +# since currently there's no way to get a full input/output list from the +# flutter tool. +add_custom_command( + OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} + ${CMAKE_CURRENT_BINARY_DIR}/_phony_ + COMMAND ${CMAKE_COMMAND} -E env + ${FLUTTER_TOOL_ENVIRONMENT} + "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh" + ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE} + VERBATIM +) +add_custom_target(flutter_assemble DEPENDS + "${FLUTTER_LIBRARY}" + ${FLUTTER_LIBRARY_HEADERS} +) diff --git a/linux/flutter/generated_plugin_registrant.cc b/linux/flutter/generated_plugin_registrant.cc new file mode 100644 index 0000000..7299b5c --- /dev/null +++ b/linux/flutter/generated_plugin_registrant.cc @@ -0,0 +1,19 @@ +// +// Generated file. Do not edit. +// + +// clang-format off + +#include "generated_plugin_registrant.h" + +#include +#include + +void fl_register_plugins(FlPluginRegistry* registry) { + g_autoptr(FlPluginRegistrar) file_selector_linux_registrar = + fl_plugin_registry_get_registrar_for_plugin(registry, "FileSelectorPlugin"); + file_selector_plugin_register_with_registrar(file_selector_linux_registrar); + g_autoptr(FlPluginRegistrar) url_launcher_linux_registrar = + fl_plugin_registry_get_registrar_for_plugin(registry, "UrlLauncherPlugin"); + url_launcher_plugin_register_with_registrar(url_launcher_linux_registrar); +} diff --git a/linux/flutter/generated_plugin_registrant.h b/linux/flutter/generated_plugin_registrant.h new file mode 100644 index 0000000..e0f0a47 --- /dev/null +++ b/linux/flutter/generated_plugin_registrant.h @@ -0,0 +1,15 @@ +// +// Generated file. Do not edit. +// + +// clang-format off + +#ifndef GENERATED_PLUGIN_REGISTRANT_ +#define GENERATED_PLUGIN_REGISTRANT_ + +#include + +// Registers Flutter plugins. +void fl_register_plugins(FlPluginRegistry* registry); + +#endif // GENERATED_PLUGIN_REGISTRANT_ diff --git a/linux/flutter/generated_plugins.cmake b/linux/flutter/generated_plugins.cmake new file mode 100644 index 0000000..786ff5c --- /dev/null +++ b/linux/flutter/generated_plugins.cmake @@ -0,0 +1,25 @@ +# +# Generated file, do not edit. +# + +list(APPEND FLUTTER_PLUGIN_LIST + file_selector_linux + url_launcher_linux +) + +list(APPEND FLUTTER_FFI_PLUGIN_LIST +) + +set(PLUGIN_BUNDLED_LIBRARIES) + +foreach(plugin ${FLUTTER_PLUGIN_LIST}) + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) + target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) + list(APPEND PLUGIN_BUNDLED_LIBRARIES $) + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) +endforeach(plugin) + +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) +endforeach(ffi_plugin) diff --git a/linux/main.cc b/linux/main.cc new file mode 100644 index 0000000..e7c5c54 --- /dev/null +++ b/linux/main.cc @@ -0,0 +1,6 @@ +#include "my_application.h" + +int main(int argc, char** argv) { + g_autoptr(MyApplication) app = my_application_new(); + return g_application_run(G_APPLICATION(app), argc, argv); +} diff --git a/linux/my_application.cc b/linux/my_application.cc new file mode 100644 index 0000000..5b1e35d --- /dev/null +++ b/linux/my_application.cc @@ -0,0 +1,124 @@ +#include "my_application.h" + +#include +#ifdef GDK_WINDOWING_X11 +#include +#endif + +#include "flutter/generated_plugin_registrant.h" + +struct _MyApplication { + GtkApplication parent_instance; + char** dart_entrypoint_arguments; +}; + +G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) + +// Implements GApplication::activate. +static void my_application_activate(GApplication* application) { + MyApplication* self = MY_APPLICATION(application); + GtkWindow* window = + GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); + + // Use a header bar when running in GNOME as this is the common style used + // by applications and is the setup most users will be using (e.g. Ubuntu + // desktop). + // If running on X and not using GNOME then just use a traditional title bar + // in case the window manager does more exotic layout, e.g. tiling. + // If running on Wayland assume the header bar will work (may need changing + // if future cases occur). + gboolean use_header_bar = TRUE; +#ifdef GDK_WINDOWING_X11 + GdkScreen* screen = gtk_window_get_screen(window); + if (GDK_IS_X11_SCREEN(screen)) { + const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen); + if (g_strcmp0(wm_name, "GNOME Shell") != 0) { + use_header_bar = FALSE; + } + } +#endif + if (use_header_bar) { + GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); + gtk_widget_show(GTK_WIDGET(header_bar)); + gtk_header_bar_set_title(header_bar, "donorconnect"); + gtk_header_bar_set_show_close_button(header_bar, TRUE); + gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); + } else { + gtk_window_set_title(window, "donorconnect"); + } + + gtk_window_set_default_size(window, 1280, 720); + gtk_widget_show(GTK_WIDGET(window)); + + g_autoptr(FlDartProject) project = fl_dart_project_new(); + fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments); + + FlView* view = fl_view_new(project); + gtk_widget_show(GTK_WIDGET(view)); + gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); + + fl_register_plugins(FL_PLUGIN_REGISTRY(view)); + + gtk_widget_grab_focus(GTK_WIDGET(view)); +} + +// Implements GApplication::local_command_line. +static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) { + MyApplication* self = MY_APPLICATION(application); + // Strip out the first argument as it is the binary name. + self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); + + g_autoptr(GError) error = nullptr; + if (!g_application_register(application, nullptr, &error)) { + g_warning("Failed to register: %s", error->message); + *exit_status = 1; + return TRUE; + } + + g_application_activate(application); + *exit_status = 0; + + return TRUE; +} + +// Implements GApplication::startup. +static void my_application_startup(GApplication* application) { + //MyApplication* self = MY_APPLICATION(object); + + // Perform any actions required at application startup. + + G_APPLICATION_CLASS(my_application_parent_class)->startup(application); +} + +// Implements GApplication::shutdown. +static void my_application_shutdown(GApplication* application) { + //MyApplication* self = MY_APPLICATION(object); + + // Perform any actions required at application shutdown. + + G_APPLICATION_CLASS(my_application_parent_class)->shutdown(application); +} + +// Implements GObject::dispose. +static void my_application_dispose(GObject* object) { + MyApplication* self = MY_APPLICATION(object); + g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); + G_OBJECT_CLASS(my_application_parent_class)->dispose(object); +} + +static void my_application_class_init(MyApplicationClass* klass) { + G_APPLICATION_CLASS(klass)->activate = my_application_activate; + G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line; + G_APPLICATION_CLASS(klass)->startup = my_application_startup; + G_APPLICATION_CLASS(klass)->shutdown = my_application_shutdown; + G_OBJECT_CLASS(klass)->dispose = my_application_dispose; +} + +static void my_application_init(MyApplication* self) {} + +MyApplication* my_application_new() { + return MY_APPLICATION(g_object_new(my_application_get_type(), + "application-id", APPLICATION_ID, + "flags", G_APPLICATION_NON_UNIQUE, + nullptr)); +} diff --git a/linux/my_application.h b/linux/my_application.h new file mode 100644 index 0000000..72271d5 --- /dev/null +++ b/linux/my_application.h @@ -0,0 +1,18 @@ +#ifndef FLUTTER_MY_APPLICATION_H_ +#define FLUTTER_MY_APPLICATION_H_ + +#include + +G_DECLARE_FINAL_TYPE(MyApplication, my_application, MY, APPLICATION, + GtkApplication) + +/** + * my_application_new: + * + * Creates a new Flutter-based application. + * + * Returns: a new #MyApplication. + */ +MyApplication* my_application_new(); + +#endif // FLUTTER_MY_APPLICATION_H_ diff --git a/macos/.gitignore b/macos/.gitignore new file mode 100644 index 0000000..746adbb --- /dev/null +++ b/macos/.gitignore @@ -0,0 +1,7 @@ +# Flutter-related +**/Flutter/ephemeral/ +**/Pods/ + +# Xcode-related +**/dgph +**/xcuserdata/ diff --git a/macos/Flutter/Flutter-Debug.xcconfig b/macos/Flutter/Flutter-Debug.xcconfig new file mode 100644 index 0000000..4b81f9b --- /dev/null +++ b/macos/Flutter/Flutter-Debug.xcconfig @@ -0,0 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" +#include "ephemeral/Flutter-Generated.xcconfig" diff --git a/macos/Flutter/Flutter-Release.xcconfig b/macos/Flutter/Flutter-Release.xcconfig new file mode 100644 index 0000000..5caa9d1 --- /dev/null +++ b/macos/Flutter/Flutter-Release.xcconfig @@ -0,0 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" +#include "ephemeral/Flutter-Generated.xcconfig" diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift new file mode 100644 index 0000000..c1b3fa0 --- /dev/null +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -0,0 +1,30 @@ +// +// Generated file. Do not edit. +// + +import FlutterMacOS +import Foundation + +import cloud_firestore +import file_selector_macos +import firebase_auth +import firebase_core +import firebase_storage +import geolocator_apple +import google_sign_in_ios +import path_provider_foundation +import shared_preferences_foundation +import url_launcher_macos + +func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { + FLTFirebaseFirestorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseFirestorePlugin")) + FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin")) + FLTFirebaseAuthPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseAuthPlugin")) + FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin")) + FLTFirebaseStoragePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseStoragePlugin")) + GeolocatorPlugin.register(with: registry.registrar(forPlugin: "GeolocatorPlugin")) + FLTGoogleSignInPlugin.register(with: registry.registrar(forPlugin: "FLTGoogleSignInPlugin")) + PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) + SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) + UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) +} diff --git a/macos/Podfile b/macos/Podfile new file mode 100644 index 0000000..c795730 --- /dev/null +++ b/macos/Podfile @@ -0,0 +1,43 @@ +platform :osx, '10.14' + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\"" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_macos_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__)) + target 'RunnerTests' do + inherit! :search_paths + end +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_macos_build_settings(target) + end +end diff --git a/macos/Runner.xcodeproj/project.pbxproj b/macos/Runner.xcodeproj/project.pbxproj new file mode 100644 index 0000000..426397a --- /dev/null +++ b/macos/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,716 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 54; + objects = { + +/* Begin PBXAggregateTarget section */ + 33CC111A2044C6BA0003C045 /* Flutter Assemble */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */; + buildPhases = ( + 33CC111E2044C6BF0003C045 /* ShellScript */, + ); + dependencies = ( + ); + name = "Flutter Assemble"; + productName = FLX; + }; +/* End PBXAggregateTarget section */ + +/* Begin PBXBuildFile section */ + 331C80D8294CF71000263BE5 /* RunnerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 331C80D7294CF71000263BE5 /* RunnerTests.swift */; }; + 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */ = {isa = PBXBuildFile; fileRef = 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */; }; + 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC10F02044A3C60003C045 /* AppDelegate.swift */; }; + 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; }; + 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; }; + 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; }; + + E277A5E154C2CB4B6992E28A /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 5AA9690195CD25274E4165B6 /* GoogleService-Info.plist */; }; + +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 331C80D9294CF71000263BE5 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 33CC10E52044A3C60003C045 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 33CC10EC2044A3C60003C045; + remoteInfo = Runner; + }; + 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 33CC10E52044A3C60003C045 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 33CC111A2044C6BA0003C045; + remoteInfo = FLX; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 33CC110E2044A8840003C045 /* Bundle Framework */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + ); + name = "Bundle Framework"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 331C80D5294CF71000263BE5 /* RunnerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RunnerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 331C80D7294CF71000263BE5 /* RunnerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunnerTests.swift; sourceTree = ""; }; + 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = ""; }; + 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = ""; }; + 33CC10ED2044A3C60003C045 /* donorconnect.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = donorconnect.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = ""; }; + 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = ""; }; + 33CC10F72044A3C60003C045 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = Runner/Info.plist; sourceTree = ""; }; + 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MainFlutterWindow.swift; sourceTree = ""; }; + 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Debug.xcconfig"; sourceTree = ""; }; + 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Release.xcconfig"; sourceTree = ""; }; + 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = "Flutter-Generated.xcconfig"; path = "ephemeral/Flutter-Generated.xcconfig"; sourceTree = ""; }; + 33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = ""; }; + 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = ""; }; + 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = ""; }; + 5AA9690195CD25274E4165B6 /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = ""; }; + BBA006A896FA7401C8E14577 /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 331C80D2294CF70F00263BE5 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 33CC10EA2044A3C60003C045 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 331C80D6294CF71000263BE5 /* RunnerTests */ = { + isa = PBXGroup; + children = ( + 331C80D7294CF71000263BE5 /* RunnerTests.swift */, + ); + path = RunnerTests; + sourceTree = ""; + }; + 33BA886A226E78AF003329D5 /* Configs */ = { + isa = PBXGroup; + children = ( + 33E5194F232828860026EE4D /* AppInfo.xcconfig */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 333000ED22D3DE5D00554162 /* Warnings.xcconfig */, + ); + path = Configs; + sourceTree = ""; + }; + 33CC10E42044A3C60003C045 = { + isa = PBXGroup; + children = ( + 33FAB671232836740065AC1E /* Runner */, + 33CEB47122A05771004F2AC0 /* Flutter */, + 331C80D6294CF71000263BE5 /* RunnerTests */, + 33CC10EE2044A3C60003C045 /* Products */, + D73912EC22F37F3D000D13A0 /* Frameworks */, + + 5AA9690195CD25274E4165B6 /* GoogleService-Info.plist */, + + ); + sourceTree = ""; + }; + 33CC10EE2044A3C60003C045 /* Products */ = { + isa = PBXGroup; + children = ( + 33CC10ED2044A3C60003C045 /* donorconnect.app */, + 331C80D5294CF71000263BE5 /* RunnerTests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 33CC11242044D66E0003C045 /* Resources */ = { + isa = PBXGroup; + children = ( + 33CC10F22044A3C60003C045 /* Assets.xcassets */, + 33CC10F42044A3C60003C045 /* MainMenu.xib */, + 33CC10F72044A3C60003C045 /* Info.plist */, + ); + name = Resources; + path = ..; + sourceTree = ""; + }; + 33CEB47122A05771004F2AC0 /* Flutter */ = { + isa = PBXGroup; + children = ( + 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */, + 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */, + 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */, + 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */, + ); + path = Flutter; + sourceTree = ""; + }; + 33FAB671232836740065AC1E /* Runner */ = { + isa = PBXGroup; + children = ( + 33CC10F02044A3C60003C045 /* AppDelegate.swift */, + 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */, + 33E51913231747F40026EE4D /* DebugProfile.entitlements */, + 33E51914231749380026EE4D /* Release.entitlements */, + 33CC11242044D66E0003C045 /* Resources */, + 33BA886A226E78AF003329D5 /* Configs */, + ); + path = Runner; + sourceTree = ""; + }; + D73912EC22F37F3D000D13A0 /* Frameworks */ = { + isa = PBXGroup; + children = ( + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 331C80D4294CF70F00263BE5 /* RunnerTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 331C80DE294CF71000263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */; + buildPhases = ( + 331C80D1294CF70F00263BE5 /* Sources */, + 331C80D2294CF70F00263BE5 /* Frameworks */, + 331C80D3294CF70F00263BE5 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 331C80DA294CF71000263BE5 /* PBXTargetDependency */, + ); + name = RunnerTests; + productName = RunnerTests; + productReference = 331C80D5294CF71000263BE5 /* RunnerTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 33CC10EC2044A3C60003C045 /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 33CC10E92044A3C60003C045 /* Sources */, + 33CC10EA2044A3C60003C045 /* Frameworks */, + 33CC10EB2044A3C60003C045 /* Resources */, + 33CC110E2044A8840003C045 /* Bundle Framework */, + 3399D490228B24CF009A79C7 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 33CC11202044C79F0003C045 /* PBXTargetDependency */, + ); + name = Runner; + productName = Runner; + productReference = 33CC10ED2044A3C60003C045 /* donorconnect.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 33CC10E52044A3C60003C045 /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = YES; + LastSwiftUpdateCheck = 0920; + LastUpgradeCheck = 1510; + ORGANIZATIONNAME = ""; + TargetAttributes = { + 331C80D4294CF70F00263BE5 = { + CreatedOnToolsVersion = 14.0; + TestTargetID = 33CC10EC2044A3C60003C045; + }; + 33CC10EC2044A3C60003C045 = { + CreatedOnToolsVersion = 9.2; + LastSwiftMigration = 1100; + ProvisioningStyle = Automatic; + SystemCapabilities = { + com.apple.Sandbox = { + enabled = 1; + }; + }; + }; + 33CC111A2044C6BA0003C045 = { + CreatedOnToolsVersion = 9.2; + ProvisioningStyle = Manual; + }; + }; + }; + buildConfigurationList = 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 33CC10E42044A3C60003C045; + productRefGroup = 33CC10EE2044A3C60003C045 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 33CC10EC2044A3C60003C045 /* Runner */, + 331C80D4294CF70F00263BE5 /* RunnerTests */, + 33CC111A2044C6BA0003C045 /* Flutter Assemble */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 331C80D3294CF70F00263BE5 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 33CC10EB2044A3C60003C045 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */, + 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */, + + E277A5E154C2CB4B6992E28A /* GoogleService-Info.plist in Resources */, + + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3399D490228B24CF009A79C7 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + alwaysOutOfDate = 1; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "echo \"$PRODUCT_NAME.app\" > \"$PROJECT_DIR\"/Flutter/ephemeral/.app_filename && \"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh embed\n"; + }; + 33CC111E2044C6BF0003C045 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + Flutter/ephemeral/FlutterInputs.xcfilelist, + ); + inputPaths = ( + Flutter/ephemeral/tripwire, + ); + outputFileListPaths = ( + Flutter/ephemeral/FlutterOutputs.xcfilelist, + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 331C80D1294CF70F00263BE5 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 331C80D8294CF71000263BE5 /* RunnerTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 33CC10E92044A3C60003C045 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */, + 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */, + 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 331C80DA294CF71000263BE5 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 33CC10EC2044A3C60003C045 /* Runner */; + targetProxy = 331C80D9294CF71000263BE5 /* PBXContainerItemProxy */; + }; + 33CC11202044C79F0003C045 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 33CC111A2044C6BA0003C045 /* Flutter Assemble */; + targetProxy = 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + 33CC10F42044A3C60003C045 /* MainMenu.xib */ = { + isa = PBXVariantGroup; + children = ( + 33CC10F52044A3C60003C045 /* Base */, + ); + name = MainMenu.xib; + path = Runner; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 331C80DB294CF71000263BE5 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/donorconnect.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/donorconnect"; + }; + name = Debug; + }; + 331C80DC294CF71000263BE5 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/donorconnect.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/donorconnect"; + }; + name = Release; + }; + 331C80DD294CF71000263BE5 /* Profile */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect.RunnerTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 5.0; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/donorconnect.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/donorconnect"; + }; + name = Profile; + }; + 338D0CE9231458BD00FA5F75 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + 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_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + 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_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CODE_SIGN_IDENTITY = "-"; + COPY_PHASE_STRIP = NO; + DEAD_CODE_STRIPPING = YES; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.14; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = macosx; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + }; + name = Profile; + }; + 338D0CEA231458BD00FA5F75 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; + CODE_SIGN_STYLE = Automatic; + COMBINE_HIDPI_IMAGES = YES; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/../Frameworks", + ); + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_VERSION = 5.0; + }; + name = Profile; + }; + 338D0CEB231458BD00FA5F75 /* Profile */ = { + isa = XCBuildConfiguration; + buildSettings = { + CODE_SIGN_STYLE = Manual; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Profile; + }; + 33CC10F92044A3C60003C045 /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + 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_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + 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_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CODE_SIGN_IDENTITY = "-"; + COPY_PHASE_STRIP = NO; + DEAD_CODE_STRIPPING = YES; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + 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_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.14; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = macosx; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 33CC10FA2044A3C60003C045 /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + 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_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + 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_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CODE_SIGN_IDENTITY = "-"; + COPY_PHASE_STRIP = NO; + DEAD_CODE_STRIPPING = YES; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = NO; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + MACOSX_DEPLOYMENT_TARGET = 10.14; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = macosx; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + }; + name = Release; + }; + 33CC10FC2044A3C60003C045 /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; + CODE_SIGN_STYLE = Automatic; + COMBINE_HIDPI_IMAGES = YES; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/../Frameworks", + ); + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + }; + name = Debug; + }; + 33CC10FD2044A3C60003C045 /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_ENTITLEMENTS = Runner/Release.entitlements; + CODE_SIGN_STYLE = Automatic; + COMBINE_HIDPI_IMAGES = YES; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/../Frameworks", + ); + PROVISIONING_PROFILE_SPECIFIER = ""; + SWIFT_VERSION = 5.0; + }; + name = Release; + }; + 33CC111C2044C6BA0003C045 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + CODE_SIGN_STYLE = Manual; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 33CC111D2044C6BA0003C045 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CODE_SIGN_STYLE = Automatic; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 331C80DE294CF71000263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 331C80DB294CF71000263BE5 /* Debug */, + 331C80DC294CF71000263BE5 /* Release */, + 331C80DD294CF71000263BE5 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 33CC10F92044A3C60003C045 /* Debug */, + 33CC10FA2044A3C60003C045 /* Release */, + 338D0CE9231458BD00FA5F75 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 33CC10FC2044A3C60003C045 /* Debug */, + 33CC10FD2044A3C60003C045 /* Release */, + 338D0CEA231458BD00FA5F75 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 33CC111C2044C6BA0003C045 /* Debug */, + 33CC111D2044C6BA0003C045 /* Release */, + 338D0CEB231458BD00FA5F75 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 33CC10E52044A3C60003C045 /* Project object */; +} diff --git a/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 0000000..2fd1f7b --- /dev/null +++ b/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,98 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/macos/Runner.xcworkspace/contents.xcworkspacedata b/macos/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..1d526a1 --- /dev/null +++ b/macos/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/macos/Runner/AppDelegate.swift b/macos/Runner/AppDelegate.swift new file mode 100644 index 0000000..8e02df2 --- /dev/null +++ b/macos/Runner/AppDelegate.swift @@ -0,0 +1,9 @@ +import Cocoa +import FlutterMacOS + +@main +class AppDelegate: FlutterAppDelegate { + override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { + return true + } +} diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..a2ec33f --- /dev/null +++ b/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,68 @@ +{ + "images" : [ + { + "size" : "16x16", + "idiom" : "mac", + "filename" : "app_icon_16.png", + "scale" : "1x" + }, + { + "size" : "16x16", + "idiom" : "mac", + "filename" : "app_icon_32.png", + "scale" : "2x" + }, + { + "size" : "32x32", + "idiom" : "mac", + "filename" : "app_icon_32.png", + "scale" : "1x" + }, + { + "size" : "32x32", + "idiom" : "mac", + "filename" : "app_icon_64.png", + "scale" : "2x" + }, + { + "size" : "128x128", + "idiom" : "mac", + "filename" : "app_icon_128.png", + "scale" : "1x" + }, + { + "size" : "128x128", + "idiom" : "mac", + "filename" : "app_icon_256.png", + "scale" : "2x" + }, + { + "size" : "256x256", + "idiom" : "mac", + "filename" : "app_icon_256.png", + "scale" : "1x" + }, + { + "size" : "256x256", + "idiom" : "mac", + "filename" : "app_icon_512.png", + "scale" : "2x" + }, + { + "size" : "512x512", + "idiom" : "mac", + "filename" : "app_icon_512.png", + "scale" : "1x" + }, + { + "size" : "512x512", + "idiom" : "mac", + "filename" : "app_icon_1024.png", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png new file mode 100644 index 0000000..82b6f9d Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png new file mode 100644 index 0000000..13b35eb Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png new file mode 100644 index 0000000..0a3f5fa Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png new file mode 100644 index 0000000..bdb5722 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png new file mode 100644 index 0000000..f083318 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png new file mode 100644 index 0000000..326c0e7 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png new file mode 100644 index 0000000..2f1632c Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png differ diff --git a/macos/Runner/Base.lproj/MainMenu.xib b/macos/Runner/Base.lproj/MainMenu.xib new file mode 100644 index 0000000..80e867a --- /dev/null +++ b/macos/Runner/Base.lproj/MainMenu.xib @@ -0,0 +1,343 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/macos/Runner/Configs/AppInfo.xcconfig b/macos/Runner/Configs/AppInfo.xcconfig new file mode 100644 index 0000000..ea44365 --- /dev/null +++ b/macos/Runner/Configs/AppInfo.xcconfig @@ -0,0 +1,14 @@ +// Application-level settings for the Runner target. +// +// This may be replaced with something auto-generated from metadata (e.g., pubspec.yaml) in the +// future. If not, the values below would default to using the project name when this becomes a +// 'flutter create' template. + +// The application's name. By default this is also the title of the Flutter window. +PRODUCT_NAME = donorconnect + +// The application's bundle identifier +PRODUCT_BUNDLE_IDENTIFIER = com.example.donorconnect + +// The copyright displayed in application information +PRODUCT_COPYRIGHT = Copyright © 2024 com.example. All rights reserved. diff --git a/macos/Runner/Configs/Debug.xcconfig b/macos/Runner/Configs/Debug.xcconfig new file mode 100644 index 0000000..36b0fd9 --- /dev/null +++ b/macos/Runner/Configs/Debug.xcconfig @@ -0,0 +1,2 @@ +#include "../../Flutter/Flutter-Debug.xcconfig" +#include "Warnings.xcconfig" diff --git a/macos/Runner/Configs/Release.xcconfig b/macos/Runner/Configs/Release.xcconfig new file mode 100644 index 0000000..dff4f49 --- /dev/null +++ b/macos/Runner/Configs/Release.xcconfig @@ -0,0 +1,2 @@ +#include "../../Flutter/Flutter-Release.xcconfig" +#include "Warnings.xcconfig" diff --git a/macos/Runner/Configs/Warnings.xcconfig b/macos/Runner/Configs/Warnings.xcconfig new file mode 100644 index 0000000..42bcbf4 --- /dev/null +++ b/macos/Runner/Configs/Warnings.xcconfig @@ -0,0 +1,13 @@ +WARNING_CFLAGS = -Wall -Wconditional-uninitialized -Wnullable-to-nonnull-conversion -Wmissing-method-return-type -Woverlength-strings +GCC_WARN_UNDECLARED_SELECTOR = YES +CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY = YES +CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE +CLANG_WARN__DUPLICATE_METHOD_MATCH = YES +CLANG_WARN_PRAGMA_PACK = YES +CLANG_WARN_STRICT_PROTOTYPES = YES +CLANG_WARN_COMMA = YES +GCC_WARN_STRICT_SELECTOR_MATCH = YES +CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES +CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES +GCC_WARN_SHADOW = YES +CLANG_WARN_UNREACHABLE_CODE = YES diff --git a/macos/Runner/DebugProfile.entitlements b/macos/Runner/DebugProfile.entitlements new file mode 100644 index 0000000..dddb8a3 --- /dev/null +++ b/macos/Runner/DebugProfile.entitlements @@ -0,0 +1,12 @@ + + + + + com.apple.security.app-sandbox + + com.apple.security.cs.allow-jit + + com.apple.security.network.server + + + diff --git a/macos/Runner/GoogleService-Info.plist b/macos/Runner/GoogleService-Info.plist new file mode 100644 index 0000000..66f73ae --- /dev/null +++ b/macos/Runner/GoogleService-Info.plist @@ -0,0 +1,30 @@ + + + + + API_KEY + AIzaSyDSUZ2WdRgNAIgom1T74_8mg-4kutgrmi4 + GCM_SENDER_ID + 445023469277 + PLIST_VERSION + 1 + BUNDLE_ID + com.example.donorconnect + PROJECT_ID + donor-connect-project + STORAGE_BUCKET + donor-connect-project.appspot.com + IS_ADS_ENABLED + + IS_ANALYTICS_ENABLED + + IS_APPINVITE_ENABLED + + IS_GCM_ENABLED + + IS_SIGNIN_ENABLED + + GOOGLE_APP_ID + 1:445023469277:ios:9a17b6ec582928d9a52534 + + \ No newline at end of file diff --git a/macos/Runner/Info.plist b/macos/Runner/Info.plist new file mode 100644 index 0000000..4789daa --- /dev/null +++ b/macos/Runner/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIconFile + + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSMinimumSystemVersion + $(MACOSX_DEPLOYMENT_TARGET) + NSHumanReadableCopyright + $(PRODUCT_COPYRIGHT) + NSMainNibFile + MainMenu + NSPrincipalClass + NSApplication + + diff --git a/macos/Runner/MainFlutterWindow.swift b/macos/Runner/MainFlutterWindow.swift new file mode 100644 index 0000000..3cc05eb --- /dev/null +++ b/macos/Runner/MainFlutterWindow.swift @@ -0,0 +1,15 @@ +import Cocoa +import FlutterMacOS + +class MainFlutterWindow: NSWindow { + override func awakeFromNib() { + let flutterViewController = FlutterViewController() + let windowFrame = self.frame + self.contentViewController = flutterViewController + self.setFrame(windowFrame, display: true) + + RegisterGeneratedPlugins(registry: flutterViewController) + + super.awakeFromNib() + } +} diff --git a/macos/Runner/Release.entitlements b/macos/Runner/Release.entitlements new file mode 100644 index 0000000..852fa1a --- /dev/null +++ b/macos/Runner/Release.entitlements @@ -0,0 +1,8 @@ + + + + + com.apple.security.app-sandbox + + + diff --git a/macos/RunnerTests/RunnerTests.swift b/macos/RunnerTests/RunnerTests.swift new file mode 100644 index 0000000..61f3bd1 --- /dev/null +++ b/macos/RunnerTests/RunnerTests.swift @@ -0,0 +1,12 @@ +import Cocoa +import FlutterMacOS +import XCTest + +class RunnerTests: XCTestCase { + + func testExample() { + // If you add code to the Runner application, consider adding tests here. + // See https://developer.apple.com/documentation/xctest for more information about using XCTest. + } + +} diff --git a/native_splash.yaml b/native_splash.yaml new file mode 100644 index 0000000..4ad491c --- /dev/null +++ b/native_splash.yaml @@ -0,0 +1,14 @@ +flutter_native_splash: + android: true + ios: true + web: true + + color: "#ffffff" + image: "assets/images/launcher_icon1.png" + branding: "assets/images/donorConnect1.png" + + android_12: + color: "#ffffff" + image: "assets/images/launcher_icon1.png" + branding: "assets/images/donorConnect1.png" + diff --git a/pubspec.lock b/pubspec.lock new file mode 100644 index 0000000..c818f96 --- /dev/null +++ b/pubspec.lock @@ -0,0 +1,1452 @@ +# Generated by pub +# See https://dart.dev/tools/pub/glossary#lockfile +packages: + _fe_analyzer_shared: + dependency: transitive + description: + name: _fe_analyzer_shared + sha256: f256b0c0ba6c7577c15e2e4e114755640a875e885099367bf6e012b19314c834 + url: "https://pub.dev" + source: hosted + version: "72.0.0" + _flutterfire_internals: + dependency: transitive + description: + name: _flutterfire_internals + sha256: "5534e701a2c505fed1f0799e652dd6ae23bd4d2c4cf797220e5ced5764a7c1c2" + url: "https://pub.dev" + source: hosted + version: "1.3.44" + _macros: + dependency: transitive + description: dart + source: sdk + version: "0.3.2" + analyzer: + dependency: transitive + description: + name: analyzer + sha256: b652861553cd3990d8ed361f7979dc6d7053a9ac8843fa73820ab68ce5410139 + url: "https://pub.dev" + source: hosted + version: "6.7.0" + animated_toggle_switch: + dependency: "direct main" + description: + name: animated_toggle_switch + sha256: "786e82be3b004100299c1c6d023f8f1928decc8353a6fdff191bf78c866262fa" + url: "https://pub.dev" + source: hosted + version: "0.8.3" + ansicolor: + dependency: transitive + description: + name: ansicolor + sha256: "50e982d500bc863e1d703448afdbf9e5a72eb48840a4f766fa361ffd6877055f" + url: "https://pub.dev" + source: hosted + version: "2.0.3" + archive: + dependency: transitive + description: + name: archive + sha256: cb6a278ef2dbb298455e1a713bda08524a175630ec643a242c399c932a0a1f7d + url: "https://pub.dev" + source: hosted + version: "3.6.1" + args: + dependency: transitive + description: + name: args + sha256: "7cf60b9f0cc88203c5a190b4cd62a99feea42759a7fa695010eb5de1c0b2252a" + url: "https://pub.dev" + source: hosted + version: "2.5.0" + async: + dependency: transitive + description: + name: async + sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" + url: "https://pub.dev" + source: hosted + version: "2.11.0" + basic_utils: + dependency: transitive + description: + name: basic_utils + sha256: "2064b21d3c41ed7654bc82cc476fd65542e04d60059b74d5eed490a4da08fc6c" + url: "https://pub.dev" + source: hosted + version: "5.7.0" + bloc: + dependency: transitive + description: + name: bloc + sha256: "106842ad6569f0b60297619e9e0b1885c2fb9bf84812935490e6c5275777804e" + url: "https://pub.dev" + source: hosted + version: "8.1.4" + boolean_selector: + dependency: transitive + description: + name: boolean_selector + sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" + url: "https://pub.dev" + source: hosted + version: "2.1.1" + bson: + dependency: transitive + description: + name: bson + sha256: "5a286c4cb9944ab21287579d1f664eb8300daa91d80938349b1a244d165a6ba5" + url: "https://pub.dev" + source: hosted + version: "5.0.4" + buffer: + dependency: transitive + description: + name: buffer + sha256: "389da2ec2c16283c8787e0adaede82b1842102f8c8aae2f49003a766c5c6b3d1" + url: "https://pub.dev" + source: hosted + version: "1.2.3" + build: + dependency: transitive + description: + name: build + sha256: "80184af8b6cb3e5c1c4ec6d8544d27711700bc3e6d2efad04238c7b5290889f0" + url: "https://pub.dev" + source: hosted + version: "2.4.1" + build_config: + dependency: transitive + description: + name: build_config + sha256: bf80fcfb46a29945b423bd9aad884590fb1dc69b330a4d4700cac476af1708d1 + url: "https://pub.dev" + source: hosted + version: "1.1.1" + build_daemon: + dependency: transitive + description: + name: build_daemon + sha256: "79b2aef6ac2ed00046867ed354c88778c9c0f029df8a20fe10b5436826721ef9" + url: "https://pub.dev" + source: hosted + version: "4.0.2" + build_resolvers: + dependency: transitive + description: + name: build_resolvers + sha256: "339086358431fa15d7eca8b6a36e5d783728cf025e559b834f4609a1fcfb7b0a" + url: "https://pub.dev" + source: hosted + version: "2.4.2" + build_runner: + dependency: "direct dev" + description: + name: build_runner + sha256: "028819cfb90051c6b5440c7e574d1896f8037e3c96cf17aaeb054c9311cfbf4d" + url: "https://pub.dev" + source: hosted + version: "2.4.13" + build_runner_core: + dependency: transitive + description: + name: build_runner_core + sha256: f8126682b87a7282a339b871298cc12009cb67109cfa1614d6436fb0289193e0 + url: "https://pub.dev" + source: hosted + version: "7.3.2" + built_collection: + dependency: transitive + description: + name: built_collection + sha256: "376e3dd27b51ea877c28d525560790aee2e6fbb5f20e2f85d5081027d94e2100" + url: "https://pub.dev" + source: hosted + version: "5.1.1" + built_value: + dependency: transitive + description: + name: built_value + sha256: c7913a9737ee4007efedaffc968c049fd0f3d0e49109e778edc10de9426005cb + url: "https://pub.dev" + source: hosted + version: "8.9.2" + characters: + dependency: transitive + description: + name: characters + sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" + url: "https://pub.dev" + source: hosted + version: "1.3.0" + checked_yaml: + dependency: transitive + description: + name: checked_yaml + sha256: feb6bed21949061731a7a75fc5d2aa727cf160b91af9a3e464c5e3a32e28b5ff + url: "https://pub.dev" + source: hosted + version: "2.0.3" + clock: + dependency: transitive + description: + name: clock + sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf + url: "https://pub.dev" + source: hosted + version: "1.1.1" + cloud_firestore: + dependency: "direct main" + description: + name: cloud_firestore + sha256: bdc7607e9169ee3ce736bbbe6a81c2a6cb15c41379346b74f77f8e641211a17f + url: "https://pub.dev" + source: hosted + version: "5.4.4" + cloud_firestore_platform_interface: + dependency: transitive + description: + name: cloud_firestore_platform_interface + sha256: "884fa34c6be2d9c7c1f4af86f90f36c0a3b3afef585a12b350a5d15368e7ec7a" + url: "https://pub.dev" + source: hosted + version: "6.4.3" + cloud_firestore_web: + dependency: transitive + description: + name: cloud_firestore_web + sha256: "6e621bbcc999f32db0bc6bfcb18d9991617ec20f8d6bf51b6a1571f5c324fafd" + url: "https://pub.dev" + source: hosted + version: "4.3.2" + code_builder: + dependency: transitive + description: + name: code_builder + sha256: f692079e25e7869c14132d39f223f8eec9830eb76131925143b2129c4bb01b37 + url: "https://pub.dev" + source: hosted + version: "4.10.0" + collection: + dependency: transitive + description: + name: collection + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a + url: "https://pub.dev" + source: hosted + version: "1.18.0" + convert: + dependency: transitive + description: + name: convert + sha256: "0f08b14755d163f6e2134cb58222dd25ea2a2ee8a195e53983d57c075324d592" + url: "https://pub.dev" + source: hosted + version: "3.1.1" + cross_file: + dependency: transitive + description: + name: cross_file + sha256: "7caf6a750a0c04effbb52a676dce9a4a592e10ad35c34d6d2d0e4811160d5670" + url: "https://pub.dev" + source: hosted + version: "0.3.4+2" + crypto: + dependency: transitive + description: + name: crypto + sha256: ec30d999af904f33454ba22ed9a86162b35e52b44ac4807d1d93c288041d7d27 + url: "https://pub.dev" + source: hosted + version: "3.0.5" + csslib: + dependency: transitive + description: + name: csslib + sha256: "706b5707578e0c1b4b7550f64078f0a0f19dec3f50a178ffae7006b0a9ca58fb" + url: "https://pub.dev" + source: hosted + version: "1.0.0" + cupertino_icons: + dependency: "direct main" + description: + name: cupertino_icons + sha256: ba631d1c7f7bef6b729a622b7b752645a2d076dba9976925b8f25725a30e1ee6 + url: "https://pub.dev" + source: hosted + version: "1.0.8" + custom_navigation_bar: + dependency: "direct main" + description: + name: custom_navigation_bar + sha256: "2e00e138a1eba71c288aadbcd728f1f8caebf659b95b793aae08a9c0d70ca941" + url: "https://pub.dev" + source: hosted + version: "0.8.2" + dart_style: + dependency: transitive + description: + name: dart_style + sha256: "7856d364b589d1f08986e140938578ed36ed948581fbc3bc9aef1805039ac5ab" + url: "https://pub.dev" + source: hosted + version: "2.3.7" + decimal: + dependency: transitive + description: + name: decimal + sha256: "24a261d5d5c87e86c7651c417a5dbdf8bcd7080dd592533910e8d0505a279f21" + url: "https://pub.dev" + source: hosted + version: "2.3.3" + dropdown_textfield: + dependency: "direct main" + description: + name: dropdown_textfield + sha256: ef8a35c52c92a563773d3efead94e5a1c162d6fe6c53974d0986aab6249928a1 + url: "https://pub.dev" + source: hosted + version: "1.2.0" + equatable: + dependency: "direct main" + description: + name: equatable + sha256: c2b87cb7756efdf69892005af546c56c0b5037f54d2a88269b4f347a505e3ca2 + url: "https://pub.dev" + source: hosted + version: "2.0.5" + fake_async: + dependency: transitive + description: + name: fake_async + sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" + url: "https://pub.dev" + source: hosted + version: "1.3.1" + ffi: + dependency: transitive + description: + name: ffi + sha256: "16ed7b077ef01ad6170a3d0c57caa4a112a38d7a2ed5602e0aca9ca6f3d98da6" + url: "https://pub.dev" + source: hosted + version: "2.1.3" + file: + dependency: transitive + description: + name: file + sha256: a3b4f84adafef897088c160faf7dfffb7696046cb13ae90b508c2cbc95d3b8d4 + url: "https://pub.dev" + source: hosted + version: "7.0.1" + file_selector_linux: + dependency: transitive + description: + name: file_selector_linux + sha256: "712ce7fab537ba532c8febdb1a8f167b32441e74acd68c3ccb2e36dcb52c4ab2" + url: "https://pub.dev" + source: hosted + version: "0.9.3" + file_selector_macos: + dependency: transitive + description: + name: file_selector_macos + sha256: "271ab9986df0c135d45c3cdb6bd0faa5db6f4976d3e4b437cf7d0f258d941bfc" + url: "https://pub.dev" + source: hosted + version: "0.9.4+2" + file_selector_platform_interface: + dependency: transitive + description: + name: file_selector_platform_interface + sha256: a3994c26f10378a039faa11de174d7b78eb8f79e4dd0af2a451410c1a5c3f66b + url: "https://pub.dev" + source: hosted + version: "2.6.2" + file_selector_windows: + dependency: transitive + description: + name: file_selector_windows + sha256: "8f5d2f6590d51ecd9179ba39c64f722edc15226cc93dcc8698466ad36a4a85a4" + url: "https://pub.dev" + source: hosted + version: "0.9.3+3" + firebase_auth: + dependency: "direct main" + description: + name: firebase_auth + sha256: d453acec0d958ba0e25d41a9901b32cb77d1535766903dea7a61b2788c304596 + url: "https://pub.dev" + source: hosted + version: "5.3.1" + firebase_auth_platform_interface: + dependency: transitive + description: + name: firebase_auth_platform_interface + sha256: "78966c2ef774f5bf2a8381a307222867e9ece3509110500f7a138c115926aa65" + url: "https://pub.dev" + source: hosted + version: "7.4.7" + firebase_auth_web: + dependency: transitive + description: + name: firebase_auth_web + sha256: "77ad3b252badedd3f08dfa21a4c7fe244be96c6da3a4067f253b13ea5d32424c" + url: "https://pub.dev" + source: hosted + version: "5.13.2" + firebase_core: + dependency: "direct main" + description: + name: firebase_core + sha256: "51dfe2fbf3a984787a2e7b8592f2f05c986bfedd6fdacea3f9e0a7beb334de96" + url: "https://pub.dev" + source: hosted + version: "3.6.0" + firebase_core_platform_interface: + dependency: transitive + description: + name: firebase_core_platform_interface + sha256: e30da58198a6d4b49d5bce4e852f985c32cb10db329ebef9473db2b9f09ce810 + url: "https://pub.dev" + source: hosted + version: "5.3.0" + firebase_core_web: + dependency: transitive + description: + name: firebase_core_web + sha256: f967a7138f5d2ffb1ce15950e2a382924239eaa521150a8f144af34e68b3b3e5 + url: "https://pub.dev" + source: hosted + version: "2.18.1" + firebase_storage: + dependency: "direct main" + description: + name: firebase_storage + sha256: e00e2909e36f5e44f839fd77dff90ff764f7bb303ed548d43617014ce05c77c8 + url: "https://pub.dev" + source: hosted + version: "12.3.3" + firebase_storage_platform_interface: + dependency: transitive + description: + name: firebase_storage_platform_interface + sha256: "462621bbdb5ab496518aa0f4785cb6db87763d5f1063aa228e1f65562937af1d" + url: "https://pub.dev" + source: hosted + version: "5.1.31" + firebase_storage_web: + dependency: transitive + description: + name: firebase_storage_web + sha256: d9221c943c1341ee2cba51857ddb5916686994b16b181e9e9d2e0d5a9056f9b7 + url: "https://pub.dev" + source: hosted + version: "3.10.3" + fixnum: + dependency: transitive + description: + name: fixnum + sha256: "25517a4deb0c03aa0f32fd12db525856438902d9c16536311e76cdc57b31d7d1" + url: "https://pub.dev" + source: hosted + version: "1.1.0" + flutter: + dependency: "direct main" + description: flutter + source: sdk + version: "0.0.0" + flutter_bloc: + dependency: "direct main" + description: + name: flutter_bloc + sha256: b594505eac31a0518bdcb4b5b79573b8d9117b193cc80cc12e17d639b10aa27a + url: "https://pub.dev" + source: hosted + version: "8.1.6" + flutter_dotenv: + dependency: "direct main" + description: + name: flutter_dotenv + sha256: b7c7be5cd9f6ef7a78429cabd2774d3c4af50e79cb2b7593e3d5d763ef95c61b + url: "https://pub.dev" + source: hosted + version: "5.2.1" + flutter_lints: + dependency: "direct dev" + description: + name: flutter_lints + sha256: "3f41d009ba7172d5ff9be5f6e6e6abb4300e263aab8866d2a0842ed2a70f8f0c" + url: "https://pub.dev" + source: hosted + version: "4.0.0" + flutter_localizations: + dependency: "direct main" + description: flutter + source: sdk + version: "0.0.0" + flutter_native_splash: + dependency: "direct main" + description: + name: flutter_native_splash + sha256: aa06fec78de2190f3db4319dd60fdc8d12b2626e93ef9828633928c2dcaea840 + url: "https://pub.dev" + source: hosted + version: "2.4.1" + flutter_plugin_android_lifecycle: + dependency: transitive + description: + name: flutter_plugin_android_lifecycle + sha256: "9b78450b89f059e96c9ebb355fa6b3df1d6b330436e0b885fb49594c41721398" + url: "https://pub.dev" + source: hosted + version: "2.0.23" + flutter_test: + dependency: "direct dev" + description: flutter + source: sdk + version: "0.0.0" + flutter_web_plugins: + dependency: transitive + description: flutter + source: sdk + version: "0.0.0" + frontend_server_client: + dependency: transitive + description: + name: frontend_server_client + sha256: f64a0333a82f30b0cca061bc3d143813a486dc086b574bfb233b7c1372427694 + url: "https://pub.dev" + source: hosted + version: "4.0.0" + geolocator: + dependency: "direct main" + description: + name: geolocator + sha256: "0ec58b731776bc43097fcf751f79681b6a8f6d3bc737c94779fe9f1ad73c1a81" + url: "https://pub.dev" + source: hosted + version: "13.0.1" + geolocator_android: + dependency: transitive + description: + name: geolocator_android + sha256: "7aefc530db47d90d0580b552df3242440a10fe60814496a979aa67aa98b1fd47" + url: "https://pub.dev" + source: hosted + version: "4.6.1" + geolocator_apple: + dependency: transitive + description: + name: geolocator_apple + sha256: bc2aca02423ad429cb0556121f56e60360a2b7d694c8570301d06ea0c00732fd + url: "https://pub.dev" + source: hosted + version: "2.3.7" + geolocator_platform_interface: + dependency: transitive + description: + name: geolocator_platform_interface + sha256: "386ce3d9cce47838355000070b1d0b13efb5bc430f8ecda7e9238c8409ace012" + url: "https://pub.dev" + source: hosted + version: "4.2.4" + geolocator_web: + dependency: transitive + description: + name: geolocator_web + sha256: "2ed69328e05cd94e7eb48bb0535f5fc0c0c44d1c4fa1e9737267484d05c29b5e" + url: "https://pub.dev" + source: hosted + version: "4.1.1" + geolocator_windows: + dependency: transitive + description: + name: geolocator_windows + sha256: "53da08937d07c24b0d9952eb57a3b474e29aae2abf9dd717f7e1230995f13f0e" + url: "https://pub.dev" + source: hosted + version: "0.2.3" + get: + dependency: "direct main" + description: + name: get + sha256: e4e7335ede17452b391ed3b2ede016545706c01a02292a6c97619705e7d2a85e + url: "https://pub.dev" + source: hosted + version: "4.6.6" + get_storage: + dependency: "direct main" + description: + name: get_storage + sha256: "39db1fffe779d0c22b3a744376e86febe4ade43bf65e06eab5af707dc84185a2" + url: "https://pub.dev" + source: hosted + version: "2.1.1" + glob: + dependency: transitive + description: + name: glob + sha256: "0e7014b3b7d4dac1ca4d6114f82bf1782ee86745b9b42a92c9289c23d8a0ab63" + url: "https://pub.dev" + source: hosted + version: "2.1.2" + google_fonts: + dependency: "direct main" + description: + name: google_fonts + sha256: b1ac0fe2832c9cc95e5e88b57d627c5e68c223b9657f4b96e1487aa9098c7b82 + url: "https://pub.dev" + source: hosted + version: "6.2.1" + google_generative_ai: + dependency: "direct main" + description: + name: google_generative_ai + sha256: "81dae159c89e4d9bdc46955b6f4ee5ae0a291f9e8f990d76f43944e0d6041d4f" + url: "https://pub.dev" + source: hosted + version: "0.4.6" + google_identity_services_web: + dependency: transitive + description: + name: google_identity_services_web + sha256: "5be191523702ba8d7a01ca97c17fca096822ccf246b0a9f11923a6ded06199b6" + url: "https://pub.dev" + source: hosted + version: "0.3.1+4" + google_sign_in: + dependency: "direct main" + description: + name: google_sign_in + sha256: "0b8787cb9c1a68ad398e8010e8c8766bfa33556d2ab97c439fb4137756d7308f" + url: "https://pub.dev" + source: hosted + version: "6.2.1" + google_sign_in_android: + dependency: transitive + description: + name: google_sign_in_android + sha256: "0928059d2f0840f63c7b07a30cf73b593ae872cdd0dbd46d1b9ba878d2599c01" + url: "https://pub.dev" + source: hosted + version: "6.1.33" + google_sign_in_ios: + dependency: transitive + description: + name: google_sign_in_ios + sha256: "83f015169102df1ab2905cf8abd8934e28f87db9ace7a5fa676998842fed228a" + url: "https://pub.dev" + source: hosted + version: "5.7.8" + google_sign_in_platform_interface: + dependency: transitive + description: + name: google_sign_in_platform_interface + sha256: "1f6e5787d7a120cc0359ddf315c92309069171306242e181c09472d1b00a2971" + url: "https://pub.dev" + source: hosted + version: "2.4.5" + google_sign_in_web: + dependency: transitive + description: + name: google_sign_in_web + sha256: "042805a21127a85b0dc46bba98a37926f17d2439720e8a459d27045d8ef68055" + url: "https://pub.dev" + source: hosted + version: "0.12.4+2" + graphs: + dependency: transitive + description: + name: graphs + sha256: "741bbf84165310a68ff28fe9e727332eef1407342fca52759cb21ad8177bb8d0" + url: "https://pub.dev" + source: hosted + version: "2.3.2" + html: + dependency: transitive + description: + name: html + sha256: "3a7812d5bcd2894edf53dfaf8cd640876cf6cef50a8f238745c8b8120ea74d3a" + url: "https://pub.dev" + source: hosted + version: "0.15.4" + http: + dependency: "direct main" + description: + name: http + sha256: b9c29a161230ee03d3ccf545097fccd9b87a5264228c5d348202e0f0c28f9010 + url: "https://pub.dev" + source: hosted + version: "1.2.2" + http_multi_server: + dependency: transitive + description: + name: http_multi_server + sha256: "97486f20f9c2f7be8f514851703d0119c3596d14ea63227af6f7a481ef2b2f8b" + url: "https://pub.dev" + source: hosted + version: "3.2.1" + http_parser: + dependency: transitive + description: + name: http_parser + sha256: "2aa08ce0341cc9b354a498388e30986515406668dbcc4f7c950c3e715496693b" + url: "https://pub.dev" + source: hosted + version: "4.0.2" + icons_launcher: + dependency: "direct main" + description: + name: icons_launcher + sha256: a7c83fbc837dc6f81944ef35c3756f533bb2aba32fcca5cbcdb2dbcd877d5ae9 + url: "https://pub.dev" + source: hosted + version: "3.0.0" + iconsax: + dependency: "direct main" + description: + name: iconsax + sha256: fb0144c61f41f3f8a385fadc27783ea9f5359670be885ed7f35cef32565d5228 + url: "https://pub.dev" + source: hosted + version: "0.0.8" + image: + dependency: transitive + description: + name: image + sha256: "2237616a36c0d69aef7549ab439b833fb7f9fb9fc861af2cc9ac3eedddd69ca8" + url: "https://pub.dev" + source: hosted + version: "4.2.0" + image_picker: + dependency: "direct main" + description: + name: image_picker + sha256: "021834d9c0c3de46bf0fe40341fa07168407f694d9b2bb18d532dc1261867f7a" + url: "https://pub.dev" + source: hosted + version: "1.1.2" + image_picker_android: + dependency: transitive + description: + name: image_picker_android + sha256: d3e5e00fdfeca8fd4ffb3227001264d449cc8950414c2ff70b0e06b9c628e643 + url: "https://pub.dev" + source: hosted + version: "0.8.12+15" + image_picker_for_web: + dependency: transitive + description: + name: image_picker_for_web + sha256: "65d94623e15372c5c51bebbcb820848d7bcb323836e12dfdba60b5d3a8b39e50" + url: "https://pub.dev" + source: hosted + version: "3.0.5" + image_picker_ios: + dependency: transitive + description: + name: image_picker_ios + sha256: "6703696ad49f5c3c8356d576d7ace84d1faf459afb07accbb0fae780753ff447" + url: "https://pub.dev" + source: hosted + version: "0.8.12" + image_picker_linux: + dependency: transitive + description: + name: image_picker_linux + sha256: "4ed1d9bb36f7cd60aa6e6cd479779cc56a4cb4e4de8f49d487b1aaad831300fa" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" + image_picker_macos: + dependency: transitive + description: + name: image_picker_macos + sha256: "3f5ad1e8112a9a6111c46d0b57a7be2286a9a07fc6e1976fdf5be2bd31d4ff62" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" + image_picker_platform_interface: + dependency: transitive + description: + name: image_picker_platform_interface + sha256: "9ec26d410ff46f483c5519c29c02ef0e02e13a543f882b152d4bfd2f06802f80" + url: "https://pub.dev" + source: hosted + version: "2.10.0" + image_picker_windows: + dependency: transitive + description: + name: image_picker_windows + sha256: "6ad07afc4eb1bc25f3a01084d28520496c4a3bb0cb13685435838167c9dcedeb" + url: "https://pub.dev" + source: hosted + version: "0.2.1+1" + intl: + dependency: "direct main" + description: + name: intl + sha256: d6f56758b7d3014a48af9701c085700aac781a92a87a62b1333b46d8879661cf + url: "https://pub.dev" + source: hosted + version: "0.19.0" + io: + dependency: transitive + description: + name: io + sha256: "2ec25704aba361659e10e3e5f5d672068d332fc8ac516421d483a11e5cbd061e" + url: "https://pub.dev" + source: hosted + version: "1.0.4" + js: + dependency: transitive + description: + name: js + sha256: c1b2e9b5ea78c45e1a0788d29606ba27dc5f71f019f32ca5140f61ef071838cf + url: "https://pub.dev" + source: hosted + version: "0.7.1" + json_annotation: + dependency: transitive + description: + name: json_annotation + sha256: "1ce844379ca14835a50d2f019a3099f419082cfdd231cd86a142af94dd5c6bb1" + url: "https://pub.dev" + source: hosted + version: "4.9.0" + jwt_decoder: + dependency: "direct main" + description: + name: jwt_decoder + sha256: "54774aebf83f2923b99e6416b4ea915d47af3bde56884eb622de85feabbc559f" + url: "https://pub.dev" + source: hosted + version: "2.0.1" + leak_tracker: + dependency: transitive + description: + name: leak_tracker + sha256: "3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05" + url: "https://pub.dev" + source: hosted + version: "10.0.5" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + sha256: "932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806" + url: "https://pub.dev" + source: hosted + version: "3.0.5" + leak_tracker_testing: + dependency: transitive + description: + name: leak_tracker_testing + sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" + url: "https://pub.dev" + source: hosted + version: "3.0.1" + lints: + dependency: transitive + description: + name: lints + sha256: "976c774dd944a42e83e2467f4cc670daef7eed6295b10b36ae8c85bcbf828235" + url: "https://pub.dev" + source: hosted + version: "4.0.0" + logging: + dependency: transitive + description: + name: logging + sha256: "623a88c9594aa774443aa3eb2d41807a48486b5613e67599fb4c41c0ad47c340" + url: "https://pub.dev" + source: hosted + version: "1.2.0" + macros: + dependency: transitive + description: + name: macros + sha256: "0acaed5d6b7eab89f63350bccd82119e6c602df0f391260d0e32b5e23db79536" + url: "https://pub.dev" + source: hosted + version: "0.1.2-main.4" + matcher: + dependency: transitive + description: + name: matcher + sha256: d2323aa2060500f906aa31a895b4030b6da3ebdcc5619d14ce1aada65cd161cb + url: "https://pub.dev" + source: hosted + version: "0.12.16+1" + material_color_utilities: + dependency: transitive + description: + name: material_color_utilities + sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec + url: "https://pub.dev" + source: hosted + version: "0.11.1" + meta: + dependency: transitive + description: + name: meta + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 + url: "https://pub.dev" + source: hosted + version: "1.15.0" + mime: + dependency: transitive + description: + name: mime + sha256: "801fd0b26f14a4a58ccb09d5892c3fbdeff209594300a542492cf13fba9d247a" + url: "https://pub.dev" + source: hosted + version: "1.0.6" + mongo_dart: + dependency: "direct main" + description: + name: mongo_dart + sha256: b0078dd433ecad7d250abaa6437cb720dd16cbfa9b8cc020460698e0703d7bc9 + url: "https://pub.dev" + source: hosted + version: "0.10.3" + mongo_dart_query: + dependency: transitive + description: + name: mongo_dart_query + sha256: "7a0f3981c3d1df467040e5654696cb0bfde6ec6db86ba313118fb3e873cee657" + url: "https://pub.dev" + source: hosted + version: "5.0.2" + nested: + dependency: transitive + description: + name: nested + sha256: "03bac4c528c64c95c722ec99280375a6f2fc708eec17c7b3f07253b626cd2a20" + url: "https://pub.dev" + source: hosted + version: "1.0.0" + package_config: + dependency: transitive + description: + name: package_config + sha256: "1c5b77ccc91e4823a5af61ee74e6b972db1ef98c2ff5a18d3161c982a55448bd" + url: "https://pub.dev" + source: hosted + version: "2.1.0" + packages_extensions: + dependency: transitive + description: + name: packages_extensions + sha256: "268108a92be955e33a58cf6492e289e43ef55a50c89fa64947f032f5cefeb3fc" + url: "https://pub.dev" + source: hosted + version: "0.1.0" + path: + dependency: transitive + description: + name: path + sha256: "087ce49c3f0dc39180befefc60fdb4acd8f8620e5682fe2476afd0b3688bb4af" + url: "https://pub.dev" + source: hosted + version: "1.9.0" + path_provider: + dependency: transitive + description: + name: path_provider + sha256: fec0d61223fba3154d87759e3cc27fe2c8dc498f6386c6d6fc80d1afdd1bf378 + url: "https://pub.dev" + source: hosted + version: "2.1.4" + path_provider_android: + dependency: transitive + description: + name: path_provider_android + sha256: c464428172cb986b758c6d1724c603097febb8fb855aa265aeecc9280c294d4a + url: "https://pub.dev" + source: hosted + version: "2.2.12" + path_provider_foundation: + dependency: transitive + description: + name: path_provider_foundation + sha256: f234384a3fdd67f989b4d54a5d73ca2a6c422fa55ae694381ae0f4375cd1ea16 + url: "https://pub.dev" + source: hosted + version: "2.4.0" + path_provider_linux: + dependency: transitive + description: + name: path_provider_linux + sha256: f7a1fe3a634fe7734c8d3f2766ad746ae2a2884abe22e241a8b301bf5cac3279 + url: "https://pub.dev" + source: hosted + version: "2.2.1" + path_provider_platform_interface: + dependency: transitive + description: + name: path_provider_platform_interface + sha256: "88f5779f72ba699763fa3a3b06aa4bf6de76c8e5de842cf6f29e2e06476c2334" + url: "https://pub.dev" + source: hosted + version: "2.1.2" + path_provider_windows: + dependency: transitive + description: + name: path_provider_windows + sha256: bd6f00dbd873bfb70d0761682da2b3a2c2fccc2b9e84c495821639601d81afe7 + url: "https://pub.dev" + source: hosted + version: "2.3.0" + petitparser: + dependency: transitive + description: + name: petitparser + sha256: c15605cd28af66339f8eb6fbe0e541bfe2d1b72d5825efc6598f3e0a31b9ad27 + url: "https://pub.dev" + source: hosted + version: "6.0.2" + platform: + dependency: transitive + description: + name: platform + sha256: "9b71283fc13df574056616011fb138fd3b793ea47cc509c189a6c3fa5f8a1a65" + url: "https://pub.dev" + source: hosted + version: "3.1.5" + plugin_platform_interface: + dependency: transitive + description: + name: plugin_platform_interface + sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02" + url: "https://pub.dev" + source: hosted + version: "2.1.8" + pointycastle: + dependency: transitive + description: + name: pointycastle + sha256: "4be0097fcf3fd3e8449e53730c631200ebc7b88016acecab2b0da2f0149222fe" + url: "https://pub.dev" + source: hosted + version: "3.9.1" + pool: + dependency: transitive + description: + name: pool + sha256: "20fe868b6314b322ea036ba325e6fc0711a22948856475e2c2b6306e8ab39c2a" + url: "https://pub.dev" + source: hosted + version: "1.5.1" + power_extensions: + dependency: transitive + description: + name: power_extensions + sha256: ad0e8b2420090d996fe8b7fd32cdf02b9b924b6d4fc0fb0b559ff6aa5e24d5b0 + url: "https://pub.dev" + source: hosted + version: "0.2.3" + provider: + dependency: transitive + description: + name: provider + sha256: c8a055ee5ce3fd98d6fc872478b03823ffdb448699c6ebdbbc71d59b596fd48c + url: "https://pub.dev" + source: hosted + version: "6.1.2" + pub_semver: + dependency: transitive + description: + name: pub_semver + sha256: "40d3ab1bbd474c4c2328c91e3a7df8c6dd629b79ece4c4bd04bee496a224fb0c" + url: "https://pub.dev" + source: hosted + version: "2.1.4" + pubspec_parse: + dependency: transitive + description: + name: pubspec_parse + sha256: c799b721d79eb6ee6fa56f00c04b472dcd44a30d258fac2174a6ec57302678f8 + url: "https://pub.dev" + source: hosted + version: "1.3.0" + rational: + dependency: transitive + description: + name: rational + sha256: cb808fb6f1a839e6fc5f7d8cb3b0a10e1db48b3be102de73938c627f0b636336 + url: "https://pub.dev" + source: hosted + version: "2.2.3" + sasl_scram: + dependency: transitive + description: + name: sasl_scram + sha256: a47207a436eb650f8fdcf54a2e2587b850dc3caef9973ce01f332b07a6fc9cb9 + url: "https://pub.dev" + source: hosted + version: "0.1.1" + saslprep: + dependency: transitive + description: + name: saslprep + sha256: "3d421d10be9513bf4459c17c5e70e7b8bc718c9fc5ad4ba5eb4f5fd27396f740" + url: "https://pub.dev" + source: hosted + version: "1.0.3" + shared_preferences: + dependency: "direct main" + description: + name: shared_preferences + sha256: "746e5369a43170c25816cc472ee016d3a66bc13fcf430c0bc41ad7b4b2922051" + url: "https://pub.dev" + source: hosted + version: "2.3.2" + shared_preferences_android: + dependency: transitive + description: + name: shared_preferences_android + sha256: "3b9febd815c9ca29c9e3520d50ec32f49157711e143b7a4ca039eb87e8ade5ab" + url: "https://pub.dev" + source: hosted + version: "2.3.3" + shared_preferences_foundation: + dependency: transitive + description: + name: shared_preferences_foundation + sha256: "07e050c7cd39bad516f8d64c455f04508d09df104be326d8c02551590a0d513d" + url: "https://pub.dev" + source: hosted + version: "2.5.3" + shared_preferences_linux: + dependency: transitive + description: + name: shared_preferences_linux + sha256: "580abfd40f415611503cae30adf626e6656dfb2f0cee8f465ece7b6defb40f2f" + url: "https://pub.dev" + source: hosted + version: "2.4.1" + shared_preferences_platform_interface: + dependency: transitive + description: + name: shared_preferences_platform_interface + sha256: "57cbf196c486bc2cf1f02b85784932c6094376284b3ad5779d1b1c6c6a816b80" + url: "https://pub.dev" + source: hosted + version: "2.4.1" + shared_preferences_web: + dependency: transitive + description: + name: shared_preferences_web + sha256: d2ca4132d3946fec2184261726b355836a82c33d7d5b67af32692aff18a4684e + url: "https://pub.dev" + source: hosted + version: "2.4.2" + shared_preferences_windows: + dependency: transitive + description: + name: shared_preferences_windows + sha256: "94ef0f72b2d71bc3e700e025db3710911bd51a71cefb65cc609dd0d9a982e3c1" + url: "https://pub.dev" + source: hosted + version: "2.4.1" + shelf: + dependency: transitive + description: + name: shelf + sha256: ad29c505aee705f41a4d8963641f91ac4cee3c8fad5947e033390a7bd8180fa4 + url: "https://pub.dev" + source: hosted + version: "1.4.1" + shelf_web_socket: + dependency: transitive + description: + name: shelf_web_socket + sha256: "073c147238594ecd0d193f3456a5fe91c4b0abbcc68bf5cd95b36c4e194ac611" + url: "https://pub.dev" + source: hosted + version: "2.0.0" + simple_gesture_detector: + dependency: transitive + description: + name: simple_gesture_detector + sha256: ba2cd5af24ff20a0b8d609cec3f40e5b0744d2a71804a2616ae086b9c19d19a3 + url: "https://pub.dev" + source: hosted + version: "0.2.1" + sky_engine: + dependency: transitive + description: flutter + source: sdk + version: "0.0.99" + smooth_page_indicator: + dependency: "direct main" + description: + name: smooth_page_indicator + sha256: "3b28b0c545fa67ed9e5997d9f9720d486f54c0c607e056a1094544e36934dff3" + url: "https://pub.dev" + source: hosted + version: "1.2.0+3" + source_span: + dependency: transitive + description: + name: source_span + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" + url: "https://pub.dev" + source: hosted + version: "1.10.0" + sprintf: + dependency: transitive + description: + name: sprintf + sha256: "1fc9ffe69d4df602376b52949af107d8f5703b77cda567c4d7d86a0693120f23" + url: "https://pub.dev" + source: hosted + version: "7.0.0" + stack_trace: + dependency: transitive + description: + name: stack_trace + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" + url: "https://pub.dev" + source: hosted + version: "1.11.1" + stream_channel: + dependency: transitive + description: + name: stream_channel + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 + url: "https://pub.dev" + source: hosted + version: "2.1.2" + stream_transform: + dependency: transitive + description: + name: stream_transform + sha256: "14a00e794c7c11aa145a170587321aedce29769c08d7f58b1d141da75e3b1c6f" + url: "https://pub.dev" + source: hosted + version: "2.1.0" + string_scanner: + dependency: transitive + description: + name: string_scanner + sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" + url: "https://pub.dev" + source: hosted + version: "1.2.0" + table_calendar: + dependency: "direct main" + description: + name: table_calendar + sha256: "4ca32b2fc919452c9974abd4c6ea611a63e33b9e4f0b8c38dba3ac1f4a6549d1" + url: "https://pub.dev" + source: hosted + version: "3.1.2" + term_glyph: + dependency: transitive + description: + name: term_glyph + sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 + url: "https://pub.dev" + source: hosted + version: "1.2.1" + test_api: + dependency: transitive + description: + name: test_api + sha256: "5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb" + url: "https://pub.dev" + source: hosted + version: "0.7.2" + timing: + dependency: transitive + description: + name: timing + sha256: "70a3b636575d4163c477e6de42f247a23b315ae20e86442bebe32d3cabf61c32" + url: "https://pub.dev" + source: hosted + version: "1.0.1" + typed_data: + dependency: transitive + description: + name: typed_data + sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c + url: "https://pub.dev" + source: hosted + version: "1.3.2" + universal_io: + dependency: transitive + description: + name: universal_io + sha256: "1722b2dcc462b4b2f3ee7d188dad008b6eb4c40bbd03a3de451d82c78bba9aad" + url: "https://pub.dev" + source: hosted + version: "2.2.2" + unorm_dart: + dependency: transitive + description: + name: unorm_dart + sha256: "23d8bf65605401a6a32cff99435fed66ef3dab3ddcad3454059165df46496a3b" + url: "https://pub.dev" + source: hosted + version: "0.3.0" + url_launcher: + dependency: "direct main" + description: + name: url_launcher + sha256: "9d06212b1362abc2f0f0d78e6f09f726608c74e3b9462e8368bb03314aa8d603" + url: "https://pub.dev" + source: hosted + version: "6.3.1" + url_launcher_android: + dependency: transitive + description: + name: url_launcher_android + sha256: "8fc3bae0b68c02c47c5c86fa8bfa74471d42687b0eded01b78de87872db745e2" + url: "https://pub.dev" + source: hosted + version: "6.3.12" + url_launcher_ios: + dependency: transitive + description: + name: url_launcher_ios + sha256: e43b677296fadce447e987a2f519dcf5f6d1e527dc35d01ffab4fff5b8a7063e + url: "https://pub.dev" + source: hosted + version: "6.3.1" + url_launcher_linux: + dependency: transitive + description: + name: url_launcher_linux + sha256: e2b9622b4007f97f504cd64c0128309dfb978ae66adbe944125ed9e1750f06af + url: "https://pub.dev" + source: hosted + version: "3.2.0" + url_launcher_macos: + dependency: transitive + description: + name: url_launcher_macos + sha256: "769549c999acdb42b8bcfa7c43d72bf79a382ca7441ab18a808e101149daf672" + url: "https://pub.dev" + source: hosted + version: "3.2.1" + url_launcher_platform_interface: + dependency: transitive + description: + name: url_launcher_platform_interface + sha256: "552f8a1e663569be95a8190206a38187b531910283c3e982193e4f2733f01029" + url: "https://pub.dev" + source: hosted + version: "2.3.2" + url_launcher_web: + dependency: transitive + description: + name: url_launcher_web + sha256: "772638d3b34c779ede05ba3d38af34657a05ac55b06279ea6edd409e323dca8e" + url: "https://pub.dev" + source: hosted + version: "2.3.3" + url_launcher_windows: + dependency: transitive + description: + name: url_launcher_windows + sha256: "49c10f879746271804767cb45551ec5592cdab00ee105c06dddde1a98f73b185" + url: "https://pub.dev" + source: hosted + version: "3.1.2" + uuid: + dependency: transitive + description: + name: uuid + sha256: a5be9ef6618a7ac1e964353ef476418026db906c4facdedaa299b7a2e71690ff + url: "https://pub.dev" + source: hosted + version: "4.5.1" + vector_math: + dependency: transitive + description: + name: vector_math + sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" + url: "https://pub.dev" + source: hosted + version: "2.1.4" + vm_service: + dependency: transitive + description: + name: vm_service + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" + url: "https://pub.dev" + source: hosted + version: "14.2.5" + vy_string_utils: + dependency: transitive + description: + name: vy_string_utils + sha256: "03f4f2ebba283b32623459fa9c47d5c70e085253c7891f5ef7d4fd539c41c078" + url: "https://pub.dev" + source: hosted + version: "0.4.6" + watcher: + dependency: transitive + description: + name: watcher + sha256: "3d2ad6751b3c16cf07c7fca317a1413b3f26530319181b37e3b9039b84fc01d8" + url: "https://pub.dev" + source: hosted + version: "1.1.0" + web: + dependency: transitive + description: + name: web + sha256: cd3543bd5798f6ad290ea73d210f423502e71900302dde696f8bff84bf89a1cb + url: "https://pub.dev" + source: hosted + version: "1.1.0" + web_socket: + dependency: transitive + description: + name: web_socket + sha256: "3c12d96c0c9a4eec095246debcea7b86c0324f22df69893d538fcc6f1b8cce83" + url: "https://pub.dev" + source: hosted + version: "0.1.6" + web_socket_channel: + dependency: transitive + description: + name: web_socket_channel + sha256: "9f187088ed104edd8662ca07af4b124465893caf063ba29758f97af57e61da8f" + url: "https://pub.dev" + source: hosted + version: "3.0.1" + xdg_directories: + dependency: transitive + description: + name: xdg_directories + sha256: "7a3f37b05d989967cdddcbb571f1ea834867ae2faa29725fd085180e0883aa15" + url: "https://pub.dev" + source: hosted + version: "1.1.0" + xml: + dependency: transitive + description: + name: xml + sha256: b015a8ad1c488f66851d762d3090a21c600e479dc75e68328c52774040cf9226 + url: "https://pub.dev" + source: hosted + version: "6.5.0" + yaml: + dependency: transitive + description: + name: yaml + sha256: "75769501ea3489fca56601ff33454fe45507ea3bfb014161abc3b43ae25989d5" + url: "https://pub.dev" + source: hosted + version: "3.1.2" +sdks: + dart: ">=3.5.0 <4.0.0" + flutter: ">=3.24.0" diff --git a/pubspec.yaml b/pubspec.yaml new file mode 100644 index 0000000..00446e9 --- /dev/null +++ b/pubspec.yaml @@ -0,0 +1,160 @@ +name: donorconnect +description: "A new Flutter project." +# The following line prevents the package from being accidentally published to +# pub.dev using `flutter 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. +version: 1.0.0+1 + +environment: + sdk: ^3.3.4 + +# Dependencies specify other packages that your package needs in order to work. +# To automatically upgrade your package dependencies to the latest versions +# consider running `flutter pub upgrade --major-versions`. Alternatively, +# dependencies can be manually updated by changing the version numbers below to +# the latest version available on pub.dev. To see which dependencies have newer +# versions available, run `flutter pub outdated`. +dependencies: + flutter: + sdk: flutter + flutter_native_splash: ^2.4.1 + # The following adds the Cupertino Icons font to your application. + # Use with the CupertinoIcons class for iOS style icons. + cupertino_icons: ^1.0.8 + http: ^1.2.2 + shared_preferences: ^2.2.3 + jwt_decoder: ^2.0.1 + get: ^4.6.6 + google_fonts: ^6.2.1 + icons_launcher: ^3.0.0 + flutter_bloc: ^8.1.6 + firebase_core: ^3.6.0 + firebase_auth: ^5.3.1 + cloud_firestore: ^5.4.4 + equatable: ^2.0.5 + firebase_storage: ^12.3.3 + image_picker: ^1.1.2 + custom_navigation_bar: ^0.8.2 + smooth_page_indicator: ^1.1.0 + iconsax: ^0.0.8 + # riverpod: ^2.5.3 + # riverpod_annotation: ^2.5.3 + flutter_localizations: + sdk: flutter + intl: ^0.19.0 + geolocator: ^13.0.1 + mongo_dart: ^0.10.3 + url_launcher: ^6.3.1 + table_calendar: ^3.1.2 + + dropdown_textfield: ^1.2.0 + google_sign_in: ^6.2.1 + animated_toggle_switch: ^0.8.3 + get_storage: ^2.1.1 + + google_generative_ai: ^0.4.6 + flutter_dotenv: ^5.2.1 + + +dev_dependencies: + flutter_test: + sdk: flutter + # The "flutter_lints" package below contains a set of recommended lints to + # encourage good coding practices. The lint set provided by the package is + # activated in the `analysis_options.yaml` file located at the root of your + # package. See that file for information about deactivating specific lint + # rules and activating additional ones. + flutter_lints: ^4.0.0 + # riverpod_generator: ^2.4.3 + build_runner: ^2.4.13 + +# 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 packages. +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 + generate: true + + # To add assets to your application, add an assets section, like this: + assets: + - assets/images/ + + # An image asset can refer to one or more resolution-specific "variants", see + # https://flutter.dev/to/resolution-aware-images + + # For details regarding adding assets from package dependencies, see + # https://flutter.dev/to/asset-from-package + + # 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/to/font-from-package + +flutter_native_splash: + # This package generates native code to customize Flutter's default white native splash screen + # with background color and splash image. + # Customize the parameters below, and run the following command in the terminal: + # dart run flutter_native_splash:create + # To restore Flutter's default white splash screen, run the following command in the terminal: + # dart run flutter_native_splash:remove + + # IMPORTANT NOTE: These parameters do not affect the configuration of Android 12 and later, which + # handle splash screens differently than prior versions of Android. Android 12 and later must be + # configured specifically in the android_12 section below. + + # color or background_image is the only required parameter. Use color to set the background + # of your splash screen to a solid color. Use background_image to set the background of your + # splash screen to a png image. This is useful for gradients. The image will be stretched to the + # size of the app. Only one parameter can be used; color and background_image cannot both be set. + color: "#ffffff" + #background_image: "assets/" + + # Optional parameters are listed below. To enable a parameter, uncomment the line by removing + # the leading # character. + + # The image parameter allows you to specify an image used in the splash screen. It must be a + # png file and should be sized for 4x pixel density. + image: assets/images/logo.png + + # From Android 12 onwards, the splash screen is handled differently than in previous versions. + # Following are specific parameters for Android 12+. + android_12: + # The image parameter sets the splash screen icon image. If this parameter is not specified, + # the app's launcher icon will be used instead. + image: assets/images/logo.png + + # Splash screen background color. + color: "#ffffff" + +icons_launcher: + image_path: "assets/images/launcher_icon.png" + platforms: + android: + enable: true + ios: + enable: true diff --git a/readme/gssoc_ext_2024.png b/readme/gssoc_ext_2024.png new file mode 100644 index 0000000..8edc338 Binary files /dev/null and b/readme/gssoc_ext_2024.png differ diff --git a/repo_structure.txt b/repo_structure.txt new file mode 100644 index 0000000..a532cce --- /dev/null +++ b/repo_structure.txt @@ -0,0 +1,403 @@ +├── CODE_OF_CONDUCT.md +├── Contributors.md +├── LICENSE.md +├── PROJECT_STRUCTURE.md +├── README.md +├── analysis_options.yaml +├── android/ +│ ├── app/ +│ │ ├── build.gradle +│ │ ├── google-services.json +│ │ └── src/ +│ │ ├── debug/ +│ │ │ └── AndroidManifest.xml +│ │ ├── main/ +│ │ │ ├── AndroidManifest.xml +│ │ │ ├── ic_launcher-playstore.png +│ │ │ ├── kotlin/ +│ │ │ │ └── com/ +│ │ │ │ └── example/ +│ │ │ │ └── donorconnect/ +│ │ │ │ └── MainActivity.kt +│ │ │ └── res/ +│ │ │ ├── drawable/ +│ │ │ │ ├── background.png +│ │ │ │ └── launch_background.xml +│ │ │ ├── drawable-hdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-hdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-mdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-mdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-hdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-hdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-mdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-mdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xxhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-night-xxxhdpi/ +│ │ │ │ └── android12splash.png +│ │ │ ├── drawable-night-xxxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-v21/ +│ │ │ │ ├── background.png +│ │ │ │ └── launch_background.xml +│ │ │ ├── drawable-xhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-xxhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── drawable-xxxhdpi/ +│ │ │ │ ├── android12splash.png +│ │ │ │ ├── branding.png +│ │ │ │ └── splash.png +│ │ │ ├── drawable-xxxhdpi-v31/ +│ │ │ │ └── android12branding.png +│ │ │ ├── mipmap-hdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-mdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xxhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── mipmap-xxxhdpi/ +│ │ │ │ └── ic_launcher.png +│ │ │ ├── values/ +│ │ │ │ └── styles.xml +│ │ │ ├── values-night/ +│ │ │ │ └── styles.xml +│ │ │ ├── values-night-v31/ +│ │ │ │ └── styles.xml +│ │ │ └── values-v31/ +│ │ │ └── styles.xml +│ │ └── profile/ +│ │ └── AndroidManifest.xml +│ ├── build.gradle +│ ├── gradle/ +│ │ └── wrapper/ +│ │ └── gradle-wrapper.properties +│ ├── gradle.properties +│ └── settings.gradle +├── assets/ +│ └── images/ +│ ├── OnBoarding1.jpg +│ ├── OnBoarding2.jpg +│ ├── OnBoarding3.jpg +│ ├── donorConnect.png +│ ├── donorConnect1.png +│ ├── empty_calendar.png +│ ├── google.png +│ ├── home.png +│ ├── home_image1.png +│ ├── home_image2.png +│ ├── launcher_icon.png +│ ├── launcher_icon1.png +│ ├── login.jpg +│ ├── logo.png +│ ├── logo1.png +│ └── signup.jpg +├── devtools_options.yaml +├── firebase.json +├── ios/ +│ ├── Flutter/ +│ │ ├── AppFrameworkInfo.plist +│ │ ├── Debug.xcconfig +│ │ └── Release.xcconfig +│ ├── Podfile +│ ├── Podfile.lock +│ ├── Runner/ +│ │ ├── AppDelegate.swift +│ │ ├── Assets.xcassets/ +│ │ │ ├── AppIcon.appiconset/ +│ │ │ │ ├── Contents.json +│ │ │ │ ├── Icon-App-1024x1024@1x.png +│ │ │ │ ├── Icon-App-20x20@1x.png +│ │ │ │ ├── Icon-App-20x20@2x.png +│ │ │ │ ├── Icon-App-20x20@3x.png +│ │ │ │ ├── Icon-App-29x29@1x.png +│ │ │ │ ├── Icon-App-29x29@2x.png +│ │ │ │ ├── Icon-App-29x29@3x.png +│ │ │ │ ├── Icon-App-38x38@2x.png +│ │ │ │ ├── Icon-App-38x38@3x.png +│ │ │ │ ├── Icon-App-40x40@1x.png +│ │ │ │ ├── Icon-App-40x40@2x.png +│ │ │ │ ├── Icon-App-40x40@3x.png +│ │ │ │ ├── Icon-App-60x60@2x.png +│ │ │ │ ├── Icon-App-60x60@3x.png +│ │ │ │ ├── Icon-App-64x64@2x.png +│ │ │ │ ├── Icon-App-64x64@3x.png +│ │ │ │ ├── Icon-App-68x68@2x.png +│ │ │ │ ├── Icon-App-76x76@1x.png +│ │ │ │ ├── Icon-App-76x76@2x.png +│ │ │ │ └── Icon-App-83.5x83.5@2x.png +│ │ │ ├── BrandingImage.imageset/ +│ │ │ │ ├── BrandingImage.png +│ │ │ │ ├── BrandingImage@2x.png +│ │ │ │ ├── BrandingImage@3x.png +│ │ │ │ └── Contents.json +│ │ │ ├── LaunchBackground.imageset/ +│ │ │ │ ├── Contents.json +│ │ │ │ └── background.png +│ │ │ └── LaunchImage.imageset/ +│ │ │ ├── Contents.json +│ │ │ ├── LaunchImage.png +│ │ │ ├── LaunchImage@2x.png +│ │ │ ├── LaunchImage@3x.png +│ │ │ └── README.md +│ │ ├── Base.lproj/ +│ │ │ ├── LaunchScreen.storyboard +│ │ │ └── Main.storyboard +│ │ ├── GoogleService-Info.plist +│ │ ├── 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 +│ └── RunnerTests/ +│ └── RunnerTests.swift +├── l10n.yaml +├── lib/ +│ ├── Utils/ +│ │ ├── Textbox.dart +│ │ ├── constants/ +│ │ │ ├── images_string.dart +│ │ │ └── text_string.dart +│ │ ├── show_snackbar.dart +│ │ └── validation_helpers.dart +│ ├── cubit/ +│ │ ├── auth/ +│ │ │ ├── auth_cubit.dart +│ │ │ └── auth_state.dart +│ │ ├── forgot_password/ +│ │ │ ├── forgot_password_cubit.dart +│ │ │ └── forgot_password_state.dart +│ │ ├── locate_blood_banks/ +│ │ │ └── locate_blood_banks_cubit.dart +│ │ ├── profile/ +│ │ │ ├── profile_cubit.dart +│ │ │ └── profile_state.dart +│ │ └── theme_toggle/ +│ │ ├── theme_cubit.dart +│ │ └── theme_state.dart +│ ├── firebase_options.dart +│ ├── l10n/ +│ │ ├── intl_en.arb +│ │ ├── intl_gu.arb +│ │ └── intl_hi.arb +│ ├── language/ +│ │ ├── cubit/ +│ │ │ └── language_cubit.dart +│ │ ├── helper/ +│ │ │ ├── langauge_popup.dart +│ │ │ ├── language.dart +│ │ │ └── language_extention.dart +│ │ └── services/ +│ │ └── language_repositoty.dart +│ ├── main.dart +│ ├── models/ +│ │ ├── user_model.dart +│ │ └── verification_status.dart +│ ├── secrets.dart +│ ├── services/ +│ │ ├── blood_bank_service.dart +│ │ └── verification_service.dart +│ └── views/ +│ ├── common_widgets/ +│ │ ├── donor_card.dart +│ │ ├── events_card.dart +│ │ ├── home_card.dart +│ │ ├── home_card_form.dart +│ │ ├── rounded_conatiner.dart +│ │ ├── rounded_image.dart +│ │ └── toggle_button.dart +│ ├── controllers/ +│ │ └── onboarding/ +│ │ └── onboarding_controller.dart +│ ├── pages/ +│ │ ├── Required/ +│ │ │ ├── required_screen.dart +│ │ │ └── widgets/ +│ │ │ └── choice_chip.dart +│ │ ├── camps/ +│ │ │ ├── calendarPage.dart +│ │ │ └── campsPage.dart +│ │ ├── forgot_password/ +│ │ │ ├── change-password.dart +│ │ │ └── forgot-password.dart +│ │ ├── learn_about_donation/ +│ │ │ └── learn_about_donation.dart +│ │ ├── locate_blood_banks/ +│ │ │ └── locate_blood_banks.dart +│ │ ├── login/ +│ │ │ └── login.dart +│ │ ├── main_home/ +│ │ │ ├── bottom_nav.dart +│ │ │ ├── chatbot.dart +│ │ │ ├── home_pages/ +│ │ │ │ └── home_screen.dart +│ │ │ └── homepage.dart +│ │ ├── onboarding/ +│ │ │ ├── onboarding.dart +│ │ │ └── widgets/ +│ │ │ ├── onboarding_dot_navigation.dart +│ │ │ ├── onboarding_next_button.dart +│ │ │ ├── onboarding_page.dart +│ │ │ └── onboarding_skip.dart +│ │ ├── profile/ +│ │ │ └── profile_screen.dart +│ │ ├── register/ +│ │ │ └── signup.dart +│ │ ├── search/ +│ │ │ ├── search_screen.dart +│ │ │ └── widgets/ +│ │ │ ├── blood_bank_form.dart +│ │ │ └── blood_donor_form.dart +│ │ └── welcome/ +│ │ └── welcome_screen.dart +│ └── verificationform.dart +├── linux/ +│ ├── CMakeLists.txt +│ ├── flutter/ +│ │ ├── CMakeLists.txt +│ │ ├── generated_plugin_registrant.cc +│ │ ├── generated_plugin_registrant.h +│ │ └── generated_plugins.cmake +│ ├── main.cc +│ ├── my_application.cc +│ └── my_application.h +├── macos/ +│ ├── Flutter/ +│ │ ├── Flutter-Debug.xcconfig +│ │ ├── Flutter-Release.xcconfig +│ │ └── GeneratedPluginRegistrant.swift +│ ├── Podfile +│ ├── Runner/ +│ │ ├── AppDelegate.swift +│ │ ├── Assets.xcassets/ +│ │ │ └── AppIcon.appiconset/ +│ │ │ ├── Contents.json +│ │ │ ├── app_icon_1024.png +│ │ │ ├── app_icon_128.png +│ │ │ ├── app_icon_16.png +│ │ │ ├── app_icon_256.png +│ │ │ ├── app_icon_32.png +│ │ │ ├── app_icon_512.png +│ │ │ └── app_icon_64.png +│ │ ├── Base.lproj/ +│ │ │ └── MainMenu.xib +│ │ ├── Configs/ +│ │ │ ├── AppInfo.xcconfig +│ │ │ ├── Debug.xcconfig +│ │ │ ├── Release.xcconfig +│ │ │ └── Warnings.xcconfig +│ │ ├── DebugProfile.entitlements +│ │ ├── GoogleService-Info.plist +│ │ ├── Info.plist +│ │ ├── MainFlutterWindow.swift +│ │ └── Release.entitlements +│ ├── Runner.xcodeproj/ +│ │ ├── project.pbxproj +│ │ ├── project.xcworkspace/ +│ │ │ └── xcshareddata/ +│ │ │ └── IDEWorkspaceChecks.plist +│ │ └── xcshareddata/ +│ │ └── xcschemes/ +│ │ └── Runner.xcscheme +│ ├── Runner.xcworkspace/ +│ │ ├── contents.xcworkspacedata +│ │ └── xcshareddata/ +│ │ └── IDEWorkspaceChecks.plist +│ └── RunnerTests/ +│ └── RunnerTests.swift +├── native_splash.yaml +├── pubspec.lock +├── pubspec.yaml +├── readme/ +│ └── gssoc_ext_2024.png +├── repo_structure.txt +├── test/ +│ └── widget_test.dart +├── web/ +│ ├── favicon.png +│ ├── icons/ +│ │ ├── Icon-192.png +│ │ ├── Icon-512.png +│ │ ├── Icon-maskable-192.png +│ │ └── Icon-maskable-512.png +│ ├── index.html +│ ├── manifest.json +│ └── splash/ +│ └── img/ +│ ├── branding-1x.png +│ ├── branding-2x.png +│ ├── branding-3x.png +│ ├── branding-4x.png +│ ├── branding-dark-1x.png +│ ├── branding-dark-2x.png +│ ├── branding-dark-3x.png +│ ├── branding-dark-4x.png +│ ├── dark-1x.png +│ ├── dark-2x.png +│ ├── dark-3x.png +│ ├── dark-4x.png +│ ├── light-1x.png +│ ├── light-2x.png +│ ├── light-3x.png +│ └── light-4x.png +└── windows/ + ├── CMakeLists.txt + ├── flutter/ + │ ├── CMakeLists.txt + │ ├── generated_plugin_registrant.cc + │ ├── generated_plugin_registrant.h + │ └── generated_plugins.cmake + └── runner/ + ├── CMakeLists.txt + ├── Runner.rc + ├── flutter_window.cpp + ├── flutter_window.h + ├── main.cpp + ├── resource.h + ├── resources/ + │ └── app_icon.ico + ├── runner.exe.manifest + ├── utils.cpp + ├── utils.h + ├── win32_window.cpp + └── win32_window.h \ No newline at end of file diff --git a/test/widget_test.dart b/test/widget_test.dart new file mode 100644 index 0000000..eb16bd8 --- /dev/null +++ b/test/widget_test.dart @@ -0,0 +1,32 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility in the flutter_test package. 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:donorconnect/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(const MyApp( + token: '', + )); + + // 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); + }); +} diff --git a/web/favicon.png b/web/favicon.png new file mode 100644 index 0000000..8aaa46a Binary files /dev/null and b/web/favicon.png differ diff --git a/web/icons/Icon-192.png b/web/icons/Icon-192.png new file mode 100644 index 0000000..b749bfe Binary files /dev/null and b/web/icons/Icon-192.png differ diff --git a/web/icons/Icon-512.png b/web/icons/Icon-512.png new file mode 100644 index 0000000..88cfd48 Binary files /dev/null and b/web/icons/Icon-512.png differ diff --git a/web/icons/Icon-maskable-192.png b/web/icons/Icon-maskable-192.png new file mode 100644 index 0000000..eb9b4d7 Binary files /dev/null and b/web/icons/Icon-maskable-192.png differ diff --git a/web/icons/Icon-maskable-512.png b/web/icons/Icon-maskable-512.png new file mode 100644 index 0000000..d69c566 Binary files /dev/null and b/web/icons/Icon-maskable-512.png differ diff --git a/web/index.html b/web/index.html new file mode 100644 index 0000000..41c66a4 --- /dev/null +++ b/web/index.html @@ -0,0 +1,139 @@ + + + + + + + + + + + + + + + + + + donorconnect + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/web/manifest.json b/web/manifest.json new file mode 100644 index 0000000..4ca217a --- /dev/null +++ b/web/manifest.json @@ -0,0 +1,35 @@ +{ + "name": "donorconnect", + "short_name": "donorconnect", + "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" + }, + { + "src": "icons/Icon-maskable-192.png", + "sizes": "192x192", + "type": "image/png", + "purpose": "maskable" + }, + { + "src": "icons/Icon-maskable-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "maskable" + } + ] +} diff --git a/web/splash/img/branding-1x.png b/web/splash/img/branding-1x.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/web/splash/img/branding-1x.png differ diff --git a/web/splash/img/branding-2x.png b/web/splash/img/branding-2x.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/web/splash/img/branding-2x.png differ diff --git a/web/splash/img/branding-3x.png b/web/splash/img/branding-3x.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/web/splash/img/branding-3x.png differ diff --git a/web/splash/img/branding-4x.png b/web/splash/img/branding-4x.png new file mode 100644 index 0000000..e588bb8 Binary files /dev/null and b/web/splash/img/branding-4x.png differ diff --git a/web/splash/img/branding-dark-1x.png b/web/splash/img/branding-dark-1x.png new file mode 100644 index 0000000..c7a0278 Binary files /dev/null and b/web/splash/img/branding-dark-1x.png differ diff --git a/web/splash/img/branding-dark-2x.png b/web/splash/img/branding-dark-2x.png new file mode 100644 index 0000000..bab0f04 Binary files /dev/null and b/web/splash/img/branding-dark-2x.png differ diff --git a/web/splash/img/branding-dark-3x.png b/web/splash/img/branding-dark-3x.png new file mode 100644 index 0000000..a44b36a Binary files /dev/null and b/web/splash/img/branding-dark-3x.png differ diff --git a/web/splash/img/branding-dark-4x.png b/web/splash/img/branding-dark-4x.png new file mode 100644 index 0000000..e588bb8 Binary files /dev/null and b/web/splash/img/branding-dark-4x.png differ diff --git a/web/splash/img/dark-1x.png b/web/splash/img/dark-1x.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/web/splash/img/dark-1x.png differ diff --git a/web/splash/img/dark-2x.png b/web/splash/img/dark-2x.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/web/splash/img/dark-2x.png differ diff --git a/web/splash/img/dark-3x.png b/web/splash/img/dark-3x.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/web/splash/img/dark-3x.png differ diff --git a/web/splash/img/dark-4x.png b/web/splash/img/dark-4x.png new file mode 100644 index 0000000..8760919 Binary files /dev/null and b/web/splash/img/dark-4x.png differ diff --git a/web/splash/img/light-1x.png b/web/splash/img/light-1x.png new file mode 100644 index 0000000..62ca2f4 Binary files /dev/null and b/web/splash/img/light-1x.png differ diff --git a/web/splash/img/light-2x.png b/web/splash/img/light-2x.png new file mode 100644 index 0000000..1c802d1 Binary files /dev/null and b/web/splash/img/light-2x.png differ diff --git a/web/splash/img/light-3x.png b/web/splash/img/light-3x.png new file mode 100644 index 0000000..8f88eaa Binary files /dev/null and b/web/splash/img/light-3x.png differ diff --git a/web/splash/img/light-4x.png b/web/splash/img/light-4x.png new file mode 100644 index 0000000..8760919 Binary files /dev/null and b/web/splash/img/light-4x.png differ diff --git a/windows/.gitignore b/windows/.gitignore new file mode 100644 index 0000000..d492d0d --- /dev/null +++ b/windows/.gitignore @@ -0,0 +1,17 @@ +flutter/ephemeral/ + +# Visual Studio user-specific files. +*.suo +*.user +*.userosscache +*.sln.docstates + +# Visual Studio build-related files. +x64/ +x86/ + +# Visual Studio cache files +# files ending in .cache can be ignored +*.[Cc]ache +# but keep track of directories ending in .cache +!*.[Cc]ache/ diff --git a/windows/CMakeLists.txt b/windows/CMakeLists.txt new file mode 100644 index 0000000..a2d7c98 --- /dev/null +++ b/windows/CMakeLists.txt @@ -0,0 +1,108 @@ +# Project-level configuration. +cmake_minimum_required(VERSION 3.14) +project(donorconnect LANGUAGES CXX) + +# The name of the executable created for the application. Change this to change +# the on-disk name of your application. +set(BINARY_NAME "donorconnect") + +# Explicitly opt in to modern CMake behaviors to avoid warnings with recent +# versions of CMake. +cmake_policy(VERSION 3.14...3.25) + +# Define build configuration option. +get_property(IS_MULTICONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) +if(IS_MULTICONFIG) + set(CMAKE_CONFIGURATION_TYPES "Debug;Profile;Release" + CACHE STRING "" FORCE) +else() + if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) + set(CMAKE_BUILD_TYPE "Debug" CACHE + STRING "Flutter build mode" FORCE) + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS + "Debug" "Profile" "Release") + endif() +endif() +# Define settings for the Profile build mode. +set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_RELEASE}") +set(CMAKE_SHARED_LINKER_FLAGS_PROFILE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE}") +set(CMAKE_C_FLAGS_PROFILE "${CMAKE_C_FLAGS_RELEASE}") +set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_RELEASE}") + +# Use Unicode for all projects. +add_definitions(-DUNICODE -D_UNICODE) + +# Compilation settings that should be applied to most targets. +# +# Be cautious about adding new options here, as plugins use this function by +# default. In most cases, you should add new options to specific targets instead +# of modifying this function. +function(APPLY_STANDARD_SETTINGS TARGET) + target_compile_features(${TARGET} PUBLIC cxx_std_17) + target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100") + target_compile_options(${TARGET} PRIVATE /EHsc) + target_compile_definitions(${TARGET} PRIVATE "_HAS_EXCEPTIONS=0") + target_compile_definitions(${TARGET} PRIVATE "$<$:_DEBUG>") +endfunction() + +# Flutter library and tool build rules. +set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter") +add_subdirectory(${FLUTTER_MANAGED_DIR}) + +# Application build; see runner/CMakeLists.txt. +add_subdirectory("runner") + + +# Generated plugin build rules, which manage building the plugins and adding +# them to the application. +include(flutter/generated_plugins.cmake) + + +# === Installation === +# Support files are copied into place next to the executable, so that it can +# run in place. This is done instead of making a separate bundle (as on Linux) +# so that building and running from within Visual Studio will work. +set(BUILD_BUNDLE_DIR "$") +# Make the "install" step default, as it's required to run. +set(CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD 1) +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) + set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE) +endif() + +set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data") +set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}") + +install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}" + COMPONENT Runtime) + +install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" + COMPONENT Runtime) + +install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) + +if(PLUGIN_BUNDLED_LIBRARIES) + install(FILES "${PLUGIN_BUNDLED_LIBRARIES}" + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) +endif() + +# Copy the native assets provided by the build.dart from all packages. +set(NATIVE_ASSETS_DIR "${PROJECT_BUILD_DIR}native_assets/windows/") +install(DIRECTORY "${NATIVE_ASSETS_DIR}" + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" + COMPONENT Runtime) + +# Fully re-copy the assets directory on each build to avoid having stale files +# from a previous install. +set(FLUTTER_ASSET_DIR_NAME "flutter_assets") +install(CODE " + file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") + " COMPONENT Runtime) +install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" + DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) + +# Install the AOT library on non-Debug builds only. +install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" + CONFIGURATIONS Profile;Release + COMPONENT Runtime) diff --git a/windows/flutter/CMakeLists.txt b/windows/flutter/CMakeLists.txt new file mode 100644 index 0000000..903f489 --- /dev/null +++ b/windows/flutter/CMakeLists.txt @@ -0,0 +1,109 @@ +# This file controls Flutter-level build steps. It should not be edited. +cmake_minimum_required(VERSION 3.14) + +set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") + +# Configuration provided via flutter tool. +include(${EPHEMERAL_DIR}/generated_config.cmake) + +# TODO: Move the rest of this into files in ephemeral. See +# https://github.com/flutter/flutter/issues/57146. +set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper") + +# Set fallback configurations for older versions of the flutter tool. +if (NOT DEFINED FLUTTER_TARGET_PLATFORM) + set(FLUTTER_TARGET_PLATFORM "windows-x64") +endif() + +# === Flutter Library === +set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll") + +# Published to parent scope for install step. +set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) +set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) +set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) +set(AOT_LIBRARY "${PROJECT_DIR}/build/windows/app.so" PARENT_SCOPE) + +list(APPEND FLUTTER_LIBRARY_HEADERS + "flutter_export.h" + "flutter_windows.h" + "flutter_messenger.h" + "flutter_plugin_registrar.h" + "flutter_texture_registrar.h" +) +list(TRANSFORM FLUTTER_LIBRARY_HEADERS PREPEND "${EPHEMERAL_DIR}/") +add_library(flutter INTERFACE) +target_include_directories(flutter INTERFACE + "${EPHEMERAL_DIR}" +) +target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}.lib") +add_dependencies(flutter flutter_assemble) + +# === Wrapper === +list(APPEND CPP_WRAPPER_SOURCES_CORE + "core_implementations.cc" + "standard_codec.cc" +) +list(TRANSFORM CPP_WRAPPER_SOURCES_CORE PREPEND "${WRAPPER_ROOT}/") +list(APPEND CPP_WRAPPER_SOURCES_PLUGIN + "plugin_registrar.cc" +) +list(TRANSFORM CPP_WRAPPER_SOURCES_PLUGIN PREPEND "${WRAPPER_ROOT}/") +list(APPEND CPP_WRAPPER_SOURCES_APP + "flutter_engine.cc" + "flutter_view_controller.cc" +) +list(TRANSFORM CPP_WRAPPER_SOURCES_APP PREPEND "${WRAPPER_ROOT}/") + +# Wrapper sources needed for a plugin. +add_library(flutter_wrapper_plugin STATIC + ${CPP_WRAPPER_SOURCES_CORE} + ${CPP_WRAPPER_SOURCES_PLUGIN} +) +apply_standard_settings(flutter_wrapper_plugin) +set_target_properties(flutter_wrapper_plugin PROPERTIES + POSITION_INDEPENDENT_CODE ON) +set_target_properties(flutter_wrapper_plugin PROPERTIES + CXX_VISIBILITY_PRESET hidden) +target_link_libraries(flutter_wrapper_plugin PUBLIC flutter) +target_include_directories(flutter_wrapper_plugin PUBLIC + "${WRAPPER_ROOT}/include" +) +add_dependencies(flutter_wrapper_plugin flutter_assemble) + +# Wrapper sources needed for the runner. +add_library(flutter_wrapper_app STATIC + ${CPP_WRAPPER_SOURCES_CORE} + ${CPP_WRAPPER_SOURCES_APP} +) +apply_standard_settings(flutter_wrapper_app) +target_link_libraries(flutter_wrapper_app PUBLIC flutter) +target_include_directories(flutter_wrapper_app PUBLIC + "${WRAPPER_ROOT}/include" +) +add_dependencies(flutter_wrapper_app flutter_assemble) + +# === Flutter tool backend === +# _phony_ is a non-existent file to force this command to run every time, +# since currently there's no way to get a full input/output list from the +# flutter tool. +set(PHONY_OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/_phony_") +set_source_files_properties("${PHONY_OUTPUT}" PROPERTIES SYMBOLIC TRUE) +add_custom_command( + OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} + ${CPP_WRAPPER_SOURCES_CORE} ${CPP_WRAPPER_SOURCES_PLUGIN} + ${CPP_WRAPPER_SOURCES_APP} + ${PHONY_OUTPUT} + COMMAND ${CMAKE_COMMAND} -E env + ${FLUTTER_TOOL_ENVIRONMENT} + "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat" + ${FLUTTER_TARGET_PLATFORM} $ + VERBATIM +) +add_custom_target(flutter_assemble DEPENDS + "${FLUTTER_LIBRARY}" + ${FLUTTER_LIBRARY_HEADERS} + ${CPP_WRAPPER_SOURCES_CORE} + ${CPP_WRAPPER_SOURCES_PLUGIN} + ${CPP_WRAPPER_SOURCES_APP} +) diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc new file mode 100644 index 0000000..e6cabfc --- /dev/null +++ b/windows/flutter/generated_plugin_registrant.cc @@ -0,0 +1,32 @@ +// +// Generated file. Do not edit. +// + +// clang-format off + +#include "generated_plugin_registrant.h" + +#include +#include +#include +#include +#include +#include +#include + +void RegisterPlugins(flutter::PluginRegistry* registry) { + CloudFirestorePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("CloudFirestorePluginCApi")); + FileSelectorWindowsRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FileSelectorWindows")); + FirebaseAuthPluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseAuthPluginCApi")); + FirebaseCorePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseCorePluginCApi")); + FirebaseStoragePluginCApiRegisterWithRegistrar( + registry->GetRegistrarForPlugin("FirebaseStoragePluginCApi")); + GeolocatorWindowsRegisterWithRegistrar( + registry->GetRegistrarForPlugin("GeolocatorWindows")); + UrlLauncherWindowsRegisterWithRegistrar( + registry->GetRegistrarForPlugin("UrlLauncherWindows")); +} diff --git a/windows/flutter/generated_plugin_registrant.h b/windows/flutter/generated_plugin_registrant.h new file mode 100644 index 0000000..dc139d8 --- /dev/null +++ b/windows/flutter/generated_plugin_registrant.h @@ -0,0 +1,15 @@ +// +// Generated file. Do not edit. +// + +// clang-format off + +#ifndef GENERATED_PLUGIN_REGISTRANT_ +#define GENERATED_PLUGIN_REGISTRANT_ + +#include + +// Registers Flutter plugins. +void RegisterPlugins(flutter::PluginRegistry* registry); + +#endif // GENERATED_PLUGIN_REGISTRANT_ diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake new file mode 100644 index 0000000..994f57f --- /dev/null +++ b/windows/flutter/generated_plugins.cmake @@ -0,0 +1,30 @@ +# +# Generated file, do not edit. +# + +list(APPEND FLUTTER_PLUGIN_LIST + cloud_firestore + file_selector_windows + firebase_auth + firebase_core + firebase_storage + geolocator_windows + url_launcher_windows +) + +list(APPEND FLUTTER_FFI_PLUGIN_LIST +) + +set(PLUGIN_BUNDLED_LIBRARIES) + +foreach(plugin ${FLUTTER_PLUGIN_LIST}) + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) + target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) + list(APPEND PLUGIN_BUNDLED_LIBRARIES $) + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) +endforeach(plugin) + +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) +endforeach(ffi_plugin) diff --git a/windows/runner/CMakeLists.txt b/windows/runner/CMakeLists.txt new file mode 100644 index 0000000..394917c --- /dev/null +++ b/windows/runner/CMakeLists.txt @@ -0,0 +1,40 @@ +cmake_minimum_required(VERSION 3.14) +project(runner LANGUAGES CXX) + +# Define the application target. To change its name, change BINARY_NAME in the +# top-level CMakeLists.txt, not the value here, or `flutter run` will no longer +# work. +# +# Any new source files that you add to the application should be added here. +add_executable(${BINARY_NAME} WIN32 + "flutter_window.cpp" + "main.cpp" + "utils.cpp" + "win32_window.cpp" + "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" + "Runner.rc" + "runner.exe.manifest" +) + +# Apply the standard set of build settings. This can be removed for applications +# that need different build settings. +apply_standard_settings(${BINARY_NAME}) + +# Add preprocessor definitions for the build version. +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION=\"${FLUTTER_VERSION}\"") +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MAJOR=${FLUTTER_VERSION_MAJOR}") +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MINOR=${FLUTTER_VERSION_MINOR}") +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_PATCH=${FLUTTER_VERSION_PATCH}") +target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_BUILD=${FLUTTER_VERSION_BUILD}") + +# Disable Windows macros that collide with C++ standard library functions. +target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX") + +# Add dependency libraries and include directories. Add any application-specific +# dependencies here. +target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app) +target_link_libraries(${BINARY_NAME} PRIVATE "dwmapi.lib") +target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}") + +# Run the Flutter tool portions of the build. This must not be removed. +add_dependencies(${BINARY_NAME} flutter_assemble) diff --git a/windows/runner/Runner.rc b/windows/runner/Runner.rc new file mode 100644 index 0000000..2fd2373 --- /dev/null +++ b/windows/runner/Runner.rc @@ -0,0 +1,121 @@ +// Microsoft Visual C++ generated resource script. +// +#pragma code_page(65001) +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +#include "winres.h" + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// English (United States) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE +BEGIN + "#include ""winres.h""\r\n" + "\0" +END + +3 TEXTINCLUDE +BEGIN + "\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// +// Icon +// + +// Icon with lowest ID value placed first to ensure application icon +// remains consistent on all systems. +IDI_APP_ICON ICON "resources\\app_icon.ico" + + +///////////////////////////////////////////////////////////////////////////// +// +// Version +// + +#if defined(FLUTTER_VERSION_MAJOR) && defined(FLUTTER_VERSION_MINOR) && defined(FLUTTER_VERSION_PATCH) && defined(FLUTTER_VERSION_BUILD) +#define VERSION_AS_NUMBER FLUTTER_VERSION_MAJOR,FLUTTER_VERSION_MINOR,FLUTTER_VERSION_PATCH,FLUTTER_VERSION_BUILD +#else +#define VERSION_AS_NUMBER 1,0,0,0 +#endif + +#if defined(FLUTTER_VERSION) +#define VERSION_AS_STRING FLUTTER_VERSION +#else +#define VERSION_AS_STRING "1.0.0" +#endif + +VS_VERSION_INFO VERSIONINFO + FILEVERSION VERSION_AS_NUMBER + PRODUCTVERSION VERSION_AS_NUMBER + FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +#ifdef _DEBUG + FILEFLAGS VS_FF_DEBUG +#else + FILEFLAGS 0x0L +#endif + FILEOS VOS__WINDOWS32 + FILETYPE VFT_APP + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904e4" + BEGIN + VALUE "CompanyName", "com.example" "\0" + VALUE "FileDescription", "donorconnect" "\0" + VALUE "FileVersion", VERSION_AS_STRING "\0" + VALUE "InternalName", "donorconnect" "\0" + VALUE "LegalCopyright", "Copyright (C) 2024 com.example. All rights reserved." "\0" + VALUE "OriginalFilename", "donorconnect.exe" "\0" + VALUE "ProductName", "donorconnect" "\0" + VALUE "ProductVersion", VERSION_AS_STRING "\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1252 + END +END + +#endif // English (United States) resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// + + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED diff --git a/windows/runner/flutter_window.cpp b/windows/runner/flutter_window.cpp new file mode 100644 index 0000000..955ee30 --- /dev/null +++ b/windows/runner/flutter_window.cpp @@ -0,0 +1,71 @@ +#include "flutter_window.h" + +#include + +#include "flutter/generated_plugin_registrant.h" + +FlutterWindow::FlutterWindow(const flutter::DartProject& project) + : project_(project) {} + +FlutterWindow::~FlutterWindow() {} + +bool FlutterWindow::OnCreate() { + if (!Win32Window::OnCreate()) { + return false; + } + + RECT frame = GetClientArea(); + + // The size here must match the window dimensions to avoid unnecessary surface + // creation / destruction in the startup path. + flutter_controller_ = std::make_unique( + frame.right - frame.left, frame.bottom - frame.top, project_); + // Ensure that basic setup of the controller was successful. + if (!flutter_controller_->engine() || !flutter_controller_->view()) { + return false; + } + RegisterPlugins(flutter_controller_->engine()); + SetChildContent(flutter_controller_->view()->GetNativeWindow()); + + flutter_controller_->engine()->SetNextFrameCallback([&]() { + this->Show(); + }); + + // Flutter can complete the first frame before the "show window" callback is + // registered. The following call ensures a frame is pending to ensure the + // window is shown. It is a no-op if the first frame hasn't completed yet. + flutter_controller_->ForceRedraw(); + + return true; +} + +void FlutterWindow::OnDestroy() { + if (flutter_controller_) { + flutter_controller_ = nullptr; + } + + Win32Window::OnDestroy(); +} + +LRESULT +FlutterWindow::MessageHandler(HWND hwnd, UINT const message, + WPARAM const wparam, + LPARAM const lparam) noexcept { + // Give Flutter, including plugins, an opportunity to handle window messages. + if (flutter_controller_) { + std::optional result = + flutter_controller_->HandleTopLevelWindowProc(hwnd, message, wparam, + lparam); + if (result) { + return *result; + } + } + + switch (message) { + case WM_FONTCHANGE: + flutter_controller_->engine()->ReloadSystemFonts(); + break; + } + + return Win32Window::MessageHandler(hwnd, message, wparam, lparam); +} diff --git a/windows/runner/flutter_window.h b/windows/runner/flutter_window.h new file mode 100644 index 0000000..6da0652 --- /dev/null +++ b/windows/runner/flutter_window.h @@ -0,0 +1,33 @@ +#ifndef RUNNER_FLUTTER_WINDOW_H_ +#define RUNNER_FLUTTER_WINDOW_H_ + +#include +#include + +#include + +#include "win32_window.h" + +// A window that does nothing but host a Flutter view. +class FlutterWindow : public Win32Window { + public: + // Creates a new FlutterWindow hosting a Flutter view running |project|. + explicit FlutterWindow(const flutter::DartProject& project); + virtual ~FlutterWindow(); + + protected: + // Win32Window: + bool OnCreate() override; + void OnDestroy() override; + LRESULT MessageHandler(HWND window, UINT const message, WPARAM const wparam, + LPARAM const lparam) noexcept override; + + private: + // The project to run. + flutter::DartProject project_; + + // The Flutter instance hosted by this window. + std::unique_ptr flutter_controller_; +}; + +#endif // RUNNER_FLUTTER_WINDOW_H_ diff --git a/windows/runner/main.cpp b/windows/runner/main.cpp new file mode 100644 index 0000000..4727688 --- /dev/null +++ b/windows/runner/main.cpp @@ -0,0 +1,43 @@ +#include +#include +#include + +#include "flutter_window.h" +#include "utils.h" + +int APIENTRY wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev, + _In_ wchar_t *command_line, _In_ int show_command) { + // Attach to console when present (e.g., 'flutter run') or create a + // new console when running with a debugger. + if (!::AttachConsole(ATTACH_PARENT_PROCESS) && ::IsDebuggerPresent()) { + CreateAndAttachConsole(); + } + + // Initialize COM, so that it is available for use in the library and/or + // plugins. + ::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED); + + flutter::DartProject project(L"data"); + + std::vector command_line_arguments = + GetCommandLineArguments(); + + project.set_dart_entrypoint_arguments(std::move(command_line_arguments)); + + FlutterWindow window(project); + Win32Window::Point origin(10, 10); + Win32Window::Size size(1280, 720); + if (!window.Create(L"donorconnect", origin, size)) { + return EXIT_FAILURE; + } + window.SetQuitOnClose(true); + + ::MSG msg; + while (::GetMessage(&msg, nullptr, 0, 0)) { + ::TranslateMessage(&msg); + ::DispatchMessage(&msg); + } + + ::CoUninitialize(); + return EXIT_SUCCESS; +} diff --git a/windows/runner/resource.h b/windows/runner/resource.h new file mode 100644 index 0000000..66a65d1 --- /dev/null +++ b/windows/runner/resource.h @@ -0,0 +1,16 @@ +//{{NO_DEPENDENCIES}} +// Microsoft Visual C++ generated include file. +// Used by Runner.rc +// +#define IDI_APP_ICON 101 + +// Next default values for new objects +// +#ifdef APSTUDIO_INVOKED +#ifndef APSTUDIO_READONLY_SYMBOLS +#define _APS_NEXT_RESOURCE_VALUE 102 +#define _APS_NEXT_COMMAND_VALUE 40001 +#define _APS_NEXT_CONTROL_VALUE 1001 +#define _APS_NEXT_SYMED_VALUE 101 +#endif +#endif diff --git a/windows/runner/resources/app_icon.ico b/windows/runner/resources/app_icon.ico new file mode 100644 index 0000000..c04e20c Binary files /dev/null and b/windows/runner/resources/app_icon.ico differ diff --git a/windows/runner/runner.exe.manifest b/windows/runner/runner.exe.manifest new file mode 100644 index 0000000..153653e --- /dev/null +++ b/windows/runner/runner.exe.manifest @@ -0,0 +1,14 @@ + + + + + PerMonitorV2 + + + + + + + + + diff --git a/windows/runner/utils.cpp b/windows/runner/utils.cpp new file mode 100644 index 0000000..3a0b465 --- /dev/null +++ b/windows/runner/utils.cpp @@ -0,0 +1,65 @@ +#include "utils.h" + +#include +#include +#include +#include + +#include + +void CreateAndAttachConsole() { + if (::AllocConsole()) { + FILE *unused; + if (freopen_s(&unused, "CONOUT$", "w", stdout)) { + _dup2(_fileno(stdout), 1); + } + if (freopen_s(&unused, "CONOUT$", "w", stderr)) { + _dup2(_fileno(stdout), 2); + } + std::ios::sync_with_stdio(); + FlutterDesktopResyncOutputStreams(); + } +} + +std::vector GetCommandLineArguments() { + // Convert the UTF-16 command line arguments to UTF-8 for the Engine to use. + int argc; + wchar_t** argv = ::CommandLineToArgvW(::GetCommandLineW(), &argc); + if (argv == nullptr) { + return std::vector(); + } + + std::vector command_line_arguments; + + // Skip the first argument as it's the binary name. + for (int i = 1; i < argc; i++) { + command_line_arguments.push_back(Utf8FromUtf16(argv[i])); + } + + ::LocalFree(argv); + + return command_line_arguments; +} + +std::string Utf8FromUtf16(const wchar_t* utf16_string) { + if (utf16_string == nullptr) { + return std::string(); + } + unsigned int target_length = ::WideCharToMultiByte( + CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, + -1, nullptr, 0, nullptr, nullptr) + -1; // remove the trailing null character + int input_length = (int)wcslen(utf16_string); + std::string utf8_string; + if (target_length == 0 || target_length > utf8_string.max_size()) { + return utf8_string; + } + utf8_string.resize(target_length); + int converted_length = ::WideCharToMultiByte( + CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, + input_length, utf8_string.data(), target_length, nullptr, nullptr); + if (converted_length == 0) { + return std::string(); + } + return utf8_string; +} diff --git a/windows/runner/utils.h b/windows/runner/utils.h new file mode 100644 index 0000000..3879d54 --- /dev/null +++ b/windows/runner/utils.h @@ -0,0 +1,19 @@ +#ifndef RUNNER_UTILS_H_ +#define RUNNER_UTILS_H_ + +#include +#include + +// Creates a console for the process, and redirects stdout and stderr to +// it for both the runner and the Flutter library. +void CreateAndAttachConsole(); + +// Takes a null-terminated wchar_t* encoded in UTF-16 and returns a std::string +// encoded in UTF-8. Returns an empty std::string on failure. +std::string Utf8FromUtf16(const wchar_t* utf16_string); + +// Gets the command line arguments passed in as a std::vector, +// encoded in UTF-8. Returns an empty std::vector on failure. +std::vector GetCommandLineArguments(); + +#endif // RUNNER_UTILS_H_ diff --git a/windows/runner/win32_window.cpp b/windows/runner/win32_window.cpp new file mode 100644 index 0000000..60608d0 --- /dev/null +++ b/windows/runner/win32_window.cpp @@ -0,0 +1,288 @@ +#include "win32_window.h" + +#include +#include + +#include "resource.h" + +namespace { + +/// Window attribute that enables dark mode window decorations. +/// +/// Redefined in case the developer's machine has a Windows SDK older than +/// version 10.0.22000.0. +/// See: https://docs.microsoft.com/windows/win32/api/dwmapi/ne-dwmapi-dwmwindowattribute +#ifndef DWMWA_USE_IMMERSIVE_DARK_MODE +#define DWMWA_USE_IMMERSIVE_DARK_MODE 20 +#endif + +constexpr const wchar_t kWindowClassName[] = L"FLUTTER_RUNNER_WIN32_WINDOW"; + +/// Registry key for app theme preference. +/// +/// A value of 0 indicates apps should use dark mode. A non-zero or missing +/// value indicates apps should use light mode. +constexpr const wchar_t kGetPreferredBrightnessRegKey[] = + L"Software\\Microsoft\\Windows\\CurrentVersion\\Themes\\Personalize"; +constexpr const wchar_t kGetPreferredBrightnessRegValue[] = L"AppsUseLightTheme"; + +// The number of Win32Window objects that currently exist. +static int g_active_window_count = 0; + +using EnableNonClientDpiScaling = BOOL __stdcall(HWND hwnd); + +// Scale helper to convert logical scaler values to physical using passed in +// scale factor +int Scale(int source, double scale_factor) { + return static_cast(source * scale_factor); +} + +// Dynamically loads the |EnableNonClientDpiScaling| from the User32 module. +// This API is only needed for PerMonitor V1 awareness mode. +void EnableFullDpiSupportIfAvailable(HWND hwnd) { + HMODULE user32_module = LoadLibraryA("User32.dll"); + if (!user32_module) { + return; + } + auto enable_non_client_dpi_scaling = + reinterpret_cast( + GetProcAddress(user32_module, "EnableNonClientDpiScaling")); + if (enable_non_client_dpi_scaling != nullptr) { + enable_non_client_dpi_scaling(hwnd); + } + FreeLibrary(user32_module); +} + +} // namespace + +// Manages the Win32Window's window class registration. +class WindowClassRegistrar { + public: + ~WindowClassRegistrar() = default; + + // Returns the singleton registrar instance. + static WindowClassRegistrar* GetInstance() { + if (!instance_) { + instance_ = new WindowClassRegistrar(); + } + return instance_; + } + + // Returns the name of the window class, registering the class if it hasn't + // previously been registered. + const wchar_t* GetWindowClass(); + + // Unregisters the window class. Should only be called if there are no + // instances of the window. + void UnregisterWindowClass(); + + private: + WindowClassRegistrar() = default; + + static WindowClassRegistrar* instance_; + + bool class_registered_ = false; +}; + +WindowClassRegistrar* WindowClassRegistrar::instance_ = nullptr; + +const wchar_t* WindowClassRegistrar::GetWindowClass() { + if (!class_registered_) { + WNDCLASS window_class{}; + window_class.hCursor = LoadCursor(nullptr, IDC_ARROW); + window_class.lpszClassName = kWindowClassName; + window_class.style = CS_HREDRAW | CS_VREDRAW; + window_class.cbClsExtra = 0; + window_class.cbWndExtra = 0; + window_class.hInstance = GetModuleHandle(nullptr); + window_class.hIcon = + LoadIcon(window_class.hInstance, MAKEINTRESOURCE(IDI_APP_ICON)); + window_class.hbrBackground = 0; + window_class.lpszMenuName = nullptr; + window_class.lpfnWndProc = Win32Window::WndProc; + RegisterClass(&window_class); + class_registered_ = true; + } + return kWindowClassName; +} + +void WindowClassRegistrar::UnregisterWindowClass() { + UnregisterClass(kWindowClassName, nullptr); + class_registered_ = false; +} + +Win32Window::Win32Window() { + ++g_active_window_count; +} + +Win32Window::~Win32Window() { + --g_active_window_count; + Destroy(); +} + +bool Win32Window::Create(const std::wstring& title, + const Point& origin, + const Size& size) { + Destroy(); + + const wchar_t* window_class = + WindowClassRegistrar::GetInstance()->GetWindowClass(); + + const POINT target_point = {static_cast(origin.x), + static_cast(origin.y)}; + HMONITOR monitor = MonitorFromPoint(target_point, MONITOR_DEFAULTTONEAREST); + UINT dpi = FlutterDesktopGetDpiForMonitor(monitor); + double scale_factor = dpi / 96.0; + + HWND window = CreateWindow( + window_class, title.c_str(), WS_OVERLAPPEDWINDOW, + Scale(origin.x, scale_factor), Scale(origin.y, scale_factor), + Scale(size.width, scale_factor), Scale(size.height, scale_factor), + nullptr, nullptr, GetModuleHandle(nullptr), this); + + if (!window) { + return false; + } + + UpdateTheme(window); + + return OnCreate(); +} + +bool Win32Window::Show() { + return ShowWindow(window_handle_, SW_SHOWNORMAL); +} + +// static +LRESULT CALLBACK Win32Window::WndProc(HWND const window, + UINT const message, + WPARAM const wparam, + LPARAM const lparam) noexcept { + if (message == WM_NCCREATE) { + auto window_struct = reinterpret_cast(lparam); + SetWindowLongPtr(window, GWLP_USERDATA, + reinterpret_cast(window_struct->lpCreateParams)); + + auto that = static_cast(window_struct->lpCreateParams); + EnableFullDpiSupportIfAvailable(window); + that->window_handle_ = window; + } else if (Win32Window* that = GetThisFromHandle(window)) { + return that->MessageHandler(window, message, wparam, lparam); + } + + return DefWindowProc(window, message, wparam, lparam); +} + +LRESULT +Win32Window::MessageHandler(HWND hwnd, + UINT const message, + WPARAM const wparam, + LPARAM const lparam) noexcept { + switch (message) { + case WM_DESTROY: + window_handle_ = nullptr; + Destroy(); + if (quit_on_close_) { + PostQuitMessage(0); + } + return 0; + + case WM_DPICHANGED: { + auto newRectSize = reinterpret_cast(lparam); + LONG newWidth = newRectSize->right - newRectSize->left; + LONG newHeight = newRectSize->bottom - newRectSize->top; + + SetWindowPos(hwnd, nullptr, newRectSize->left, newRectSize->top, newWidth, + newHeight, SWP_NOZORDER | SWP_NOACTIVATE); + + return 0; + } + case WM_SIZE: { + RECT rect = GetClientArea(); + if (child_content_ != nullptr) { + // Size and position the child window. + MoveWindow(child_content_, rect.left, rect.top, rect.right - rect.left, + rect.bottom - rect.top, TRUE); + } + return 0; + } + + case WM_ACTIVATE: + if (child_content_ != nullptr) { + SetFocus(child_content_); + } + return 0; + + case WM_DWMCOLORIZATIONCOLORCHANGED: + UpdateTheme(hwnd); + return 0; + } + + return DefWindowProc(window_handle_, message, wparam, lparam); +} + +void Win32Window::Destroy() { + OnDestroy(); + + if (window_handle_) { + DestroyWindow(window_handle_); + window_handle_ = nullptr; + } + if (g_active_window_count == 0) { + WindowClassRegistrar::GetInstance()->UnregisterWindowClass(); + } +} + +Win32Window* Win32Window::GetThisFromHandle(HWND const window) noexcept { + return reinterpret_cast( + GetWindowLongPtr(window, GWLP_USERDATA)); +} + +void Win32Window::SetChildContent(HWND content) { + child_content_ = content; + SetParent(content, window_handle_); + RECT frame = GetClientArea(); + + MoveWindow(content, frame.left, frame.top, frame.right - frame.left, + frame.bottom - frame.top, true); + + SetFocus(child_content_); +} + +RECT Win32Window::GetClientArea() { + RECT frame; + GetClientRect(window_handle_, &frame); + return frame; +} + +HWND Win32Window::GetHandle() { + return window_handle_; +} + +void Win32Window::SetQuitOnClose(bool quit_on_close) { + quit_on_close_ = quit_on_close; +} + +bool Win32Window::OnCreate() { + // No-op; provided for subclasses. + return true; +} + +void Win32Window::OnDestroy() { + // No-op; provided for subclasses. +} + +void Win32Window::UpdateTheme(HWND const window) { + DWORD light_mode; + DWORD light_mode_size = sizeof(light_mode); + LSTATUS result = RegGetValue(HKEY_CURRENT_USER, kGetPreferredBrightnessRegKey, + kGetPreferredBrightnessRegValue, + RRF_RT_REG_DWORD, nullptr, &light_mode, + &light_mode_size); + + if (result == ERROR_SUCCESS) { + BOOL enable_dark_mode = light_mode == 0; + DwmSetWindowAttribute(window, DWMWA_USE_IMMERSIVE_DARK_MODE, + &enable_dark_mode, sizeof(enable_dark_mode)); + } +} diff --git a/windows/runner/win32_window.h b/windows/runner/win32_window.h new file mode 100644 index 0000000..e901dde --- /dev/null +++ b/windows/runner/win32_window.h @@ -0,0 +1,102 @@ +#ifndef RUNNER_WIN32_WINDOW_H_ +#define RUNNER_WIN32_WINDOW_H_ + +#include + +#include +#include +#include + +// A class abstraction for a high DPI-aware Win32 Window. Intended to be +// inherited from by classes that wish to specialize with custom +// rendering and input handling +class Win32Window { + public: + struct Point { + unsigned int x; + unsigned int y; + Point(unsigned int x, unsigned int y) : x(x), y(y) {} + }; + + struct Size { + unsigned int width; + unsigned int height; + Size(unsigned int width, unsigned int height) + : width(width), height(height) {} + }; + + Win32Window(); + virtual ~Win32Window(); + + // Creates a win32 window with |title| that is positioned and sized using + // |origin| and |size|. New windows are created on the default monitor. Window + // sizes are specified to the OS in physical pixels, hence to ensure a + // consistent size this function will scale the inputted width and height as + // as appropriate for the default monitor. The window is invisible until + // |Show| is called. Returns true if the window was created successfully. + bool Create(const std::wstring& title, const Point& origin, const Size& size); + + // Show the current window. Returns true if the window was successfully shown. + bool Show(); + + // Release OS resources associated with window. + void Destroy(); + + // Inserts |content| into the window tree. + void SetChildContent(HWND content); + + // Returns the backing Window handle to enable clients to set icon and other + // window properties. Returns nullptr if the window has been destroyed. + HWND GetHandle(); + + // If true, closing this window will quit the application. + void SetQuitOnClose(bool quit_on_close); + + // Return a RECT representing the bounds of the current client area. + RECT GetClientArea(); + + protected: + // Processes and route salient window messages for mouse handling, + // size change and DPI. Delegates handling of these to member overloads that + // inheriting classes can handle. + virtual LRESULT MessageHandler(HWND window, + UINT const message, + WPARAM const wparam, + LPARAM const lparam) noexcept; + + // Called when CreateAndShow is called, allowing subclass window-related + // setup. Subclasses should return false if setup fails. + virtual bool OnCreate(); + + // Called when Destroy is called. + virtual void OnDestroy(); + + private: + friend class WindowClassRegistrar; + + // OS callback called by message pump. Handles the WM_NCCREATE message which + // is passed when the non-client area is being created and enables automatic + // non-client DPI scaling so that the non-client area automatically + // responds to changes in DPI. All other messages are handled by + // MessageHandler. + static LRESULT CALLBACK WndProc(HWND const window, + UINT const message, + WPARAM const wparam, + LPARAM const lparam) noexcept; + + // Retrieves a class instance pointer for |window| + static Win32Window* GetThisFromHandle(HWND const window) noexcept; + + // Update the window frame's theme to match the system theme. + static void UpdateTheme(HWND const window); + + bool quit_on_close_ = false; + + // window handle for top level window. + HWND window_handle_ = nullptr; + + // window handle for hosted content. + HWND child_content_ = nullptr; +}; + +#endif // RUNNER_WIN32_WINDOW_H_