<div class="row header">
<div class="col-md-2 col-sm-3 col-xs-3 top-left-block" [ngClass]="{ 'border-bottom': isMenuDisplayed === false }">
- <div class="hamburger-block">
- <span (click)="toggleMenu()" class="glyphicon glyphicon-menu-hamburger"></span>
+ <div class="hamburger-block" (click)="toggleMenu()">
+ <span class="glyphicon glyphicon-menu-hamburger"></span>
</div>
- <div id="peertube-title" class="title-menu-left-block header">
+ <div id="peertube-title">
<a [routerLink]="['/videos/list']" title="Homepage"></a>
</div>
</div>
margin-bottom: 0;
display: flex;
position: fixed;
+ padding: 0;
&.border-bottom {
border-bottom: 1px solid $header-border-color;
}
.hamburger-block {
- margin-right: 20px;
+ margin-right: 15px;
margin-left: 15px;
.glyphicon {
background: url(/client/assets/logo.png) no-repeat;
background-size: contain;
background-position: center;
- width: 180px;
height: 100%;
margin: auto;
+ width: 135px;
&:hover {
color: inherit !important;
}
}
}
+
+ @media screen and (max-width: 500px) {
+ #peertube-title {
+ display: none;
+ }
+
+ .hamburger-block {
+ width: 100%;
+ text-align: center;
+ }
+ }
+
+ @media screen and (min-width: 500px) and (max-width: 600px) {
+ #peertube-title a {
+ width: 80px;
+ }
+ }
+
+ @media screen and (min-width: 600px) and (max-width: 700px) {
+ #peertube-title a {
+ width: 100px;
+ }
+ }
+
+ @media screen and (min-width: 1000px) {
+ #peertube-title a {
+ width: 120px;
+ }
+ }
+
+ @media screen and (min-width: 1000px) {
+ #peertube-title a {
+ width: 120px;
+ }
+ }
+
+ @media screen and (min-width: 1200px) {
+ padding-left: 15px;
+
+ .hamburger-block {
+ margin-right: 15px;
+ }
+
+ #peertube-title a {
+ width: 135px;
+ }
+ }
+
+ @media screen and (min-width: 1600px) {
+ .hamburger-block {
+ margin-right: 20px;
+ }
+
+ #peertube-title a {
+ width: 180px;
+ }
+ }
}
my-search {
this.videoService.loadVideoCategories();
this.videoService.loadVideoLicences();
this.videoService.loadVideoLanguages();
+
+ // Do not display menu on small screens
+ if (window.innerWidth < 600) {
+ this.isMenuDisplayed = false;
+ }
}
isInAdmin() {
+++ /dev/null
-menu {
- background-color: $black-background;
- padding: 25px;
- margin: 0;
- height: 100%;
-
- .panel-block {
- margin-bottom: 15px;
- }
-
- .block-title {
- text-transform: uppercase;
- font-weight: bold;
- color: $menu-color-block;
- margin-bottom: 10px;
- }
-
- a {
- display: block;
- margin-left: 5px;
- height: 30px;
- color: $menu-color-link;
- cursor: pointer;
- transition: color 0.3s;
-
- &:hover, &:focus {
- text-decoration: none !important;
- outline: none !important;
- }
-
- .glyphicon {
- margin-right: 15px;
- }
-
- &:hover, &.active {
- color: #fff;
- }
- }
-}
@Component({
selector: 'my-menu-admin',
templateUrl: './menu-admin.component.html',
- styleUrls: [ './menu-admin.component.scss' ]
+ styleUrls: [ './menu.component.scss' ]
})
export class MenuAdminComponent { }
--- /dev/null
+menu {
+ background-color: $black-background;
+ padding: 15px;
+ margin: 0;
+ height: 100%;
+ white-space: nowrap;
+ text-overflow: ellipsis;
+ overflow: hidden;
+
+ @media screen and (max-width: 550px) {
+ font-size: 90%;
+ }
+
+ @media screen and (min-width: 1200px) {
+ padding: 25px;
+ }
+
+ .panel-block {
+ margin-bottom: 15px;
+ }
+
+ .block-title {
+ text-transform: uppercase;
+ font-weight: bold;
+ color: $menu-color-block;
+ margin-bottom: 10px;
+ }
+
+ a {
+ display: block;
+ margin-left: 5px;
+ height: 30px;
+ color: $menu-color-link;
+ cursor: pointer;
+ transition: color 0.3s;
+
+ &:hover, &:focus {
+ text-decoration: none !important;
+ outline: none !important;
+ }
+
+ .glyphicon {
+ margin-right: 15px;
+ }
+
+ &:hover, &.active {
+ color: #fff;
+ }
+ }
+}
@Component({
selector: 'my-menu',
templateUrl: './menu.component.html',
- styleUrls: [ './menu-admin.component.scss' ]
+ styleUrls: [ './menu.component.scss' ]
})
export class MenuComponent implements OnInit {
isLoggedIn: boolean;
<div *ngIf="video !== null" id="video-info">
<div class="row video-name-views">
- <div class="col-md-8 video-name">
+ <div class="col-xs-8 col-md-8 video-name">
{{ video.name }}
</div>
- <div class="col-md-4 pull-right video-views">
+ <div class="col-xs-4 col-md-4 pull-right video-views">
{{ video.views}} views
</div>
</div>
<div class="row video-small-blocks">
- <div class="col-md-3 video-small-block video-small-block-author">
+ <div class="col-xs-5 col-xs-3 col-md-3 video-small-block video-small-block-author">
<a title="Access to all videos of this user" [routerLink]="['/videos/list', { field: 'author', search: video.author }]">
{{ video.by }}
</a>
</div>
- <div class="col-md-3 video-small-block video-small-block-share">
+ <div class="col-xs-2 col-md-3 video-small-block video-small-block-share">
<a class="option" (click)="showShareModal()" title="Share the video">
<span class="glyphicon glyphicon-share"></span>
<span class="video-small-block-text">Share</span>
</a>
</div>
- <div class="col-md-3 video-small-block video-small-block-more">
+ <div class="col-xs-2 col-md-3 video-small-block video-small-block-more">
<div class="video-small-block-dropdown" dropdown dropup="true" placement="right">
<a class="option" title="Access to more options" dropdownToggle>
<span class="glyphicon glyphicon-option-horizontal"></span>
</div>
</div>
- <div class="col-md-3 video-small-block video-small-block-rating">
+ <div class="col-xs-3 col-md-3 video-small-block video-small-block-rating">
<div class="video-small-block-like">
<span
class="glyphicon glyphicon-thumbs-up" title="Like this video"
</div>
<div class="row video-details">
- <div class="video-details-date-description col-md-9">
+ <div class="video-details-date-description col-xs-8 col-md-9">
<div class="video-details-date">
Published on {{ video.createdAt | date:'short' }}
</div>
</div>
</div>
- <div class="video-details-attributes col-md-3">
+ <div class="video-details-attributes col-xs-4 col-md-3">
<div class="video-details-attribute">
<span class="video-details-attribute-label">
Category:
// Keep a symmetry with the video name
padding-right: $video-watch-info-padding-left
}
+
}
.video-small-blocks {
a {
cursor: pointer;
transition: color 0.3s;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
&, &:hover {
color: inherit;
}
}
}
+
+ @media screen and (max-width: 400px) {
+ .video-name-views {
+ font-size: 16px !important;
+ }
+ }
+
+ @media screen and (max-width: 800px) {
+ .video-name-views {
+ .video-name {
+ padding-left: 5px;
+ padding-right: 0px;
+ }
+
+ .video-views {
+ padding-left: 0px;
+ padding-right: 5px;
+ }
+ }
+
+ .video-small-blocks {
+ a, .video-small-block-text {
+ font-size: 13px !important;
+ }
+
+ .glyphicon {
+ font-size: 18px !important;
+ }
+
+ .video-small-block-author {
+ padding-left: 10px;
+ }
+ }
+
+ .video-details {
+ .video-details-date-description {
+ padding-left: 10px;
+ font-size: 13px !important;
+ }
+
+ .video-details-attributes {
+ font-size: 11px !important;
+
+ .video-details-attribute-label {
+ width: 50px;
+ }
+ }
+ }
+ }
}
.content-padding {
padding: 15px 30px;
+ @media screen and (max-width: 800px) {
+ padding: 15px 10px;
+ }
+
@media screen and (min-width: 1400px) {
padding: 15px 40px;
}