Clean up code
This commit is contained in:
parent
fae3043c3b
commit
322d7725f2
|
|
@ -3,7 +3,7 @@
|
|||
:data-scrollto="chapter.id"
|
||||
class="chapter">
|
||||
<div
|
||||
:class="{'hideable-element--hidden': titleGreyedOut}"
|
||||
:class="{'hideable-element--greyed-out': titleGreyedOut}"
|
||||
class="hideable-element"
|
||||
v-if="!titleHidden">
|
||||
<h3
|
||||
|
|
@ -26,7 +26,7 @@
|
|||
@bookmark="bookmark(!chapter.bookmark)"
|
||||
/>
|
||||
<div
|
||||
:class="{'hideable-element--hidden': descriptionGreyedOut}"
|
||||
:class="{'hideable-element--greyed-out': descriptionGreyedOut}"
|
||||
class="chapter__intro intro hideable-element"
|
||||
v-if="!descriptionHidden"
|
||||
>
|
||||
|
|
@ -97,10 +97,9 @@ export default {
|
|||
}));
|
||||
},
|
||||
note() {
|
||||
if (!(this.chapter && this.chapter.bookmark)) {
|
||||
return;
|
||||
if (this.chapter && this.chapter.bookmark) {
|
||||
return this.chapter.bookmark.note;
|
||||
}
|
||||
return this.chapter.bookmark.note;
|
||||
},
|
||||
titleGreyedOut() {
|
||||
return this.textHidden(CHAPTER_TITLE_TYPE) && this.editModule;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<div
|
||||
:class="{'hideable-element--hidden': hidden}"
|
||||
:class="{'hideable-element--greyed-out': hidden}"
|
||||
class="content-block__container hideable-element">
|
||||
<div
|
||||
:class="specialClass"
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<li
|
||||
:class="{'hideable-element--hidden': hidden}"
|
||||
:class="{'hideable-element--greyed-out': hidden}"
|
||||
class="objective hideable-element"
|
||||
v-if="editModule || !hidden">
|
||||
<visibility-action
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
.hideable-element {
|
||||
position: relative;
|
||||
|
||||
&--hidden {
|
||||
&--greyed-out {
|
||||
&::before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
|
|
|
|||
Loading…
Reference in New Issue