diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..5470ef2 --- /dev/null +++ b/.env.example @@ -0,0 +1,46 @@ +# GitHub Personal Access Token +# This token is required to authenticate requests to GitHub’s API for fetching +# repository releases and assets without hitting rate limits. +# +# Purpose: +# The GitHub API limits the number of requests per hour for unauthorized +# requests. By including a GitHub Personal Access Token, you increase the rate +# limit available for your application, allowing it to function without interruptions. +# +# Without this token, you may experience 403 (Forbidden) errors if the app +# exceeds the API’s request limit. GitHub tokens also ensure that your application +# has authorized access to private repositories, if needed. +# +# How to get your GitHub Personal Access Token: +# +# 1. Sign in to GitHub: Go to https://github.com/ and login. +# +# 2. Access Settings: +# - In the top right corner of any GitHub page, click your profile picture. +# - Click on **Settings** in the dropdown menu. +# +# 3. Open Developer Settings: +# - Scroll down and click **Developer settings** in the left sidebar. +# +# 4. Generate Token: +# - Select **Personal access tokens** > **Tokens (classic)** from the left sidebar. +# - Click on **Generate new token** > **Generate new token (classic)**. +# +# 5. Configure Token Permissions: +# - In the **Note** field, add a description (e.g., "Access for My Project"). +# - Set the **Expiration** duration, or leave it as "No expiration" if you want it to last indefinitely. +# - Under **Select scopes**, choose at least: +# - `repo` - Grants read and write access to repositories, which allows access to private repositories if needed. +# +# 6. Generate and Copy Token: +# - Click **Generate token** at the bottom of the page. +# - GitHub will show your token only once. Copy it immediately and store it in a safe place. +# +# 7. Add Token Here: +# - Place the token below as the value for `GITHUB_TOKEN`. +# +# GitHub Documentation: +# - More details on personal access tokens: https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token +# - GitHub API rate limits: https://docs.github.com/en/rest/overview/resources-in-the-rest-api#rate-limiting + +GITHUB_TOKEN=your_personal_access_token_here diff --git a/.eslintignore b/.eslintignore index 4b7cd47..506e574 100644 --- a/.eslintignore +++ b/.eslintignore @@ -5,6 +5,10 @@ node_modules/ build/ dist/ .out/ +**/build/**/*.js +**/.next/**/*.js +**/build/**/*.ts +**/.next/**/*.ts # Ignore all configuration files in the root directory # This includes ESLint, Prettier, Babel, Stylelint, and other config files @@ -25,11 +29,12 @@ dist/ # Ignore lock files package-lock.json +pnpm-lock.yaml yarn.lock # Ignore log files npm-debug.log -yarn-error.log +pnpm-error.log pnpm-debug.log # Ignore coverage directory used by testing tools diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 44acdbe..0000000 --- a/.eslintrc.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - extends: "next/core-web-vitals", -}; diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..bffb357 --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,3 @@ +{ + "extends": "next/core-web-vitals" +} diff --git a/.gitattributes b/.gitattributes index 605115a..4fae9ab 100644 --- a/.gitattributes +++ b/.gitattributes @@ -200,4 +200,4 @@ Procfile text # DISABLE SHRINKWRAP MERGING AS RESULTS MAY BE INVALID. npm-shrinkwrap.json merge=binary shrinkwrap.yaml merge=binary -yarn.lock merge=binary +pnpm.lock merge=binary diff --git a/CODE_OF_CONDUCT.md b/.github/CODE_OF_CONDUCT.md similarity index 97% rename from CODE_OF_CONDUCT.md rename to .github/CODE_OF_CONDUCT.md index 5445e1d..2b666a4 100644 --- a/CODE_OF_CONDUCT.md +++ b/.github/CODE_OF_CONDUCT.md @@ -55,7 +55,7 @@ further defined and clarified by project maintainers. ## Enforcement Instances of abusive, harassing, or otherwise unacceptable behavior may be -reported by contacting the project team at codeilluminators@gmail.com. All +reported by contacting the project team at serstor15@gmail.com. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 8633e01..8b16fdb 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,6 +1,6 @@ # These are supported funding model platforms -github: [Storik4Pro, lumenpearson, ValdikSS] +github: [Storik4pro, lumenpearson, ValdikSS, bol-van, xvzc, hufrea] patreon: # Replace with a single Patreon username open_collective: # Replace with a single Open Collective username ko_fi: # Replace with a single Ko-fi username diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md deleted file mode 100644 index 64e5669..0000000 --- a/.github/ISSUE_TEMPLATE/bug-report.md +++ /dev/null @@ -1,38 +0,0 @@ ---- -name: Bug report -about: Create a report to help us improve GoodbyeDPI UI documentation -title: "\U0001F47E BUG" -labels: bug -assignees: '' - ---- - -**Describe the bug** -A clear and concise description of what the bug is. - -**To Reproduce** -Steps to reproduce the behavior: -1. Go to '...' -2. Click on '....' -3. Scroll down to '....' -4. See error - -**Expected behavior** -A clear and concise description of what you expected to happen. - -**Screenshots** -If applicable, add screenshots to help explain your problem. - -**Desktop (please complete the following information):** - - OS: [e.g. iOS] - - Browser [e.g. chrome, safari] - - Version [e.g. 22] - -**Smartphone (please complete the following information):** - - Device: [e.g. iPhone6] - - OS: [e.g. iOS8.1] - - Browser [e.g. stock browser, safari] - - Version [e.g. 22] - -**Additional context** -Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 189feb1..0000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,20 +0,0 @@ ---- -name: Feature request -about: Suggest an idea for this project -title: "✨ IMPROVE" -labels: documentation, enhancement -assignees: '' - ---- - -**Is your feature request related to a problem? Please describe.** -A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] - -**Describe the solution you'd like** -A clear and concise description of what you want to happen. - -**Describe alternatives you've considered** -A clear and concise description of any alternative solutions or features you've considered. - -**Additional context** -Add any other context or screenshots about the feature request here. diff --git a/.github/assets/readme-logo.png b/.github/assets/readme-logo.png new file mode 100644 index 0000000..84762ed Binary files /dev/null and b/.github/assets/readme-logo.png differ diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..c9a5fd7 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,25 @@ +version: 2 +updates: + # Configuration to check for updates in Node.js dependencies (using pnpm). + - package-ecosystem: 'npm' # The package manager for the project (using "npm" ecosystem for pnpm). + directory: '/' # Directory where the package.json is located (root in this case). + schedule: + interval: 'weekly' # Frequency of the update checks (can be daily, weekly, or monthly). + commit-message: + prefix: 'chore(deps)' # Prefix added to commit messages for dependency updates. + labels: + - 'dependencies' + - 'node' + - 'pnpm' + open-pull-requests-limit: 5 # Limit the number of open pull requests created by Dependabot at a time. + ignore: + # List of specific dependencies to ignore for updates. + # Useful for libraries where automatic updates might cause issues. + - dependency-name: 'next' + - dependency-name: 'babylon' + - dependency-name: 'typescript' + - dependency-name: 'autoprefixer' + - dependency-name: 'lucide-react' + - dependency-name: 'eslint-config-next' + - dependency-name: 'eslint' + rebase-strategy: 'auto' # Automatically rebase pull requests if conflicts arise. diff --git a/.github/workflows/dependabot-automerge.yml b/.github/workflows/dependabot-automerge.yml new file mode 100644 index 0000000..bad8c11 --- /dev/null +++ b/.github/workflows/dependabot-automerge.yml @@ -0,0 +1,34 @@ +# Automatically squashes and merges Dependabot dependency upgrades if tests pass + +name: Dependabot Auto-merge + +on: pull_request_target + +permissions: + pull-requests: write + contents: write + +jobs: + dependabot: + runs-on: ubuntu-latest + + if: ${{ github.actor == 'dependabot[bot]' }} + steps: + - name: Fetch Dependabot metadata + id: dependabot-metadata + uses: dependabot/fetch-metadata@v1.3.3 + with: + github-token: '${{ secrets.GITHUB_TOKEN }}' + + - name: Approve Dependabot PR + run: gh pr review --approve "$PR_URL" + env: + PR_URL: ${{ github.event.pull_request.html_url }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Auto-merge (squash) Dependabot PR + if: ${{ steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major' }} + run: gh pr merge --auto --squash "$PR_URL" + env: + PR_URL: ${{ github.event.pull_request.html_url }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.gitignore b/.gitignore index 17167b7..39ab6ee 100644 --- a/.gitignore +++ b/.gitignore @@ -1,75 +1,97 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. - -# dependencies -/node_modules -/.pnp -.pnp.js -.yarn/install-state.gz +# Logs and Debugging +logs/ +*.log +npm-debug.log* +pnpm-debug.log* +pnpm-error.log* +pnpm-debug.log* +lerna-debug.log* -# next.js -/.next/ +# Node Modules +node_modules/ -# testing -/.nyc_output -/coverage -/out/ +# Distribution Builds +dist/ +build/ +output +out/ +dist-ssr/ +!/out/.gitkeep +!/dist/.gitkeep +!/build/.gitkeep -# production -/build -/dist +# Vercel Deployment +.vercel/ -# OS -.DS_Store -*.pem +# Next.js +.next/ +out/ +!/out/.gitkeep -# debug -*.log -npm-debug.log* -pnpm-debug.log* -yarn-debug.log* -yarn-error.log* -lerna-debug.log* +# Testing and Coverage +coverage/ +.nyc_output/ +.vitest/ -# dotenv environment variable files +# Local Environment Files .env +.env*.local .env.development.local .env.test.local .env.production.local -.env.local - -# IDEs and editors -/.idea -.project -.classpath -.c9/ -*.launch -.settings/ -*.sublime-workspace + +# Package Managers +.pnp +.pnp.js +.yarn/install-state.gz + +# WiX +WixTools + +# TypeScript +*.tsbuildinfo + +# Lint and Formatter +.eslintcache +.stylelintcache +.prettiercache +.npmrc +.pnpmrc + +# IDE and Editor Settings +# Visual Studio Code .vscode/* -!.vscode/settings.json -!.vscode/tasks.json -!.vscode/launch.json !.vscode/extensions.json +!.vscode/settings.json -# temp directory -.temp -.tmp +# JetBrains IDEs (WebStorm, IntelliJ, etc.) +.idea/ +*.iml -# Runtime data -pids -*.pid -*.seed -*.pid.lock +# Visual Studio +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? -# local env files -.env*.local +# Operating System Specific Files +# macOS +.DS_Store -# vercel -.vercel +# Windows +Thumbs.db -# typescript -*.tsbuildinfo -next-env.d.ts +# Miscellaneous +*.local +*.lock +yarn.lock +package-lock.json + +# Temporary Files +tmp/ +temp/ -# Diagnostic reports (https://nodejs.org/api/report.html) -report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json +# Other +keys/* +!/keys/.gitkeep diff --git a/.husky/pre-commit b/.husky/pre-commit new file mode 100644 index 0000000..a4fc325 --- /dev/null +++ b/.husky/pre-commit @@ -0,0 +1,4 @@ +#!/usr/bin/env sh +. "$(dirname -- "$0")/_/husky.sh" + +npm exec lint-staged diff --git a/.lintstagedrc.js b/.lintstagedrc.js new file mode 100644 index 0000000..d5a7dbb --- /dev/null +++ b/.lintstagedrc.js @@ -0,0 +1,13 @@ +const path = require('path'); + +const buildEslintCommand = filenames => + `next lint --fix --file ${filenames + .map(f => path.relative(process.cwd(), f)) + .join(' --file ')}`; + +module.exports = { + '**/**/*.{js,jsx,ts,tsx}': [buildEslintCommand], + '*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}': [ + 'biome check --apply --no-errors-on-unmatched', // Format, sort imports, lint, and apply safe fixes + ], +}; diff --git a/.lintstagedrc.json b/.lintstagedrc.json deleted file mode 100644 index ceaa164..0000000 --- a/.lintstagedrc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "*": "pnpm run clean:write" -} diff --git a/.markdownlint.config b/.markdownlint.config new file mode 100644 index 0000000..5c6eeb7 --- /dev/null +++ b/.markdownlint.config @@ -0,0 +1,13 @@ +{ + "default": true, + "line-length": false, + "no-trailing-punctuation": + "punctuation": '.,;:' + "list-marker-space": false + "no-multiple-blanks": false + "no-hard-tabs": false + "MD001": false + "MD013": false + "MD024": false + "MD033": false +} diff --git a/.node-version b/.node-version new file mode 100644 index 0000000..209e3ef --- /dev/null +++ b/.node-version @@ -0,0 +1 @@ +20 diff --git a/.pnpmignore b/.pnpmignore deleted file mode 100644 index 4abbfa9..0000000 --- a/.pnpmignore +++ /dev/null @@ -1,16 +0,0 @@ -# Ignore temporary files and directories -.tmp - -# Ignore production directories -.next -prod -dist - -# Ignore the directory with installed dependencies -node_modules - -# Ignore the React configuration files -.env - -# Ignore the log files -*.log diff --git a/.prettierignore b/.prettierignore index 10b95e3..cf39fae 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,9 +1,10 @@ node_modules .husky -/coverage +/dist/ +/node_modules/ +/stories/ .prettierignore .stylelintignore .editorconfig .eslintignore -.pnpmignore -.pnpmrc + diff --git a/.prettierrc.js b/.prettierrc.js deleted file mode 100644 index 4225769..0000000 --- a/.prettierrc.js +++ /dev/null @@ -1,16 +0,0 @@ -// Some settings are automatically inherited from .editorconfig -module.exports = { - overrides: [ - { - files: ".editorconfig", - options: { parser: "yaml" }, - }, - ], - useTabs: true, - printWidth: 80, - tabWidth: 2, - singleQuote: false, - jsxSingleQuote: false, - trailingComma: "all", - semi: true, -}; diff --git a/.prettierrc.json b/.prettierrc.json new file mode 100644 index 0000000..92fd5e5 --- /dev/null +++ b/.prettierrc.json @@ -0,0 +1,15 @@ +{ + "arrowParens": "avoid", + "bracketSpacing": true, + "endOfLine": "lf", + "jsxSingleQuote": false, + "printWidth": 80, + "proseWrap": "preserve", + "quoteProps": "as-needed", + "requirePragma": false, + "semi": true, + "singleQuote": true, + "tabWidth": 2, + "trailingComma": "all", + "useTabs": true +} diff --git a/README.md b/README.md index e69de29..41c3284 100644 --- a/README.md +++ b/README.md @@ -0,0 +1,14 @@ +

+ GoodbyeDPI +

+ +

GoodbyeDPI UI / Docs

+ +

+ + Stargazers + + + + Releases +

diff --git a/app/App.tsx b/app/App.tsx new file mode 100644 index 0000000..688b87d --- /dev/null +++ b/app/App.tsx @@ -0,0 +1,29 @@ +import { ThemeProvider } from "@/components/contexts/theme-provider"; +import { Footer } from "@/components/footer"; +import { Navbar } from "@/components/navbar"; +import { Analytics } from "@vercel/analytics/react"; +import { SpeedInsights } from "@vercel/speed-insights/next"; +import { PropsWithChildren } from "react"; + +export const App = (props: PropsWithChildren) => { + return ( + <> + + +
+ {props.children} +
+