diff --git a/README.md b/README.md
index c1ee69f..c33261c 100644
--- a/README.md
+++ b/README.md
@@ -275,6 +275,10 @@ If you use webmention.io you can also enable pingback with `pingback: true`
### Disabling comments per-page basis
Add `disableComments: true` to post front matter.
+## Custom shortcodes
+### Video (for local videofiles)
+Example: `{{< video src="/media/movie.mp4" type="video/mp4" preload="auto" caption="Some caption" alt="Some alt" >}}`
+
## Contributing
If you find a bug or have an idea for a feature, feel free to write an [issue](https://github.com/mitrichius/hugo-theme-anubis/issues) or make a PR.
diff --git a/assets/css/main.css b/assets/css/main.css
index c098ef3..01af0ab 100644
--- a/assets/css/main.css
+++ b/assets/css/main.css
@@ -537,6 +537,13 @@ article figcaption {
margin-bottom: 2em;
}
+article video {
+ max-width: 100%;
+ display: block;
+ height: auto;
+ margin: 0 auto .5em;
+}
+
code.has-jax {
-webkit-font-smoothing: antialiased;
background: inherit !important;
diff --git a/i18n/en.yaml b/i18n/en.yaml
index fc85605..922d96b 100644
--- a/i18n/en.yaml
+++ b/i18n/en.yaml
@@ -59,4 +59,7 @@ toNewPost:
other: "to new post"
toOldPost:
- other: "to old post"
\ No newline at end of file
+ other: "to old post"
+
+videoIsNotSupported:
+ other: "Your browser does not support video"
\ No newline at end of file
diff --git a/i18n/ru.yaml b/i18n/ru.yaml
index e0c70c9..19c85d5 100644
--- a/i18n/ru.yaml
+++ b/i18n/ru.yaml
@@ -56,4 +56,7 @@ toNewPost:
other: "к новой записи"
toOldPost:
- other: "к старой записи"
\ No newline at end of file
+ other: "к старой записи"
+
+videoIsNotSupported:
+ other: "Ваш браузер не поддерживает видео"
\ No newline at end of file
diff --git a/layouts/shortcodes/video.html b/layouts/shortcodes/video.html
new file mode 100644
index 0000000..c950670
--- /dev/null
+++ b/layouts/shortcodes/video.html
@@ -0,0 +1,20 @@
+
+{{ if .Get "caption" }}
+
+ {{ .Get "caption" | markdownify }}
+
+{{ end }}
+