Skip to content

Instantly share code, notes, and snippets.

View Moyf's full-sized avatar

Moy Moyf

  • HangZhou
View GitHub Profile
// Example
/**
```dataviewjs
dv.view("mediaViewInFolder", {
folder: "_global/emotion",
showTitle: true,
title: "My Emotion",
pagination: 9,
addAlt: true,
exclude: ["bad"],
@Moyf
Moyf / Beautified separator style.css
Last active April 24, 2025 16:30
Beautified separator style for Obsidian
/* Moy OB 基础样式调节 */
/* Created: 2025-04-03 */
/* 注释文本变小 */
.cm-comment {
font-size: 0.8em;
opacity: 0.8;
}

<%* // 获取编辑器实例 const editor = app.workspace.activeEditor.editor;

// 获取当前行 const cursor = editor.getCursor(); const line = editor.getLine(cursor.line);

// 1. 将普通文本或普通列表转换成未完成的任务 if (!/^[\s]*- [[ x-]]/.test(line)) {

@Moyf
Moyf / Moy-Vertical Tabs.css
Last active April 21, 2025 02:48
Obsidian CSS: Vertical Tabs
/* Moy Vertical Tabs.css */
/* 2025-04-14 */
/* Extracted from MicroMike theme: https://github.com/ThisTheThe/MicroMike */
/* More snippets available: https://github.com/ThisTheThe/MicroMike/tree/main/Snippets */
/* Modified by @PandaNoSleep with thanks! */
/* Better experience when used with: */
/* Floating Sidebar: https://forum-zh.obsidian.md/t/topic/32602 */