From 76fa1733fff4e3aa4356df08272e4811db996dab Mon Sep 17 00:00:00 2001 From: Evan You Date: Mon, 14 Jun 2021 10:50:22 -0400 Subject: [PATCH] fix: fix vue code block type indication --- src/client/theme-default/styles/code.css | 60 +++++++++++++----------- 1 file changed, 32 insertions(+), 28 deletions(-) diff --git a/src/client/theme-default/styles/code.css b/src/client/theme-default/styles/code.css index 67c4b5c6..1e821af9 100644 --- a/src/client/theme-default/styles/code.css +++ b/src/client/theme-default/styles/code.css @@ -116,7 +116,7 @@ div[class*='language-'].line-numbers-mode { /* Language marker */ -[class*='language-']:before { +div[class*='language-']:before { position: absolute; top: 0.6em; right: 1em; @@ -125,93 +125,97 @@ div[class*='language-'].line-numbers-mode { color: #888; } -[class~='language-html']:before, -[class~='language-markup']:before { +div[class~='language-html']:before, +div[class~='language-markup']:before { content: 'html'; } -[class~='language-md']:before, -[class~='language-markdown']:before { +div[class~='language-md']:before, +div[class~='language-markdown']:before { content: 'md'; } -[class~='language-css']:before { +div[class~='language-css']:before { content: 'css'; } -[class~='language-sass']:before { +div[class~='language-sass']:before { content: 'sass'; } -[class~='language-scss']:before { +div[class~='language-scss']:before { content: 'scss'; } -[class~='language-less']:before { +div[class~='language-less']:before { content: 'less'; } -[class~='language-stylus']:before { +div[class~='language-stylus']:before { content: 'styl'; } -[class~='language-js']:before, -[class~='language-javascript']:before { +div[class~='language-js']:before, +div[class~='language-javascript']:before { content: 'js'; } -[class~='language-ts']:before, -[class~='language-typescript']:before { +div[class~='language-ts']:before, +div[class~='language-typescript']:before { content: 'ts'; } -[class~='language-json']:before { +div[class~='language-json']:before { content: 'json'; } -[class~='language-rb']:before, -[class~='language-ruby']:before { +div[class~='language-rb']:before, +div[class~='language-ruby']:before { content: 'rb'; } -[class~='language-py']:before, -[class~='language-python']:before { +div[class~='language-py']:before, +div[class~='language-python']:before { content: 'py'; } -[class~='language-sh']:before, -[class~='language-bash']:before { +div[class~='language-sh']:before, +div[class~='language-bash']:before { content: 'sh'; } -[class~='language-php']:before { +div[class~='language-php']:before { content: 'php'; } -[class~='language-go']:before { +div[class~='language-go']:before { content: 'go'; } -[class~='language-rust']:before { +div[class~='language-rust']:before { content: 'rust'; } -[class~='language-java']:before { +div[class~='language-java']:before { content: 'java'; } -[class~='language-c']:before { +div[class~='language-c']:before { content: 'c'; } -[class~='language-yaml']:before { +div[class~='language-yaml']:before { content: 'yaml'; } -[class~='language-dockerfile']:before { +div[class~='language-dockerfile']:before { content: 'dockerfile'; } +div[class~='language-vue']:before { + content: 'vue'; +} + /** * prism.js tomorrow night eighties for JavaScript, CoffeeScript, CSS and HTML. * Based on https://github.com/chriskempson/tomorrow-theme