Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Release #201

Open
wants to merge 108 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
Show all changes
108 commits
Select commit Hold shift + click to select a range
8b06ee3
[IMP] Import/Export Bookmarks
user-64bit May 16, 2024
61b17e5
Merge pull request #197 from us3r64bit/develop
medyo Jun 4, 2024
8c1b3e9
improve the import/export bookmarks UI
medyo Jun 6, 2024
37f406c
change the import/export icons
medyo Jun 6, 2024
b25327a
feat: Add auth modal ui and show it next to onboarding.
zouhir96 Jan 27, 2025
71cd2e6
feat: Add google auth.
zouhir96 Jan 27, 2025
6d26d06
feat: Show user info in setting.
zouhir96 Jan 27, 2025
19a3dee
feat: Fix imports.
zouhir96 Jan 30, 2025
b612a46
feat: Add github auth
zouhir96 Jan 30, 2025
49f5683
feat: Add logout and observe current user.
zouhir96 Jan 30, 2025
7c15152
feat: Moved firebase config variable to .env file.
zouhir96 Feb 9, 2025
da9cf87
feat: Create CurrentUser type.
zouhir96 Feb 10, 2025
885dc3d
feat: Create useAuth hook.
zouhir96 Feb 10, 2025
7a7a22e
feat: Add profile button to header and create profile page.
zouhir96 Feb 10, 2025
c7b0bae
feat: Separate useAuth and AuthStore.
zouhir96 Feb 11, 2025
005b348
feat: Move auth modal state handle to AuthStore.
zouhir96 Feb 12, 2025
9cd9297
feat: Create AuthModalStore without persist.
zouhir96 Feb 16, 2025
f563614
feat: Rebame config file to firebase config.
zouhir96 Feb 16, 2025
fa616c4
fix: Code reviews.
zouhir96 Feb 16, 2025
240e15b
fix modal not showing in other pages
medyo Feb 16, 2025
827f2cf
feat: Create separated file for authModalStore.
zouhir96 Feb 16, 2025
4a0c08e
fix: Code reviews.
zouhir96 Feb 16, 2025
217c9a9
feat: New AuthModal ui.
zouhir96 Feb 17, 2025
dfcd2b0
feat: Add authorization token to request interceptor
medyo Feb 19, 2025
5b44bc8
feat: Add user connection and disconnection tracking to analytics
medyo Feb 19, 2025
18f5ac4
refactor the button component
medyo Feb 22, 2025
005cfad
refactor: Simplify signIn function by removing providerName parameter
medyo Feb 22, 2025
4511c82
style: Adjust button padding for small and medium sizes
medyo Feb 22, 2025
2a23308
style: Update button component in AuthModal for consistent size and s…
medyo Feb 22, 2025
a42a312
refactor the Modal component and improve Auth Modal
medyo Feb 22, 2025
eb3b6db
style: Adjust authModal width for responsive design
medyo Feb 22, 2025
fe41293
refactor: Remove bookmark import/export functionality from ProfileSet…
medyo Feb 23, 2025
c7d52a1
feat: Add CircleButton component with customizable sizes and variants
medyo Feb 23, 2025
359269c
refactor: Replace button elements with CircleButton and Button compon…
medyo Feb 23, 2025
b2338b3
refactor: Simplify Button usage in BookmarkSettings component
medyo Feb 23, 2025
0914b6c
refactor: Update button styles and layout in App.css for improved fle…
medyo Feb 23, 2025
c4d7f33
refactor: Rename round-icon-button class to circle-button for consist…
medyo Feb 23, 2025
31d70b3
fix: Add validation for Firebase configuration to prevent initializat…
medyo Feb 23, 2025
b20b44a
refactor: Move input styles to App.css and replace button with Button…
medyo Feb 23, 2025
db58341
feat: Add profile image container with streak indicator in Header com…
medyo Feb 23, 2025
3629657
feat: Implement hit tracking and update user streak in AuthStore
medyo Feb 23, 2025
d22b911
feat: Remove unused idToken and email
zouhir96 Feb 24, 2025
9fb260b
feat: Remove Profile page + Moved userInfo to General settings.
zouhir96 Feb 24, 2025
6c89c50
feat: Replace button elements with Button component for consistency
medyo Feb 24, 2025
f9bf089
feat: Update logout button size and adjust user info layout for bette…
medyo Feb 24, 2025
f62c62e
refactor: Simplify Header component by removing back navigation for home
medyo Feb 24, 2025
dc42241
Merge branch 'zouhir-auth' into feat-streaks
medyo Feb 24, 2025
03367d5
feat: Update user info display to show provider name instead of provi…
medyo Feb 24, 2025
d67a39c
feat: Adjust user image size and enhance layout for user information …
medyo Feb 24, 2025
d1dac8c
Merge branch 'zouhir-auth' into feat-streaks
medyo Feb 25, 2025
e4010d4
feat: Show auth provider icon in user info.
zouhir96 Feb 24, 2025
1b5fd18
feat: Create ConfirmModal component.
zouhir96 Feb 25, 2025
0bc49d4
feat: Add logout confirm modal.
zouhir96 Feb 25, 2025
e22c85c
feat: Logout firebase user.
zouhir96 Feb 25, 2025
9a8b8ba
fix: Merge conflicts.
zouhir96 Feb 25, 2025
8c91828
feat: Implement logout functionality using Firebase signOut
medyo Feb 25, 2025
822890b
feat: Enhance user settings UI with improved logout button and layout…
medyo Feb 25, 2025
e802001
refactor: Remove unused searchEngine prop from GeneralSettings component
medyo Feb 25, 2025
5a2faa1
Merge branch 'zouhir-auth' into feat-streaks
medyo Feb 26, 2025
d8cbe27
feat: Add user streak display to GeneralSettings component
medyo Feb 26, 2025
e6eb469
feat: Refactor streak display in GeneralSettings component for improv…
medyo Feb 27, 2025
329c02c
feat: Update manifest files to version 3 and adjust permissions
medyo Mar 9, 2025
698d5f5
feat: Add message listener for token reception in auth.js
medyo Mar 9, 2025
72c2948
refactor: Clean up background.js by removing commented-out code
medyo Mar 9, 2025
2eebb3d
feat: Add content script to handle token reception and messaging
medyo Mar 9, 2025
9211342
refactor: Update return types for environment utility functions
medyo Mar 9, 2025
2d4d638
feat: Simplify Firebase configuration by removing unused keys and add…
medyo Mar 9, 2025
bde2db3
feat: Add host permission checks for Firefox sign-in functionality
medyo Mar 9, 2025
5b4ff4a
feat: Refactor auth modal store to include error handling and simplif…
medyo Mar 9, 2025
c62fecf
feat: Add dangerToast style for error notifications and adjust modal …
medyo Mar 9, 2025
d60f3c4
feat: Wrap AppLayout component with AuthProvider for improved authent…
medyo Mar 9, 2025
074b1f9
feat: Implement getOauthLink API and custom hook for OAuth authentica…
medyo Mar 9, 2025
6c9ade3
feat: Enhance AuthModal with OAuth link handling and error management
medyo Mar 9, 2025
d30a6d8
feat: Add AuthProvider component for handling user authentication via…
medyo Mar 9, 2025
8bc9d3e
feat: Add error styling to AuthModal for improved user feedback
medyo Mar 9, 2025
90de2ba
feat: Change script injection to document.documentElement for improve…
medyo Mar 9, 2025
2a55970
feat: Remove unused GitHub and Google auth providers from Firebase setup
medyo Mar 9, 2025
b0f2c7d
feat: Add Spinner component for loading indicators with customizable …
medyo Mar 9, 2025
b8bd09a
feat: Add loading state to Button component with spinner indicator
medyo Mar 9, 2025
8972fc3
feat: Add CSS styles for Spinner component with customizable sizes
medyo Mar 9, 2025
0d596f2
feat: Update AuthModal to include Google and GitHub auth providers wi…
medyo Mar 9, 2025
827b755
feat: Add success toast notification for user login with dynamic welc…
medyo Mar 9, 2025
e12fd5e
refactor: replace react-device-detect with responsive breakpoints and…
medyo Mar 9, 2025
1d7de16
feat: Refactor OAuth link retrieval to accept dynamic provider strings
medyo Mar 22, 2025
8c7c972
feat: Update API endpoint for OAuth link retrieval
medyo Mar 22, 2025
9d2932d
feat: Simplify content script matches in base manifest
medyo Mar 22, 2025
cc38776
xMerge branch 'zouhir-auth' into feat-streaks
medyo Mar 24, 2025
bb81416
feat: Refactor isConnected function to use direct user check
medyo Mar 24, 2025
d3a531e
Merge branch 'zouhir-auth' into feat-streaks
medyo Mar 24, 2025
55894bb
feat: Update isConnected check to use direct reference
medyo Mar 24, 2025
d10274c
feat: Add pluralization utility and update streak display in user info
medyo Mar 24, 2025
ae9df23
Add ad verification
medyo Mar 24, 2025
ee24252
Merge pull request #211 from zouhir96/auth
medyo Mar 24, 2025
a8ffd60
Merge pull request #216 from medyo/feat-streaks
medyo Mar 24, 2025
39d5da0
Merge branch 'develop' into fix-dynamic-breakpoint-view
medyo Mar 24, 2025
3fe74b2
rename vite config to mjs
medyo Mar 24, 2025
b09464b
chore: update dependencies and set Node.js engine version
medyo Mar 24, 2025
79183a2
fix: update request interceptor to use InternalAxiosRequestConfig
medyo Mar 24, 2025
4db152e
Merge branch 'develop' into fix-dynamic-breakpoint-view
medyo Mar 24, 2025
2736e88
Merge pull request #215 from medyo/fix-dynamic-breakpoint-view
medyo Mar 24, 2025
051e1c5
chore: update Node.js version in GitHub Actions workflow to 18
medyo Mar 26, 2025
d53d4d8
fix: add unique keys to list items in UserInfo component
medyo Mar 26, 2025
67f94aa
fix: update logout modal title and description for clarity
medyo Mar 26, 2025
0c70a29
fix: improve auth error handling and update modal styles for better u…
medyo Mar 26, 2025
fa162ac
fix: restrict content script matches to production URL only
medyo Mar 27, 2025
d1a2770
feat: enhance streak display with new icon and styling adjustments
medyo Mar 27, 2025
ea20354
fix: update background style for content section with gradient
medyo Mar 27, 2025
e53dc2c
fix: update content background color and adjust border styling for co…
medyo Mar 28, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '16'
node-version: 18

