Skip to content

Commit

Permalink
fix: autocomplete link (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
fpasquet authored Jan 29, 2024
1 parent 8e07f05 commit 43851a3
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@eleven-labs/design-system",
"description": "Design System for Eleven Labs",
"version": "0.26.1",
"version": "0.26.2",
"repository": {
"type": "git",
"url": "https://github.com/eleven-labs/design-system.git"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,24 @@ import type { ComponentPropsWithoutRef } from '@/types';
export interface CategoryEndingBlockProps extends BoxProps {
title: React.ReactNode;
description: React.ReactNode;
expertiseLink: { label: string } & ComponentPropsWithoutRef<'a'>;
expertiseLink?: { label: string } & ComponentPropsWithoutRef<'a'>;
}

export const CategoryEndingBlock: React.FC<CategoryEndingBlockProps> = ({
title,
description,
expertiseLink: { label: expertiseLinkLabel, ...expertiseLink },
expertiseLink: { label: expertiseLinkLabel, ...expertiseLink } = {},
...props
}) => (
<Box {...props}>
<Text size="m" fontWeight="bold">
{title}
</Text>
<Text mt="m">{description}</Text>
<Button as="a" mt="l" {...expertiseLink}>
{expertiseLinkLabel}
</Button>
{expertiseLinkLabel && (
<Button as="a" mt="l" {...expertiseLink}>
{expertiseLinkLabel}
</Button>
)}
</Box>
);
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { action } from '@storybook/addon-actions';
import type { Meta, StoryObj } from '@storybook/react';

import { Autocomplete } from './Autocomplete';
Expand All @@ -9,7 +8,7 @@ const meta: Meta<typeof Autocomplete> = {
placeholder: 'Rechercher par nom d’article ou d’auteur',
searchLink: {
label: 'Voir tous les résultats',
onClick: action('search'),
href: '#',
},
},
parameters: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
filter: drop-shadow(0 4px 14px rgb(0 0 0 / 25%));

&__item {
position: relative;
display: block;

&--is-highlighted {
Expand Down

0 comments on commit 43851a3

Please sign in to comment.