Skip to content

Commit

Permalink
feat: typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
ob6160 committed Jun 27, 2021
1 parent d668669 commit 6444f07
Show file tree
Hide file tree
Showing 21 changed files with 6 additions and 6 deletions.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Drawer/Drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import Portal from '../Portal';

const MENU_HEIGHT = 60; // px

const Drawer = ({ visible, animateFrom, ...props }) => {
const Drawer = ({ visible, animateFrom = 'left', ...props }) => {
const animateTo = animateFrom === 'right' ? 'left' : 'right';

const variants = {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Header/MainMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const MainMenu = ({
width="100%"
>
<Box as="li" ml={[0, 4]}>
<StyledNavLink to="/" onClick={onMenuItemClick} exact>
<StyledNavLink href="/" onClick={onMenuItemClick} exact>
Find a Toilet
</StyledNavLink>
</Box>
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions src/components/Sidebar.js → src/components/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ import {
} from '@fortawesome/free-solid-svg-icons';
import { NavLink } from 'next/link';

import { Media } from '../components/Media';
import { Media } from './Media';
import VisuallyHidden from './VisuallyHidden';
import Box from './Box';
import Text from './Text';
import Icon from './Icon';
import LocationSearch from './LocationSearch';
import Filters from './Filters';
import Button from '../components/Button';
import Drawer from '../components/Drawer';
import Button from './Button';
import Drawer from './Drawer';
import { useMapState } from './MapState';

const Arrow = styled((props) => <Icon icon={faAngleRight} {...props} />, {
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export default {
getSettings(namespace) {
return JSON.parse(localStorage.getItem(namespace) || '{}');
},
getSetting(namespace, key, defaultVal) {
getSetting(namespace, key, defaultVal = '') {
const val = this.getSettings(namespace)[key];

return val === undefined ? defaultVal : val;
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 6444f07

Please sign in to comment.