- name: Install dependencies
run: yarn
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
18.20.0
12 changes: 8 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -9,23 +9,24 @@
"@tanstack/react-query-persist-client": "^5.8.4",
"@types/dompurify": "^2.3.4",
"@types/jspath": "^0.4.0",
"axios": "^0.21.2",
"axios": "^1.8.4",
"axios-cache-adapter": "^2.7.3",
"country-emoji": "^1.5.4",
"dompurify": "^2.2.7",
"dompurify": "^3.2.4",
"firebase": "^11.2.0",
"htmlparser2": "^8.0.1",
"jsonpath": "^1.1.1",
"normalize.css": "^8.0.1",
"prop-types": "^15.0.0-0",
"react": "^17.0.1",
"react-contexify": "^5.0.0",
"react-device-detect": "^1.17.0",
"react-dom": "^17.0.1",
"react-easy-sort": "^1.5.1",
"react-error-boundary": "^3.1.4",
"react-icons": "^5.2.1",
"react-markdown": "^7.0.1",
"react-modal": "^3.12.1",
"react-responsive": "^10.0.1",
"react-router-dom": "^6.21.0",
"react-select": "^5.0.1",
"react-share": "^4.4.1",
@@ -40,6 +41,9 @@
"web-vitals": "^0.2.4",
"zustand": "^4.3.3"
},
"engines": {
"node": "18"
},
"scripts": {
"start": "vite",
"preview": "vite preview",
@@ -91,7 +95,7 @@
"prettier": "^2.7.1",
"terser": "^5.19.2",
"typescript": "^5.1.6",
"vite": "^4.4.5",
"vite": "^6.2.3",
"vite-plugin-svgr": "^3.2.0",
"vite-tsconfig-paths": "^4.2.0"
}
6 changes: 6 additions & 0 deletions public/auth.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
window.addEventListener('message', (event) => {
if (event.data.type === 'TOKEN_RECEIVED') {
// Forward to content script
window.postMessage(event.data, '*')
}
})
7 changes: 1 addition & 6 deletions public/background.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,4 @@
/*chrome.browserAction.onClicked.addListener(function (tab) {
chrome.tabs.create({ url: "chrome://newtab" });
}
);*/

