Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 3 additions & 0 deletions .github/workflows/pull.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ jobs:
- name: Install dependencies
run: bun install

- name: Generate WXT types
run: bunx wxt prepare

- name: Build files
run: bun compile

3 changes: 3 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ jobs:
- name: Install dependencies
run: bun install

- name: Generate WXT types
run: bunx wxt prepare

- name: Build files
run: bun compile

3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ dev
local_output
diff.txt

docs/*
docs/*
.claude
8 changes: 7 additions & 1 deletion bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
"axios": "1.18.0",
"canvas-confetti": "1.9.4",
"chart.js": "4.5.1",
"class-variance-authority": "0.7.1",
"clsx": "2.1.1",
"framer-motion": "12.40.0",
"jalali-moment": "3.3.11",
"moment": "2.30.1",
Expand Down
36 changes: 36 additions & 0 deletions src/common/utils/cn.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import { type ClassValue, clsx } from 'clsx'
import { extendTailwindMerge } from 'tailwind-merge'

const twMerge = extendTailwindMerge<'wg-backdrop'>({
extend: {
classGroups: {
'wg-backdrop': ['bg-glass'],

'bg-color': ['bg-widget', 'bg-content', 'bg-raised'],
'text-color': ['text-strong', 'text-content', 'text-muted', 'text-subtle'],
'border-color': ['border-content', 'border-strong'],

rounded: ['rounded-widget', 'rounded-card'],
shadow: ['elevation-sm', 'elevation', 'elevation-lg'],
transition: ['transition-ui'],
'outline-style': ['focus-ring'],
z: [
'z-base',
'z-raised',
'z-sticky',
'z-drag',
'z-nav',
'z-backdrop',
'z-sheet',
'z-modal',
'z-popover',
'z-toast',
'z-pet',
],
},
},
})

export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs))
}
1 change: 1 addition & 0 deletions src/common/utils/translate-error.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ const errorTranslations: Record<string, string> = {
FOLDER_STRUCTURE_TOO_DEEP: 'FOLDER_STRUCTURE_TOO_DEEP',
BULK_IMPORT_LIMIT_EXCEEDED: `تعداد آیتم درون‌ریزی بیش‌از حد هست`,
NO_VALID_ITEMS_TO_IMPORT: 'هیچ آیتم معتبری برای درون‌ریزی وجود نداره',
BIRTHDATE_CANNOT_BE_CHANGED: 'به تازگی تاریخ تولدت رو عوض کردی!',
}

const validationTranslations: Record<string, string> = {
Expand Down
11 changes: 6 additions & 5 deletions src/components/auth/auth-required-modal.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { callEvent } from '@/common/utils/call-event'
import Modal from '@/components/modal'
import { Button } from '../button/button'
import { Modal } from '@/components/ui'
import { Button } from '@/components/ui'
import { Icon } from '@/src/icons'

interface AuthRequiredModalProps {
Expand Down Expand Up @@ -35,7 +35,7 @@ export function AuthRequiredModal({
closeOnBackdropClick={true}
>
<div className="flex flex-col items-center justify-between w-full text-center h-62">
<div className="relative flex items-center justify-center w-16 h-16 mt-8 rounded-full bg-blue-500/10">
<div className="relative flex items-center justify-center w-16 h-16 mt-8 rounded-full bg-primary/10">
<div
className="absolute inset-0 rounded-full bg-primary/5 animate-ping"
style={{ animationDuration: '2s' }}
Expand All @@ -52,15 +52,16 @@ export function AuthRequiredModal({
<Button
onClick={triggerAccountTabDisplay}
size="md"
isPrimary={true}
variant="primary"
className={`flex-1 border-none rounded-2xl text-xs w-full`}
>
{loginButtonText}
</Button>
<Button
onClick={onClose}
size="md"
className="w-32 border border-content text-content hover:bg-base-300/50 rounded-2xl"
variant="outline"
className="w-32 rounded-2xl"
>
{cancelButtonText}
</Button>
Expand Down
10 changes: 5 additions & 5 deletions src/components/auth/require-auth.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Motion as motion } from '@/common/motion'
import type { ReactNode } from 'react'
import { callEvent } from '@/common/utils/call-event'
import { useAuth } from '@/context/auth.context'
import { Button } from '../button/button'
import { Button } from '@/components/ui'

interface RequireAuthProps {
children: ReactNode
Expand Down Expand Up @@ -49,8 +49,8 @@ export const RequireAuth = ({ children, fallback, mode = 'block' }: RequireAuthP
<Button
onClick={handleAuthClick}
size="sm"
isPrimary={true}
className="btn mt-2 !w-fit px-6 border-none shadow-none text-white rounded-3xl transition-colors duration-300 ease-in-out"
variant="primary"
className="mt-2 w-fit px-6 border-none shadow-none rounded-3xl"
>
ورود به حساب
</Button>
Expand All @@ -76,8 +76,8 @@ export const RequireAuth = ({ children, fallback, mode = 'block' }: RequireAuthP
<Button
onClick={handleAuthClick}
size="sm"
isPrimary={true}
className="btn mt-2 !w-fit px-6 border-none shadow-none text-white rounded-3xl transition-colors duration-300 ease-in-out"
variant="primary"
className="mt-2 w-fit px-6 border-none shadow-none rounded-3xl"
>
ورود به حساب
</Button>
Expand Down
2 changes: 1 addition & 1 deletion src/components/auth/require-verification.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Motion as motion } from '@/common/motion'
import type { ReactNode } from 'react'
import { callEvent } from '@/common/utils/call-event'
import { useAuth } from '@/context/auth.context'
import { Button } from '../button/button'
import { Button } from '@/components/ui'
import { Icon } from '@/src/icons'

interface RequireVerificationProps {
Expand Down
10 changes: 0 additions & 10 deletions src/components/badges/new.badge.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions src/components/blur-mode/blur-mode.button.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { useState } from 'react'
import { useGeneralSetting } from '@/context/general-setting.context'
import Tooltip from '../tool-tip'
import { Tooltip } from '@/components/ui'
import { Icon } from '@/src/icons'
import { ConfirmationModal } from '../modal/confirmation-modal'
import { ConfirmationModal } from '@/components/ui'
import Analytics from '@/analytics'

export function BlurModeButton() {
Expand Down
48 changes: 0 additions & 48 deletions src/components/button/button.tsx

This file was deleted.

25 changes: 0 additions & 25 deletions src/components/chip.component.tsx

This file was deleted.

1 change: 0 additions & 1 deletion src/components/date-picker/index.ts

This file was deleted.

2 changes: 0 additions & 2 deletions src/components/dropdown/index.ts

This file was deleted.

14 changes: 8 additions & 6 deletions src/components/extension-installed-modal.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { useState } from 'react'
import keepItImage from '@/assets/images/keep-it.png'
import { Button } from './button/button'
import Checkbox from './checkbox'
import Modal from './modal'
import { Button } from './ui'
import { Checkbox } from '@/components/ui'
import { Modal } from '@/components/ui'
import { Icon } from '../icons'

interface ExtensionInstalledModalProps {
Expand Down Expand Up @@ -72,7 +72,7 @@ const StepOne = ({ onGetStarted }: StepOneProps) => {
size="md"
onClick={onGetStarted}
className="w-full text-base font-light shadow-sm rounded-2xl shadow-primary outline-none!"
isPrimary={true}
variant="primary"
>
شروع کنید
</Button>
Expand Down Expand Up @@ -158,14 +158,16 @@ const StepFirefoxConsent = ({ onGetStarted }: StepFirefoxConsentProps) => {
<Button
onClick={handleDecline}
size="md"
className="flex items-center justify-center w-40 btn btn-error rounded-xl"
variant="danger"
className="flex items-center justify-center w-40 rounded-xl"
>
🚫 حذف افزونه
</Button>
<Button
onClick={handleConfirm}
size="md"
className="w-40 btn btn-success rounded-xl"
variant="success"
className="w-40 rounded-xl"
>
✅ تأیید و ادامه
</Button>
Expand Down
5 changes: 0 additions & 5 deletions src/components/filter-tooltip/index.ts

This file was deleted.

25 changes: 0 additions & 25 deletions src/components/loading/icon-loading.tsx

This file was deleted.

2 changes: 0 additions & 2 deletions src/components/pagination/index.ts

This file was deleted.

Loading
Loading