diff --git a/config/tailwind/buttons.js b/config/tailwind/buttons.js index a88a16c..b72637a 100644 --- a/config/tailwind/buttons.js +++ b/config/tailwind/buttons.js @@ -23,17 +23,17 @@ module.exports = plugin(({ addComponents }) => { // Variants '.btn': { ...base, - '@apply bg-blue-500 text-white enabled:hover:bg-blue-600 enabled:active:bg-blue-700 aria-expanded:bg-blue-700': + '@apply bg-blue-500 text-white hover:bg-blue-600 active:bg-blue-700 aria-expanded:bg-blue-700': {}, }, '.btn-outline': { ...base, - '@apply bg-transparent text-gray-600 border border-gray-600 enabled:hover:bg-black/5 enabled:active:bg-black/10 aria-expanded:bg-black/10': + '@apply bg-transparent text-gray-600 border border-gray-600 hover:bg-black/5 active:bg-black/10 aria-expanded:bg-black/10': {}, }, '.btn-subtle': { ...base, - '@apply bg-transparent text-gray-600 enabled:hover:bg-black/5 enabled:active:bg-black/10 aria-expanded:bg-black/10 dark:text-gray-300 dark:active:text-white dark:enabled:active:bg-black/30 dark:enabled:hover:bg-black/20 dark:aria-expanded:bg-black/30 dark:aria-expanded:text-white': + '@apply bg-transparent text-gray-600 hover:bg-black/5 active:bg-black/10 aria-expanded:bg-black/10 dark:text-gray-300 dark:active:text-white dark:active:bg-black/30 dark:hover:bg-black/20 dark:aria-expanded:bg-black/30 dark:aria-expanded:text-white': {}, }, diff --git a/src/app.tsx b/src/app.tsx index bfb0ddb..7f318df 100644 --- a/src/app.tsx +++ b/src/app.tsx @@ -148,6 +148,7 @@ export function App(props: AppProps) {
diff --git a/src/features/utility-bar/DirectLink.tsx b/src/features/utility-bar/DirectLink.tsx new file mode 100644 index 0000000..8b8391c --- /dev/null +++ b/src/features/utility-bar/DirectLink.tsx @@ -0,0 +1,28 @@ +import { Link1Icon } from '@radix-ui/react-icons' + +interface DirectLinkProps { + url?: string +} + +export function DirectLink({ + url, +}: DirectLinkProps) { + if (!url) { + return null + } + + // TODO eventually refactor to use a button component + return ( + + + + ) +} + + diff --git a/src/features/utility-bar/UtilityBar.tsx b/src/features/utility-bar/UtilityBar.tsx index 3d68690..d1efcc3 100644 --- a/src/features/utility-bar/UtilityBar.tsx +++ b/src/features/utility-bar/UtilityBar.tsx @@ -5,10 +5,12 @@ import ToggleFullscreen from './ToggleFullscreen' import ToggleTheme from './ToggleTheme' import ToggleViewportDropdown from './ToggleViewportDropdown' import ToggleSettingsDialog from './ToggleSettingsDialog' +import { DirectLink } from './DirectLink' interface UtilityBarProps { showSettings: boolean isDoc: boolean + partUrl?: string|null } export default function (props: UtilityBarProps) { @@ -36,6 +38,9 @@ export default function (props: UtilityBarProps) { {/* Settings Control */} {props.showSettings && } + {/* Direct Link */} + {props.partUrl && } + {/* Fullscreen control */}