Skip to content

Commit

Permalink
Update Sidebar.tsx
Browse files Browse the repository at this point in the history
fixed undefined name to id
  • Loading branch information
parthikjadav authored Nov 26, 2024
1 parent afd5e8c commit 422b50d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion library/src/containers/Sidebar/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,10 @@ export const Sidebar: React.FunctionComponent = () => {
<ul className="text-sm mt-2">
{messages.map((message, index) => (
<li key={`menu-message-list-${message.name() ?? index}`}>
// fixed the href message.name() to message.id() to fix undifined name
<a
className="flex break-words no-underline text-gray-700 mt-2 hover:text-gray-900"
href={`#message-${message.name()}`}
href={`#message-${message.id()}`}
onClick={() => setShowSidebar(false)}
>
<div className="break-all inline-block">{message.id()}</div>
Expand Down

0 comments on commit 422b50d

Please sign in to comment.