This commit is contained in:
taskylizard 2023-11-05 22:23:56 +05:30
parent 4ab375107c
commit e6aa2f2f27
No known key found for this signature in database
GPG Key ID: 5CABA3D642DDC497
2 changed files with 3 additions and 3 deletions

View File

@ -6,11 +6,11 @@ export function copyableCodePlugin(md: MarkdownRenderer) {
// Save the original rule for backticks
const defaultRender =
md.renderer.rules.code_inline ||
function(tokens, idx, options, env, self) {
function (tokens, idx, options, env, self) {
return self.renderToken(tokens, idx, options);
};
md.renderer.rules.code_inline = function(tokens, idx, options, env, self) {
md.renderer.rules.code_inline = function (tokens, idx, options, env, self) {
// @ts-expect-error shut the fuck up already I HATE THIS
if (!env.frontmatter.title || (env.frontmatter.title && !env.frontmatter.title === "base64")) {
return defaultRender(tokens, idx, options, env, self);

View File

@ -1,5 +1,5 @@
<script setup lang="ts">
import { inject } from "vue";
import { inject } from "vue";
import { useData } from "vitepress";
import VPIconMoon from "vitepress/dist/client/theme-default/components/icons/VPIconMoon.vue";