[+] Obsidian dotfiles

This commit is contained in:
2025-04-18 01:34:27 -04:00
parent b41ed2c68d
commit 04439d26e4
23 changed files with 3586 additions and 0 deletions
+2
View File
@@ -0,0 +1,2 @@
app.json
workspace.json
+11
View File
@@ -0,0 +1,11 @@
{
"accentColor": "#ef6b7f",
"monospaceFontFamily": "Sarasa Mono SC",
"cssTheme": "Minimal",
"enabledCssSnippets": [
"hydev"
],
"textFontFamily": "",
"baseFontSize": 18,
"theme": "obsidian"
}
+6
View File
@@ -0,0 +1,6 @@
[
"image-captions",
"obsidian-custom-attachment-location",
"obsidian-export-image",
"table-editor-obsidian"
]
+32
View File
@@ -0,0 +1,32 @@
{
"file-explorer": true,
"global-search": true,
"switcher": true,
"graph": true,
"backlink": true,
"outgoing-link": true,
"tag-pane": true,
"page-preview": true,
"daily-notes": true,
"templates": true,
"note-composer": true,
"command-palette": true,
"slash-command": false,
"editor-status": true,
"starred": false,
"markdown-importer": false,
"zk-prefixer": false,
"random-note": false,
"outline": true,
"word-count": true,
"slides": false,
"audio-recorder": false,
"workspaces": false,
"file-recovery": true,
"publish": false,
"sync": false,
"canvas": true,
"bookmarks": true,
"properties": false,
"webviewer": false
}
+22
View File
@@ -0,0 +1,22 @@
{
"collapse-filter": true,
"search": "",
"showTags": false,
"showAttachments": false,
"hideUnresolved": false,
"showOrphans": true,
"collapse-color-groups": true,
"colorGroups": [],
"collapse-display": true,
"showArrow": false,
"textFadeMultiplier": 0,
"nodeSizeMultiplier": 1,
"lineSizeMultiplier": 1,
"collapse-forces": true,
"centerStrength": 0.518713248970312,
"repelStrength": 10,
"linkStrength": 1,
"linkDistance": 250,
"scale": 0.28165328146789437,
"close": false
}
+1
View File
@@ -0,0 +1 @@
{}
+95
View File
@@ -0,0 +1,95 @@
/*
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
if you want to view the source, please visit the github repository of this plugin
*/
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
// src/main.ts
var main_exports = {};
__export(main_exports, {
default: () => ImageCaptions
});
module.exports = __toCommonJS(main_exports);
var import_obsidian = require("obsidian");
var ImageCaptions = class extends import_obsidian.Plugin {
async onload() {
this.registerMarkdownPostProcessor(externalImageProcessor());
this.observer = new MutationObserver((mutations) => {
mutations.forEach((rec) => {
if (rec.type === "childList") {
rec.target.querySelectorAll(".image-embed").forEach((imageEmbedContainer) => {
var _a;
const img = imageEmbedContainer.querySelector("img");
let captionText = imageEmbedContainer.getAttribute("alt") || "";
const width = imageEmbedContainer.getAttribute("width") || "";
if (captionText === imageEmbedContainer.getAttribute("src")) {
captionText = "";
}
if (!img)
return;
const figure = imageEmbedContainer.querySelector("figure");
const figCaption = imageEmbedContainer.querySelector("figcaption");
if (figure || ((_a = img.parentElement) == null ? void 0 : _a.nodeName) === "FIGURE") {
if (figCaption && captionText) {
figCaption.innerText = captionText;
} else if (!captionText) {
imageEmbedContainer.appendChild(img);
figure == null ? void 0 : figure.remove();
}
} else {
if (captionText && captionText !== imageEmbedContainer.getAttribute("src")) {
insertFigureWithCaption(img, imageEmbedContainer, captionText);
}
}
if (width) {
img.setAttribute("width", width);
} else {
img.removeAttribute("width");
}
});
}
});
});
this.observer.observe(document.body, { subtree: true, childList: true });
}
onunload() {
this.observer.disconnect();
}
};
function externalImageProcessor() {
return (el) => {
el.findAll("img:not(.emoji)").forEach((img) => {
const captionText = img.getAttribute("alt");
const parent = img.parentElement;
if (parent && (parent == null ? void 0 : parent.nodeName) !== "FIGURE" && captionText && captionText !== img.getAttribute("src")) {
insertFigureWithCaption(img, parent, captionText);
}
});
};
}
function insertFigureWithCaption(imageEl, outerEl, captionText) {
const figure = outerEl.createEl("figure");
figure.addClass("image-captions-figure");
figure.appendChild(imageEl);
figure.createEl("figcaption", {
text: captionText,
cls: "image-captions-caption"
});
}
@@ -0,0 +1,11 @@
{
"id": "image-captions",
"name": "Image Captions",
"version": "1.0.7",
"minAppVersion": "0.15.0",
"description": "Adds captions to images when there is alt-text specified",
"author": "Alan Grainger",
"authorUrl": "https://github.com/alangrainger",
"fundingUrl": "https://ko-fi.com/alan_",
"isDesktopOnly": false
}
@@ -0,0 +1,20 @@
.image-captions-figure {
margin: 0;
padding: 2px;
width: fit-content;
border-radius: 2px;
}
.image-captions-caption {
margin: -5px 0 0 0;
padding: 3px 5px;
text-align: center;
}
.theme-dark .image-captions-figure {
background: #303030;
}
.theme-light .image-captions-figure {
background: #ebebeb;
}
@@ -0,0 +1,20 @@
{
"attachmentFolderPath": "./Assets/${filename}",
"attachmentRenameMode": "Only pasted images",
"customTokensStr": "",
"duplicateNameSeparator": " ",
"excludePaths": [],
"generatedAttachmentFilename": "${date:YYYY-MM-DD HH-mm}",
"includePaths": [],
"jpegQuality": 0.8,
"shouldConvertPastedImagesToJpeg": false,
"shouldDeleteOrphanAttachments": false,
"shouldKeepEmptyAttachmentFolders": false,
"shouldRenameAttachmentFiles": true,
"shouldRenameAttachmentFolder": true,
"shouldRenameAttachmentsToLowerCase": false,
"shouldRenameCollectedAttachments": false,
"specialCharacters": "#^[]|*\\<>:?",
"specialCharactersReplacement": "-",
"warningVersion": "7.2.6"
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,11 @@
{
"id": "obsidian-custom-attachment-location",
"name": "Custom Attachment Location",
"version": "7.2.6",
"minAppVersion": "1.8.9",
"description": "Customize attachment location with variables(${fileName}, ${date:format}, etc) like typora.",
"author": "RainCat1998",
"authorUrl": "https://github.com/RainCat1998/",
"isDesktopOnly": false,
"fundingUrl": "https://www.buymeacoffee.com/mnaoumov"
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,11 @@
{
"id": "obsidian-export-image",
"name": "Export Image plugin",
"version": "2.4.4",
"minAppVersion": "1.4.0",
"description": "Easily convert your article to image.",
"author": "Zhou Hua",
"authorUrl": "",
"isDesktopOnly": false,
"sponsor": "https://ko-fi.com/zhouhua"
}
@@ -0,0 +1,249 @@
/*
This CSS file will be included with your plugin, and
available in the app when your plugin is enabled.
If your plugin does not need CSS, delete this file.
*/
.export-image-preview-container {
pointer-events: none;
}
.export-image-root .obsidian-banner-wrapper {
margin-top: 0 !important;
padding-top: 0;
}
.export-image-root .markdown-preview-view:has(.obsidian-banner-wrapper) {
padding-top: calc(var(--banner-height) + var(--size-4-6));
}
.export-image-root.markdown-reading-view {
container-type: normal !important;
}
.export-image-root pre {
overflow: hidden;
}
.export-image-preview-main {
display: flex;
margin: 20px 0;
flex-wrap: nowrap;
--line-height-tight: 20px;
}
.export-image-preview-left {
width: 50%;
padding: 20px;
overflow-y: auto;
font-size: 14px;
line-height: 28px;
box-sizing: border-box;
}
.export-image-preview-right {
width: 50%;
padding: 20px;
box-sizing: border-box;
}
@media (max-width: 1000px) {
.export-image-preview-main {
flex-wrap: wrap;
}
.export-image-preview-left {
width: 100%;
}
.export-image-preview-right {
width: 100%;
}
}
.export-image-preview-out {
width: 100%;
transition: width 0.25s;
background-size: 20px 20px;
background-position: 0 0, 10px 10px;
background-image: linear-gradient(
45deg,
var(--background-modifier-border) 25%,
transparent 25%,
transparent 75%,
var(--background-modifier-border) 75%
),
linear-gradient(
45deg,
var(--background-modifier-border) 25%,
transparent 25%,
transparent 75%,
var(--background-modifier-border) 75%
);
}
.export-image-preview-root .info-text {
line-height: 20px;
opacity: 0.6;
font-size: 12px;
margin-top: 16px;
}
.export-image-root .user-info-container {
display: flex;
padding: 16px 32px;
alignitems: center;
}
.user-info-avatar {
width: 36px;
height: 36px;
border-radius: 50%;
border: 1px solid var(--background-modifier-border);
background-size: cover;
margin: 0 20px;
}
.export-image-root .user-info-name {
font-size: 16px;
padding-bottom: 6px;
}
.export-image-root .user-info-remark {
opacity: 0.5;
font-size: 12px;
white-space: nowrap;
}
.export-image-preview-actions {
display: flex;
align-items: start;
justify-content: center;
}
.export-image-preview-actions button {
margin: 0 32px;
}
.export-image-preview-actions p {
margin: 5px 0 0 0;
font-size: 12px;
color: var(--color-red);
text-align: center;
}
.export-image-root .multi-select-pill-content {
margin: 0 6px;
}
.export-image-root .metadata-property-name {
padding: var(--size-4-1) var(--size-4-2);
text-overflow: ellipsis;
overflow: hidden;
height: var(--input-height);
}
.export-image-select-photo {
padding: 20px;
display: flex;
flex-direction: column;
}
.export-image-select-photo-main {
margin-top: 20px;
border-radius: 8px;
border: 1px solid var(--background-modifier-border);
display: flex;
}
.export-image-select-photo-left {
border-right: 1px solid var(--background-modifier-border);
height: 300px;
overflow-y: auto;
flex: 1;
font-size: 14px;
line-height: 28px;
padding: 8px;
word-break: keep-all;
overflow-x: hidden;
}
.export-image-select-item {
cursor: pointer;
text-overflow: ellipsis;
white-space: nowrap;
overflow-x: hidden;
}
.export-image-select-empty {
text-align: center;
font-size: 16px;
margin-top: 50px;
opacity: 0.8;
}
.export-image-select-preview {
padding: 20px;
height: 300px;
width: 200px;
display: flex;
justify-content: center;
align-items: center;
}
.export-image-select-selected {
font-size: 12px;
margin-top: 8px;
opacity: 0.7;
}
.export-image-select-actions {
margin-top: 40px;
display: flex;
justify-content: center;
}
.export-image-setting-preview-mock {
border: 1px solid var(--background-modifier-border);
border-radius: 8px;
}
.export-image-progress-bar {
max-width: 320px;
width: 100%;
height: var(--size-4-2);
border-radius: var(--radius-s);
background-color: var(--background-secondary);
box-shadow: inset 0 0 0 1px var(--background-modifier-border);
}
.export-image-progress-bar-inner {
width: 0;
height: 100%;
border-radius: var(--radius-s);
background-color: var(--interactive-accent);
transition: width 0.6s;
}
.export-image-preview-file-item {
display: flex;
align-items: center;
padding-top: 10px;
}
.export-image-select-all {
font-weight: bolder;
padding-bottom: 10px;
border-bottom: 1px solid var(--background-modifier-border);
}
.export-image-filename {
padding-left: 10px;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
.export-image-select-number {
flex-grow: 1;
text-align: right;
}
.export-image-hidden {
position: fixed;
top: 9999px;
width: auto;
height: auto;
}
.export-image-split-hr hr {
opacity: 0;
height: 0;
}
@@ -0,0 +1,6 @@
{
"formatType": "weak",
"showRibbonIcon": true,
"bindEnter": true,
"bindTab": true
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,17 @@
{
"id": "table-editor-obsidian",
"name": "Advanced Tables",
"author": "Tony Grosinger",
"authorUrl": "https://grosinger.net",
"description": "Improved table navigation, formatting, manipulation, and formulas",
"isDesktopOnly": false,
"minAppVersion": "1.0.0",
"version": "0.22.1",
"js": "main.js",
"fundingUrl": {
"Github Sponsor": "https://github.com/sponsors/tgrosinger",
"Buy me a Coffee": "https://buymeacoffee.com/tgrosinger",
"Paypal": "https://paypal.me/tgrosinger"
},
"donation": "https://buymeacoffee.com/tgrosinger"
}
@@ -0,0 +1,78 @@
:root {
--advanced-tables-helper-size: 28px;
}
.HyperMD-table-row span.cm-inline-code {
font-size: 100%;
padding: 0px;
}
.advanced-tables-buttons>div>.title {
font-weight: var(--font-medium);
font-size: var(--nav-item-size);
color: var(--nav-item-color);
text-decoration: underline;
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container {
column-gap: 0.2rem;
margin: 0.2rem 0 0.2rem 0;
justify-content: start;
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container::before {
min-width: 2.6rem;
line-height: var(--advanced-tables-helper-size);
font-size: var(--nav-item-size);
font-weight: var(--nav-item-weight);
color: var(--nav-item-color);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container>* {
height: var(--advanced-tables-helper-size);
line-height: var(--advanced-tables-helper-size);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container .nav-action-button {
width: var(--advanced-tables-helper-size);
height: var(--advanced-tables-helper-size);
display: flex;
justify-content: center;
align-items: center;
border-radius: var(--radius-s);
}
[data-type="advanced-tables-toolbar"] .nav-buttons-container .nav-action-button:hover {
background-color: var(--nav-item-background-hover);
color: var(--nav-item-color-hover);
font-weight: var(--nav-item-weight-hover);
}
.advanced-tables-row-label {
width: 50px;
}
.widget-icon {
width: 20px;
height: 20px;
fill: var(--text-muted);
}
.widget-icon:hover {
fill: var(--text-normal);
}
.advanced-tables-csv-export textarea {
height: 200px;
width: 100%;
}
.advanced-tables-donation {
width: 70%;
margin: 0 auto;
text-align: center;
}
.advanced-tables-donate-button {
margin: 10px;
}
+28
View File
@@ -0,0 +1,28 @@
@font-face
font-family: 'LXGW WenKai'
src: url("https://aza.moe/fonts/LXGWWenKai-Regular.woff2") format('woff2'), url("https://aza.moe/fonts/LXGWWenKai-Regular.woff") format('woff')
.font-custom
--font-fallback: "Noto Sans SC", Avenir, Helvetica, Arial, sans-serif
--font-text: "Maiandra GD", "LXGW WenKai", var(--font-fallback) !important
--font-interface: "Maiandra GD", "LXGW WenKai", var(--font-fallback) !important
body
@extend .font-custom
.image-embed
img
border-radius: 10px
.image-captions-figure
border-radius: 10px
color: #aaa
font-size: 0.9em
.cm-line:has(.cm-hmd-frontmatter)
line-height: calc(0.7em + 4px)
.cm-hmd-frontmatter
font-size: 0.7em
color: #aaa
line-height: 0.5em
+31
View File
@@ -0,0 +1,31 @@
@font-face {
font-family: "LXGW WenKai";
src: url("https://aza.moe/fonts/LXGWWenKai-Regular.woff2") format("woff2"), url("https://aza.moe/fonts/LXGWWenKai-Regular.woff") format("woff");
}
.font-custom, body {
--font-fallback: "Noto Sans SC", Avenir, Helvetica, Arial, sans-serif;
--font-text: "Maiandra GD", "LXGW WenKai", var(--font-fallback) !important;
--font-interface: "Maiandra GD", "LXGW WenKai", var(--font-fallback) !important;
}
.image-embed img {
border-radius: 10px;
}
.image-captions-figure {
border-radius: 10px;
color: #aaa;
font-size: 0.9em;
}
.cm-line:has(.cm-hmd-frontmatter) {
line-height: calc(0.7em + 4px);
}
.cm-hmd-frontmatter {
font-size: 0.7em;
color: #aaa;
line-height: 0.5em;
}
/*# sourceMappingURL=hydev.css.map */
+8
View File
@@ -0,0 +1,8 @@
{
"name": "Minimal",
"version": "7.7.19",
"minAppVersion": "1.6.1",
"author": "@kepano",
"authorUrl": "https://twitter.com/kepano",
"fundingUrl": "https://www.buymeacoffee.com/kepano"
}
File diff suppressed because one or more lines are too long