Skip to content

Commit c47bfc4

Browse files
committed
Optimizing link margins and paddings
1 parent 74e9124 commit c47bfc4

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/components/Links/Link.tsx

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ export const Link: FC<Props> = ({
7373
className={classNames(
7474
'grid grid-cols-[auto,1fr,auto] grid-rows-[auto,auto]',
7575
'items-center gap-x-2',
76+
'p-1',
7677
{
7778
'text-gray-400 hover:text-gray-600': !visible,
7879
'dark:text-gray-400 dark:hover:text-gray-300': !visible,
@@ -95,7 +96,7 @@ export const Link: FC<Props> = ({
9596
<div
9697
className={classNames(
9798
'grid items-center justify-center',
98-
'm-1 p-1',
99+
'p-1',
99100
'bg-white',
100101
'rounded',
101102
)}
@@ -112,15 +113,15 @@ export const Link: FC<Props> = ({
112113
</div>
113114

114115
<div
115-
className={classNames('my-1', {
116-
'text-gray-900 dark:text-gray-50': visible,
116+
className={classNames({
117+
'text-black dark:text-gray-50': visible,
117118
'line-through': !visible,
118119
})}
119120
>
120121
{link.title}
121122
</div>
122123

123-
<div className="flex self-stretch">
124+
<div className="flex self-stretch -my-1 -mr-1">
124125
{searchable && !isCustomizeMode ? (
125126
<>
126127
{focus ? (
@@ -157,7 +158,7 @@ export const Link: FC<Props> = ({
157158
{showDescription && link.description !== undefined ? (
158159
<div
159160
className={classNames('col-start-2', 'pb-1', 'text-sm', {
160-
'text-gray-600 dark:text-gray-300': visible,
161+
'text-gray-500 dark:text-gray-300': visible,
161162
})}
162163
>
163164
{link.description}

0 commit comments

Comments
 (0)