Skip to content

Commit 8caa67e

Browse files
committed
style(calendar): update text colors for improved readability and consistency
1 parent 4bab4d2 commit 8caa67e

File tree

6 files changed

+16
-13
lines changed

6 files changed

+16
-13
lines changed

src/layouts/calendar/calendar.tsx

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,20 +50,20 @@ export const PersianCalendar: React.FC = () => {
5050
<div className="grid gap-4 md:grid-cols-5" dir="rtl">
5151
<div className="p-4 md:col-span-3 bg-gradient-to-br from-neutral-100 to-neutral-50 dark:from-neutral-800 dark:to-neutral-900 rounded-xl backdrop-blur-sm lg:h-96">
5252
<div className="flex items-center justify-between mb-4">
53-
<h3 className="text-xl font-medium text-gray-200">
53+
<h3 className="text-xl font-medium text-gray-500 dark:text-gray-100">
5454
{PERSIAN_MONTHS[currentDate.jMonth()]} {currentDate.jYear()}
5555
</h3>
5656
<div className="flex gap-2">
5757
<button
5858
onClick={() => changeMonth(-1)}
59-
className="flex flex-row-reverse items-center gap-1 p-2 text-gray-400 rounded-lg hover:text-gray-200 hover:bg-gray-700/50"
59+
className="flex flex-row-reverse items-center gap-1 p-2 text-gray-500 rounded-lg dark:text-gray-200 hover:text-gray-200 hover:bg-gray-700/50"
6060
>
6161
ماه قبل
6262
<FaChevronRight />
6363
</button>
6464
<button
6565
onClick={() => changeMonth(1)}
66-
className="flex flex-row-reverse items-center gap-1 p-2 text-gray-400 rounded-lg hover:text-gray-200 hover:bg-gray-700/50"
66+
className="flex flex-row-reverse items-center gap-1 p-2 text-gray-500 rounded-lg dark:text-gray-200 hover:text-gray-200 hover:bg-gray-700/50"
6767
>
6868
<FaChevronLeft />
6969
ماه بعد
@@ -73,7 +73,10 @@ export const PersianCalendar: React.FC = () => {
7373

7474
<div className="grid grid-cols-7 gap-2">
7575
{WEEKDAYS.map((day) => (
76-
<div key={day} className="py-2 text-xs text-center text-gray-400">
76+
<div
77+
key={day}
78+
className="py-2 text-xs text-center text-gray-500 dark:text-gray-200"
79+
>
7780
{day}
7881
</div>
7982
))}
@@ -99,7 +102,7 @@ export const PersianCalendar: React.FC = () => {
99102
</div>
100103

101104
<div className="p-4 md:col-span-2 bg-gradient-to-br from-neutral-100 to-neutral-50 dark:from-neutral-800 dark:to-neutral-900 rounded-xl backdrop-blur-sm">
102-
<h3 className="mb-4 text-xl font-medium text-gray-200">
105+
<h3 className="mb-4 text-xl font-medium text-gray-500 dark:text-gray-100">
103106
{PERSIAN_MONTHS[selectedDate.jMonth()]} {selectedDate.jDate()}
104107
</h3>
105108

@@ -117,7 +120,7 @@ const CalendarLayout = () => {
117120
return (
118121
<section className="p-2 mx-1 overflow-y-auto rounded lg:mx-4 max-h-[calc(100vh-4rem)]">
119122
<div className="flex items-center justify-between w-full px-1 mb-4">
120-
<h2 className="text-lg font-semibold text-gray-200 font-[balooTamma]">
123+
<h2 className="text-lg font-semibold dark:text-gray-200 font-[balooTamma]">
121124
📅 Calender
122125
</h2>
123126
<div

src/layouts/calendar/components/day.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export function DayItem({
4242
onClick={() => setSelectedDate(cellDate)}
4343
className={`
4444
relative p-2 rounded-lg text-sm transition-colors
45-
${isHoliday ? 'text-red-400' : 'text-gray-300'}
45+
${isHoliday ? 'text-red-400' : 'text-gray-600 dark:text-gray-300'}
4646
${isSelected ? 'bg-blue-500/20' : 'hover:bg-gray-700/50'}
4747
${todayShamsiEvent || hasTodo ? 'font-bold' : ''}
4848
${isToday(cellDate) ? 'ring-2 ring-blue-500' : ''}

src/layouts/calendar/components/events/event.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ export function Events({ events, currentDate }: Prop) {
3333

3434
return (
3535
<div>
36-
<h4 className="mb-2 text-lg text-gray-300">رویدادها</h4>
36+
<h4 className="mb-2 text-lg text-gray-500 dark:text-gray-400">رویدادها</h4>
3737
<div className="h-40 space-y-3 overflow-y-auto lg:h-32">
3838
{selectedEvents.length > 0 ? (
3939
selectedEvents.map((event, index) => (

src/layouts/calendar/components/todos/todo-input.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ export function TodoInput({ onAdd }: Prop) {
2222
value={text}
2323
onChange={(e) => setText(e.target.value)}
2424
placeholder="یادداشت جدید..."
25-
className="flex-1 px-3 py-2 text-gray-200 placeholder-gray-400 rounded-lg bg-gray-700/50 focus:outline-none focus:ring-2 focus:ring-blue-500"
25+
className="flex-1 px-3 py-2 text-gray-600 placeholder-gray-500 rounded-lg bg-gray-300/50 dark:bg-gray-700/50 focus:outline-none focus:ring-2 focus:ring-blue-500 "
2626
/>
2727
<button
2828
type="submit"

src/layouts/calendar/components/todos/todo.item.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,16 @@ export function TodoItem({ todo, deleteTodo, toggleTodo }: Prop) {
1010
return (
1111
<div
1212
key={todo.id}
13-
className="flex items-center gap-2 p-3 rounded-lg bg-gray-700/30 group"
13+
className="flex items-center gap-2 p-3 rounded-lg bg-gray-300/80 dark:bg-neutral-800/50 group"
1414
>
1515
<input
1616
type="checkbox"
1717
checked={todo.completed}
1818
onChange={() => toggleTodo(todo.id)}
19-
className="w-4 h-4 border-gray-500 rounded"
19+
className="w-4 h-4 border-gray-500 rounded "
2020
/>
2121
<span
22-
className={`flex-1 text-gray-200 ${todo.completed ? 'line-through text-gray-400' : ''}`}
22+
className={`flex-1 text-gray-600 dark:text-gray-300 ${todo.completed ? 'line-through text-gray-400' : ''}`}
2323
>
2424
{todo.text}
2525
</span>

src/layouts/calendar/components/todos/todos.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export function Todos({ currentDate }: TodoProp) {
1717

1818
return (
1919
<div className="mb-6">
20-
<h4 className="mb-2 text-lg text-gray-300">یادداشت‌های روز</h4>
20+
<h4 className="mb-2 text-lg text-gray-500 dark:text-gray-200">یادداشت‌های روز</h4>
2121
<TodoInput onAdd={(text) => addTodo(text, selectedDateStr)} />
2222
<div className="h-40 space-y-2 overflow-y-auto lg:h-32">
2323
{selectedDateTodos.map((todo) => (

0 commit comments

Comments
 (0)