Add subtitle block, update font sizes
This commit is contained in:
parent
d2dabd6952
commit
03d8ed6712
|
|
@ -39,6 +39,7 @@
|
|||
import DocumentBlock from '@/components/content-blocks/DocumentBlock';
|
||||
import InfogramBlock from '@/components/content-blocks/InfogramBlock';
|
||||
import GeniallyBlock from '@/components/content-blocks/GeniallyBlock';
|
||||
import SubtitleBlock from '@/components/content-blocks/SubtitleBlock';
|
||||
import Assignment from '@/components/content-blocks/assignment/Assignment';
|
||||
import Solution from '@/components/content-blocks/Solution';
|
||||
import AddContentBlockButton from '@/components/AddContentBlockButton';
|
||||
|
|
@ -64,6 +65,7 @@
|
|||
'document_block': DocumentBlock,
|
||||
'infogram_block': InfogramBlock,
|
||||
'genially_block': GeniallyBlock,
|
||||
'subtitle': SubtitleBlock,
|
||||
Solution,
|
||||
Assignment,
|
||||
Task,
|
||||
|
|
@ -150,7 +152,11 @@
|
|||
&--task {
|
||||
.content-block__title {
|
||||
color: $color-brand;
|
||||
margin-top: $default-padding;
|
||||
@include light-border(bottom);
|
||||
@include desktop {
|
||||
margin-top: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
<template>
|
||||
<h5 class="subtitle" v-html="value.text"></h5>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: ['value']
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.subtitle {
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
</style>
|
||||
|
|
@ -41,12 +41,12 @@ h1 {
|
|||
}
|
||||
|
||||
h2 {
|
||||
font-size: 2.625rem; // 42px
|
||||
font-size: 2.75rem; // 44px
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 2.13rem; // 34px
|
||||
font-size: 2.125rem; // 34px
|
||||
line-height: 2.63rem; // 42px
|
||||
margin-bottom: 52px;
|
||||
}
|
||||
|
|
@ -56,6 +56,11 @@ h4 {
|
|||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
h5 {
|
||||
font-size: 1.125rem; // 18px
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
input, textarea, select, button {
|
||||
font-family: $sans-serif-font-family;
|
||||
font-weight: $font-weight-regular;
|
||||
|
|
|
|||
|
|
@ -73,6 +73,10 @@ class InfogramBlock(blocks.StructBlock):
|
|||
class GeniallyBlock(blocks.StructBlock):
|
||||
id = blocks.TextBlock()
|
||||
|
||||
|
||||
class SubtitleBlock(blocks.StructBlock):
|
||||
text = blocks.TextBlock()
|
||||
|
||||
# 'text_block' 'task' 'basic_knowledge' 'student_entry' 'image_block'
|
||||
#
|
||||
# url = blocks.URLBlock()
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ from wagtail.core.fields import StreamField
|
|||
from wagtail.images.blocks import ImageChooserBlock
|
||||
|
||||
from books.blocks import TextBlock, BasicKnowledgeBlock, LinkBlock, VideoBlock, DocumentBlock, \
|
||||
ImageUrlBlock, AssignmentBlock, InfogramBlock, GeniallyBlock
|
||||
ImageUrlBlock, AssignmentBlock, InfogramBlock, GeniallyBlock, SubtitleBlock
|
||||
from core.wagtail_utils import StrictHierarchyPage
|
||||
from users.models import SchoolClass
|
||||
|
||||
|
|
@ -46,6 +46,7 @@ class ContentBlock(StrictHierarchyPage):
|
|||
('document_block', DocumentBlock()),
|
||||
('infogram_block', InfogramBlock()),
|
||||
('genially_block', GeniallyBlock()),
|
||||
('subtitle', SubtitleBlock()),
|
||||
], null=True, blank=True)
|
||||
|
||||
type = models.CharField(
|
||||
|
|
|
|||
Loading…
Reference in New Issue