Skip to content

Commit

Permalink
fix search dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
abvthecity committed Feb 22, 2024
1 parent e22e608 commit ddb2400
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions packages/ui/app/src/search/SearchDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export const SearchDialog: React.FC<SearchDialog.Props> = (providedProps) => {
/>
<Dialog.Panel
className={classNames(
"md:max-w-content-width my-header-height-padded relative z-10 mx-6 max-h-96 md:mx-auto",
"md:max-w-content-width my-header-height-padded relative z-10 mx-6 max-h-[calc(100vh-var(--spacing-header-height)-var(--spacing-header-height)-2rem)] md:mx-auto flex flex-col",
{
"mt-4": fromHeader,
},
Expand All @@ -83,7 +83,7 @@ function FernInstantSearch({ searchClient, searchService, inputRef }: FernInstan
const { activeNavigatable } = useNavigationContext();
return (
<InstantSearch searchClient={searchClient} indexName={searchService.index}>
<div className="border-default bg-background-translucent flex h-auto flex-col overflow-hidden rounded-xl border text-left align-middle shadow-2xl backdrop-blur-lg">
<div className="border-default bg-background-translucent flex h-auto min-h-0 shrink flex-col overflow-hidden rounded-xl border text-left align-middle shadow-2xl backdrop-blur-lg">
<SearchBox
ref={inputRef}
placeholder={
Expand Down
8 changes: 4 additions & 4 deletions packages/ui/app/src/search/content/EndpointRecordV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const EndpointRecordV2: React.FC<EndpointRecordV2.Props> = ({ hit, isHove
<div
className={classNames("line-clamp-1 flex space-x-1 items-center text-sm text-start", {
"t-muted": !isHovered,
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
})}
>
<div
Expand Down Expand Up @@ -68,7 +68,7 @@ export const EndpointRecordV2: React.FC<EndpointRecordV2.Props> = ({ hit, isHove
<div
className={classNames("text-sm tracking-wide", {
"t-muted": !isHovered,
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
})}
>
Endpoint
Expand All @@ -77,7 +77,7 @@ export const EndpointRecordV2: React.FC<EndpointRecordV2.Props> = ({ hit, isHove
<div className="flex items-center justify-between">
<span
className={classNames("line-clamp-1 text-start text-xs", {
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
"t-muted": !isHovered,
})}
>
Expand All @@ -86,7 +86,7 @@ export const EndpointRecordV2: React.FC<EndpointRecordV2.Props> = ({ hit, isHove

<CornerDownLeft
className={classNames("size-3", {
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
"t-muted": !isHovered,
})}
/>
Expand Down
8 changes: 4 additions & 4 deletions packages/ui/app/src/search/content/PageRecordV2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ export const PageRecordV2: React.FC<PageRecordV2.Props> = ({ hit, isHovered }) =
<span
className={classNames("line-clamp-1 text-sm text-start", {
"text-text-default-light dark:text-text-default-dark": !isHovered,
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
})}
>
{hit.title}
</span>
<div
className={classNames("text-sm tracking-wide", {
"t-muted": !isHovered,
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
})}
>
Page
Expand All @@ -34,7 +34,7 @@ export const PageRecordV2: React.FC<PageRecordV2.Props> = ({ hit, isHovered }) =
<div className="flex items-center justify-between">
<span
className={classNames("line-clamp-1 text-start text-xs", {
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
"t-muted": !isHovered,
})}
>
Expand All @@ -43,7 +43,7 @@ export const PageRecordV2: React.FC<PageRecordV2.Props> = ({ hit, isHovered }) =

<CornerDownLeft
className={classNames("size-3", {
"text-white dark:text-black": isHovered,
"t-accent-contrast": isHovered,
"t-muted": !isHovered,
})}
/>
Expand Down

0 comments on commit ddb2400

Please sign in to comment.