Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
exo/libs/shared/ui/src/lib/skipToMainContentLink/index.stories.tsx
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork and 2 spoons outside of the repository.
22 lines (21 sloc)
571 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react' | |
import SkipToMainContentLink from './index'; | |
export default { | |
title: 'Skip To Main Content Link', | |
component: SkipToMainContentLink | |
} | |
export const Basic = () => ( | |
<> | |
<SkipToMainContentLink skipTo="#cta" /> | |
<main className="focus:outline-2 space-y-10"> | |
<div>This is main content</div> | |
<button | |
onClick={() => alert('clicked')} | |
id="cta" | |
className="px-4 py-2 bg-green-600 rounded-sm text-white focus:border-red-500 focus:outline-red-500" | |
> | |
Test | |
</button> | |
</main> | |
</> | |
); |