Skip to content

Commit

Permalink
chore: replace all bg-active to bg-button
Browse files Browse the repository at this point in the history
  • Loading branch information
OXeu committed Jul 11, 2024
1 parent 1492329 commit 72ae3c2
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion client/src/components/feed_card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export function FeedCard({ id, title, avatar, draft, listed, top, summary, hasht
const { t } = useTranslation()
return (
<>
<Link href={`/feed/${id}`} target="_blank" className="w-full rounded-2xl bg-w my-2 p-6 duration-300 ani-show bg-active">
<Link href={`/feed/${id}`} target="_blank" className="w-full rounded-2xl bg-w my-2 p-6 duration-300 ani-show bg-button">
{avatar &&
<div className="flex flex-row items-center mb-2 rounded-xl overflow-clip">
<img src={avatar} alt=""
Expand Down
6 changes: 3 additions & 3 deletions client/src/components/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ function UserAvatar({ profile, className, mobile }: { className?: string, profil
</> : <>
<button title={githubLoginText} aria-label={githubLoginText}
onClick={() => window.location.href = `${oauth_url}`}
className={`flex rounded-xl border dark:border-neutral-600 ${mobile ? "bg-secondary" : "bg-w"} h-10 sm:h-auto px-2 py-2 bg-w bg-active t-primary items-center justify-center`}>
className={`flex rounded-xl border dark:border-neutral-600 ${mobile ? "bg-secondary" : "bg-w"} h-10 sm:h-auto px-2 py-2 bg-w bg-button t-primary items-center justify-center`}>
<i className="ri-github-line ri-xl"></i>
<p className="text-sm ml-1">
{githubLoginText}
Expand Down Expand Up @@ -194,7 +194,7 @@ function LanguageSwitch({ className }: { className?: string }) {
<div className={className + " flex flex-row items-center"}>
<Popup trigger={
<button title={label} aria-label={label}
className="flex rounded-full border dark:border-neutral-600 px-2 bg-w aspect-[1] items-center justify-center t-primary bg-active">
className="flex rounded-full border dark:border-neutral-600 px-2 bg-w aspect-[1] items-center justify-center t-primary bg-button">
<i className="ri-translate-2"></i>
</button>
}
Expand Down Expand Up @@ -234,7 +234,7 @@ function SearchButton({ className, onClose }: { className?: string, onClose?: ()
}
return (<div className={className + " flex flex-row items-center"}>
<button onClick={() => setIsOpened(true)} title={label} aria-label={label}
className="flex rounded-full border dark:border-neutral-600 px-2 bg-w aspect-[1] items-center justify-center t-primary bg-active">
className="flex rounded-full border dark:border-neutral-600 px-2 bg-w aspect-[1] items-center justify-center t-primary bg-button">
<i className="ri-search-line"></i>
</button>
<ReactModal
Expand Down
4 changes: 2 additions & 2 deletions client/src/components/icon.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
export function Icon({ name, label, className, onClick, hover = true }: { name: string, label: string, className?: string, onClick: () => any, hover?: boolean }) {
return (
<button title={label} aria-label={label} onClick={onClick} className={`max-w-12 flex rounded-full border px-2 bg-w aspect-[1] items-center justify-center t-primary ${hover ? "bg-active" : ""} ` + className}>
<button title={label} aria-label={label} onClick={onClick} className={`max-w-12 flex rounded-full border px-2 bg-w aspect-[1] items-center justify-center t-primary ${hover ? "bg-button" : ""} ` + className}>
<i className={name}></i>
</button>
)
}

export function IconSmall({ name, label, className, onClick, hover = true }: { name: string, label: string, className?: string, onClick: () => any, hover?: boolean }) {
return (
<button title={label} aria-label={label} onClick={onClick} className={`max-w-8 flex rounded-full border px-2 bg-w aspect-[1] items-center justify-center t-primary ${hover ? "bg-active" : ""} ` + className}>
<button title={label} aria-label={label} onClick={onClick} className={`max-w-8 flex rounded-full border px-2 bg-w aspect-[1] items-center justify-center t-primary ${hover ? "bg-button" : ""} ` + className}>
<i className={name}></i>
</button>
)
Expand Down
8 changes: 4 additions & 4 deletions client/src/page/friends.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ function Friend({ friend }: { friend: FriendItem }) {
]
return (
<>
<a title={friend.name} href={friend.url} target="_blank" className="bg-active w-full bg-w rounded-xl p-4 flex flex-col justify-center items-center relative ani-show">
<a title={friend.name} href={friend.url} target="_blank" className="bg-button w-full bg-w rounded-xl p-4 flex flex-col justify-center items-center relative ani-show">
<div className="w-16 h-16">
<img className={"rounded-full " + (friend.health.length > 0 ? "grayscale" : "")} src={friend.avatar} alt={friend.name} />
</div>
Expand All @@ -213,7 +213,7 @@ function Friend({ friend }: { friend: FriendItem }) {
{friend.accepted !== 1 && <p className={`${friend.accepted === 0 ? "t-primary" : "text-theme"}`}>{statusOption[friend.accepted + 1].label}</p>}
{friend.health.length > 0 && <p className="text-sm text-gray-500 text-center">{errorHumanize(friend.health)}</p>}
{(profile?.permission || profile?.id === friend.uid) && <>
<button onClick={(e) => { e.preventDefault(); setIsOpen(true) }} className="absolute top-0 right-0 m-2 px-2 py-1 bg-secondary t-primary rounded-full bg-active">
<button onClick={(e) => { e.preventDefault(); setIsOpen(true) }} className="absolute top-0 right-0 m-2 px-2 py-1 bg-secondary t-primary rounded-full bg-button">
<i className="ri-settings-line"></i>
</button></>}
</a>
Expand Down Expand Up @@ -276,8 +276,8 @@ function Friend({ friend }: { friend: FriendItem }) {
<Input value={avatar} setValue={setAvatar} placeholder={t('avatar.url')} className="mt-2" />
<Input value={url} setValue={setUrl} placeholder={t('url')} className="my-2" />
<div className='flex flex-row justify-center space-x-2'>
<button onClick={deleteFriend} className="bg-secondary text-theme rounded-full bg-active px-4 py-2 mt-2">{t('delete.title')}</button>
<button onClick={updateFriend} className="bg-secondary t-primary rounded-full bg-active px-4 py-2 mt-2">{t('save')}</button>
<button onClick={deleteFriend} className="bg-secondary text-theme rounded-full bg-button px-4 py-2 mt-2">{t('delete.title')}</button>
<button onClick={updateFriend} className="bg-secondary t-primary rounded-full bg-button px-4 py-2 mt-2">{t('save')}</button>
</div>
</div >
</Modal>
Expand Down

0 comments on commit 72ae3c2

Please sign in to comment.