Skip to content

Commit

Permalink
Merge pull request #37 from kawamataryo/add-darkmode
Browse files Browse the repository at this point in the history
🎨 add darkmode
  • Loading branch information
kawamataryo authored Feb 2, 2024
2 parents 66c61fb + 6241e4c commit 5d7fdca
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/lib/components/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Modal = ({ children, anchorRef, open = false }: Props) => {
return (
<>
<dialog className="modal" ref={anchorRef} open={open}>
<div className="modal-box p-10 bg-white w-[750px] max-w-none text-gray-800">
<div className="modal-box p-10 bg-base-100 w-[750px] max-w-none text-base-content">
{children}
</div>
<form method="dialog" className="modal-backdrop">
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/UserCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ const UserCard = ({ user, actionMode, clickAction }: Props) => {
{user.displayName}
</a>
</h2>
<p className="whitespace-nowrap w-fit break-all text-gray-500 text-sm">
<p className="whitespace-nowrap w-fit break-all text-gray-500 dark:text-gray-400 text-sm">
<a
href={`https://bsky.app/profile/${user.handle}`}
target="_blank"
Expand Down
2 changes: 1 addition & 1 deletion src/lib/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,6 @@ export const MATCH_TYPE_LABEL_AND_COLOR = {
},
[BSKY_USER_MATCH_TYPE.DESCRIPTION]: {
label: "Included handle name in description",
color: "neutral",
color: "secondary",
},
};
4 changes: 2 additions & 2 deletions src/popup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ function IndexPopup() {

return (
<div className="px-5 pt-3 pb-4 w-[380px]">
<h1 className="text-primary text-2xl font-thin flex gap-2 items-center">
<h1 className="text-primary dark:text-white text-2xl font-thin flex gap-2 items-center">
<svg
className="w-5 h-5"
xmlns="http://www.w3.org/2000/svg"
Expand Down Expand Up @@ -210,7 +210,7 @@ function IndexPopup() {
<button
type="submit"
className={
"disabled:text-gray-600 mt-3 normal-case btn btn-primary btn-sm w-full"
"disabled:text-gray-600 dark:disabled:bg-gray-700 dark:disabled:text-gray-300 mt-3 normal-case btn btn-primary btn-sm w-full"
}
disabled={isDisabled}
>
Expand Down
7 changes: 6 additions & 1 deletion tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,12 @@ module.exports = {
primary: "#1D4ED8"
}
},
{
dark: {
...require("daisyui/src/theming/themes").night,
primary: "#1D4ED8"
}
}
],
},
darkMode: ['class', '[data-theme="night"]']
}

0 comments on commit 5d7fdca

Please sign in to comment.