diff --git a/Makefile b/Makefile index f0a461d..5da2088 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ help: @perl -nle'print $& if m{^[a-zA-Z_-]+:.*?## .*$$}' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' build: - @docker build -t code.headbright.be/konstantin/iamkonstantin:1.0.16 . + @docker build -t code.headbright.be/konstantin/iamkonstantin:1.0.21 . publish: - @docker push code.headbright.be/konstantin/iamkonstantin:1.0.16 + @docker push code.headbright.be/konstantin/iamkonstantin:1.0.21 diff --git a/blog/migrations/0013_alter_blogpage_body.py b/blog/migrations/0013_alter_blogpage_body.py new file mode 100644 index 0000000..afd1143 --- /dev/null +++ b/blog/migrations/0013_alter_blogpage_body.py @@ -0,0 +1,22 @@ +# Generated by Django 5.0.2 on 2024-03-23 16:56 + +import wagtail.blocks +import wagtail.embeds.blocks +import wagtail.fields +import wagtail.images.blocks +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('blog', '0012_blogindexpage_canonical_url_blogindexpage_og_image_and_more'), + ] + + operations = [ + migrations.AlterField( + model_name='blogpage', + name='body', + field=wagtail.fields.StreamField([('heading_block', wagtail.blocks.StructBlock([('heading_text', wagtail.blocks.CharBlock(form_classname='title', required=True)), ('size', wagtail.blocks.ChoiceBlock(blank=True, choices=[('', 'Select a heading size'), ('h2', 'H2'), ('h3', 'H3'), ('h4', 'H4')], required=False))])), ('paragraph', wagtail.blocks.RichTextBlock(blank=True)), ('code', wagtail.blocks.StructBlock([('language', wagtail.blocks.ChoiceBlock(choices=[('bash', 'Bash/Shell'), ('css', 'CSS'), ('dart', 'Dart'), ('docker', 'Docker'), ('elixir', 'Elixir'), ('go', 'Go'), ('html', 'HTML'), ('javascript', 'Javascript'), ('json', 'JSON'), ('kotlin', 'Kotlin'), ('python', 'Python'), ('rust', 'Rust'), ('swift', 'Swift'), ('toml', 'TOML'), ('yaml', 'YAML')], help_text='Coding language', identifier='language', label='Language')), ('code', wagtail.blocks.TextBlock(identifier='code', label='Code'))], label='Code snippet')), ('image_block', wagtail.blocks.StructBlock([('image', wagtail.images.blocks.ImageChooserBlock(required=True)), ('caption', wagtail.blocks.CharBlock(required=False)), ('attribution', wagtail.blocks.CharBlock(required=False))])), ('embed_block', wagtail.embeds.blocks.EmbedBlock(help_text='Insert a URL to embed. For example, https://www.youtube.com/watch?v=SGJFWirQ3ks', icon='media'))], blank=True, help_text='Write anything'), + ), + ] diff --git a/iamkonstantin_web/settings/base.py b/iamkonstantin_web/settings/base.py index cc564ec..fa6168a 100644 --- a/iamkonstantin_web/settings/base.py +++ b/iamkonstantin_web/settings/base.py @@ -197,6 +197,7 @@ WAGTAIL_CODE_BLOCK_LANGUAGES = ( ('json', 'JSON'), ('kotlin', 'Kotlin'), ('python', 'Python'), + ('rust', 'Rust'), ('swift', 'Swift'), ('toml', 'TOML'), ('yaml', 'YAML'), diff --git a/theme/static_src/src/styles.css b/theme/static_src/src/styles.css index e214abe..f01c4ef 100644 --- a/theme/static_src/src/styles.css +++ b/theme/static_src/src/styles.css @@ -80,6 +80,7 @@ } code[class*="language-"], pre[class*="language-"] { + white-space: pre-wrap !important; word-break: break-word !important; } }