const uninstallUrl = `https://hackertab.dev/uninstall.html`
if (chrome.runtime.setUninstallURL) {
chrome.runtime.setUninstallURL(uninstallUrl)
}
}
9 changes: 9 additions & 0 deletions public/base.manifest.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
{
"manifest_version": 3,
"name": "Hackertab.dev - developer news",
"description": "All developer news in one tab",
"version": "1.20.1",
"chrome_url_overrides": {
"newtab": "index.html"
},
"host_permissions": ["https://*.hackertab.dev/*"],
"content_scripts": [
{
"matches": ["https://hackertab.dev/*"],
"run_at": "document_start",
"js": ["content.js"]
}
],
"icons": {
"16": "/logos/logo16.png",
"32": "/logos/logo32.png",
4 changes: 1 addition & 3 deletions public/chrome.manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
{
"manifest_version": 3,
"background": {
"service_worker": "background.js"
},
"host_permissions": ["https://*.hackertab.dev/*"]
}
}
12 changes: 12 additions & 0 deletions public/content.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
const script = document.createElement('script')
script.src = chrome.runtime.getURL('auth.js')
document.documentElement.appendChild(script)

// Listen for messages from the injected script
window.addEventListener('message', (event) => {
if (event.source !== window || !event.data || event.data.type !== 'TOKEN_RECEIVED') {
return
}

chrome.runtime.sendMessage({ ...event.data })
})
20 changes: 4 additions & 16 deletions public/firefox.manifest.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
{
"manifest_version": 2,
"background": {
"scripts": [
"background.js"
]
},
"permissions": [
"https://*.hackertab.dev/*"
],
"content_security_policy": "script-src 'self' object-src 'self'",
"applications": {
"gecko": {
"id": "{f8793186-e9da-4332-aa1e-dc3d9f7bb04c}"
}
}
}
"background": {
"scripts": ["background.js"]
}
}
13 changes: 12 additions & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
import { useEffect, useLayoutEffect, useState } from 'react'
import { DNDLayout } from 'src/components/Layout'
import { setupAnalytics, setupIdentification, trackPageView } from 'src/lib/analytics'
import {
identifyAdvBlocked,
setupAnalytics,
setupIdentification,
trackPageView,
} from 'src/lib/analytics'
import { useUserPreferences } from 'src/stores/preferences'
import { AppContentLayout } from './components/Layout'
import { verifyAdvStatus } from './features/adv/utils/status'
import { isWebOrExtensionVersion } from './utils/Environment'
import { lazyImport } from './utils/lazyImport'
const { OnboardingModal } = lazyImport(() => import('src/features/onboarding'), 'OnboardingModal')
@@ -30,6 +36,11 @@ export const App = () => {
document.body.classList.remove('preload')
setupAnalytics()
setupIdentification()
const adVerifier = async () => {
const status = await verifyAdvStatus()
identifyAdvBlocked(status)
}
adVerifier()
}, [])

useEffect(() => {
Loading