mirror of
https://github.com/elyby/accounts-frontend.git
synced 2025-01-16 08:33:15 +05:30
#116: improve userbar layout for small screens and long nicknames
This commit is contained in:
parent
e0ab116a9a
commit
446bfbaa29
@ -1,15 +1,14 @@
|
|||||||
.group {
|
|
||||||
position: relative; // это нужно только чтобы postcss не удалял пустой класс и composes мог его схавать
|
|
||||||
}
|
|
||||||
|
|
||||||
.horizontalGroup {
|
.horizontalGroup {
|
||||||
composes: group;
|
display: flex;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item {
|
.item {
|
||||||
|
white-space: nowrap;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
|
||||||
$borderConfig: 1px solid rgba(#fff, 0.15);
|
$borderConfig: 1px solid rgba(#fff, 0.15);
|
||||||
|
|
||||||
float: left;
|
|
||||||
border-left: $borderConfig;
|
border-left: $borderConfig;
|
||||||
|
|
||||||
&:last-child {
|
&:last-child {
|
||||||
|
@ -27,7 +27,7 @@ export default class LoggedInPanel extends Component {
|
|||||||
const { user } = this.props;
|
const { user } = this.props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={buttonGroups.horizontalGroup}>
|
<div className={classNames(buttonGroups.horizontalGroup, styles.loggedInPanel)}>
|
||||||
<Link to="/" className={classNames(buttons.green, buttonGroups.item)}>
|
<Link to="/" className={classNames(buttons.green, buttonGroups.item)}>
|
||||||
<span className={styles.userIcon} />
|
<span className={styles.userIcon} />
|
||||||
<span className={styles.userName}>{user.username}</span>
|
<span className={styles.userName}>{user.username}</span>
|
||||||
|
@ -1,3 +1,6 @@
|
|||||||
|
.loggedInPanel {
|
||||||
|
justify-content: flex-end;
|
||||||
|
}
|
||||||
|
|
||||||
.userIcon {
|
.userIcon {
|
||||||
composes: user from 'components/ui/icons.scss';
|
composes: user from 'components/ui/icons.scss';
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
.userbar {
|
.userbar {
|
||||||
|
text-align: right;
|
||||||
}
|
}
|
||||||
|
@ -36,6 +36,7 @@ $userBarHeight: 50px;
|
|||||||
|
|
||||||
.headerContent {
|
.headerContent {
|
||||||
composes: wrapper;
|
composes: wrapper;
|
||||||
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
@ -65,5 +66,8 @@ $userBarHeight: 50px;
|
|||||||
}
|
}
|
||||||
|
|
||||||
.userbar {
|
.userbar {
|
||||||
float: right;
|
position: absolute;
|
||||||
|
right: 0;
|
||||||
|
left: 115px;
|
||||||
|
top: 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user