Rewrite styles to scss and use i respective components
This commit is contained in:
18
src/components/Link/Link.tsx
Normal file
18
src/components/Link/Link.tsx
Normal file
@@ -0,0 +1,18 @@
|
||||
import React from 'react';
|
||||
import { Link as RLink } from 'react-router-dom';
|
||||
import './link.scss';
|
||||
type LinkProps = {
|
||||
pageName: string;
|
||||
style?: React.CSSProperties;
|
||||
className?: string;
|
||||
};
|
||||
|
||||
function Link({ pageName, children, className, style = {} }: React.PropsWithChildren<LinkProps>) {
|
||||
return (
|
||||
<RLink to={`/techradar/${pageName}.html`} style={style} {...{ className }}>
|
||||
{children}
|
||||
</RLink>
|
||||
);
|
||||
}
|
||||
|
||||
export default Link;
|
||||
8
src/components/Link/link.scss
Normal file
8
src/components/Link/link.scss
Normal file
@@ -0,0 +1,8 @@
|
||||
.link {
|
||||
color: var(--color-white);
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
&:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user