diff --git a/.deepsource.toml b/.deepsource.toml
index 2dfb9d157..cc615ff47 100644
--- a/.deepsource.toml
+++ b/.deepsource.toml
@@ -2,11 +2,10 @@ version = 1
[[analyzers]]
name = "javascript"
-enabled = true
[analyzers.meta]
plugins = ["react"]
+ environment = ["nodejs"]
[[transformers]]
name = "prettier"
-enabled = true
\ No newline at end of file
diff --git a/.env b/.env
index 494d26fc3..ea6e0a209 100644
--- a/.env
+++ b/.env
@@ -1,7 +1,8 @@
-VITE_DUMMYGRAM_APIKEY =AIzaSyAldAwalnW6viLMQR-djtoUudQNWTZREOc
-VITE_DUMMYGRAM_AUTHDOMAIN =dummy-gram.firebaseapp.com
-VITE_DUMMYGRAM_PROJECTID = dummy-gram
-VITE_DUMMYGRAM_STORAGEBUCKET = dummy-gram.appspot.com
-VITE_DUMMYGRAM_MESSAGINGSENDERID =329994030699
-VITE_DUMMYGRAM_APPID = 1:329994030699:web:4d6e02e440b5def1066b2e
-VITE_DUMMYGRAM_MEASUREMENTID = G-E5KS3423ZK
+VITE_DUMMYGRAM_APIKEY = AIzaSyCngWCAMuh-3lOk_unlhOes9otDo2Go_kw
+VITE_DUMMYGRAM_AUTHDOMAIN = dummy-graham.firebaseapp.com
+VITE_DUMMYGRAM_PROJECTID = dummy-graham
+VITE_DUMMYGRAM_STORAGEBUCKET = dummy-graham.appspot.com
+VITE_DUMMYGRAM_MESSAGINGSENDERID = 1039947824283
+VITE_DUMMYGRAM_APPID = 1:1039947824283:web:b8658e4fdf5b6f90959a3e
+VITE_DUMMYGRAM_MEASUREMENTID = G-56JCX3KWGS
+VITE_DUMMYGRAM_DBURL = https://dummy-graham-default-rtdb.asia-southeast1.firebasedatabase.app
diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml
index 024526579..1f4f8b2ea 100644
--- a/.github/ISSUE_TEMPLATE/bug.yml
+++ b/.github/ISSUE_TEMPLATE/bug.yml
@@ -14,7 +14,7 @@ body:
id: reproduction
attributes:
label: Steps to reproduce
- description: Steps to reproduce the bug that you found !
+ description: Steps to reproduce the bug that you found!
validations:
required: true
@@ -49,3 +49,21 @@ body:
description: Is there anything else we should know about this bug?
validations:
required: false
+
+ - type: checkboxes
+ id: terms
+ attributes:
+ label: "Record"
+ options:
+ - label: I agree to follow this project's Code of Conduct
+ required: true
+ - label: I have checked the existing issues
+ - label: I am a participant of a program
+ - label: I want to work on this issue
+ - type: textarea
+ id: optionalinfo
+ attributes:
+ label: Optional information
+ description: Which program you`re participating from?
+ validations:
+ required: false
diff --git a/.github/ISSUE_TEMPLATE/docs.yml b/.github/ISSUE_TEMPLATE/docs.yml
index e79b6e2e7..aa4b8266d 100644
--- a/.github/ISSUE_TEMPLATE/docs.yml
+++ b/.github/ISSUE_TEMPLATE/docs.yml
@@ -24,3 +24,13 @@ body:
description: Is there anything else we should know about this issue?
validations:
required: false
+ - type: checkboxes
+ id: terms
+ attributes:
+ label: "Record"
+ options:
+ - label: I agree to follow this project's Code of Conduct
+ required: true
+ - label: I have checked the existing issues
+ - label: I'm a GSSoC'23 contributor
+ - label: I want to work on this issue
diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml
index 139c28e60..ed22b058d 100644
--- a/.github/ISSUE_TEMPLATE/feature_request.yml
+++ b/.github/ISSUE_TEMPLATE/feature_request.yml
@@ -24,3 +24,13 @@ body:
description: Is there anything else we should know about this idea?
validations:
required: false
+ - type: checkboxes
+ id: terms
+ attributes:
+ label: "Record"
+ options:
+ - label: I agree to follow this project's Code of Conduct
+ required: true
+ - label: I have checked the existing issues
+ - label: I'm a GSSoC'23 contributor
+ - label: I want to work on this issue
diff --git a/.github/ISSUE_TEMPLATE/other.yml b/.github/ISSUE_TEMPLATE/other.yml
index e14996c3d..40a9beeba 100644
--- a/.github/ISSUE_TEMPLATE/other.yml
+++ b/.github/ISSUE_TEMPLATE/other.yml
@@ -20,3 +20,13 @@ body:
description: Is there anything else we should know about this issue?
validations:
required: false
+ - type: checkboxes
+ id: terms
+ attributes:
+ label: "Record"
+ options:
+ - label: I agree to follow this project's Code of Conduct
+ required: true
+ - label: I have checked the existing issues
+ - label: I'm a GSSoC'23 contributor
+ - label: I want to work on this issue
diff --git a/.github/ISSUE_TEMPLATE/styles.yml b/.github/ISSUE_TEMPLATE/styles.yml
new file mode 100644
index 000000000..7f6fd26ac
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/styles.yml
@@ -0,0 +1,39 @@
+name: Style Changing Request
+description: Suggest a style design
+title: '[style]: '
+labels: ['enhancement']
+
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thanks for taking the time to fill out this template!
+ - type: textarea
+ id: style-idea
+ attributes:
+ label: What's the style idea?
+ placeholder: Add descriptions
+ value: 'We need to improve...'
+ validations:
+ required: true
+ - type: textarea
+ id: screenshots
+ attributes:
+ label: Add screenshots
+ description: Add screenshots to demonstrate the idea
+ placeholder: Add screenshots
+ value: 'Add screenshots here'
+ - type: checkboxes
+ id: terms
+ attributes:
+ label: Code of Conduct
+ description: By submitting this issue, you agree to follow our Code of Conduct
+ options:
+ - label: I agree to follow this project's Code of Conduct
+ required: true
+ - label: I have read the [Contributing Guidelines](https://github.com/narayan954/dummygram/blob/master/CONTRIBUTING.md)
+ required: true
+ - label: I agree to follow this project's [Code of Conduct](https://github.com/narayan954/dummygram/blob/master/CODE_OF_CONDUCT.md)
+ required: true
+ - label: I'm a GSSoC'23 contributor
+ - label: I want to work on this issue
diff --git a/.github/workflows/assigner.yml b/.github/workflows/assigner.yml
new file mode 100644
index 000000000..dd623f641
--- /dev/null
+++ b/.github/workflows/assigner.yml
@@ -0,0 +1,44 @@
+# name: Assigner
+
+# on:
+# issue_comment:
+# types: [created]
+
+# jobs:
+# slash_assign:
+# # If the acton was triggered by a new comment that starts with `/assign`
+# # or a on a schedule
+# if: >
+# (github.event_name == 'issue_comment' && startsWith(github.event.comment.body, '/assign')) || github.event_name == 'workflow_dispatch'
+# runs-on: ubuntu-latest
+# steps:
+# - name: Assign the user or unassign stale assignments
+# uses: JasonEtco/slash-assign-action@v0.0.3
+# with:
+# assigned_label: Assigned
+# days_until_warning: 3
+# days_until_unassign: 4
+# stale_assignment_label: Stale
+# assigned_comment: "This issue [has been assigned]({{ comment.html_url }}) to {{ comment.user.login }}!\nIt will become unassigned if it is not closed within {{ totalDays }} days. A maintainer can also add the **{{ inputs.pin_label }}** label to prevent it from being unassigned."
+# fail_comment: "This issue is already assigned to a contributor."
+
+# - name: Message failure
+# if: ${{ failure() }}
+# uses: actions/github-script@v4
+# with:
+# script: |
+# github.issues.createComment({
+# issue_number: context.issue.number,
+# owner: context.repo.owner,
+# repo: context.repo.repo,
+# body: 'The issue is already assigned!\nPlease find/create a new issue to contribute to.\nYou can safely disregard the failed workflow notification for this issue. ❌',
+# });
+# - name: Checkout code
+# uses: actions/checkout@main
+# - name: Run Action
+# uses: Suvraneel/Issue_Watcher@main
+# with:
+# token: "${{ secrets.GITHUB_TOKEN }}"
+# author: "${{github.actor}}"
+# repo: narayan954/dummygram #Change the Repo name
+# maxIssue: 1
diff --git a/.github/workflows/close_old_issues.yaml b/.github/workflows/close_old_issues.yaml
new file mode 100644
index 000000000..61d211ead
--- /dev/null
+++ b/.github/workflows/close_old_issues.yaml
@@ -0,0 +1,34 @@
+# name: Close Old Issues
+# on:
+# schedule:
+# - cron: "0 0 * * *"
+
+# jobs:
+# close-issues:
+# runs-on: ubuntu-latest
+
+# steps:
+# - name: Checkout Repository
+# uses: actions/checkout@v3
+
+# - name: Close Old Issues
+# run: |
+# open_issues=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
+# "https://api.github.com/repos/${{ github.repository }}/issues?state=open" \
+# | jq -r '.[] | .number')
+
+# for issue in $open_issues; do
+# # Get the last updated timestamp of the issue
+# last_updated=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
+# "https://api.github.com/repos/${{ github.repository }}/issues/$issue" \
+# | jq -r '.updated_at')
+
+# days_since_update=$(( ( $(date +%s) - $(date -d "$last_updated" +%s) ) / 86400 ))
+
+# if [ $days_since_update -gt 7 ]; then # Modify the condition to check if days_since_update is greater than 7
+# curl -s -X PATCH -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
+# -H "Accept: application/vnd.github.v3+json" \
+# -d '{"state":"closed"}' \
+# "https://api.github.com/repos/${{ github.repository }}/issues/$issue"
+# fi
+# done
diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
new file mode 100644
index 000000000..3ed2906da
--- /dev/null
+++ b/.github/workflows/codeql.yml
@@ -0,0 +1,77 @@
+# For most projects, this workflow file will not need changing; you simply need
+# to commit it to your repository.
+#
+# You may wish to alter this file to override the set of languages analyzed,
+# or to provide custom queries or build logic.
+#
+# ******** NOTE ********
+# We have attempted to detect the languages in your repository. Please check
+# the `language` matrix defined below to confirm you have the correct set of
+# supported CodeQL languages.
+#
+name: "CodeQL"
+
+on:
+ push:
+ branches: [ "master" ]
+ pull_request:
+ # The branches below must be a subset of the branches above
+ branches: [ "master" ]
+ schedule:
+ - cron: '43 3 * * 6'
+
+jobs:
+ analyze:
+ name: Analyze
+ runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
+ timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
+ permissions:
+ actions: read
+ contents: read
+ security-events: write
+
+ strategy:
+ fail-fast: false
+ matrix:
+ language: [ 'javascript' ]
+ # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
+ # Use only 'java' to analyze code written in Java, Kotlin or both
+ # Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
+ # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
+
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v3
+
+ # Initializes the CodeQL tools for scanning.
+ - name: Initialize CodeQL
+ uses: github/codeql-action/init@v2
+ with:
+ languages: ${{ matrix.language }}
+ # If you wish to specify custom queries, you can do so here or in a config file.
+ # By default, queries listed here will override any specified in a config file.
+ # Prefix the list here with "+" to use these queries and those in the config file.
+
+ # For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
+ # queries: security-extended,security-and-quality
+
+
+ # Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
+ # If this step fails, then you should remove it and run the build manually (see below)
+ - name: Autobuild
+ uses: github/codeql-action/autobuild@v2
+
+ # ℹ️ Command-line programs to run using the OS shell.
+ # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
+
+ # If the Autobuild fails above, remove it and uncomment the following three lines.
+ # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
+
+ # - run: |
+ # echo "Run, Build Application using script"
+ # ./location_of_script_within_repo/buildscript.sh
+
+ - name: Perform CodeQL Analysis
+ uses: github/codeql-action/analyze@v2
+ with:
+ category: "/language:${{matrix.language}}"
diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml
index a1a352e6f..34bf39f78 100644
--- a/.github/workflows/greetings.yml
+++ b/.github/workflows/greetings.yml
@@ -1,17 +1,34 @@
name: Greetings
-on: [pull_request_target, issues]
+on:
+ fork:
+ push:
+ branches: [main]
+ issues:
+ types: [opened]
+ pull_request_target:
+ types: [opened]
jobs:
greeting:
+ runs-on: ubuntu-latest
+ permissions:
+ issues: write
+ pull-requests: write
+ steps:
+ - uses: actions/first-interaction@v1
+ continue-on-error: true
+ with:
+ repo-token: ${{ secrets.GITHUB_TOKEN }}
+ issue-message: "Hi there ${{ github.actor }}!, welcome to Dummygram :)"
+ pr-message: "Hi there ${{ github.actor }}!, congratulations on your first pull request :)"
+
+ welcome:
runs-on: ubuntu-latest
- permissions:
- issues: write
- pull-requests: write
steps:
- - uses: actions/first-interaction@v1
- continue-on-error: true
- with:
- repo-token: ${{ secrets.GITHUB_TOKEN }}
- issue-message: "Hi there, Thanks a lot for raising the issue, we'll look into it asap. Also please mention if you wish to work on the issue as well so you could be assigned"
- pr-message: "Hi there, Thanks a lot for your first pull request, we'll be reviewing it asap :)"
+ - uses: actions/checkout@v3
+ - uses: EddieHubCommunity/gh-action-community/src/welcome@main
+ with:
+ github-token: ${{ secrets.GITHUB_TOKEN }}
+ issue-message: "Hello ${{ github.actor }}! \n Thank you for raising this issue! 😊 Your contribution is valuable to us! 😊 \n\nPlease make sure to follow our [Contributing Guidelines. 💪🏻](https://github.com/narayan954/dummygram/blob/master/CONTRIBUTING.md) \n\nOur reviewers shall carefully assess the issue and reach out to you soon! 😇 \n We appreciate your patience! "
+ pr-message: "Thank you ${{ github.actor }}! for creating this pull request and contributing to Dummygram! 💗\n\n The maintainers will review this Pull Request and provide feedback as soon as possible! 😇\nWe appreciate your patience and contribution, Keep up the great work! 😀"
diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml
new file mode 100644
index 000000000..b8374ebfc
--- /dev/null
+++ b/.github/workflows/linting.yml
@@ -0,0 +1,21 @@
+# name: Linting
+
+# on: [push, pull_request]
+
+# jobs:
+
+# Linting:
+
+# runs-on: ubuntu-latest
+
+# steps:
+
+# - name: Checkout
+# uses: actions/checkout@v3
+# with:
+# ref: ${{ github.head_ref }}
+
+# - name: Lint code with prettier
+# uses: creyD/prettier_action@v4.3
+# with:
+# prettier_options: --write **/*.{js,md}
diff --git a/.gitignore b/.gitignore
index 32d5008b3..ceb20f25b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -19,6 +19,8 @@ dist-ssr
*.njsproj
*.sln
*.sw?
+*.lock
+vite.config.js.*
# testing
/coverage
@@ -45,3 +47,4 @@ yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
+.env
diff --git a/.husky/commit-msg b/.husky/commit-msg
new file mode 100755
index 000000000..b56767669
--- /dev/null
+++ b/.husky/commit-msg
@@ -0,0 +1,4 @@
+#!/usr/bin/env sh
+. "$(dirname -- "$0")/_/husky.sh"
+
+npx --no -- commitlint --edit "$1"
diff --git a/.prettierrc b/.prettierrc
new file mode 100644
index 000000000..de8114db4
--- /dev/null
+++ b/.prettierrc
@@ -0,0 +1,5 @@
+{
+ "useTabs": false,
+ "tabWidth": 2,
+ "trailingComma": "all"
+}
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index f3b835f7e..45d6ee0c2 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -60,7 +60,7 @@ Open Source projects always have something to workon and improves with each new
You have forked the project you want to contribute to your github account. To get this project on your development machine we use clone command of git.
-`$ git clone https://github.com/
@@ -10,21 +10,21 @@ You can SIGNIN or SIGNUP here and also view posts posted on dummygram.
## SIGNUP Dialog
-
+
## SIGNIN Dialog
-
+
## HOME Page
-
+
Now, you can create new post, like and comment on previous posts.
@@ -32,21 +32,21 @@ Now, you can create new post, like and comment on previous posts.
## New Post dialog
-
+
## New Post Preview dialog
-
+
## Post-posting
-
+
"Post was uploaded successfully!" will appear at right top.
You can view your post now.
@@ -55,7 +55,7 @@ You can view your post now.
## Adding Reactions in Comments
-
+
You can add reaction in comments by clicking on emoji tab.
@@ -63,7 +63,7 @@ You can add reaction in comments by clicking on emoji tab.
## Comment Dialog
-
+
You can view all comments on post on this dialog.
@@ -71,7 +71,7 @@ You can view all comments on post on this dialog.
## Theme Switching
-
+
You can switch between Light mode and Dark mode using bottom-right button.
@@ -79,6 +79,6 @@ You can switch between Light mode and Dark mode using bottom-right button.
## LOGOUT
-
+
You can logout using top-right "LOGOUT" button on nav bar.
"Logged out Successfully!" will appear at right top.
diff --git a/README-HINDI.md b/README-HINDI.md
deleted file mode 100644
index d37ba583f..000000000
--- a/README-HINDI.md
+++ /dev/null
@@ -1,215 +0,0 @@
-
addReaction("smiley")}>😅
+addReaction("like")}>❤️
+addReaction("laughing")}>😂
+addReaction("thumbsUp")}>👍
+ + )} +{message.text}
+ {message.edited && ( +Take Picture
++ @{user.username} +
+ +No notifications
+ )} +
- {userComment.content.username}{" "}
- {userComment.content.text}
-
- deleteComment(event, userComment)
- }
- >
- {user &&
- userComment.content.username ===
- user.displayName ? (
-
+
+
+
= 100 ? "postCaption" : "postCaptiontext"
+ }`}
+ >
+
{bio ? trimBio(bio) : "..."}
+{time}
+No likes!!
+ ) : ( ++ Bio:{" "} + + {bio?.length > 90 ? trimBio(bio) : bio} + +
+Posts: {posts}
+ {followers && following && ( ++ {following} Following +
++ {followers} Followers +
+We're sorry to see you leaving
++ Do you want sound effects to play for certain actions while using + DummyGram? +
+Off
+On
+ ++ Occasionally we'll play a sound effect to draw your attention to + something that's happened, such as receiving a message or when you + saved a post. +
+{caption}
+{caption}
+Sorry😓 No story!
+ )} +{bio ? bio : "..."}
+ {uid !== currentUser?.uid && ( + + )} +{time}
+ +{caption}
+{content.text}
++ No Comments to Show!! +
+ )} ++ Welcome to Dummygram, an exciting platform that aims to reimagine + and revolutionize the way we connect and share moments with others. + A creative space where you can showcase your unique perspective, + explore diverse content, and foster meaningful connections with + like-minded individuals from around the globe. +
++ Combine the best features of Instagram while adding a touch of + innovation and uniqueness. We strive to create a platform that + encourages creativity, authenticity, and positive interactions. +
++ Dummygram's development has been started by{" "} + + Narayan Soni + {" "} + in September 2022 and now has over {contributors} contributors to + success. Together let's move ahead and make dummygram a huge + success. Join us today on{" "} + + GitHub! + +
+© 2023 NARAYAN SONI. All rights reserved.
++ Have a question in mind? We've got the answers! +
+Oops, not here, take a U-turn, no fear,
+Find Dummygram's realm, it's near.
+Click 'Back Home' below, come what may,
+Brighter times just a click away!"
++ {text.length > maxLength ? text.slice(0, maxLength) + "..." : text} +
+ ); +} + +function PostWithoutImage({ post, maxLength }) { + return ( +{bio}
+@{username}
+{country}
++ {errorMesssage} +
+ )} ++ {errorMesssage} +
+ )} ++ Welcome to Dummygram, place to share your wonderful moments and + connect with others +
+Error: {error.message}
+{info?.componentStack}
+ {
+ if (type === "anchor") {
+ if (
+ !location.href.includes("login") &&
+ !location.href.includes("signup")
+ ) {
+ navigate("/");
+ }
+ }
+ window.scrollTo({ top: 0, left: 0, behavior: "smooth" });
+ }}
+ >
+