Ghost/ghost/admin/app/styles/layouts/content.css

224 lines
3.9 KiB
CSS
Raw Normal View History

2015-05-14 16:45:37 +03:00
/* Content /ghost/
/* Header
2015-05-14 16:45:37 +03:00
/* ---------------------------------------------------------- */
.gh-content-view-container .view-header {
border-bottom: none;
2015-05-14 16:45:37 +03:00
}
.basic-filter {
margin-top: 0.5em;
border-bottom: #dfe1e3 1px solid;
2015-05-14 16:45:37 +03:00
}
.basic-filter ul {
display: flex;
flex-direction: row;
margin-bottom: 0;
padding-left: 0.7em;
2015-05-14 16:45:37 +03:00
}
.basic-filter li {
list-style: none;
display: inline-block;
margin-bottom: 0;
padding: 0 0.5em 10px 0.5em;
}
.basic-filter li.active {
border-bottom: #dfe1e3 3px solid ;
}
.basic-filter li a {
color: var(--midgrey);
}
.basic-filter li a.active {
font-weight: bold;
color: var(--darkgrey);
2015-05-14 16:45:37 +03:00
}
@media (max-width: 500px) {
.basic-filter ul {
padding-left: 8px !important;
}
}
@media (max-width: 800px) {
.basic-filter ul {
padding-left: 15px;
}
}
2015-05-14 16:45:37 +03:00
/* Content List
2015-05-14 16:45:37 +03:00
/* ---------------------------------------------------------- */
.content-list {
position: relative;
overflow-y: auto;
2015-05-14 16:45:37 +03:00
}
.content-list ol {
margin: 20px 4vw;
padding: 0;
list-style: none;
2015-05-14 16:45:37 +03:00
}
.gh-posts-list-item {
position: relative;
margin: 0;
padding: 0;
border-bottom: #dfe1e3 1px solid;
2015-05-14 16:45:37 +03:00
}
.gh-posts-list-item a {
display: block;
padding: 19px 25px 22px 20px;
color: rgba(0, 0, 0, 0.5);
}
.gh-posts-list-item a:hover {
text-decoration: none;
}
.gh-posts-list-item .entry-title {
margin: 0 0 0.2em 0;
2016-11-14 12:55:08 +03:00
font-size: 1.5rem;
line-height: 1.3em;
2015-05-14 16:45:37 +03:00
font-weight: normal;
}
.gh-posts-list-item p {
margin: 0 0 1em 0;
font-size: 0.8em;
line-height: 1.5em;
}
.gh-posts-list-item .entry-meta {
2016-11-14 12:55:08 +03:00
position: relative;
margin-top: 7px;
2015-05-14 16:45:37 +03:00
line-height: 18px;
}
.gh-posts-list-item .avatar {
2015-05-16 14:43:12 +03:00
position: relative;
2015-05-14 16:45:37 +03:00
float: left;
2016-11-14 12:55:08 +03:00
margin: 1px 10px 0px 0;
2015-05-14 16:45:37 +03:00
width: 18px;
height: 18px;
background-position: center center;
2015-05-16 14:43:12 +03:00
background-size: cover;
border-radius: 18px;
2015-05-14 16:45:37 +03:00
}
.gh-posts-list-item .avatar img {
2015-05-14 16:45:37 +03:00
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
opacity: 0;
}
.gh-posts-list-item .status,
.gh-posts-list-item .author {
2015-05-14 16:45:37 +03:00
font-size: 1.3rem;
font-weight: 300;
transition: opacity 0.15s linear;
}
.gh-posts-list-item .avatar:hover + .author + .status {
2015-05-14 16:45:37 +03:00
opacity: 0;
}
.gh-posts-list-item .avatar:hover + .author {
2015-05-14 16:45:37 +03:00
opacity: 1;
}
.gh-posts-list-item .author {
2015-05-14 16:45:37 +03:00
position: absolute;
2016-11-14 12:55:08 +03:00
bottom: 0;
left: 28px;
2015-05-14 16:45:37 +03:00
opacity: 0;
}
.gh-posts-list-item .status .draft {
2015-05-14 16:45:37 +03:00
color: var(--red);
}
.gh-posts-list-item .status .scheduled {
Scheduler UI refs TryGhost/Ghost#6413 and TryGhost/Ghost#6870 needs TryGhost/Ghost#6861 - **Post Settings Menu (PSM)**:'Publish Date' input accepts a date from now, min. 2 minutes to allow scheduler processing on the server. Also, there will always be some delay between typing the date and clicking on the 'Schedule Post' button. If the user types a future date for an already published post, the date will be reseted and he sees the message, that the post needs to be unpublished first. Once, the date is accepted, the label will change to 'Scheduled Date'. - adds a CP 'timeScheduled' to post model, which will return `true` if the publish time is currently in the future. - **Changes to the button flow in editor**: - if the the CP `timeScheduled` returns true, a different drop-down-menu will be shown: 'Schedule Post' replaces 'Publish Now' and 'Unschedule' replaces 'Unpublish'. - Covering the _edge cases_, especially when a scheduled post is about to be published, while the user is in the editor. - First, a new CP `scheduleCountdown` will return the remaining time, when the estimated publish time is 15 minutes from now. A notification with this live-ticker is shown next to the save button. Once, we reach a 2 minutes limit, another CP `statusFreeze` will return true and causes the save button to only show `Unschedule` in a red state, until we reach the publish time - Once the publish time is reached, a CP `scheduledWillPublish` causes the buttons and the existing code to pretend we're already dealing with a publish post. At the moment, there's no way to make a background-fetch of the now serverside-scheduled post model from the server, so Ember doesn't know about the changed state at that time. - Changes in the editor, which are done during this 'status freeze'-process will be saved back correctly, once the user hits 'Update Post' after the buttons changed back. A click on 'Unpublish' will change the status back to a draft. - The user will get a regular 'toaster' notification that the post has been published. - adds CP `isScheduled` for scheduled posts - adds CP `offset` to component `gh-posts-list-item` and helper `gh-format-time-scheduled` to show schedule date in content overview. - sets timeout in `gh-spin-button` to 10ms for `Ember.testing` - changes error message in `gh-editor-base-controller` to be in one line, seperated with a `:` TODOs: - [x] new sort order for posts (1. scheduled, 2. draft, 3. published) (refs TryGhost/Ghost#6932) - [ ] Move posts sorting from posts controller to model and refactor to use `Ember.comparable` mixin - [x] Flows for draft -> scheduled -> published like described in TryGhost/Ghost#6870 incl. edge cases and button behaviour - [x] Tests - [x] new PSM behaviour for time/date in future - [x] display publishedAt date with timezone offset on posts overview
2016-02-02 10:04:40 +03:00
color: var(--green);
2015-05-14 16:45:37 +03:00
}
@media (max-width: 400px) {
.gh-posts-list-item a {
2015-05-14 16:45:37 +03:00
padding: 15px;
}
}
@media (max-width: 900px) {
.gh-posts-list-item a {
2015-05-14 16:45:37 +03:00
padding-right: 40px;
}
}
@media (min-width: 901px) {
.gh-posts-list-item a:after {
2015-05-14 16:45:37 +03:00
display: none;
}
}
@media (min-width: 901px) {
.content-list .active a {
2016-11-14 12:55:08 +03:00
box-shadow: var(--blue) 3px 0 0 inset;
2015-05-14 16:45:37 +03:00
}
}
/* Empty State
/* ---------------------------------------------------------- */
.no-posts-box {
position: relative;
2015-05-16 14:43:12 +03:00
z-index: 600;
display: flex;
justify-content: center;
align-items: center;
2015-05-16 00:28:30 +03:00
margin: 0 auto;
padding: 0;
2015-05-16 14:43:12 +03:00
height: 90%;
2015-05-14 16:45:37 +03:00
}
.no-posts-box .no-posts {
display: flex;
flex-direction: column;
align-items: center;
2015-05-14 16:45:37 +03:00
}
.no-posts-box .no-posts h3 {
margin-bottom: 20px;
color: var(--midgrey);
2015-05-14 16:45:37 +03:00
font-size: 2em;
2015-05-16 14:43:12 +03:00
font-weight: 200;
2015-05-14 16:45:37 +03:00
}
/* Keyboard Focus Effects
/* ---------------------------------------------------------- */
/* This has to be a pseudo element to sit over the top of everything else in the content list */
.tag-list-content.keyboard-focused:before,
.tag-settings.keyboard-focused:before {
2015-05-16 00:28:30 +03:00
content: "";
2015-05-14 16:45:37 +03:00
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 500;
animation: keyboard-focus-style-fade-out 1.5s 1 forwards;
2015-05-16 14:43:12 +03:00
pointer-events: none;
2015-05-14 16:45:37 +03:00
}