1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-25 12:56:41 +07:00

#23 added superpowers ui tab

This commit is contained in:
Fedor Katurov 2021-03-19 17:00:26 +07:00
parent c939dcbce8
commit b1f019ebae
15 changed files with 162 additions and 42 deletions

View file

@ -0,0 +1,16 @@
import React, { FC, MouseEventHandler } from 'react';
import classNames from 'classnames';
import styles from './styles.module.scss';
interface IProps {
active?: boolean;
onClick?: MouseEventHandler<any>;
}
const Tab: FC<IProps> = ({ active, onClick, children }) => (
<div className={classNames(styles.tab, { [styles.active]: active })} onClick={onClick}>
{children}
</div>
);
export { Tab };

View file

@ -0,0 +1,20 @@
@import "src/styles/variables";
.tab {
@include outer_shadow();
padding: $gap;
margin-right: $gap;
border-radius: $radius $radius 0 0;
font: $font_14_semibold;
text-transform: uppercase;
cursor: pointer;
background-color: $content_bg;
color: white;
text-decoration: none;
border: none;
&.active {
background: lighten($content_bg, 4%);
}
}

View file

@ -0,0 +1,12 @@
import React, { FC, useCallback } from 'react';
import styles from './styles.module.scss';
import classNames from 'classnames';
import { IAuthState } from '~/redux/auth/types';
interface IProps {}
const Tabs: FC<IProps> = ({ children }) => {
return <div className={styles.wrap}>{children}</div>;
};
export { Tabs };

View file

@ -0,0 +1,9 @@
@import "src/styles/variables";
.wrap {
display: flex;
align-items: flex-start;
justify-content: flex-start;
margin: $gap * 2 0 0 0;
padding: 0 $gap;
}