Compare commits
2 commits
fbbddd0aac
...
c920a669db
Author | SHA1 | Date | |
---|---|---|---|
c920a669db | |||
2d04d4dde1 |
78 changed files with 1 additions and 55741 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -575,6 +575,7 @@ cython_debug/
|
|||
|
||||
# Ignore all Obsidian-related files
|
||||
.obsidian/ # Obsidian configuration folder
|
||||
.obsidian/**/*
|
||||
*.md~ # Temporary/backup files created by Obsidian
|
||||
*.sync-conflict* # Files created during sync conflicts in Obsidian
|
||||
|
||||
|
|
7
.obsidian/app.json
vendored
7
.obsidian/app.json
vendored
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
"alwaysUpdateLinks": true,
|
||||
"showUnsupportedFiles": true,
|
||||
"propertiesInDocument": "source",
|
||||
"promptDelete": false,
|
||||
"newFileLocation": "current"
|
||||
}
|
8
.obsidian/appearance.json
vendored
8
.obsidian/appearance.json
vendored
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
"cssTheme": "AnuPpuccin",
|
||||
"baseFontSizeAction": true,
|
||||
"enabledCssSnippets": [
|
||||
"extended-colorschemes",
|
||||
"S - Checkboxes"
|
||||
]
|
||||
}
|
3
.obsidian/backlink.json
vendored
3
.obsidian/backlink.json
vendored
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
"backlinkInDocument": true
|
||||
}
|
15
.obsidian/community-plugins.json
vendored
15
.obsidian/community-plugins.json
vendored
|
@ -1,15 +0,0 @@
|
|||
[
|
||||
"editing-toolbar",
|
||||
"obsidian-style-settings",
|
||||
"obsidian-markdown-formatting-assistant-plugin",
|
||||
"obsidian-kanban",
|
||||
"cmdr",
|
||||
"link-favicon",
|
||||
"url-into-selection",
|
||||
"obsidian-icon-folder",
|
||||
"automatic-table-of-contents",
|
||||
"dataview",
|
||||
"obsidian-dictionary-plugin",
|
||||
"tab-panels",
|
||||
"obsidian-textgenerator-plugin"
|
||||
]
|
30
.obsidian/core-plugins-migration.json
vendored
30
.obsidian/core-plugins-migration.json
vendored
|
@ -1,30 +0,0 @@
|
|||
{
|
||||
"file-explorer": true,
|
||||
"global-search": true,
|
||||
"switcher": true,
|
||||
"graph": true,
|
||||
"backlink": true,
|
||||
"canvas": true,
|
||||
"outgoing-link": true,
|
||||
"tag-pane": true,
|
||||
"properties": false,
|
||||
"page-preview": true,
|
||||
"daily-notes": true,
|
||||
"templates": true,
|
||||
"note-composer": true,
|
||||
"command-palette": true,
|
||||
"slash-command": false,
|
||||
"editor-status": true,
|
||||
"bookmarks": true,
|
||||
"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
|
||||
}
|
30
.obsidian/core-plugins.json
vendored
30
.obsidian/core-plugins.json
vendored
|
@ -1,30 +0,0 @@
|
|||
{
|
||||
"file-explorer": true,
|
||||
"global-search": true,
|
||||
"switcher": false,
|
||||
"graph": false,
|
||||
"backlink": true,
|
||||
"canvas": false,
|
||||
"outgoing-link": true,
|
||||
"tag-pane": true,
|
||||
"properties": true,
|
||||
"page-preview": true,
|
||||
"daily-notes": false,
|
||||
"templates": true,
|
||||
"note-composer": true,
|
||||
"command-palette": true,
|
||||
"slash-command": true,
|
||||
"editor-status": true,
|
||||
"bookmarks": false,
|
||||
"markdown-importer": false,
|
||||
"zk-prefixer": false,
|
||||
"random-note": false,
|
||||
"outline": false,
|
||||
"word-count": true,
|
||||
"slides": false,
|
||||
"audio-recorder": false,
|
||||
"workspaces": false,
|
||||
"file-recovery": true,
|
||||
"publish": false,
|
||||
"sync": false
|
||||
}
|
BIN
.obsidian/icons/boxicons.zip
vendored
BIN
.obsidian/icons/boxicons.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/coolicons.zip
vendored
BIN
.obsidian/icons/coolicons.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/feather-icons.zip
vendored
BIN
.obsidian/icons/feather-icons.zip
vendored
Binary file not shown.
1
.obsidian/icons/feather-icons/Bookmark.svg
vendored
1
.obsidian/icons/feather-icons/Bookmark.svg
vendored
|
@ -1 +0,0 @@
|
|||
<svg xmlns="http://www.w3.org/2000/svg" width="16px" height="16px" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M19 21l-7-5-7 5V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z"></path></svg>
|
Before Width: | Height: | Size: 258 B |
1
.obsidian/icons/feather-icons/Tag.svg
vendored
1
.obsidian/icons/feather-icons/Tag.svg
vendored
|
@ -1 +0,0 @@
|
|||
<svg xmlns="http://www.w3.org/2000/svg" width="16px" height="16px" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20.59 13.41l-7.17 7.17a2 2 0 0 1-2.83 0L2 12V2h10l8.59 8.59a2 2 0 0 1 0 2.82z"></path><line x1="7" y1="7" x2="7.01" y2="7"></line></svg>
|
Before Width: | Height: | Size: 331 B |
BIN
.obsidian/icons/font-awesome-brands.zip
vendored
BIN
.obsidian/icons/font-awesome-brands.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/font-awesome-regular.zip
vendored
BIN
.obsidian/icons/font-awesome-regular.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/font-awesome-solid.zip
vendored
BIN
.obsidian/icons/font-awesome-solid.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/icon-brew.zip
vendored
BIN
.obsidian/icons/icon-brew.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/lucide-icons.zip
vendored
BIN
.obsidian/icons/lucide-icons.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/octicons.zip
vendored
BIN
.obsidian/icons/octicons.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/remix-icons.zip
vendored
BIN
.obsidian/icons/remix-icons.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/rpg-awesome.zip
vendored
BIN
.obsidian/icons/rpg-awesome.zip
vendored
Binary file not shown.
BIN
.obsidian/icons/simple-icons.zip
vendored
BIN
.obsidian/icons/simple-icons.zip
vendored
Binary file not shown.
1
.obsidian/icons/simple-icons/Python.svg
vendored
1
.obsidian/icons/simple-icons/Python.svg
vendored
|
@ -1 +0,0 @@
|
|||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill="currentColor" width="16px" height="16px"><path d="M14.25.18l.9.2.73.26.59.3.45.32.34.34.25.34.16.33.1.3.04.26.02.2-.01.13V8.5l-.05.63-.13.55-.21.46-.26.38-.3.31-.33.25-.35.19-.35.14-.33.1-.3.07-.26.04-.21.02H8.77l-.69.05-.59.14-.5.22-.41.27-.33.32-.27.35-.2.36-.15.37-.1.35-.07.32-.04.27-.02.21v3.06H3.17l-.21-.03-.28-.07-.32-.12-.35-.18-.36-.26-.36-.36-.35-.46-.32-.59-.28-.73-.21-.88-.14-1.05-.05-1.23.06-1.22.16-1.04.24-.87.32-.71.36-.57.4-.44.42-.33.42-.24.4-.16.36-.1.32-.05.24-.01h.16l.06.01h8.16v-.83H6.18l-.01-2.75-.02-.37.05-.34.11-.31.17-.28.25-.26.31-.23.38-.2.44-.18.51-.15.58-.12.64-.1.71-.06.77-.04.84-.02 1.27.05zm-6.3 1.98l-.23.33-.08.41.08.41.23.34.33.22.41.09.41-.09.33-.22.23-.34.08-.41-.08-.41-.23-.33-.33-.22-.41-.09-.41.09zm13.09 3.95l.28.06.32.12.35.18.36.27.36.35.35.47.32.59.28.73.21.88.14 1.04.05 1.23-.06 1.23-.16 1.04-.24.86-.32.71-.36.57-.4.45-.42.33-.42.24-.4.16-.36.09-.32.05-.24.02-.16-.01h-8.22v.82h5.84l.01 2.76.02.36-.05.34-.11.31-.17.29-.25.25-.31.24-.38.2-.44.17-.51.15-.58.13-.64.09-.71.07-.77.04-.84.01-1.27-.04-1.07-.14-.9-.2-.73-.25-.59-.3-.45-.33-.34-.34-.25-.34-.16-.33-.1-.3-.04-.25-.02-.2.01-.13v-5.34l.05-.64.13-.54.21-.46.26-.38.3-.32.33-.24.35-.2.35-.14.33-.1.3-.06.26-.04.21-.02.13-.01h5.84l.69-.05.59-.14.5-.21.41-.28.33-.32.27-.35.2-.36.15-.36.1-.35.07-.32.04-.28.02-.21V6.07h2.09l.14.01zm-6.47 14.25l-.23.33-.08.41.08.41.23.33.33.23.41.08.41-.08.33-.23.23-.33.08-.41-.08-.41-.23-.33-.33-.23-.41-.08-.41.08z"></path></svg>
|
Before Width: | Height: | Size: 1.5 KiB |
|
@ -1 +0,0 @@
|
|||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" fill="currentColor" width="16px" height="16px"><path d="M11.435 20.69c-.09-.11-.219-.182-.328-.255-.092-.055-.128-.11-.11-.238.183-1.077.347-2.154.511-3.25.11-.73.22-1.46.347-2.227.165.11.329.22.475.329.036.036.018.091.018.128-.036.255-.073.53-.128.785l-.273 1.77-.274 1.753c-.019.146-.037.31-.073.457.073.018.11-.037.164-.055 1.387-.73 2.775-1.442 4.163-2.173l.11-.054c.036-.019.072-.037.109 0 .146.09.292.2.456.31-.073.036-.11.073-.164.091-1.607.84-3.195 1.68-4.802 2.52-.055.018-.11.036-.128.091l-.073.018zm-4.874-9.858c-.037.292-.091.547-.128.803-.128.84-.274 1.661-.402 2.501-.073.493-.164.986-.237 1.479-.018.091-.055.128-.128.146-.146.036-.31.091-.456.146-.018-.037 0-.073 0-.11.146-.912.292-1.807.438-2.72.146-.876.274-1.77.42-2.647.018-.073.036-.128.128-.146.127-.037.237-.073.365-.11.073-.036.128-.018.2.037l.932.93c.986.987 1.99 1.973 2.976 2.94.018.019.036.055.073.073-.183.073-.366.11-.53.183-.055.018-.091-.037-.11-.055-.237-.237-.474-.475-.73-.712a375.76 375.76 0 0 1-2.702-2.684c-.036 0-.054-.018-.11-.054m4.748 2.83a8.286 8.286 0 0 1-.402-.384c-.037-.037-.018-.091 0-.128.11-.328.219-.657.347-.986l1.205-3.45a.338.338 0 0 0 .036-.128c-.073-.018-.128.018-.182.036-1.497.475-2.976.932-4.473 1.406-.238.073-.165.092-.329-.073l-.274-.274c.037-.054.11-.054.165-.073 1.734-.547 3.468-1.095 5.185-1.643.127-.036.2-.018.292.073.054.073.146.146.219.22.073.054.073.127.054.2-.2.548-.383 1.096-.584 1.643-.401 1.15-.803 2.3-1.205 3.433a.318.318 0 0 1-.054.127m-.31 1.15a5.268 5.268 0 0 0-.074.53c0 .073-.055.073-.11.091-.401.128-.784.256-1.168.365-1.132.366-2.282.712-3.414 1.078-.036.018-.091.036-.146.054a.284.284 0 0 0 .146.11c1.278.876 2.556 1.77 3.834 2.647.11.073.183.146.128.292-.037.128-.037.256-.073.384-.055 0-.091-.037-.128-.055C8.496 19.284 7 18.244 5.502 17.22c-.091-.073-.128-.127-.11-.255.019-.11.055-.201.055-.31 0-.092.055-.128.128-.147 1.77-.566 3.56-1.113 5.33-1.68.02 0 .056 0 .092-.017M6.944 3.62c-.018.183-.055.365-.073.53 0 .073-.073.073-.128.073-.328.11-.675.2-1.004.31-1.205.365-2.391.73-3.596 1.095-.037.019-.092.019-.128.073.055.037.091.073.146.11 1.278.895 2.538 1.807 3.816 2.702.09.073.127.128.11.256a3.37 3.37 0 0 0-.074.42c-.055-.019-.091-.055-.146-.074L1.431 5.994c-.11-.074-.146-.147-.11-.256.018-.11.037-.2.055-.31 0-.073.036-.11.128-.147l1.26-.383c1.35-.402 2.683-.821 4.034-1.223.037-.037.091-.037.146-.055m5.477 3.725c-.146.054-.292.09-.438.146-.091.036-.164.018-.237-.055-.493-.511-1.004-1.004-1.516-1.516a183.922 183.922 0 0 0-1.825-1.807c-.037-.036-.055-.091-.128-.11a6.081 6.081 0 0 0-.091.566c-.146.859-.274 1.717-.42 2.556-.092.548-.183 1.078-.256 1.625-.018.092-.036.128-.128.146-.146.037-.31.092-.456.146-.018-.11.018-.2.036-.273l.548-3.396c.091-.603.201-1.205.292-1.808.019-.073.037-.11.11-.127.128-.037.237-.073.365-.11.091-.037.146-.018.219.055l1.46 1.46c.786.785 1.589 1.57 2.374 2.355.018.037.073.073.091.147m.672 7.755a3.728 3.728 0 0 1-.13-.76c-.115-.959-.014-1.885.36-2.774.572-1.388 1.56-2.417 2.904-3.073a8.12 8.12 0 0 1 2.116-.676c.05.059.027.13.023.185l.032.332c.013.074-.026.108-.1.12-.484.113-.97.262-1.423.469-1.228.536-2.164 1.367-2.76 2.57a4.954 4.954 0 0 0-.526 2.544c.02.24.04.478.078.719.013.074.009.129-.085.159a3.57 3.57 0 0 0-.489.185m2.53 1.77c.013-.183.006-.348.02-.53.004-.073.025-.108.117-.12.481-.076.947-.19 1.382-.397 1.606-.712 2.66-1.92 3.09-3.628.177-.683.207-1.376.146-2.076.002-.036-.012-.092-.01-.129.006-.072-.06-.169-.002-.22.04-.052.131-.045.205-.058.13-.028.242-.057.373-.102.057.242.075.5.077.737a7.32 7.32 0 0 1-.054 1.552 5.652 5.652 0 0 1-1.478 3.081c-.87.928-1.953 1.492-3.179 1.754a2.843 2.843 0 0 1-.687.135m5.343-10.442c.054.004.075-.032.113-.047a54.441 54.441 0 0 1 2.265-1.251c.039-.034.095-.048.147-.008.157.102.333.206.509.31a.555.555 0 0 1-.134.082c-.95.501-1.917.983-2.867 1.483a.865.865 0 0 0-.195.17c-.349.543-.718 1.103-1.067 1.646-.062.105-.062.105-.167.043-.106-.063-.193-.124-.299-.186-.105-.062-.105-.062-.044-.15l.677-1.05c.143-.21.268-.42.41-.63a.368.368 0 0 0 .07-.197 182.142 182.142 0 0 1 .211-3.297c.142.064.263.164.405.23.16.083.19.177.176.36a76.356 76.356 0 0 0-.16 2.038c-.01.145-.039.29-.05.454m-3.882 4.468c-.018.255-.316.6-.575.637a.458.458 0 0 1-.465-.16.43.43 0 0 1-.077-.463.87.87 0 0 1 .436-.482.445.445 0 0 1 .474.033c.156.12.238.255.207.435m1.856 1.21c-.018.255-.317.6-.577.655-.186.042-.328-.023-.464-.16a.4.4 0 0 1-.08-.445c.09-.232.23-.405.457-.5.322-.16.688.104.664.45M.883 6.432c.164.091.292.2.456.31.055.037.037.091.019.146l-.165 1.04c-.2 1.242-.401 2.465-.602 3.707 0 .036-.037.091 0 .146.055-.037.11-.055.164-.091l4.108-2.246c.11-.055.182-.055.274.018.11.092.219.165.347.256-.037.055-.092.073-.128.091-1.589.877-3.177 1.735-4.747 2.61-.11.056-.183.074-.274-.017-.073-.073-.164-.128-.255-.183-.073-.036-.092-.091-.073-.164.073-.438.146-.858.2-1.296.22-1.388.457-2.776.676-4.163a.253.253 0 0 1 0-.164"></path></svg>
|
Before Width: | Height: | Size: 4.8 KiB |
BIN
.obsidian/icons/tabler-icons.zip
vendored
BIN
.obsidian/icons/tabler-icons.zip
vendored
Binary file not shown.
1
.obsidian/icons/tabler-icons/Tags.svg
vendored
1
.obsidian/icons/tabler-icons/Tags.svg
vendored
|
@ -1 +0,0 @@
|
|||
<svg xmlns="http://www.w3.org/2000/svg" width="16px" height="16px" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="icon icon-tabler icons-tabler-outline icon-tabler-tags"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M3 8v4.172a2 2 0 0 0 .586 1.414l5.71 5.71a2.41 2.41 0 0 0 3.408 0l3.592 -3.592a2.41 2.41 0 0 0 0 -3.408l-5.71 -5.71a2 2 0 0 0 -1.414 -.586h-4.172a2 2 0 0 0 -2 2z"></path><path d="M18 19l1.592 -1.592a4.82 4.82 0 0 0 0 -6.816l-4.592 -4.592"></path><path d="M7 10h-.01"></path></svg>
|
Before Width: | Height: | Size: 594 B |
4
.obsidian/page-preview.json
vendored
4
.obsidian/page-preview.json
vendored
|
@ -1,4 +0,0 @@
|
|||
{
|
||||
"bookmarks": false,
|
||||
"outline": false
|
||||
}
|
|
@ -1,293 +0,0 @@
|
|||
let Plugin = class {}
|
||||
let MarkdownRenderer = {}
|
||||
let MarkdownRenderChild = class {}
|
||||
let htmlToMarkdown = (html) => html
|
||||
|
||||
if (isObsidian()) {
|
||||
const obsidian = require('obsidian')
|
||||
Plugin = obsidian.Plugin
|
||||
MarkdownRenderer = obsidian.MarkdownRenderer
|
||||
MarkdownRenderChild = obsidian.MarkdownRenderChild
|
||||
htmlToMarkdown = obsidian.htmlToMarkdown
|
||||
}
|
||||
|
||||
const codeblockId = 'table-of-contents'
|
||||
const codeblockIdShort = 'toc'
|
||||
const availableOptions = {
|
||||
title: {
|
||||
type: 'string',
|
||||
default: '',
|
||||
comment: '',
|
||||
},
|
||||
style: {
|
||||
type: 'value',
|
||||
default: 'nestedList',
|
||||
values: ['nestedList', 'nestedOrderedList', 'inlineFirstLevel'],
|
||||
comment: 'TOC style (nestedList|nestedOrderedList|inlineFirstLevel)',
|
||||
},
|
||||
minLevel: {
|
||||
type: 'number',
|
||||
default: 0,
|
||||
comment: 'Include headings from the specified level',
|
||||
},
|
||||
maxLevel: {
|
||||
type: 'number',
|
||||
default: 0,
|
||||
comment: 'Include headings up to the specified level',
|
||||
},
|
||||
includeLinks: {
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
comment: 'Make headings clickable',
|
||||
},
|
||||
debugInConsole: {
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
comment: 'Print debug info in Obsidian console',
|
||||
},
|
||||
}
|
||||
|
||||
class ObsidianAutomaticTableOfContents extends Plugin {
|
||||
async onload() {
|
||||
const handler = (sourceText, element, context) => {
|
||||
context.addChild(new Renderer(this.app, element, context.sourcePath, sourceText))
|
||||
}
|
||||
this.registerMarkdownCodeBlockProcessor(codeblockId, handler)
|
||||
this.registerMarkdownCodeBlockProcessor(codeblockIdShort, handler)
|
||||
this.addCommand({
|
||||
id: 'insert-automatic-table-of-contents',
|
||||
name: 'Insert table of contents',
|
||||
editorCallback: onInsertToc,
|
||||
})
|
||||
this.addCommand({
|
||||
id: 'insert-automatic-table-of-contents-docs',
|
||||
name: 'Insert table of contents (documented)',
|
||||
editorCallback: onInsertTocWithDocs,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
function onInsertToc(editor) {
|
||||
const markdown = '```' + codeblockId + '\n```'
|
||||
editor.replaceRange(markdown, editor.getCursor())
|
||||
}
|
||||
|
||||
function onInsertTocWithDocs(editor) {
|
||||
let markdown = ['```' + codeblockId]
|
||||
Object.keys(availableOptions).forEach((optionName) => {
|
||||
const option = availableOptions[optionName]
|
||||
const comment = option.comment.length > 0 ? ` # ${option.comment}` : ''
|
||||
markdown.push(`${optionName}: ${option.default}${comment}`)
|
||||
})
|
||||
markdown.push('```')
|
||||
editor.replaceRange(markdown.join('\n'), editor.getCursor())
|
||||
}
|
||||
|
||||
class Renderer extends MarkdownRenderChild {
|
||||
constructor(app, element, sourcePath, sourceText) {
|
||||
super(element)
|
||||
this.app = app
|
||||
this.element = element
|
||||
this.sourcePath = sourcePath
|
||||
this.sourceText = sourceText
|
||||
}
|
||||
|
||||
// Render on load
|
||||
onload() {
|
||||
this.render()
|
||||
this.registerEvent(this.app.metadataCache.on('changed', this.onMetadataChange.bind(this)))
|
||||
}
|
||||
|
||||
// Render on file change
|
||||
onMetadataChange() {
|
||||
this.render()
|
||||
}
|
||||
|
||||
render() {
|
||||
try {
|
||||
const options = parseOptionsFromSourceText(this.sourceText)
|
||||
if (options.debugInConsole) debug('Options', options)
|
||||
|
||||
const metadata = this.app.metadataCache.getCache(this.sourcePath)
|
||||
const headings = metadata && metadata.headings ? metadata.headings : []
|
||||
if (options.debugInConsole) debug('Headings', headings)
|
||||
|
||||
const markdown = getMarkdownFromHeadings(headings, options)
|
||||
if (options.debugInConsole) debug('Markdown', markdown)
|
||||
|
||||
this.element.empty()
|
||||
MarkdownRenderer.renderMarkdown(markdown, this.element, this.sourcePath, this)
|
||||
} catch(error) {
|
||||
const readableError = `_💥 Could not render table of contents (${error.message})_`
|
||||
MarkdownRenderer.renderMarkdown(readableError, this.element, this.sourcePath, this)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getMarkdownFromHeadings(headings, options) {
|
||||
const markdownHandlersByStyle = {
|
||||
nestedList: getMarkdownNestedListFromHeadings,
|
||||
nestedOrderedList: getMarkdownNestedOrderedListFromHeadings,
|
||||
inlineFirstLevel: getMarkdownInlineFirstLevelFromHeadings,
|
||||
}
|
||||
let markdown = ''
|
||||
if (options.title && options.title.length > 0) {
|
||||
markdown += options.title + '\n'
|
||||
}
|
||||
const noHeadingMessage = '_Table of contents: no headings found_'
|
||||
markdown += markdownHandlersByStyle[options.style](headings, options) || noHeadingMessage
|
||||
return markdown
|
||||
}
|
||||
|
||||
function getMarkdownNestedListFromHeadings(headings, options) {
|
||||
return getMarkdownListFromHeadings(headings, false, options)
|
||||
}
|
||||
|
||||
function getMarkdownNestedOrderedListFromHeadings(headings, options) {
|
||||
return getMarkdownListFromHeadings(headings, true, options)
|
||||
}
|
||||
|
||||
function getMarkdownListFromHeadings(headings, isOrdered, options) {
|
||||
const prefix = isOrdered ? '1.' : '-'
|
||||
const lines = []
|
||||
const minLevel = options.minLevel > 0
|
||||
? options.minLevel
|
||||
: Math.min(...headings.map((heading) => heading.level))
|
||||
headings.forEach((heading) => {
|
||||
if (heading.level < minLevel) return
|
||||
if (options.maxLevel > 0 && heading.level > options.maxLevel) return
|
||||
lines.push(`${'\t'.repeat(heading.level - minLevel)}${prefix} ${getMarkdownHeading(heading, options)}`)
|
||||
})
|
||||
return lines.length > 0 ? lines.join('\n') : null
|
||||
}
|
||||
|
||||
function getMarkdownInlineFirstLevelFromHeadings(headings, options) {
|
||||
const minLevel = options.minLevel > 0
|
||||
? options.minLevel
|
||||
: Math.min(...headings.map((heading) => heading.level))
|
||||
const items = headings
|
||||
.filter((heading) => heading.level === minLevel)
|
||||
.map((heading) => {
|
||||
return getMarkdownHeading(heading, options)
|
||||
})
|
||||
return items.length > 0 ? items.join(' | ') : null
|
||||
}
|
||||
|
||||
function getMarkdownHeading(heading, options) {
|
||||
const stripMarkdown = (text) => {
|
||||
text = text.replaceAll('*', '').replaceAll('_', '').replaceAll('`', '')
|
||||
text = text.replaceAll('==', '').replaceAll('~~', '')
|
||||
text = text.replace(/\[([^\]]+)\]\([^)]+\)/g, '$1') // Strip markdown links
|
||||
return text
|
||||
}
|
||||
const stripHtml = (text) => stripMarkdown(htmlToMarkdown(text))
|
||||
const stripWikilinks = (text, isForLink) => {
|
||||
// Strip [[link|text]] format
|
||||
// For the text part of the final link we only keep "text"
|
||||
// For the link part we need the text + link
|
||||
// Example: "# Some [[file.md|heading]]" must be translated to "[[#Some file.md heading|Some heading]]"
|
||||
text = text.replace(/\[\[([^\]]+)\|([^\]]+)\]\]/g, isForLink ? '$1 $2' : '$2')
|
||||
text = text.replace(/\[\[([^\]]+)\]\]/g, '$1') // Strip [[link]] format
|
||||
// Replace malformed links & reserved wikilinks chars
|
||||
text = text.replaceAll('[[', '').replaceAll('| ', isForLink ? '' : '- ').replaceAll('|', isForLink ? ' ' : '-')
|
||||
return text
|
||||
}
|
||||
const stripTags = (text) => text.replaceAll('#', '')
|
||||
if (options.includeLinks) {
|
||||
// Remove markdown, HTML & wikilinks from text for readability, as they are not rendered in a wikilink
|
||||
let text = heading.heading
|
||||
text = stripMarkdown(text)
|
||||
text = stripHtml(text)
|
||||
text = stripWikilinks(text, false)
|
||||
// Remove wikilinks & tags from link or it won't be clickable (on the other hand HTML & markdown must stay)
|
||||
let link = heading.heading
|
||||
link = stripWikilinks(link, true)
|
||||
link = stripTags(link)
|
||||
|
||||
// Return wiklink style link
|
||||
return `[[#${link}|${text}]]`
|
||||
// Why not markdown links? Because even if it looks like the text part would have a better compatibility
|
||||
// with complex headings (as it would support HTML, markdown, etc) the link part is messy,
|
||||
// because it requires some encoding that looks buggy and undocumented; official docs state the link must be URL encoded
|
||||
// (https://help.obsidian.md/Linking+notes+and+files/Internal+links#Supported+formats+for+internal+links)
|
||||
// but it doesn't work properly, example: "## Some <em>heading</em> with simple HTML" must be encoded as:
|
||||
// [Some <em>heading</em> with simple HTML](#Some%20<em>heading</em>%20with%20simpler%20HTML)
|
||||
// and not
|
||||
// [Some <em>heading</em> with simple HTML](#Some%20%3Cem%3Eheading%3C%2Fem%3E%20with%20simpler%20HTML)
|
||||
// Also it won't be clickable at all if the heading contains #tags or more complex HTML
|
||||
// (example: ## Some <em style="background: red">heading</em> #with-a-tag)
|
||||
// (unless there is a way to encode these use cases that I didn't find)
|
||||
}
|
||||
return heading.heading
|
||||
}
|
||||
|
||||
function parseOptionsFromSourceText(sourceText = '') {
|
||||
const options = {}
|
||||
Object.keys(availableOptions).forEach((option) => {
|
||||
options[option] = availableOptions[option].default
|
||||
})
|
||||
sourceText.split('\n').forEach((line) => {
|
||||
const option = parseOptionFromSourceLine(line)
|
||||
if (option !== null) {
|
||||
options[option.name] = option.value
|
||||
}
|
||||
})
|
||||
return options
|
||||
}
|
||||
|
||||
function parseOptionFromSourceLine(line) {
|
||||
const matches = line.match(/([a-zA-Z0-9._ ]+):(.*)/)
|
||||
if (line.startsWith('#') || !matches) return null
|
||||
const possibleName = matches[1].trim()
|
||||
const optionParams = availableOptions[possibleName]
|
||||
let possibleValue = matches[2].trim()
|
||||
if (!optionParams || optionParams.type !== 'string') {
|
||||
// Strip comments from values except for strings (as a string may contain markdown)
|
||||
possibleValue = possibleValue.replace(/#[^#]*$/, '').trim()
|
||||
}
|
||||
const valueError = new Error(`Invalid value for \`${possibleName}\``)
|
||||
if (optionParams && optionParams.type === 'number') {
|
||||
const value = parseInt(possibleValue)
|
||||
if (value < 0) throw valueError
|
||||
return { name: possibleName, value }
|
||||
}
|
||||
if (optionParams && optionParams.type === 'boolean') {
|
||||
if (!['true', 'false'].includes(possibleValue)) throw valueError
|
||||
return { name: possibleName, value: possibleValue === 'true' }
|
||||
}
|
||||
if (optionParams && optionParams.type === 'value') {
|
||||
if (!optionParams.values.includes(possibleValue)) throw valueError
|
||||
return { name: possibleName, value: possibleValue }
|
||||
}
|
||||
if (optionParams && optionParams.type === 'string') {
|
||||
return { name: possibleName, value: possibleValue }
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
function debug(type, data) {
|
||||
console.log(...[
|
||||
`%cAutomatic Table Of Contents %c${type}:\n`,
|
||||
'color: orange; font-weight: bold',
|
||||
'font-weight: bold',
|
||||
data,
|
||||
])
|
||||
}
|
||||
|
||||
function isObsidian() {
|
||||
if (typeof process !== 'object') {
|
||||
return true // Obsidian mobile doesn't have a global process object
|
||||
}
|
||||
return !process.env || !process.env.JEST_WORKER_ID // Jest runtime is not Obsidian
|
||||
}
|
||||
|
||||
if (isObsidian()) {
|
||||
module.exports = ObsidianAutomaticTableOfContents
|
||||
} else {
|
||||
module.exports = {
|
||||
parseOptionsFromSourceText,
|
||||
getMarkdownFromHeadings,
|
||||
}
|
||||
}
|
||||
|
||||
/* nosourcemap */
|
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "automatic-table-of-contents",
|
||||
"name": "Automatic Table Of Contents",
|
||||
"version": "1.4.0",
|
||||
"minAppVersion": "1.3.0",
|
||||
"description": "Create a table of contents in a note, that updates itself when the note changes",
|
||||
"author": "Johan Satgé",
|
||||
"authorUrl": "https://github.com/johansatge",
|
||||
"isDesktopOnly": false
|
||||
}
|
29
.obsidian/plugins/cmdr/data.json
vendored
29
.obsidian/plugins/cmdr/data.json
vendored
|
@ -1,29 +0,0 @@
|
|||
{
|
||||
"confirmDeletion": true,
|
||||
"showAddCommand": true,
|
||||
"debug": false,
|
||||
"editorMenu": [],
|
||||
"fileMenu": [],
|
||||
"leftRibbon": [],
|
||||
"rightRibbon": [],
|
||||
"titleBar": [],
|
||||
"statusBar": [],
|
||||
"pageHeader": [],
|
||||
"macros": [],
|
||||
"explorer": [],
|
||||
"hide": {
|
||||
"statusbar": [],
|
||||
"leftRibbon": []
|
||||
},
|
||||
"spacing": 8,
|
||||
"advancedToolbar": {
|
||||
"rowHeight": 48,
|
||||
"rowCount": 1,
|
||||
"spacing": 0,
|
||||
"buttonWidth": 48,
|
||||
"columnLayout": false,
|
||||
"mappedIcons": [],
|
||||
"tooltips": false,
|
||||
"heightOffset": 0
|
||||
}
|
||||
}
|
11
.obsidian/plugins/cmdr/main.js
vendored
11
.obsidian/plugins/cmdr/main.js
vendored
File diff suppressed because one or more lines are too long
11
.obsidian/plugins/cmdr/manifest.json
vendored
11
.obsidian/plugins/cmdr/manifest.json
vendored
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "cmdr",
|
||||
"name": "Commander",
|
||||
"version": "0.5.2",
|
||||
"minAppVersion": "1.4.0",
|
||||
"description": "Customize your workspace by adding commands everywhere, create Macros and supercharge your mobile toolbar.",
|
||||
"author": "jsmorabito & phibr0",
|
||||
"authorUrl": "https://github.com/phibr0",
|
||||
"fundingUrl": "https://ko-fi.com/phibr0",
|
||||
"isDesktopOnly": false
|
||||
}
|
1
.obsidian/plugins/cmdr/styles.css
vendored
1
.obsidian/plugins/cmdr/styles.css
vendored
File diff suppressed because one or more lines are too long
20725
.obsidian/plugins/dataview/main.js
vendored
20725
.obsidian/plugins/dataview/main.js
vendored
File diff suppressed because one or more lines are too long
11
.obsidian/plugins/dataview/manifest.json
vendored
11
.obsidian/plugins/dataview/manifest.json
vendored
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "dataview",
|
||||
"name": "Dataview",
|
||||
"version": "0.5.67",
|
||||
"minAppVersion": "0.13.11",
|
||||
"description": "Complex data views for the data-obsessed.",
|
||||
"author": "Michael Brenan <blacksmithgu@gmail.com>",
|
||||
"authorUrl": "https://github.com/blacksmithgu",
|
||||
"helpUrl": "https://blacksmithgu.github.io/obsidian-dataview/",
|
||||
"isDesktopOnly": false
|
||||
}
|
146
.obsidian/plugins/dataview/styles.css
vendored
146
.obsidian/plugins/dataview/styles.css
vendored
|
@ -1,146 +0,0 @@
|
|||
/** Live Preview padding fixes, specifically for DataviewJS custom HTML elements. */
|
||||
.is-live-preview .block-language-dataviewjs > p, .is-live-preview .block-language-dataviewjs > span {
|
||||
line-height: 1.0;
|
||||
}
|
||||
|
||||
.block-language-dataview {
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
/*****************/
|
||||
/** Table Views **/
|
||||
/*****************/
|
||||
|
||||
/* List View Default Styling; rendered internally as a table. */
|
||||
.table-view-table {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.table-view-table > thead > tr, .table-view-table > tbody > tr {
|
||||
margin-top: 1em;
|
||||
margin-bottom: 1em;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.table-view-table > tbody > tr:hover {
|
||||
background-color: var(--table-row-background-hover);
|
||||
}
|
||||
|
||||
.table-view-table > thead > tr > th {
|
||||
font-weight: 700;
|
||||
font-size: larger;
|
||||
border-top: none;
|
||||
border-left: none;
|
||||
border-right: none;
|
||||
border-bottom: solid;
|
||||
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.table-view-table > tbody > tr > td {
|
||||
text-align: left;
|
||||
border: none;
|
||||
font-weight: 400;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.table-view-table ul, .table-view-table ol {
|
||||
margin-block-start: 0.2em !important;
|
||||
margin-block-end: 0.2em !important;
|
||||
}
|
||||
|
||||
/** Rendered value styling for any view. */
|
||||
.dataview-result-list-root-ul {
|
||||
padding: 0em !important;
|
||||
margin: 0em !important;
|
||||
}
|
||||
|
||||
.dataview-result-list-ul {
|
||||
margin-block-start: 0.2em !important;
|
||||
margin-block-end: 0.2em !important;
|
||||
}
|
||||
|
||||
/** Generic grouping styling. */
|
||||
.dataview.result-group {
|
||||
padding-left: 8px;
|
||||
}
|
||||
|
||||
/*******************/
|
||||
/** Inline Fields **/
|
||||
/*******************/
|
||||
|
||||
.dataview.inline-field-key {
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
font-family: var(--font-monospace);
|
||||
background-color: var(--background-primary-alt);
|
||||
color: var(--text-nav-selected);
|
||||
}
|
||||
|
||||
.dataview.inline-field-value {
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
font-family: var(--font-monospace);
|
||||
background-color: var(--background-secondary-alt);
|
||||
color: var(--text-nav-selected);
|
||||
}
|
||||
|
||||
.dataview.inline-field-standalone-value {
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
font-family: var(--font-monospace);
|
||||
background-color: var(--background-secondary-alt);
|
||||
color: var(--text-nav-selected);
|
||||
}
|
||||
|
||||
/***************/
|
||||
/** Task View **/
|
||||
/***************/
|
||||
|
||||
.dataview.task-list-item, .dataview.task-list-basic-item {
|
||||
margin-top: 3px;
|
||||
margin-bottom: 3px;
|
||||
transition: 0.4s;
|
||||
}
|
||||
|
||||
.dataview.task-list-item:hover, .dataview.task-list-basic-item:hover {
|
||||
background-color: var(--text-selection);
|
||||
box-shadow: -40px 0 0 var(--text-selection);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/*****************/
|
||||
/** Error Views **/
|
||||
/*****************/
|
||||
|
||||
div.dataview-error-box {
|
||||
width: 100%;
|
||||
min-height: 150px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border: 4px dashed var(--background-secondary);
|
||||
}
|
||||
|
||||
.dataview-error-message {
|
||||
color: var(--text-muted);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/*************************/
|
||||
/** Additional Metadata **/
|
||||
/*************************/
|
||||
|
||||
.dataview.small-text {
|
||||
font-size: smaller;
|
||||
color: var(--text-muted);
|
||||
margin-left: 3px;
|
||||
}
|
||||
|
||||
.dataview.small-text::before {
|
||||
content: "(";
|
||||
}
|
||||
|
||||
.dataview.small-text::after {
|
||||
content: ")";
|
||||
}
|
12
.obsidian/plugins/editing-toolbar/main.js
vendored
12
.obsidian/plugins/editing-toolbar/main.js
vendored
File diff suppressed because one or more lines are too long
11
.obsidian/plugins/editing-toolbar/manifest.json
vendored
11
.obsidian/plugins/editing-toolbar/manifest.json
vendored
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "editing-toolbar",
|
||||
"name": "Editing Toolbar",
|
||||
"version": "2.4.16",
|
||||
"minAppVersion": "0.14.0",
|
||||
"description": "The Obsidian Editing Toolbar is modified from cmenu, which provides more powerful customization settings and has many built-in editing commands to be a MS Word-like toolbar editing experience.",
|
||||
"author": "Cuman",
|
||||
"authorUrl": "https://github.com/cumany/obsidian-editing-toolbar",
|
||||
"fundingUrl": "https://github.com/cumany#thank-you-very-much-for-your-support",
|
||||
"isDesktopOnly": false
|
||||
}
|
971
.obsidian/plugins/editing-toolbar/styles.css
vendored
971
.obsidian/plugins/editing-toolbar/styles.css
vendored
|
@ -1,971 +0,0 @@
|
|||
#cMenuToolbarModalBar {
|
||||
width: auto;
|
||||
height: auto;
|
||||
padding: 3px;
|
||||
display: grid;
|
||||
user-select: none;
|
||||
border-radius: var(--radius-m);
|
||||
position: absolute;
|
||||
transition: 100ms cubic-bezier(0.92, -0.53, 0.65, 1.21);
|
||||
-webkit-transition: 100ms cubic-bezier(0.92, -0.53, 0.65, 1.21);
|
||||
min-width: fit-content;
|
||||
justify-content: space-around;
|
||||
z-index: var(--layer-modal);
|
||||
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarFlex {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarFlex :is(.cMenuToolbarCommandItem, button[class^=cMenuToolbarCommandsubItem]) {
|
||||
min-width: 20px;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar .cMenuToolbarCommandItem {
|
||||
margin: 2px;
|
||||
border: none;
|
||||
display: flex;
|
||||
cursor: default;
|
||||
padding: 5px 6px;
|
||||
box-shadow: none;
|
||||
margin-left: 3px;
|
||||
margin-right: 3px;
|
||||
position: relative;
|
||||
border-radius: var(--radius-s);
|
||||
font-size: initial !important;
|
||||
background-color: var(--background-primary-alt);
|
||||
height: auto;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem button:hover,
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommand]:hover,
|
||||
#cMenuToolbarSecond:hover {
|
||||
background-color: var(--background-modifier-hover) !important;
|
||||
}
|
||||
|
||||
/* #cMenuToolbarModalBar button.cMenuToolbarCommandItem svg {
|
||||
width: 1.3em;
|
||||
height: 1.3em;
|
||||
} */
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar SETTINGS BUTTONS
|
||||
----------------------------------------------------------------*/
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonAdd,
|
||||
button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonAdd {
|
||||
background-color: var(--interactive-accent);
|
||||
}
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonDelete,
|
||||
button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonDelete {
|
||||
background-color: #989cab;
|
||||
}
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonRefresh,
|
||||
button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonRefresh {
|
||||
background-color: var(--text-accent);
|
||||
}
|
||||
|
||||
button.cMenuToolbarSettingsButton {
|
||||
padding: 4px 14px;
|
||||
border-radius: var(--radius-m);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar SETTING ITEMS
|
||||
----------------------------------------------------------------*/
|
||||
.setting-item.cMenuToolbarCommandItem:first-child {
|
||||
padding-top: 18px;
|
||||
}
|
||||
|
||||
.cMenuToolbarCommandItem {
|
||||
cursor: grab;
|
||||
padding: 18px 0 18px 0;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .sortable-fallback {
|
||||
cursor: grabbing;
|
||||
box-shadow: 0px 3px 32px rgb(31 38 135 / 15%);
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .sortable-grab {
|
||||
cursor: grabbing !important;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .sortable-ghost {
|
||||
opacity: 0.4;
|
||||
cursor: grabbing;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .sortable-chosen {
|
||||
cursor: grabbing;
|
||||
padding: 18px 0 18px 18px;
|
||||
background-color: var(--color-base-10, --background-primary);
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .sortable-drag {
|
||||
cursor: grabbing;
|
||||
box-shadow: 0px 3px 32px rgb(31 38 135 / 15%);
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer {
|
||||
border-top: 1px solid var(--background-modifier-border);
|
||||
border-bottom: 1px solid var(--background-modifier-border);
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar CLASS CHANGES
|
||||
----------------------------------------------------------------*/
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarDefaultAesthetic {
|
||||
border: 1px solid var(--background-modifier-border);
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarDefaultAesthetic:not(.top) :is(.cMenuToolbarCommandItem, button[class^=cMenuToolbarCommandsubItem]) {
|
||||
min-height: 28px;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarDefaultAesthetic:not(.top) button[class^=cMenuToolbarCommandsubItem] {
|
||||
margin: auto;
|
||||
padding: 6px;
|
||||
box-shadow: none;
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
|
||||
place-items: center;
|
||||
|
||||
}
|
||||
|
||||
.cMenuToolbarDefaultAesthetic {
|
||||
background-color: var(--color-base-10, --background-primary);
|
||||
}
|
||||
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarGlassAesthetic,
|
||||
#cMenuToolbarModalBar.cMenuToolbarGlassAesthetic~#cMenuToolbarPopoverBar {
|
||||
backdrop-filter: blur(6px);
|
||||
-webkit-backdrop-filter: blur(6px);
|
||||
box-shadow: none;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarGlassAesthetic:not(.top) button[class^=cMenuToolbarCommandsubItem] {
|
||||
margin: auto;
|
||||
padding: 0px;
|
||||
box-shadow: none;
|
||||
border: none;
|
||||
display: flex;
|
||||
border-radius: var(--radius-s);
|
||||
font-size: 10px;
|
||||
margin-right: 0px;
|
||||
position: relative;
|
||||
background-color: transparent;
|
||||
place-items: center;
|
||||
clear: both;
|
||||
max-width: 28px;
|
||||
max-height: 23px;
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar ICONS
|
||||
----------------------------------------------------------------*/
|
||||
|
||||
.cMenuToolbarIconPick {
|
||||
line-height: normal;
|
||||
vertical-align: middle;
|
||||
margin-right: 8px;
|
||||
}
|
||||
|
||||
.cMenuToolbarIconPick svg {
|
||||
width: 17px;
|
||||
height: 17px;
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar STATUS BAR MENU
|
||||
----------------------------------------------------------------*/
|
||||
|
||||
.cMenuToolbar-statusbar-menu {
|
||||
text-align: center;
|
||||
width: 200px;
|
||||
}
|
||||
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item.settings-item {
|
||||
font-size: 12px;
|
||||
text-align: center;
|
||||
line-height: 1;
|
||||
border-radius: var(--radius-m);
|
||||
height: auto;
|
||||
padding: 8px 5px 0px 5px;
|
||||
margin: 0 auto;
|
||||
width: fit-content;
|
||||
color: var(--text-faint);
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item.settings-item .menu-item-title {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item:hover,
|
||||
.cMenuToolbar-statusbar-menu .menu-item .selected:hover,
|
||||
.cMenuToolbar-statusbar-menu .menu-item.selected:not(.is-disabled):not(.is-label) {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item-title {
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .slider {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item.buttonitem {
|
||||
padding-top: 10px;
|
||||
padding-bottom: 4px;
|
||||
height: fit-content;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item.buttonitem button.cMenuToolbarSettingsButton {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item-icon svg path {
|
||||
fill: var(--text-muted);
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu .menu-item-icon svg {
|
||||
stroke: var(--text-muted);
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu>.menu-item:is([data-section="ButtonAdd"]) {
|
||||
display: inline-flex;
|
||||
padding: 0px 0px 5px 5px;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu>.menu-item {
|
||||
display: inline-flex;
|
||||
padding: 0px 0px 5px 5px;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-menu>.menu-item:is([data-section="ButtonAdd"]) .menu-item-icon {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar STATUS BAR BUTTONS
|
||||
----------------------------------------------------------------*/
|
||||
|
||||
.cMenuToolbar-statusbar-button {
|
||||
cursor: default;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.cMenuToolbar-statusbar-button svg {
|
||||
display: flex;
|
||||
width: 1.3em;
|
||||
height: 1.3em;
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------
|
||||
cMenuToolbar SUPPORT
|
||||
---------------------------------------------`-------------------*/
|
||||
|
||||
.cDonationSection {
|
||||
width: 60%;
|
||||
height: 50vh;
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
color: var(--text-normal);
|
||||
}
|
||||
|
||||
|
||||
#cMenuToolbarModalBar {
|
||||
align-items: center;
|
||||
justify-items: center;
|
||||
border: none;
|
||||
backdrop-filter: none;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarGlassAesthetic .cMenuToolbarCommandItem {
|
||||
|
||||
background-color: #ffffff00;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarGlassAesthetic [class^=cMenuToolbarCommandsubItem] {
|
||||
|
||||
background-color: #ffffff00;
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar .cMenuToolbarCommandItem {
|
||||
justify-content: center;
|
||||
align-content: center;
|
||||
place-items: center;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* #cMenuToolbarModalBar.cMenuToolbarTinyAesthetic .cMenuToolbarCommandItem svg{
|
||||
width: 1em;
|
||||
height: 1em;
|
||||
} */
|
||||
|
||||
|
||||
|
||||
div.modal-container.cMenuToolbar-Modal:not(.changename) .modal-bg {
|
||||
background-color: transparent !important;
|
||||
backdrop-filter: none !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.modal-container.cMenuToolbar-Modal:not(.changename) .modal {
|
||||
padding: 10px 30px;
|
||||
min-width: 130px;
|
||||
position: absolute;
|
||||
bottom: 2em;
|
||||
right: 0.5em;
|
||||
background-color: rgb(var(--mono-rgb-0), 0.8);
|
||||
backdrop-filter: blur(4px);
|
||||
}
|
||||
|
||||
.modal-container.cMenuToolbar-Modal .modal-title {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.modal-container.cMenuToolbar-Modal .modal input[type='range'] {
|
||||
width: 90%;
|
||||
|
||||
}
|
||||
|
||||
body.theme-dark .modal-container.cMenuToolbar-Modal .modal input[type='range'] {
|
||||
background-color: var(--background-secondary);
|
||||
}
|
||||
|
||||
/*tiny 样式*/
|
||||
#cMenuToolbarModalBar.cMenuToolbarTinyAesthetic {
|
||||
align-items: center;
|
||||
justify-items: center;
|
||||
border: 1px solid var(--background-modifier-border-hover);
|
||||
backdrop-filter: none;
|
||||
background-color: var(--background-secondary);
|
||||
}
|
||||
|
||||
|
||||
#cMenuToolbarModalBar.cMenuToolbarTinyAesthetic .cMenuToolbarCommandItem {
|
||||
margin: auto;
|
||||
padding: 0px;
|
||||
box-shadow: none;
|
||||
margin-left: 0px;
|
||||
margin-right: 0px;
|
||||
position: relative;
|
||||
background-color: transparent;
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar .cMenuToolbarCommandItem {
|
||||
margin: auto;
|
||||
|
||||
padding: 0px;
|
||||
box-shadow: none;
|
||||
|
||||
margin-left: 4px;
|
||||
margin-right: 0px;
|
||||
position: relative;
|
||||
background-color: transparent;
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
|
||||
}
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar).cMenuToolbarTinyAesthetic:not(.top) button[class^=cMenuToolbarCommandsubItem] {
|
||||
margin: auto;
|
||||
padding: 0px;
|
||||
box-shadow: none;
|
||||
border: none;
|
||||
display: flex;
|
||||
border-radius: var(--radius-s);
|
||||
font-size: 10px;
|
||||
margin-right: 0px;
|
||||
position: relative;
|
||||
background-color: transparent;
|
||||
|
||||
place-items: center;
|
||||
clear: both;
|
||||
max-width: 28px;
|
||||
max-height: 18px;
|
||||
|
||||
}
|
||||
|
||||
button[class^=cMenuToolbarCommandsubItem]::after {
|
||||
|
||||
content: url("data:image/svg+xml,%3Csvg width='4' height='4' version='1.1' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1024 1024' enable-background='new 0 0 1024 1024' xml:space='preserve'%3E%3Cpath fill='%23666' d='M13.24 80.11 l461.75 560.8 q14.56 16.02 36.41 16.02 q21.85 0 36.42 -16.02 l463.2 -560.8 q10.2 -10.19 12.38 -24.75 q2.18 -14.57 -3.64 -27.68 q-5.82 -13.11 -18.21 -20.39 q-12.39 -7.29 -26.95 -7.29 l-924.95 0 q-20.4 0 -34.23 13.11 q-13.84 13.11 -15.29 32.77 q-1.46 19.66 13.11 34.23 Z'/%3E%3C/svg%3E");
|
||||
|
||||
margin-left: 1px;
|
||||
margin-top: 6px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem {
|
||||
background-color: var(--color-base-10, --background-primary);
|
||||
border-radius: var(--radius-s);
|
||||
border: 1px solid var(--background-modifier-border);
|
||||
|
||||
position: absolute;
|
||||
z-index: var(--layer-menu);
|
||||
user-select: none;
|
||||
transform: translateY(90%) translateX(0%);
|
||||
-webkit-transform: translateY(90%) translateX(0%);
|
||||
display: flex;
|
||||
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem svg {
|
||||
max-width: 1.3em;
|
||||
max-height: 1.3em;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem button.menu-item {
|
||||
background-color: transparent;
|
||||
line-height: 2em;
|
||||
display: inline-flex;
|
||||
box-shadow: none;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem .menu-item {
|
||||
margin-left: 2px;
|
||||
margin-right: 2px;
|
||||
padding: 0px 4px 0px 4px;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem {
|
||||
|
||||
visibility: hidden;
|
||||
transition: all 0.3s linear;
|
||||
-webkit-transition: all 0.3s linear;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbarCommandsubItem-font-color .triangle-icon {
|
||||
position: absolute;
|
||||
margin-left: 18px;
|
||||
bottom: 8%;
|
||||
background-size: 4px 4px;
|
||||
background-image: url("data:image/svg+xml,%3Csvg width='4' height='4' version='1.1' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1024 1024' enable-background='new 0 0 1024 1024' xml:space='preserve'%3E%3Cpath fill='%23666' d='M13.24 80.11 l461.75 560.8 q14.56 16.02 36.41 16.02 q21.85 0 36.42 -16.02 l463.2 -560.8 q10.2 -10.19 12.38 -24.75 q2.18 -14.57 -3.64 -27.68 q-5.82 -13.11 -18.21 -20.39 q-12.39 -7.29 -26.95 -7.29 l-924.95 0 q-20.4 0 -34.23 13.11 q-13.84 13.11 -15.29 32.77 q-1.46 19.66 13.11 34.23 Z'/%3E%3C/svg%3E");
|
||||
|
||||
width: 16px;
|
||||
height: 20px;
|
||||
background-position: center;
|
||||
|
||||
background-repeat: no-repeat;
|
||||
min-width: unset;
|
||||
border-left: 2px solid transparent;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar):not(.top) button.cMenuToolbarCommandsubItem-font-color .triangle-icon {
|
||||
margin-left: 16px;
|
||||
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar):not(.top) button.cMenuToolbarCommandsubItem-font-color .x-color-picker-wrapper {
|
||||
top: auto;
|
||||
bottom: calc(100%);
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar):not(.top) button[class^=cMenuToolbarCommandsubItem]:not(.cMenuToolbarSecond)>.subitem {
|
||||
bottom: calc(100% + 2.8em);
|
||||
}
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbarCommandsubItem-font-color .subitem {
|
||||
visibility: hidden;
|
||||
transition: all 0.3s linear;
|
||||
-webkit-transition: all 0.3s linear;
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbarCommandsubItem-font-color .subitem:hover {
|
||||
visibility: visible;
|
||||
transition: all 0.3s linear;
|
||||
-webkit-transition: all 0.3s linear;
|
||||
}
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]:hover>.subitem {
|
||||
|
||||
visibility: visible;
|
||||
transition: all 0.3s linear;
|
||||
-webkit-transition: all 0.3s linear;
|
||||
}
|
||||
|
||||
/* :is(#cMenuToolbarModalBar,#cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem] >.subitem:hover {
|
||||
visibility:visible;
|
||||
transition: all 0.3s linear;
|
||||
-webkit-transition: all 0.3s linear;
|
||||
} */
|
||||
|
||||
.cMenuToolbarCommandsubItem-font-color button {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarCommandItem .setting-item-info {
|
||||
|
||||
flex: 30%;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarSettingsTabsContainer_sub {
|
||||
border-left: 1px solid var(--background-modifier-border);
|
||||
flex-flow: column;
|
||||
min-height: 45px;
|
||||
display: flex;
|
||||
padding: 0;
|
||||
margin-left: 10px;
|
||||
flex: 70%;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarSettingsTabsContainer_sub:empty {
|
||||
border: 2px dashed rgba(var(--interactive-accent-rgb), 0.5);
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarSettingsTabsContainer_sub:empty::before {
|
||||
content: "✖️Drag it here";
|
||||
margin: auto;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarSettingsTabsContainer_sub .cMenuToolbarCommandItem {
|
||||
flex: auto;
|
||||
margin-left: 2em;
|
||||
;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarSettingsTabsContainer_sub .setting-item-control {
|
||||
flex: 0;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbarCommandSubItem>.setting-item-info {
|
||||
flex: 70px;
|
||||
}
|
||||
|
||||
.cMenuToolbarCommandSubItem>.setting-item-control {
|
||||
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsButton.cMenuToolbarSettingsButtonaddsub {
|
||||
background-color: var(--background-secondary-alt);
|
||||
}
|
||||
|
||||
|
||||
.setting-item button.cMenuToolbarSettingsIcon {
|
||||
display: block;
|
||||
transform: translateX(-30%);
|
||||
-webkit-transform: translateX(-30%);
|
||||
}
|
||||
|
||||
.setting-item button.cMenuToolbarSettingsIcon:empty::before {
|
||||
content: "❗";
|
||||
}
|
||||
|
||||
.setting-item button.cMenuToolbarSettingsIcon svg {
|
||||
max-width: 1.5em;
|
||||
max-height: 1.5em;
|
||||
}
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsIcon:hover {
|
||||
background-color: var(--interactive-accent-hover);
|
||||
}
|
||||
|
||||
.modal.mod-settings button:not(.mod-cta):not(.mod-warning).cMenuToolbarSettingsIcon {
|
||||
background-color: transparent;
|
||||
box-shadow: 0 1px 1px 0px var(--background-modifier-border);
|
||||
}
|
||||
|
||||
@media screen and (min-width: 781px) {
|
||||
.cMenuToolbar-Modal .wideInputPromptInputEl {
|
||||
width: 40rem;
|
||||
max-width: 100%;
|
||||
height: 20rem;
|
||||
background-color: rgb(var(--mono-rgb-0), 0.8);
|
||||
}
|
||||
}
|
||||
|
||||
.cMenuToolbarcustomIcon svg {
|
||||
max-width: 1.3em;
|
||||
max-height: 1.3em;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
|
||||
.cMenuToolbarSettingsButton svg {
|
||||
max-width: 1.3em;
|
||||
max-height: 1.3em;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.cmdr-page-header {
|
||||
min-width: 1em;
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
.x-color-picker-wrapper {
|
||||
right: 0px;
|
||||
top: 1.8em;
|
||||
min-width: 1px;
|
||||
padding: 10px;
|
||||
box-shadow: 0 8px 10px 1px rgba(0, 0, 0, 0.14);
|
||||
position: absolute;
|
||||
width: fit-content;
|
||||
font-weight: 400;
|
||||
font-family: Source Sans Pro, sans-serif;
|
||||
border-radius: var(--radius-s);
|
||||
background-color: var(--color-base-10, --background-primary);
|
||||
}
|
||||
|
||||
.markdown-source-view.mod-cm6 .x-color-picker-wrapper table.x-color-picker-table#x-color-picker-table {
|
||||
width: unset;
|
||||
border-collapse: separate;
|
||||
border-spacing: 6px;
|
||||
margin: auto !important;
|
||||
}
|
||||
|
||||
.x-color-picker-wrapper table.x-color-picker-table#x-backgroundcolor-picker-table {
|
||||
width: unset;
|
||||
border-collapse: separate;
|
||||
border-spacing: 6px;
|
||||
margin: auto !important;
|
||||
}
|
||||
|
||||
.x-color-picker-wrapper .x-color-picker-table th {
|
||||
border: 0;
|
||||
text-align: left;
|
||||
font-weight: normal;
|
||||
background: transparent !important;
|
||||
color: #718096;
|
||||
}
|
||||
|
||||
.x-color-picker-wrapper #x-color-picker-table td {
|
||||
font-size: 1px;
|
||||
padding: 9px;
|
||||
cursor: default;
|
||||
border: solid 1px var(--background-modifier-border);
|
||||
}
|
||||
|
||||
.x-color-picker-wrapper #x-backgroundcolor-picker-table td {
|
||||
font-size: 1px;
|
||||
border-radius: 50%;
|
||||
padding: 9px;
|
||||
cursor: default;
|
||||
border: solid 1px var(--background-modifier-border);
|
||||
}
|
||||
|
||||
.x-color-picker-wrapper .x-color-picker-table tr td:hover {
|
||||
filter: brightness(1.2);
|
||||
box-shadow: 0 3px 6px -4px rgba(0, 0, 0, .12), 0 6px 16px 0 rgba(0, 0, 0, .08), 0 9px 28px 8px rgba(0, 0, 0, .05);
|
||||
}
|
||||
|
||||
/* .x-color-picker-wrapper tbody>tr:hover {
|
||||
background-color: transparent !important;
|
||||
} */
|
||||
|
||||
/**top**/
|
||||
#cMenuToolbarModalBar.top {
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
position: relative;
|
||||
height: 38px;
|
||||
align-items: center;
|
||||
transition: all 0.2s linear;
|
||||
-webkit-transition: all 0.2s linear;
|
||||
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar.top.autohide {
|
||||
opacity: 0;
|
||||
transition: all 0.5s linear;
|
||||
-webkit-transition: all 0.5s linear;
|
||||
}
|
||||
|
||||
|
||||
#cMenuToolbarModalBar.top.autohide:hover {
|
||||
opacity: 1;
|
||||
transition: all 1s linear;
|
||||
-webkit-transition: all 1s linear;
|
||||
}
|
||||
|
||||
|
||||
#cMenuToolbarModalBar.top :is(.cMenuToolbarCommandItem, button[class^=cMenuToolbarCommandsubItem]):not(.cMenuToolbar-Divider-Line) {
|
||||
font-size: 10px;
|
||||
margin-right: 0px;
|
||||
clear: both;
|
||||
opacity: 1;
|
||||
flex-shrink: 0;
|
||||
height: 26px;
|
||||
padding: 0;
|
||||
border: none;
|
||||
background: transparent;
|
||||
cursor: default;
|
||||
outline: none;
|
||||
box-shadow: none;
|
||||
border-radius: var(--radius-s);
|
||||
display: inline-flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
transition: all 0.2s linear;
|
||||
-webkit-transition: all 0.2s linear;
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/* #cMenuToolbarModalBar.top button.cMenuToolbarCommandItem:hover {
|
||||
background-color: var(--interactive-hover);
|
||||
} */
|
||||
|
||||
|
||||
|
||||
#cMenuToolbarPopoverBar {
|
||||
|
||||
padding: 0 10px;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
width: fit-content;
|
||||
z-index: var(--layer-popover);
|
||||
background-color: var(--color-base-10, --background-primary);
|
||||
background-clip: padding-box;
|
||||
border-radius: var(--radius-m);
|
||||
|
||||
margin-left: auto;
|
||||
margin-right: 25px;
|
||||
transition: all 0.1s linear;
|
||||
-webkit-transition: all 0.1s linear;
|
||||
margin-top: 32px;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
#cMenuToolbarPopoverBar :is(.cMenuToolbarCommandItem, button[class^=cMenuToolbarCommandsubItem]) {
|
||||
|
||||
height: 26px;
|
||||
margin-left: 4px;
|
||||
font-size: 10px;
|
||||
margin-right: 4px;
|
||||
clear: both;
|
||||
opacity: 1;
|
||||
flex-shrink: 0;
|
||||
height: 26px;
|
||||
padding: 0;
|
||||
border: none;
|
||||
background: transparent;
|
||||
cursor: default;
|
||||
outline: none;
|
||||
box-shadow: none;
|
||||
border-radius: var(--radius-s);
|
||||
display: inline-flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
transition: all 0.2s linear;
|
||||
-webkit-transition: all 0.2s linear;
|
||||
|
||||
}
|
||||
|
||||
#cMenuToolbarModalBar .more-menu {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
box-shadow: none;
|
||||
margin-left: 4px;
|
||||
border-left: 1px inset var(--background-modifier-form-field);
|
||||
height: 24px;
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
/*Divider-Line**/
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line {
|
||||
padding: 0;
|
||||
|
||||
line-height: 0px;
|
||||
border-left: 200px solid rgba(var(--interactive-accent-rgb), 0.05);
|
||||
border-right: 200px solid rgba(var(--interactive-accent-rgb), 0.05);
|
||||
text-align: center;
|
||||
background: rgba(var(--interactive-accent-rgb), 0.2);
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-control button:not(:last-child) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-info {
|
||||
flex: 1 1 auto;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-control {
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-info .setting-item-name {
|
||||
font-size: 12px;
|
||||
text-align: right;
|
||||
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-control button:last-child {
|
||||
padding: 0;
|
||||
background-color: transparent !important;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-control button:last-child svg {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.cMenuToolbarSettingsTabsContainer .cMenuToolbar-Divider-Line .setting-item-control button:last-child::before {
|
||||
content: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 1024 1024' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M511.674077 66.707284c-246.52265 0-446.347744 199.835328-446.347744 446.347744s199.825095 446.356954 446.347744 446.356954c246.50423 0 446.348768-199.844537 446.348768-446.356954S758.177284 66.707284 511.674077 66.707284zM744.967424 667.159826c21.8701 21.8701 21.8701 57.310264 0 79.199807-21.8701 21.851681-57.30924 21.851681-79.198783-0.019443L511.674077 592.264045 357.56007 746.359632c-21.8701 21.8701-57.30924 21.851681-79.17934-0.019443s-21.8701-57.290821 0-79.160921L432.493713 513.065262 278.379707 358.950232c-21.8701-21.86089-21.8701-57.328683 0-79.18855 21.8701-21.87931 57.30924-21.87931 79.17934 0l154.114007 154.104797 154.095587-154.104797c21.889543-21.87931 57.32766-21.87931 79.198783-0.010233 21.8701 21.8701 21.8701 57.348126 0 79.207993L590.89128 513.065262 744.967424 667.159826z' fill='%23666666'/%3E%3C/svg%3E");
|
||||
}
|
||||
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbar-Divider-Line
|
||||
{
|
||||
min-width: unset;
|
||||
flex-shrink: 0;
|
||||
display: inline-flex;
|
||||
width: 0.6px;
|
||||
background-color: var(--background-modifier-border);
|
||||
height: 22px;
|
||||
opacity: 0.8;
|
||||
margin: 0;
|
||||
}
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button[class^=cMenuToolbarCommandsubItem]>.subitem button.menu-item.cMenuToolbar-Divider-Line
|
||||
{ min-width: unset;
|
||||
flex-shrink: 0;
|
||||
display: inline-flex;
|
||||
width: 0.6px;
|
||||
background-color: var(--background-modifier-border);
|
||||
height: 22px;
|
||||
opacity: 0.8;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
height: auto;
|
||||
|
||||
}
|
||||
|
||||
.theme-dark :is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbar-Divider-Line {
|
||||
|
||||
background-color: #4f4f5188;
|
||||
|
||||
}
|
||||
|
||||
:is(#cMenuToolbarModalBar, #cMenuToolbarPopoverBar) button.cMenuToolbar-Divider-Line svg {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.workspace-tabs.mod-stacked .workspace-tab-header:not(.is-active)+.workspace-leaf #cMenuToolbarModalBar {
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
:is(.cm-line, p) span[style^="background:rgba"] {
|
||||
color: var(--text-normal);
|
||||
}
|
||||
|
||||
:is(.cm-line, p) span[style^="background:#"] {
|
||||
color: black;
|
||||
}
|
||||
|
||||
.setting-item.toolbar-cta:after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
top: -10%;
|
||||
width: 104%;
|
||||
left: -2%;
|
||||
height: 120%;
|
||||
outline: 2px solid var(--text-accent);
|
||||
border-radius: 1em;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.setting-item.toolbar-cta {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.toolbar-pickr .pcr-last-color,
|
||||
.pickr .pcr-button{
|
||||
background-color: var(--pcr-color);
|
||||
}
|
||||
.toolbar-pickr .pcr-interaction :not(:is(input.pcr-save,.pcr-result)){
|
||||
display:none;
|
||||
}
|
||||
.toolbar-pickr .pcr-swatches {
|
||||
display:none;
|
||||
}
|
||||
.toolbar-pickr {
|
||||
display:flex;
|
||||
}
|
||||
|
||||
|
||||
div[data-type="thino_view"] .memo-editor-wrapper:has(#cMenuToolbarModalBar)
|
||||
{
|
||||
padding-top:0;
|
||||
padding-left:0;
|
||||
padding-right:0;
|
||||
}
|
||||
|
||||
div[data-type="thino_view"] .memo-editor-wrapper:has(#cMenuToolbarModalBar) .common-tools-wrapper
|
||||
{
|
||||
padding-left:16px;
|
||||
padding-right:16px;
|
||||
}
|
||||
div[data-type="thino_view"] .memo-editor-wrapper #cMenuToolbarModalBar ~ .cm-editor{
|
||||
padding-top:38px;
|
||||
padding-bottom:0px;
|
||||
padding-left:16px;
|
||||
padding-right:16px;
|
||||
}
|
||||
div[data-type=thino_view] .common-editor-wrapper .common-editor-inputer:has(#cMenuToolbarModalBar)
|
||||
{
|
||||
min-height:118px;
|
||||
}
|
||||
|
||||
div[data-type=thino_view] #cMenuToolbarModalBar.top
|
||||
{
|
||||
position:absolute!important;
|
||||
width: 100%;
|
||||
}
|
||||
body.auto-hide-header .workspace-tab-header-container:hover + .workspace-tab-container .workspace-leaf .workspace-leaf-content>.view-header {
|
||||
margin-top: 0;
|
||||
transition: all 0.1s linear;
|
||||
}
|
||||
|
||||
body.auto-hide-header .workspace-tab-header-container + .workspace-tab-container .workspace-leaf .workspace-leaf-content>.view-header:hover {
|
||||
margin-top: 0;
|
||||
transition: all 0.6s linear;
|
||||
}
|
||||
body.auto-hide-header .workspace-tab-header-container + .workspace-tab-container .workspace-leaf .workspace-leaf-content>.view-header {
|
||||
margin-top: -40px;
|
||||
transition: all 0.6s linear;
|
||||
}
|
17
.obsidian/plugins/link-favicon/data.json
vendored
17
.obsidian/plugins/link-favicon/data.json
vendored
|
@ -1,17 +0,0 @@
|
|||
{
|
||||
"provider": "duckduckgo",
|
||||
"fallbackProvider": "google",
|
||||
"providerDomain": "",
|
||||
"fallbackProviderDomain": "",
|
||||
"ignored": "",
|
||||
"overwritten": [],
|
||||
"protocol": [],
|
||||
"showAliased": true,
|
||||
"showLink": true,
|
||||
"enableReading": true,
|
||||
"enableSource": true,
|
||||
"enableLivePreview": true,
|
||||
"debounce": 500,
|
||||
"iconPosition": "front",
|
||||
"colorInversion": true
|
||||
}
|
12
.obsidian/plugins/link-favicon/main.js
vendored
12
.obsidian/plugins/link-favicon/main.js
vendored
File diff suppressed because one or more lines are too long
10
.obsidian/plugins/link-favicon/manifest.json
vendored
10
.obsidian/plugins/link-favicon/manifest.json
vendored
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "link-favicon",
|
||||
"name": "Link Favicons",
|
||||
"version": "1.8.4",
|
||||
"minAppVersion": "1.3.0",
|
||||
"description": "See the favicon for a linked website. ",
|
||||
"author": "Johannes Theiner",
|
||||
"authorUrl": "https://github.com/joethei",
|
||||
"isDesktopOnly": false
|
||||
}
|
7
.obsidian/plugins/link-favicon/styles.css
vendored
7
.obsidian/plugins/link-favicon/styles.css
vendored
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
|
||||
if you want to view the source, please visit the github repository of this plugin
|
||||
https://github.com/joethei/obisidian-link-favicon
|
||||
*/
|
||||
|
||||
.link-favicon{cursor:pointer!important;image-rendering:-webkit-optimize-contrast;margin-bottom:.3em;margin-left:.1em;margin-right:.1em;max-height:1em;vertical-align:bottom}.link-favicon-preview{font-size:50px;text-align:center}.link-favicon-preview img{height:50px}.link-favicon[data-color-inversion=true][data-is-readable-a-a=false]{filter:hue-rotate(180deg) invert(1)}.link-favicon-scrollable-content{height:60vh;overflow:auto}
|
|
@ -1 +0,0 @@
|
|||
{}
|
|
@ -1,74 +0,0 @@
|
|||
{
|
||||
"getLangFromFile": true,
|
||||
"defaultLanguage": "en_US",
|
||||
"normalLang": "en_US",
|
||||
"shouldShowSynonymPopover": true,
|
||||
"shouldShowCustomContextMenu": false,
|
||||
"apiSettings": {
|
||||
"en_US": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": "Free Dictionary API"
|
||||
},
|
||||
"hi": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"es": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": "Altervista"
|
||||
},
|
||||
"fr": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": "Altervista"
|
||||
},
|
||||
"ja": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"ru": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"en_GB": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"de": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": "Open Thesaurus"
|
||||
},
|
||||
"it": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": "Altervista"
|
||||
},
|
||||
"ko": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"pt_BR": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"ar": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"tr": {
|
||||
"definitionApiName": "Free Dictionary API",
|
||||
"synonymApiName": null
|
||||
},
|
||||
"cn": {
|
||||
"definitionApiName": "Offline Dictionary",
|
||||
"synonymApiName": null
|
||||
}
|
||||
},
|
||||
"partOfSpeechApiName": "Systran API",
|
||||
"advancedSynonymAnalysis": false,
|
||||
"useCaching": false,
|
||||
"folder": "",
|
||||
"capitalizedFileName": true,
|
||||
"prefix": "",
|
||||
"suffix": " ({{lang}})",
|
||||
"template": "---\n# {{notice}}\naliases: [\"{{word}}\"]\n---\n\n# {{word}}\n\n## {{pronunciationHeader}}\n\n{{phoneticList}}\n\n## {{meaningHeader}}\n\n{{meanings}}\n\n## {{originHeader}}\n\n{{origin}}\n",
|
||||
"languageSpecificSubFolders": false
|
||||
}
|
File diff suppressed because one or more lines are too long
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-dictionary-plugin",
|
||||
"name": "Dictionary",
|
||||
"version": "2.22.0",
|
||||
"minAppVersion": "0.12.11",
|
||||
"description": "This is a simple dictionary for the Obsidian Note-Taking Tool.",
|
||||
"author": "phibr0",
|
||||
"authorUrl": "https://github.com/phibr0",
|
||||
"isDesktopOnly": false
|
||||
}
|
|
@ -1,36 +0,0 @@
|
|||
.setting-item.extra > .setting-item-info {
|
||||
opacity: 0.65;
|
||||
}
|
||||
|
||||
a[href="https://ko-fi.com/phibr0"] > img
|
||||
{
|
||||
height: 3em;
|
||||
}
|
||||
|
||||
a[href="https://ko-fi.com/phibr0"]
|
||||
{
|
||||
transform: translate(0, 5%);
|
||||
}
|
||||
|
||||
.dictionaryprefixsuffix .setting-item-control input {
|
||||
margin-left: 0.5rem;
|
||||
}
|
||||
|
||||
.dictionarytextarea .setting-item-control textarea {
|
||||
height: 15em;
|
||||
width: 100%;
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
.dictionarycenter {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.dictionarybuttons {
|
||||
display: flex;
|
||||
place-content: center;
|
||||
}
|
||||
|
||||
.dictionary-view-content {
|
||||
overflow-y: hidden !important;
|
||||
}
|
40
.obsidian/plugins/obsidian-icon-folder/data.json
vendored
40
.obsidian/plugins/obsidian-icon-folder/data.json
vendored
|
@ -1,40 +0,0 @@
|
|||
{
|
||||
"settings": {
|
||||
"migrated": 6,
|
||||
"iconPacksPath": ".obsidian/icons",
|
||||
"fontSize": 16,
|
||||
"emojiStyle": "native",
|
||||
"iconColor": null,
|
||||
"recentlyUsedIcons": [
|
||||
"📋",
|
||||
"🖊",
|
||||
"🖇",
|
||||
"📎",
|
||||
"📑"
|
||||
],
|
||||
"recentlyUsedIconsSize": 5,
|
||||
"rules": [],
|
||||
"extraMargin": {
|
||||
"top": 0,
|
||||
"right": 4,
|
||||
"bottom": 0,
|
||||
"left": 0
|
||||
},
|
||||
"iconInTabsEnabled": true,
|
||||
"iconInTitleEnabled": true,
|
||||
"iconInTitlePosition": "inline",
|
||||
"iconInFrontmatterEnabled": false,
|
||||
"iconInFrontmatterFieldName": "icon",
|
||||
"iconColorInFrontmatterFieldName": "iconColor",
|
||||
"iconsBackgroundCheckEnabled": false,
|
||||
"iconsInNotesEnabled": true,
|
||||
"iconsInLinksEnabled": true,
|
||||
"iconIdentifier": ":",
|
||||
"lucideIconPackType": "native",
|
||||
"debugMode": false
|
||||
},
|
||||
"00 Index": "🗃",
|
||||
"01 Appendix": "📑",
|
||||
"03 Attachments": "🗂",
|
||||
"02 Templates": "📋"
|
||||
}
|
7118
.obsidian/plugins/obsidian-icon-folder/main.js
vendored
7118
.obsidian/plugins/obsidian-icon-folder/main.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-icon-folder",
|
||||
"name": "Iconize",
|
||||
"version": "2.14.4",
|
||||
"minAppVersion": "0.9.12",
|
||||
"description": "Add icons to anything you desire in Obsidian, including files, folders, and text.",
|
||||
"author": "Florian Woelki",
|
||||
"authorUrl": "https://florianwoelki.com/",
|
||||
"isDesktopOnly": false
|
||||
}
|
119
.obsidian/plugins/obsidian-icon-folder/styles.css
vendored
119
.obsidian/plugins/obsidian-icon-folder/styles.css
vendored
|
@ -1,119 +0,0 @@
|
|||
.iconize-inline-title-wrapper {
|
||||
width: var(--line-width);
|
||||
margin-inline: var(--content-margin);
|
||||
}
|
||||
|
||||
.iconize-title-icon {
|
||||
max-width: var(--max-width);
|
||||
margin-right: var(--size-4-2);
|
||||
}
|
||||
|
||||
.iconize-icon-in-link {
|
||||
transform: translateY(20%);
|
||||
margin-right: var(--size-2-2);
|
||||
display: inline-flex;
|
||||
}
|
||||
|
||||
.iconize-icon {
|
||||
border: 1px solid transparent;
|
||||
margin: 0px 4px 0px 0px;
|
||||
display: flex;
|
||||
align-self: center;
|
||||
margin: auto 0;
|
||||
}
|
||||
|
||||
.nav-folder-title,
|
||||
.nav-file-title {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.iconize-setting input[type='color'] {
|
||||
margin: 0 6px;
|
||||
}
|
||||
|
||||
.iconize-modal.prompt-results {
|
||||
margin: 0;
|
||||
overflow-y: auto;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
.prompt .iconize-subheadline {
|
||||
margin-top: 12px;
|
||||
font-size: 12px;
|
||||
color: gray;
|
||||
grid-column-start: 1;
|
||||
grid-column-end: 6;
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
.iconize-modal.prompt-results {
|
||||
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||
}
|
||||
.prompt .iconize-subheadline {
|
||||
grid-column-end: 4;
|
||||
}
|
||||
}
|
||||
|
||||
.iconize-modal.prompt-results .suggestion-item {
|
||||
cursor: pointer;
|
||||
white-space: pre-wrap;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
align-items: center;
|
||||
flex-direction: column-reverse;
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
color: var(--text-muted);
|
||||
padding: 16px 8px;
|
||||
line-break: auto;
|
||||
word-break: break-word;
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
.iconize-modal.prompt-results .suggestion-item.suggestion-item__center {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.iconize-icon-preview {
|
||||
font-size: 22px;
|
||||
}
|
||||
|
||||
.iconize-icon-preview img {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
|
||||
.iconize-icon-preview svg {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
color: currentColor;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.iconize-dragover {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.iconize-dragover-el {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
color: var(--text-normal);
|
||||
background-color: var(--background-secondary-alt);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
/* Custom rule modal. */
|
||||
.iconize-custom-modal .modal-content {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.iconize-custom-modal .modal-content input {
|
||||
width: 100%;
|
||||
margin-right: 0.5rem;
|
||||
}
|
153
.obsidian/plugins/obsidian-kanban/main.js
vendored
153
.obsidian/plugins/obsidian-kanban/main.js
vendored
File diff suppressed because one or more lines are too long
11
.obsidian/plugins/obsidian-kanban/manifest.json
vendored
11
.obsidian/plugins/obsidian-kanban/manifest.json
vendored
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-kanban",
|
||||
"name": "Kanban",
|
||||
"version": "2.0.51",
|
||||
"minAppVersion": "1.0.0",
|
||||
"description": "Create markdown-backed Kanban boards in Obsidian.",
|
||||
"author": "mgmeyers",
|
||||
"authorUrl": "https://github.com/mgmeyers/obsidian-kanban",
|
||||
"helpUrl": "https://publish.obsidian.md/kanban/Obsidian+Kanban+Plugin",
|
||||
"isDesktopOnly": false
|
||||
}
|
1
.obsidian/plugins/obsidian-kanban/styles.css
vendored
1
.obsidian/plugins/obsidian-kanban/styles.css
vendored
File diff suppressed because one or more lines are too long
|
@ -1,53 +0,0 @@
|
|||
{
|
||||
"triggerChar": "\\",
|
||||
"sidePaneSideLeft": false,
|
||||
"savedColors": [
|
||||
"#ff0000"
|
||||
],
|
||||
"aviabileRegions": [
|
||||
"textEdit",
|
||||
"tabels",
|
||||
"html",
|
||||
"latex",
|
||||
"greekLetters",
|
||||
"colors",
|
||||
"callouts"
|
||||
],
|
||||
"regionSettings": [
|
||||
{
|
||||
"name": "textEdit",
|
||||
"active": true,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "tables",
|
||||
"active": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "html",
|
||||
"active": true,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "latex",
|
||||
"active": true,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "greekLetters",
|
||||
"active": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "colors",
|
||||
"active": false,
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"name": "callouts",
|
||||
"active": true,
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
File diff suppressed because it is too large
Load diff
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-markdown-formatting-assistant-plugin",
|
||||
"name": "Markdown Formatting Assistant",
|
||||
"version": "0.4.1",
|
||||
"minAppVersion": "0.15.6",
|
||||
"description": "This Plugin provides a simple Editor for Markdown, HTML and Colors and in addition a command interface. The command interface facilitate a faster workflow.",
|
||||
"author": "Reocin",
|
||||
"authorUrl": "https://github.com/Reocin/obsidian-markdown-formatting-assistant-plugin",
|
||||
"isDesktopOnly": false
|
||||
}
|
|
@ -1,62 +0,0 @@
|
|||
/* Sets all the text color to red! */
|
||||
.nav-action-button {
|
||||
color: var(--text-muted);
|
||||
cursor: pointer;
|
||||
padding: 0px;
|
||||
margin: 5px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.nav-action-text-button {
|
||||
color: var(--text-muted);
|
||||
cursor: pointer;
|
||||
padding: 5px;
|
||||
margin: 4px;
|
||||
border-radius: 4px;
|
||||
text-align: center;
|
||||
border: 1px solid;
|
||||
}
|
||||
.nav-action-text-button.is-active {
|
||||
background-color: var(--interactive-accent);
|
||||
color: var(--text-on-accent);
|
||||
}
|
||||
.nav-action-text-button.is-active:hover {
|
||||
color: var(--text-on-accent);
|
||||
}
|
||||
.nav-action-text-button:hover {
|
||||
color: var(--text-accent);
|
||||
}
|
||||
|
||||
.color-icon {
|
||||
color: var(--text-muted);
|
||||
cursor: pointer;
|
||||
width: 16px;
|
||||
min-width: 16px;
|
||||
max-width: 16px;
|
||||
height: 16px;
|
||||
min-height: 16px;
|
||||
max-height: 16px;
|
||||
margin: 3px;
|
||||
display: inline-block;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.command-list-view-row {
|
||||
display: flex;
|
||||
}
|
||||
.command-list-view-container {
|
||||
min-width: 60px;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.command-list-view-icon {
|
||||
height: 24px;
|
||||
max-height: 24px;
|
||||
border: 1px solid gray;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
.command-list-view-text {
|
||||
padding-left: 12px;
|
||||
color: #c7254e;
|
||||
}
|
|
@ -1,54 +0,0 @@
|
|||
{
|
||||
"anuppuccin-theme-settings-extended@@anp-theme-ext-dark": true,
|
||||
"anuppuccin-theme-settings@@anp-active-line": "anp-current-line-border",
|
||||
"anuppuccin-theme-settings@@anp-callout-select": "anp-callout-sleek",
|
||||
"anuppuccin-theme-settings@@anp-callout-color-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-callout-fold-position": "1",
|
||||
"anuppuccin-theme-settings@@anp-custom-checkboxes": true,
|
||||
"anuppuccin-theme-settings@@anp-speech-bubble": true,
|
||||
"anuppuccin-theme-settings@@anp-codeblock-numbers": true,
|
||||
"anuppuccin-theme-settings@@anp-list-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-table-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-table-width": true,
|
||||
"anuppuccin-theme-settings@@anp-table-th-highlight": true,
|
||||
"anuppuccin-theme-settings@@anp-td-highlight": "anp-table-row-alt",
|
||||
"anuppuccin-theme-settings@@anp-table-align-td": "left",
|
||||
"anuppuccin-theme-settings@@anp-toggle-preview": true,
|
||||
"anuppuccin-theme-settings@@anp-toggle-scrollbars": true,
|
||||
"anuppuccin-theme-settings@@bold-weight": "700",
|
||||
"anuppuccin-theme-settings@@anp-header-color-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-header-margin-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-header-divider-color-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-h3-color-custom": "anp-h3-yellow",
|
||||
"anuppuccin-theme-settings@@anp-h2-color-custom": "anp-h2-maroon",
|
||||
"anuppuccin-theme-settings@@anp-h4-color-custom": "anp-h4-green",
|
||||
"anuppuccin-theme-settings@@anp-h5-color-custom": "anp-h5-sapphire",
|
||||
"anuppuccin-theme-settings@@anp-h6-color-custom": "anp-h6-mauve",
|
||||
"anuppuccin-theme-settings@@anp-decoration-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-canvas-dark-bg": true,
|
||||
"anuppuccin-theme-settings@@anp-file-icons": true,
|
||||
"anuppuccin-theme-settings@@anp-collapse-folders": false,
|
||||
"anuppuccin-theme-settings@@anp-pdf-blend-toggle-dark": true,
|
||||
"anuppuccin-theme-settings@@anp-alt-rainbow-style": "anp-simple-rainbow-color-toggle",
|
||||
"anuppuccin-theme-settings@@anp-full-rainbow-text-color-toggle-dark": false,
|
||||
"anuppuccin-theme-settings@@anp-full-rainbow-text-color-toggle-light": false,
|
||||
"anuppuccin-theme-settings@@anp-alt-tab-style": "anp-alternate-tab-toggle",
|
||||
"anuppuccin-theme-settings@@anp-layout-select": "anp-card-layout",
|
||||
"anuppuccin-theme-settings@@anp-hide-borders": false,
|
||||
"anuppuccin-theme-settings@@anp-card-layout-actions": true,
|
||||
"anuppuccin-theme-settings@@anp-card-layout-filebrowser": true,
|
||||
"checkbox@@check-color": true,
|
||||
"anuppuccin-theme-settings@@anuppuccin-theme-accents": "ctp-accent-maroon",
|
||||
"anuppuccin-theme-settings@@anp-simple-rainbow-title-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-simple-rainbow-collapse-icon-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-simple-rainbow-indentation-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-simple-rainbow-icon-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-rainbow-subfolder-color-toggle": true,
|
||||
"anuppuccin-theme-settings@@anp-h1-divider": true,
|
||||
"anuppuccin-theme-settings@@anp-h2-divider": true,
|
||||
"anuppuccin-theme-settings@@anp-h3-divider": true,
|
||||
"anuppuccin-theme-settings@@anp-h4-divider": true,
|
||||
"anuppuccin-theme-settings@@anp-h5-divider": true,
|
||||
"anuppuccin-theme-settings@@anp-h6-divider": true,
|
||||
"anuppuccin-theme-settings-extended@@catppuccin-theme-dark-extended": "ctp-rosepine-dark"
|
||||
}
|
165
.obsidian/plugins/obsidian-style-settings/main.js
vendored
165
.obsidian/plugins/obsidian-style-settings/main.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-style-settings",
|
||||
"name": "Style Settings",
|
||||
"version": "1.0.9",
|
||||
"minAppVersion": "0.11.5",
|
||||
"description": "Offers controls for adjusting theme, plugin, and snippet CSS variables.",
|
||||
"author": "mgmeyers",
|
||||
"authorUrl": "https://github.com/mgmeyers/obsidian-style-settings",
|
||||
"isDesktopOnly": false
|
||||
}
|
243
.obsidian/plugins/obsidian-style-settings/styles.css
vendored
243
.obsidian/plugins/obsidian-style-settings/styles.css
vendored
File diff suppressed because one or more lines are too long
2492
.obsidian/plugins/obsidian-textgenerator-plugin/main.js
vendored
2492
.obsidian/plugins/obsidian-textgenerator-plugin/main.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "obsidian-textgenerator-plugin",
|
||||
"name": "Text Generator",
|
||||
"version": "0.7.42",
|
||||
"minAppVersion": "1.6.0",
|
||||
"description": "Text generation using AI",
|
||||
"author": "Noureddine Haouari",
|
||||
"authorUrl": "https://text-gen.com",
|
||||
"isDesktopOnly": false,
|
||||
"fundingUrl": "https://www.buymeacoffee.com/haouarine"
|
||||
}
|
File diff suppressed because it is too large
Load diff
12
.obsidian/plugins/tab-panels/main.js
vendored
12
.obsidian/plugins/tab-panels/main.js
vendored
|
@ -1,12 +0,0 @@
|
|||
/*
|
||||
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
|
||||
if you want to view the source, please visit the github repository of this plugin
|
||||
*/
|
||||
|
||||
var S=Object.defineProperty;var D=Object.getOwnPropertyDescriptor;var H=Object.getOwnPropertyNames;var A=Object.prototype.hasOwnProperty;var G=(c,t)=>{for(var e in t)S(c,e,{get:t[e],enumerable:!0})},W=(c,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of H(t))!A.call(c,s)&&s!==e&&S(c,s,{get:()=>t[s],enumerable:!(n=D(t,s))||n.enumerable});return c};var B=c=>W(S({},"__esModule",{value:!0}),c);var F={};G(F,{default:()=>f});module.exports=B(F);var v=require("obsidian");var d=require("obsidian"),y={codeblockKeyword:"tab-panels",hideNoTabWarning:!1,highlightSelectedTabName:!0},m=class extends d.PluginSettingTab{constructor(e,n){super(e,n);this.plugin=n}display(){let{containerEl:e}=this,n=this.plugin.settings;e.empty(),new d.Setting(e).setName("Codeblock keyword").addText(i=>i.setValue(n.codeblockKeyword).setPlaceholder("tab-panels").onChange(async l=>{n.codeblockKeyword=l,await this.plugin.saveSettings()})),new d.Setting(e).setName("Hide no tab warning").addToggle(i=>i.setValue(n.hideNoTabWarning).onChange(async l=>{n.hideNoTabWarning=l,await this.plugin.saveSettings()})),new d.Setting(e).setHeading().setName("Styling"),new d.Setting(e).setName("Highlight selected tab name").addToggle(i=>i.setValue(n.highlightSelectedTabName).onChange(async l=>{n.highlightSelectedTabName=l,await this.plugin.saveSettings()}));let s=new DocumentFragment;s.appendText("Reload the app to apply changes"),s.appendChild(createEl("br")),s.appendChild(createEl("br")),s.appendText("Found bugs or want a feature? "),s.appendChild(createEl("a",{text:"Create a GitHub issue!",href:"https://github.com/GnoxNahte/obsidian-tab-panels/issues/new"})),new d.Setting(e).setDesc(s)}};var h=require("obsidian"),T=class{constructor(t){this.plugin=t}create(t,e,n){e.classList.add("tab-panel-container"),this.plugin.settings.highlightSelectedTabName&&e.classList.add("highlight-selected-tab-name");let s=createEl("div",{cls:"tab-scroll-container",parent:e}),i=createEl("ul",{cls:"tab-container",parent:s}),l=createDiv({cls:"content-container",parent:e}),r=Array.from(t.matchAll(/^[^\S\r\n]*---[^\S\r\n]*(.*)/gm));if(r.length===0){s.classList.add("hide-container");let o=createDiv({parent:l,cls:"selected"});if(h.MarkdownRenderer.render(this.plugin.app,t,o,n.sourcePath,this.plugin),!this.plugin.settings.hideNoTabWarning){let a=`> [!WARNING] No tabs created
|
||||
> To create tabs, use \`--- Tab Name\`.
|
||||
>For more info: [GitHub README](https://github.com/GnoxNahte/obsidian-tab-panels)
|
||||
>To hide this popup: Settings > Hide no tab warning`;h.MarkdownRenderer.render(this.plugin.app,a,o,n.sourcePath,this.plugin)}return}let g=0,p=-1;for(let o=0;o<r.length;o++){++p;let a=r[o][1],u=a.match(/\(default\)\s*$/i);u&&(g=p,a=a.substring(0,u.index));let E=createEl("li",{cls:"tab",parent:i}),C=p;E.addEventListener("click",()=>this.switchTab(C,i,l)),h.MarkdownRenderer.render(this.plugin.app,a,E,n.sourcePath,this.plugin);let N=b=>{var L;let x=o<r.length-1?r[o+1].index:t.length,P=t.substring((L=r[o].index)!=null?L:0,x);return b?P.substring(P.indexOf(`
|
||||
`)):P},w=N(!0),k=0;do{++k;let b=w.match(/^ *~{3}|`{3}/gm);if(b!==null&&b.length%2===1&&o+1<r.length){++o,w+=N(!1);continue}else break}while(k<20);let M=createDiv({parent:l});h.MarkdownRenderer.render(this.plugin.app,w,M,n.sourcePath,this.plugin)}this.switchTab(g,i,l,!0)}switchTab(t,e,n,s=!1){let i="selected",l=e.children;for(let a=0;a<l.length;a++)l[a].classList.remove(i);let r=n.children;for(let a=0;a<r.length;a++)r[a].classList.remove(i);let g=l[t];if(g.classList.add(i),r[t].classList.add(i),!s||t===0)return;if(e.parentElement===null){console.error("Cannot find scroll element");return}function o(){setTimeout(()=>{if(e.parentElement===null)return;let a=g.offsetLeft;e.parentElement.scrollLeft=a-35,e.parentElement.scrollLeft===0&&o()},100)}o()}};var f=class extends v.Plugin{async onload(){await this.loadSettings(),this.tabPanelBuilder=new T(this),this.registerMarkdownCodeBlockProcessor(this.settings.codeblockKeyword,(e,n,s)=>this.tabPanelBuilder.create(e,n,s)),this.addSettingTab(new m(this.app,this))}async loadSettings(){this.settings=Object.assign({},y,await this.loadData())}async saveSettings(){await this.saveData(this.settings)}};
|
||||
|
||||
/* nosourcemap */
|
11
.obsidian/plugins/tab-panels/manifest.json
vendored
11
.obsidian/plugins/tab-panels/manifest.json
vendored
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"id": "tab-panels",
|
||||
"name": "Tab Panels",
|
||||
"version": "1.0.2",
|
||||
"minAppVersion": "1.5.11",
|
||||
"description": "Create tab panels to organize content into sections",
|
||||
"author": "GnoxNahte",
|
||||
"authorUrl": "https://gnoxnahte.com",
|
||||
"fundingUrl": "https://ko-fi.com/gnoxnahtedev",
|
||||
"isDesktopOnly": false
|
||||
}
|
118
.obsidian/plugins/tab-panels/styles.css
vendored
118
.obsidian/plugins/tab-panels/styles.css
vendored
|
@ -1,118 +0,0 @@
|
|||
.tab-panel-container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
--padding-dist: 0.8em;
|
||||
--outer-border-radius: 1.5em;
|
||||
--inner-border-radius: calc(var(--outer-border-radius) - var(--padding-dist));
|
||||
padding: var(--padding-dist);
|
||||
|
||||
border: var(--border-width) solid var(--background-modifier-border);
|
||||
border-radius: var(--outer-border-radius);
|
||||
background-color: var(--background-secondary-alt);
|
||||
}
|
||||
|
||||
.tab-scroll-container {
|
||||
overflow-x: auto;
|
||||
overflow-y: hidden;
|
||||
scroll-behavior: smooth;
|
||||
|
||||
&.hide-container {
|
||||
display: none;
|
||||
}
|
||||
|
||||
&::-webkit-scrollbar-track-piece {
|
||||
margin-left: 3px;
|
||||
}
|
||||
|
||||
&::-webkit-scrollbar-track {
|
||||
background-color: var(--background-primary) !important;
|
||||
|
||||
border-top-left-radius: 0.5em;
|
||||
border-top-right-radius: 0.5em;
|
||||
|
||||
border: var(--border-width) solid var(--background-modifier-border);
|
||||
border-bottom: none;
|
||||
|
||||
box-shadow: 0 5px 0 -1px var(--background-primary),
|
||||
0 5px var(--background-modifier-border);
|
||||
}
|
||||
}
|
||||
|
||||
ul.tab-container {
|
||||
/* margin: 0 7px; */
|
||||
display: flex;
|
||||
list-style: none;
|
||||
margin-block: 0;
|
||||
margin: 0 15px;
|
||||
gap: 0.2em;
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
.tab-panel-container li.tab {
|
||||
/* Remove list styling */
|
||||
white-space: nowrap;
|
||||
margin-inline-start: 0;
|
||||
|
||||
padding: 0.2em 1em 0.6em;
|
||||
|
||||
border-top-left-radius: 0.5em;
|
||||
border-top-right-radius: 0.5em;
|
||||
|
||||
&.selected {
|
||||
border: var(--border-width) solid var(--background-modifier-border);
|
||||
border-bottom: none;
|
||||
margin-bottom: -1px;
|
||||
background-color: var(--background-primary);
|
||||
|
||||
/* Small curves at the sides of the tabs */
|
||||
/* Copied from inspecting Obsidian tabs */
|
||||
&::before {
|
||||
box-shadow: inset 0 0 0 var(--tab-outline-width) var(--tab-outline-color), 0 0 0 calc(var(--tab-curve) * 4) var(--tab-background-active);
|
||||
left: calc(var(--tab-curve) * -2);
|
||||
clip-path: inset(50% calc(var(--tab-curve) * -1) 0 50%);
|
||||
position: absolute;
|
||||
bottom: 1px;
|
||||
content: '';
|
||||
width: calc(var(--tab-curve) * 2);
|
||||
height: calc(var(--tab-curve) * 2);
|
||||
border-radius: 100%;
|
||||
/* border: 2px solid red; */
|
||||
}
|
||||
&::after {
|
||||
box-shadow: inset 0 0 0 var(--tab-outline-width) var(--tab-outline-color), 0 0 0 calc(var(--tab-curve) * 4) var(--tab-background-active);
|
||||
right: calc(var(--tab-curve) * -2);
|
||||
clip-path: inset(50% 50% 0 calc(var(--tab-curve) * -1));
|
||||
position: absolute;
|
||||
bottom: 1px;
|
||||
content: '';
|
||||
width: calc(var(--tab-curve) * 2);
|
||||
height: calc(var(--tab-curve) * 2);
|
||||
border-radius: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.highlight-selected-tab-name li.selected.tab {
|
||||
color: var(--color-accent);
|
||||
}
|
||||
|
||||
div.content-container {
|
||||
background-color: var(--background-primary);
|
||||
padding: 1em;
|
||||
border-radius: var(--inner-border-radius);
|
||||
box-shadow: 0 0 0 var(--border-width) var(--background-modifier-border);
|
||||
}
|
||||
|
||||
.content-container > div {
|
||||
&:not(.selected) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
& *:first-child {
|
||||
margin-top: 0 !important;
|
||||
}
|
||||
|
||||
& *:last-child {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
}
|
756
.obsidian/plugins/url-into-selection/main.js
vendored
756
.obsidian/plugins/url-into-selection/main.js
vendored
|
@ -1,756 +0,0 @@
|
|||
'use strict';
|
||||
|
||||
var obsidian = require('obsidian');
|
||||
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
PERFORMANCE OF THIS SOFTWARE.
|
||||
***************************************************************************** */
|
||||
/* global Reflect, Promise */
|
||||
|
||||
var extendStatics = function(d, b) {
|
||||
extendStatics = Object.setPrototypeOf ||
|
||||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
||||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
||||
return extendStatics(d, b);
|
||||
};
|
||||
|
||||
function __extends(d, b) {
|
||||
if (typeof b !== "function" && b !== null)
|
||||
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
||||
extendStatics(d, b);
|
||||
function __() { this.constructor = d; }
|
||||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
||||
}
|
||||
|
||||
function __awaiter(thisArg, _arguments, P, generator) {
|
||||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
||||
return new (P || (P = Promise))(function (resolve, reject) {
|
||||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
||||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
||||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
||||
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
||||
});
|
||||
}
|
||||
|
||||
function __generator(thisArg, body) {
|
||||
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
||||
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
||||
function verb(n) { return function (v) { return step([n, v]); }; }
|
||||
function step(op) {
|
||||
if (f) throw new TypeError("Generator is already executing.");
|
||||
while (_) try {
|
||||
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
||||
if (y = 0, t) op = [op[0] & 2, t.value];
|
||||
switch (op[0]) {
|
||||
case 0: case 1: t = op; break;
|
||||
case 4: _.label++; return { value: op[1], done: false };
|
||||
case 5: _.label++; y = op[1]; op = [0]; continue;
|
||||
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
||||
default:
|
||||
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
||||
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
||||
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
||||
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
||||
if (t[2]) _.ops.pop();
|
||||
_.trys.pop(); continue;
|
||||
}
|
||||
op = body.call(thisArg, _);
|
||||
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
||||
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
||||
}
|
||||
}
|
||||
|
||||
function getDefaultExportFromCjs (x) {
|
||||
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
||||
}
|
||||
|
||||
function createCommonjsModule(fn, basedir, module) {
|
||||
return module = {
|
||||
path: basedir,
|
||||
exports: {},
|
||||
require: function (path, base) {
|
||||
return commonjsRequire(path, (base === undefined || base === null) ? module.path : base);
|
||||
}
|
||||
}, fn(module, module.exports), module.exports;
|
||||
}
|
||||
|
||||
function commonjsRequire () {
|
||||
throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
|
||||
}
|
||||
|
||||
var assertNever_1 = createCommonjsModule(function (module, exports) {
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
/**
|
||||
* Helper function for exhaustive checks of discriminated unions.
|
||||
* https://basarat.gitbooks.io/typescript/docs/types/discriminated-unions.html
|
||||
*
|
||||
* @example
|
||||
*
|
||||
* type A = {type: 'a'};
|
||||
* type B = {type: 'b'};
|
||||
* type Union = A | B;
|
||||
*
|
||||
* function doSomething(arg: Union) {
|
||||
* if (arg.type === 'a') {
|
||||
* return something;
|
||||
* }
|
||||
*
|
||||
* if (arg.type === 'b') {
|
||||
* return somethingElse;
|
||||
* }
|
||||
*
|
||||
* // TS will error if there are other types in the union
|
||||
* // Will throw an Error when called at runtime.
|
||||
* // Use `assertNever(arg, true)` instead to fail silently.
|
||||
* return assertNever(arg);
|
||||
* }
|
||||
*/
|
||||
function assertNever(value, noThrow) {
|
||||
if (noThrow) {
|
||||
return value;
|
||||
}
|
||||
throw new Error("Unhandled discriminated union member: " + JSON.stringify(value));
|
||||
}
|
||||
exports.assertNever = assertNever;
|
||||
exports.default = assertNever;
|
||||
});
|
||||
|
||||
var assertNever = /*@__PURE__*/getDefaultExportFromCjs(assertNever_1);
|
||||
|
||||
// Copyright Joyent, Inc. and other Node contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||
// copy of this software and associated documentation files (the
|
||||
// "Software"), to deal in the Software without restriction, including
|
||||
// without limitation the rights to use, copy, modify, merge, publish,
|
||||
// distribute, sublicense, and/or sell copies of the Software, and to permit
|
||||
// persons to whom the Software is furnished to do so, subject to the
|
||||
// following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included
|
||||
// in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
||||
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
||||
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
||||
// USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
// resolves . and .. elements in a path array with directory names there
|
||||
// must be no slashes, empty elements, or device names (c:\) in the array
|
||||
// (so also no leading and trailing slashes - it does not distinguish
|
||||
// relative and absolute paths)
|
||||
function normalizeArray(parts, allowAboveRoot) {
|
||||
// if the path tries to go above the root, `up` ends up > 0
|
||||
var up = 0;
|
||||
for (var i = parts.length - 1; i >= 0; i--) {
|
||||
var last = parts[i];
|
||||
if (last === '.') {
|
||||
parts.splice(i, 1);
|
||||
} else if (last === '..') {
|
||||
parts.splice(i, 1);
|
||||
up++;
|
||||
} else if (up) {
|
||||
parts.splice(i, 1);
|
||||
up--;
|
||||
}
|
||||
}
|
||||
|
||||
// if the path is allowed to go above the root, restore leading ..s
|
||||
if (allowAboveRoot) {
|
||||
for (; up--; up) {
|
||||
parts.unshift('..');
|
||||
}
|
||||
}
|
||||
|
||||
return parts;
|
||||
}
|
||||
|
||||
// Split a filename into [root, dir, basename, ext], unix version
|
||||
// 'root' is just a slash, or nothing.
|
||||
var splitPathRe =
|
||||
/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;
|
||||
var splitPath = function(filename) {
|
||||
return splitPathRe.exec(filename).slice(1);
|
||||
};
|
||||
|
||||
// path.resolve([from ...], to)
|
||||
// posix version
|
||||
function resolve() {
|
||||
var resolvedPath = '',
|
||||
resolvedAbsolute = false;
|
||||
|
||||
for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
|
||||
var path = (i >= 0) ? arguments[i] : '/';
|
||||
|
||||
// Skip empty and invalid entries
|
||||
if (typeof path !== 'string') {
|
||||
throw new TypeError('Arguments to path.resolve must be strings');
|
||||
} else if (!path) {
|
||||
continue;
|
||||
}
|
||||
|
||||
resolvedPath = path + '/' + resolvedPath;
|
||||
resolvedAbsolute = path.charAt(0) === '/';
|
||||
}
|
||||
|
||||
// At this point the path should be resolved to a full absolute path, but
|
||||
// handle relative paths to be safe (might happen when process.cwd() fails)
|
||||
|
||||
// Normalize the path
|
||||
resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) {
|
||||
return !!p;
|
||||
}), !resolvedAbsolute).join('/');
|
||||
|
||||
return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
|
||||
}
|
||||
// path.normalize(path)
|
||||
// posix version
|
||||
function normalize(path) {
|
||||
var isPathAbsolute = isAbsolute(path),
|
||||
trailingSlash = substr(path, -1) === '/';
|
||||
|
||||
// Normalize the path
|
||||
path = normalizeArray(filter(path.split('/'), function(p) {
|
||||
return !!p;
|
||||
}), !isPathAbsolute).join('/');
|
||||
|
||||
if (!path && !isPathAbsolute) {
|
||||
path = '.';
|
||||
}
|
||||
if (path && trailingSlash) {
|
||||
path += '/';
|
||||
}
|
||||
|
||||
return (isPathAbsolute ? '/' : '') + path;
|
||||
}
|
||||
// posix version
|
||||
function isAbsolute(path) {
|
||||
return path.charAt(0) === '/';
|
||||
}
|
||||
|
||||
// posix version
|
||||
function join() {
|
||||
var paths = Array.prototype.slice.call(arguments, 0);
|
||||
return normalize(filter(paths, function(p, index) {
|
||||
if (typeof p !== 'string') {
|
||||
throw new TypeError('Arguments to path.join must be strings');
|
||||
}
|
||||
return p;
|
||||
}).join('/'));
|
||||
}
|
||||
|
||||
|
||||
// path.relative(from, to)
|
||||
// posix version
|
||||
function relative(from, to) {
|
||||
from = resolve(from).substr(1);
|
||||
to = resolve(to).substr(1);
|
||||
|
||||
function trim(arr) {
|
||||
var start = 0;
|
||||
for (; start < arr.length; start++) {
|
||||
if (arr[start] !== '') break;
|
||||
}
|
||||
|
||||
var end = arr.length - 1;
|
||||
for (; end >= 0; end--) {
|
||||
if (arr[end] !== '') break;
|
||||
}
|
||||
|
||||
if (start > end) return [];
|
||||
return arr.slice(start, end - start + 1);
|
||||
}
|
||||
|
||||
var fromParts = trim(from.split('/'));
|
||||
var toParts = trim(to.split('/'));
|
||||
|
||||
var length = Math.min(fromParts.length, toParts.length);
|
||||
var samePartsLength = length;
|
||||
for (var i = 0; i < length; i++) {
|
||||
if (fromParts[i] !== toParts[i]) {
|
||||
samePartsLength = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
var outputParts = [];
|
||||
for (var i = samePartsLength; i < fromParts.length; i++) {
|
||||
outputParts.push('..');
|
||||
}
|
||||
|
||||
outputParts = outputParts.concat(toParts.slice(samePartsLength));
|
||||
|
||||
return outputParts.join('/');
|
||||
}
|
||||
|
||||
var sep = '/';
|
||||
var delimiter = ':';
|
||||
|
||||
function dirname(path) {
|
||||
var result = splitPath(path),
|
||||
root = result[0],
|
||||
dir = result[1];
|
||||
|
||||
if (!root && !dir) {
|
||||
// No dirname whatsoever
|
||||
return '.';
|
||||
}
|
||||
|
||||
if (dir) {
|
||||
// It has a dirname, strip trailing slash
|
||||
dir = dir.substr(0, dir.length - 1);
|
||||
}
|
||||
|
||||
return root + dir;
|
||||
}
|
||||
|
||||
function basename(path, ext) {
|
||||
var f = splitPath(path)[2];
|
||||
// TODO: make this comparison case-insensitive on windows?
|
||||
if (ext && f.substr(-1 * ext.length) === ext) {
|
||||
f = f.substr(0, f.length - ext.length);
|
||||
}
|
||||
return f;
|
||||
}
|
||||
|
||||
|
||||
function extname(path) {
|
||||
return splitPath(path)[3];
|
||||
}
|
||||
var path = {
|
||||
extname: extname,
|
||||
basename: basename,
|
||||
dirname: dirname,
|
||||
sep: sep,
|
||||
delimiter: delimiter,
|
||||
relative: relative,
|
||||
join: join,
|
||||
isAbsolute: isAbsolute,
|
||||
normalize: normalize,
|
||||
resolve: resolve
|
||||
};
|
||||
function filter (xs, f) {
|
||||
if (xs.filter) return xs.filter(f);
|
||||
var res = [];
|
||||
for (var i = 0; i < xs.length; i++) {
|
||||
if (f(xs[i], i, xs)) res.push(xs[i]);
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
// String.prototype.substr - negative index don't work in IE8
|
||||
var substr = 'ab'.substr(-1) === 'b' ?
|
||||
function (str, start, len) { return str.substr(start, len) } :
|
||||
function (str, start, len) {
|
||||
if (start < 0) start = str.length + start;
|
||||
return str.substr(start, len);
|
||||
}
|
||||
;
|
||||
|
||||
function fileUrl(filePath, options = {}) {
|
||||
if (typeof filePath !== 'string') {
|
||||
throw new TypeError(`Expected a string, got ${typeof filePath}`);
|
||||
}
|
||||
|
||||
const {resolve = true} = options;
|
||||
|
||||
let pathName = filePath;
|
||||
if (resolve) {
|
||||
pathName = path.resolve(filePath);
|
||||
}
|
||||
|
||||
pathName = pathName.replace(/\\/g, '/');
|
||||
|
||||
// Windows drive letter must be prefixed with a slash.
|
||||
if (pathName[0] !== '/') {
|
||||
pathName = `/${pathName}`;
|
||||
}
|
||||
|
||||
// Escape required characters for path components.
|
||||
// See: https://tools.ietf.org/html/rfc3986#section-3.3
|
||||
return encodeURI(`file://${pathName}`).replace(/[?#]/g, encodeURIComponent);
|
||||
}
|
||||
|
||||
// https://www.oreilly.com/library/view/regular-expressions-cookbook/9781449327453/ch08s18.html
|
||||
var win32Path = /^[a-z]:\\(?:[^\\/:*?"<>|\r\n]+\\)*[^\\/:*?"<>|\r\n]*$/i;
|
||||
var unixPath = /^(?:\/[^/]+)+\/?$/i;
|
||||
var testFilePath = function (url) { return win32Path.test(url) || unixPath.test(url); };
|
||||
function UrlIntoSelection(editor, cb, settings) {
|
||||
// skip all if nothing should be done
|
||||
if (!editor.somethingSelected() && settings.nothingSelected === 0 /* doNothing */)
|
||||
return;
|
||||
if (typeof cb !== "string" && cb.clipboardData === null) {
|
||||
console.error("empty clipboardData in ClipboardEvent");
|
||||
return;
|
||||
}
|
||||
var clipboardText = getCbText(cb);
|
||||
if (clipboardText === null)
|
||||
return;
|
||||
var _a = getSelnRange(editor, settings), selectedText = _a.selectedText, replaceRange = _a.replaceRange;
|
||||
var replaceText = getReplaceText(clipboardText, selectedText, settings);
|
||||
if (replaceText === null)
|
||||
return;
|
||||
// apply changes
|
||||
if (typeof cb !== "string")
|
||||
cb.preventDefault(); // prevent default paste behavior
|
||||
replace(editor, replaceText, replaceRange);
|
||||
// if nothing is selected and the nothing selected behavior is to insert [](url) place the cursor between the square brackets
|
||||
if ((selectedText === "") && settings.nothingSelected === 2 /* insertInline */) {
|
||||
editor.setCursor({ ch: replaceRange.from.ch + 1, line: replaceRange.from.line });
|
||||
}
|
||||
}
|
||||
function getSelnRange(editor, settings) {
|
||||
var selectedText;
|
||||
var replaceRange;
|
||||
if (editor.somethingSelected()) {
|
||||
selectedText = editor.getSelection().trim();
|
||||
replaceRange = null;
|
||||
}
|
||||
else {
|
||||
switch (settings.nothingSelected) {
|
||||
case 1 /* autoSelect */:
|
||||
replaceRange = getWordBoundaries(editor, settings);
|
||||
selectedText = editor.getRange(replaceRange.from, replaceRange.to);
|
||||
break;
|
||||
case 2 /* insertInline */:
|
||||
case 3 /* insertBare */:
|
||||
replaceRange = getCursor(editor);
|
||||
selectedText = "";
|
||||
break;
|
||||
case 0 /* doNothing */:
|
||||
throw new Error("should be skipped");
|
||||
default:
|
||||
assertNever(settings.nothingSelected);
|
||||
}
|
||||
}
|
||||
return { selectedText: selectedText, replaceRange: replaceRange };
|
||||
}
|
||||
function isUrl(text, settings) {
|
||||
if (text === "")
|
||||
return false;
|
||||
try {
|
||||
// throw TypeError: Invalid URL if not valid
|
||||
new URL(text);
|
||||
return true;
|
||||
}
|
||||
catch (error) {
|
||||
// settings.regex: fallback test allows url without protocol (http,file...)
|
||||
return testFilePath(text) || new RegExp(settings.regex).test(text);
|
||||
}
|
||||
}
|
||||
function isImgEmbed(text, settings) {
|
||||
var rules = settings.listForImgEmbed
|
||||
.split("\n")
|
||||
.filter(function (v) { return v.length > 0; })
|
||||
.map(function (v) { return new RegExp(v); });
|
||||
for (var _i = 0, rules_1 = rules; _i < rules_1.length; _i++) {
|
||||
var reg = rules_1[_i];
|
||||
if (reg.test(text))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
* Validate that either the text on the clipboard or the selected text is a link, and if so return the link as
|
||||
* a markdown link with the selected text as the link's text, or, if the value on the clipboard is not a link
|
||||
* but the selected text is, the value of the clipboard as the link's text.
|
||||
* If the link matches one of the image url regular expressions return a markdown image link.
|
||||
* @param clipboardText text on the clipboard.
|
||||
* @param selectedText highlighted text
|
||||
* @param settings plugin settings
|
||||
* @returns a mardown link or image link if the clipboard or selction value is a valid link, else null.
|
||||
*/
|
||||
function getReplaceText(clipboardText, selectedText, settings) {
|
||||
var linktext;
|
||||
var url;
|
||||
if (isUrl(clipboardText, settings)) {
|
||||
linktext = selectedText;
|
||||
url = clipboardText;
|
||||
}
|
||||
else if (isUrl(selectedText, settings)) {
|
||||
linktext = clipboardText;
|
||||
url = selectedText;
|
||||
}
|
||||
else
|
||||
return null; // if neither of two is an URL, the following code would be skipped.
|
||||
var imgEmbedMark = isImgEmbed(clipboardText, settings) ? "!" : "";
|
||||
url = processUrl(url);
|
||||
if (selectedText === "" && settings.nothingSelected === 3 /* insertBare */) {
|
||||
return "<".concat(url, ">");
|
||||
}
|
||||
else {
|
||||
return imgEmbedMark + "[".concat(linktext, "](").concat(url, ")");
|
||||
}
|
||||
}
|
||||
/** Process file url, special characters, etc */
|
||||
function processUrl(src) {
|
||||
var output;
|
||||
if (testFilePath(src)) {
|
||||
output = fileUrl(src, { resolve: false });
|
||||
}
|
||||
else {
|
||||
output = src;
|
||||
}
|
||||
if (/[<>]/.test(output))
|
||||
output = output.replace("<", "%3C").replace(">", "%3E");
|
||||
return /[\(\) ]/.test(output) ? "<".concat(output, ">") : output;
|
||||
}
|
||||
function getCbText(cb) {
|
||||
var clipboardText;
|
||||
if (typeof cb === "string") {
|
||||
clipboardText = cb;
|
||||
}
|
||||
else {
|
||||
if (cb.clipboardData === null) {
|
||||
console.error("empty clipboardData in ClipboardEvent");
|
||||
return null;
|
||||
}
|
||||
else {
|
||||
clipboardText = cb.clipboardData.getData("text");
|
||||
}
|
||||
}
|
||||
return clipboardText.trim();
|
||||
}
|
||||
function getWordBoundaries(editor, settings) {
|
||||
var cursor = editor.getCursor();
|
||||
var line = editor.getLine(cursor.line);
|
||||
var wordBoundaries = findWordAt(line, cursor);
|
||||
// If the token the cursor is on is a url, grab the whole thing instead of just parsing it like a word
|
||||
var start = wordBoundaries.from.ch;
|
||||
var end = wordBoundaries.to.ch;
|
||||
while (start > 0 && !/\s/.test(line.charAt(start - 1)))
|
||||
--start;
|
||||
while (end < line.length && !/\s/.test(line.charAt(end)))
|
||||
++end;
|
||||
if (isUrl(line.slice(start, end), settings)) {
|
||||
wordBoundaries.from.ch = start;
|
||||
wordBoundaries.to.ch = end;
|
||||
}
|
||||
return wordBoundaries;
|
||||
}
|
||||
var findWordAt = (function () {
|
||||
var nonASCIISingleCaseWordChar = /[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;
|
||||
function isWordChar(char) {
|
||||
return /\w/.test(char) || char > "\x80" &&
|
||||
(char.toUpperCase() != char.toLowerCase() || nonASCIISingleCaseWordChar.test(char));
|
||||
}
|
||||
return function (line, pos) {
|
||||
var check;
|
||||
var start = pos.ch;
|
||||
var end = pos.ch;
|
||||
(end === line.length) ? --start : ++end;
|
||||
var startChar = line.charAt(pos.ch);
|
||||
if (isWordChar(startChar)) {
|
||||
check = function (ch) { return isWordChar(ch); };
|
||||
}
|
||||
else if (/\s/.test(startChar)) {
|
||||
check = function (ch) { return /\s/.test(ch); };
|
||||
}
|
||||
else {
|
||||
check = function (ch) { return (!/\s/.test(ch) && !isWordChar(ch)); };
|
||||
}
|
||||
while (start > 0 && check(line.charAt(start - 1)))
|
||||
--start;
|
||||
while (end < line.length && check(line.charAt(end)))
|
||||
++end;
|
||||
return { from: { line: pos.line, ch: start }, to: { line: pos.line, ch: end } };
|
||||
};
|
||||
})();
|
||||
function getCursor(editor) {
|
||||
return { from: editor.getCursor(), to: editor.getCursor() };
|
||||
}
|
||||
function replace(editor, replaceText, replaceRange) {
|
||||
if (replaceRange === void 0) { replaceRange = null; }
|
||||
// replaceRange is only not null when there isn't anything selected.
|
||||
if (replaceRange && replaceRange.from && replaceRange.to) {
|
||||
editor.replaceRange(replaceText, replaceRange.from, replaceRange.to);
|
||||
}
|
||||
// if word is null or undefined
|
||||
else
|
||||
editor.replaceSelection(replaceText);
|
||||
}
|
||||
|
||||
var DEFAULT_SETTINGS = {
|
||||
regex: /[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)/
|
||||
.source,
|
||||
nothingSelected: 0 /* doNothing */,
|
||||
listForImgEmbed: "",
|
||||
};
|
||||
var UrlIntoSelectionSettingsTab = /** @class */ (function (_super) {
|
||||
__extends(UrlIntoSelectionSettingsTab, _super);
|
||||
function UrlIntoSelectionSettingsTab() {
|
||||
return _super !== null && _super.apply(this, arguments) || this;
|
||||
}
|
||||
UrlIntoSelectionSettingsTab.prototype.display = function () {
|
||||
var _this = this;
|
||||
var containerEl = this.containerEl;
|
||||
var plugin = this.plugin;
|
||||
containerEl.empty();
|
||||
containerEl.createEl("h2", { text: "URL-into-selection Settings" });
|
||||
new obsidian.Setting(containerEl)
|
||||
.setName("Fallback Regular expression")
|
||||
.setDesc("Regular expression used to match URLs when default match fails.")
|
||||
.addText(function (text) {
|
||||
return text
|
||||
.setPlaceholder("Enter regular expression here..")
|
||||
.setValue(plugin.settings.regex)
|
||||
.onChange(function (value) { return __awaiter(_this, void 0, void 0, function () {
|
||||
return __generator(this, function (_a) {
|
||||
switch (_a.label) {
|
||||
case 0:
|
||||
if (!(value.length > 0)) return [3 /*break*/, 2];
|
||||
plugin.settings.regex = value;
|
||||
return [4 /*yield*/, plugin.saveSettings()];
|
||||
case 1:
|
||||
_a.sent();
|
||||
_a.label = 2;
|
||||
case 2: return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
}); });
|
||||
});
|
||||
new obsidian.Setting(containerEl)
|
||||
.setName("Behavior on pasting URL when nothing is selected")
|
||||
.setDesc("Auto Select: Automatically select word surrounding the cursor.")
|
||||
.addDropdown(function (dropdown) {
|
||||
var options = {
|
||||
0: "Do nothing",
|
||||
1: "Auto Select",
|
||||
2: "Insert [](url)",
|
||||
3: "Insert <url>",
|
||||
};
|
||||
dropdown
|
||||
.addOptions(options)
|
||||
.setValue(plugin.settings.nothingSelected.toString())
|
||||
.onChange(function (value) { return __awaiter(_this, void 0, void 0, function () {
|
||||
return __generator(this, function (_a) {
|
||||
switch (_a.label) {
|
||||
case 0:
|
||||
plugin.settings.nothingSelected = +value;
|
||||
return [4 /*yield*/, plugin.saveSettings()];
|
||||
case 1:
|
||||
_a.sent();
|
||||
this.display();
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
}); });
|
||||
});
|
||||
new obsidian.Setting(containerEl)
|
||||
.setName("Whitelist for image embed syntax")
|
||||
.setDesc(createFragment(function (el) {
|
||||
el.appendText("![selection](url) will be used for URL that matches the following list.");
|
||||
el.createEl("br");
|
||||
el.appendText("Rules are regex-based, split by line break.");
|
||||
}))
|
||||
.addTextArea(function (text) {
|
||||
text
|
||||
.setPlaceholder("Example:\nyoutu.?be|vimeo")
|
||||
.setValue(plugin.settings.listForImgEmbed)
|
||||
.onChange(function (value) {
|
||||
plugin.settings.listForImgEmbed = value;
|
||||
plugin.saveData(plugin.settings);
|
||||
return text;
|
||||
});
|
||||
text.inputEl.rows = 6;
|
||||
text.inputEl.cols = 25;
|
||||
});
|
||||
};
|
||||
return UrlIntoSelectionSettingsTab;
|
||||
}(obsidian.PluginSettingTab));
|
||||
|
||||
var UrlIntoSel_Plugin = /** @class */ (function (_super) {
|
||||
__extends(UrlIntoSel_Plugin, _super);
|
||||
function UrlIntoSel_Plugin() {
|
||||
var _this = _super !== null && _super.apply(this, arguments) || this;
|
||||
// pasteHandler = (cm: CodeMirror.Editor, e: ClipboardEvent) => UrlIntoSelection(cm, e, this.settings);
|
||||
_this.pasteHandler = function (evt, editor) { return UrlIntoSelection(editor, evt, _this.settings); };
|
||||
return _this;
|
||||
}
|
||||
UrlIntoSel_Plugin.prototype.onload = function () {
|
||||
return __awaiter(this, void 0, void 0, function () {
|
||||
var _this = this;
|
||||
return __generator(this, function (_a) {
|
||||
switch (_a.label) {
|
||||
case 0:
|
||||
console.log("loading url-into-selection");
|
||||
return [4 /*yield*/, this.loadSettings()];
|
||||
case 1:
|
||||
_a.sent();
|
||||
this.addSettingTab(new UrlIntoSelectionSettingsTab(this.app, this));
|
||||
this.addCommand({
|
||||
id: "paste-url-into-selection",
|
||||
name: "",
|
||||
editorCallback: function (editor) { return __awaiter(_this, void 0, void 0, function () {
|
||||
var clipboardText;
|
||||
return __generator(this, function (_a) {
|
||||
switch (_a.label) {
|
||||
case 0: return [4 /*yield*/, navigator.clipboard.readText()];
|
||||
case 1:
|
||||
clipboardText = _a.sent();
|
||||
UrlIntoSelection(editor, clipboardText, this.settings);
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
}); },
|
||||
});
|
||||
this.app.workspace.on("editor-paste", this.pasteHandler);
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
UrlIntoSel_Plugin.prototype.onunload = function () {
|
||||
console.log("unloading url-into-selection");
|
||||
this.app.workspace.off("editor-paste", this.pasteHandler);
|
||||
};
|
||||
UrlIntoSel_Plugin.prototype.loadSettings = function () {
|
||||
return __awaiter(this, void 0, void 0, function () {
|
||||
var _a, _b, _c, _d;
|
||||
return __generator(this, function (_e) {
|
||||
switch (_e.label) {
|
||||
case 0:
|
||||
_a = this;
|
||||
_c = (_b = Object).assign;
|
||||
_d = [{}, DEFAULT_SETTINGS];
|
||||
return [4 /*yield*/, this.loadData()];
|
||||
case 1:
|
||||
_a.settings = _c.apply(_b, _d.concat([_e.sent()]));
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
UrlIntoSel_Plugin.prototype.saveSettings = function () {
|
||||
return __awaiter(this, void 0, void 0, function () {
|
||||
return __generator(this, function (_a) {
|
||||
switch (_a.label) {
|
||||
case 0: return [4 /*yield*/, this.saveData(this.settings)];
|
||||
case 1:
|
||||
_a.sent();
|
||||
return [2 /*return*/];
|
||||
}
|
||||
});
|
||||
});
|
||||
};
|
||||
return UrlIntoSel_Plugin;
|
||||
}(obsidian.Plugin));
|
||||
|
||||
module.exports = UrlIntoSel_Plugin;
|
||||
|
||||
|
||||
/* nosourcemap */
|
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
"id": "url-into-selection",
|
||||
"name": "Paste URL into selection",
|
||||
"description": "Paste URL \"into\" selected text.",
|
||||
"isDesktopOnly": false,
|
||||
"js": "main.js",
|
||||
"version": "1.7.0"
|
||||
}
|
1292
.obsidian/snippets/S - Checkboxes.css
vendored
1292
.obsidian/snippets/S - Checkboxes.css
vendored
File diff suppressed because one or more lines are too long
3911
.obsidian/snippets/extended-colorschemes.css
vendored
3911
.obsidian/snippets/extended-colorschemes.css
vendored
File diff suppressed because it is too large
Load diff
4
.obsidian/templates.json
vendored
4
.obsidian/templates.json
vendored
|
@ -1,4 +0,0 @@
|
|||
{
|
||||
"folder": "02 Templates",
|
||||
"timeFormat": "HH:MM"
|
||||
}
|
125
.obsidian/text-generator.json
vendored
125
.obsidian/text-generator.json
vendored
|
@ -1,125 +0,0 @@
|
|||
{
|
||||
"packagesHash": {
|
||||
"default": {
|
||||
"packageId": "default",
|
||||
"name": "Default Prompts Package",
|
||||
"version": "0.0.9",
|
||||
"minTextGeneratorVersion": "0.5.0",
|
||||
"description": "This is the main package that comes with Text Generator plugin in Obsidian",
|
||||
"author": "Noureddine Haouari",
|
||||
"tags": "writing, brainstorming",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/gpt-3-prompt-templates"
|
||||
},
|
||||
"dalle": {
|
||||
"packageId": "dalle",
|
||||
"name": "OpenAI Dalle Package",
|
||||
"version": "0.1.1",
|
||||
"minTextGeneratorVersion": "0.7.0",
|
||||
"description": "The package contains some interessting Dalle-2/Dalle-3 prompt templates",
|
||||
"author": "Noureddine Haouari",
|
||||
"tags": "photo, dalle-2, dalle-3",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/tg-dalle-package"
|
||||
},
|
||||
"huggingface": {
|
||||
"packageId": "huggingface",
|
||||
"name": "Huggingface Prompts Package",
|
||||
"version": "0.0.4",
|
||||
"minTextGeneratorVersion": "0.5.0",
|
||||
"description": "Huggingface Prompts comes with Text Generator plugin in Obsidian",
|
||||
"author": "Noureddine Haouari",
|
||||
"tags": "writing, brainstorming, huggingface",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/huggingface"
|
||||
},
|
||||
"awesomePrompts": {
|
||||
"packageId": "awesomePrompts",
|
||||
"name": "Awesome Prompts",
|
||||
"version": "0.0.3",
|
||||
"minTextGeneratorVersion": "0.5.7",
|
||||
"description": "This repo includes ChatGPT prompt curation to use ChatGPT better.",
|
||||
"author": "f",
|
||||
"tags": "writing, brainstorming, awesome",
|
||||
"authorUrl": "https://github.com/f/awesome-chatgpt-prompts",
|
||||
"repo": "text-gen/awesome-tg-package"
|
||||
},
|
||||
"tts": {
|
||||
"packageId": "tts",
|
||||
"name": "Text To Speech Package",
|
||||
"version": "0.0.3",
|
||||
"minTextGeneratorVersion": "0.6.0",
|
||||
"description": "Contains Text To Speech Templates and support for TTS for other templates",
|
||||
"author": "Noureddine",
|
||||
"tags": "TTS, Speak",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/TTS"
|
||||
},
|
||||
"vision": {
|
||||
"packageId": "vision",
|
||||
"name": "Vision Package",
|
||||
"version": "0.0.2",
|
||||
"minTextGeneratorVersion": "0.6.0",
|
||||
"description": "Contains Vision Templates and support for Vision for other templates (Scripts)",
|
||||
"author": "Noureddine",
|
||||
"tags": "OpenAI,markdown,gpt-4-vision,vision,images",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/tg-vision"
|
||||
},
|
||||
"smartConnections": {
|
||||
"packageId": "smartConnections",
|
||||
"name": "Smart Connections Package",
|
||||
"version": "0.0.1",
|
||||
"minTextGeneratorVersion": "0.6.0",
|
||||
"description": "Contains Smart Connection Templates and support for Smart Connections for other templates (Script)",
|
||||
"author": "Noureddine",
|
||||
"tags": "smartConnections,smart-connections",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/tg-smartConnections"
|
||||
},
|
||||
"Experimental": {
|
||||
"packageId": "Experimental",
|
||||
"name": "Experimental Package",
|
||||
"version": "0.0.2",
|
||||
"minTextGeneratorVersion": "0.6.6",
|
||||
"description": "Contains experimental templates",
|
||||
"author": "Noureddine",
|
||||
"tags": "experiments",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/experimental-package"
|
||||
},
|
||||
"testExtension": {
|
||||
"core": true,
|
||||
"type": "feature",
|
||||
"packageId": "testExtension",
|
||||
"name": "test extension Package",
|
||||
"version": "0.0.1",
|
||||
"minTextGeneratorVersion": "0.1.0",
|
||||
"description": "testing extension package",
|
||||
"author": "Noureddine Haouari",
|
||||
"tags": "testing",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/gpt-3-prompt-templates",
|
||||
"folderName": "testExtension",
|
||||
"price": 20,
|
||||
"installed": false
|
||||
},
|
||||
"excalidraw": {
|
||||
"packageId": "excalidraw",
|
||||
"name": "excalidraw package",
|
||||
"version": "0.0.1",
|
||||
"minTextGeneratorVersion": "0.6.0",
|
||||
"description": "Contains Excalidraw Templates and support for Excalidraw for other templates (Scripts)",
|
||||
"author": "Noureddine",
|
||||
"tags": "OpenAI,markdown,gpt-4-vision,vision,images",
|
||||
"authorUrl": "https://www.buymeacoffee.com/haouarine",
|
||||
"repo": "text-gen/tg-excalidraw",
|
||||
"core": true,
|
||||
"folderName": "excalidrawPackage",
|
||||
"price": 2
|
||||
}
|
||||
},
|
||||
"resources": {},
|
||||
"installedPackagesHash": {},
|
||||
"subscriptions": []
|
||||
}
|
7
.obsidian/themes/AnuPpuccin/manifest.json
vendored
7
.obsidian/themes/AnuPpuccin/manifest.json
vendored
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
"name": "AnuPpuccin",
|
||||
"version": "1.5.0",
|
||||
"minAppVersion": "1.6.0",
|
||||
"author": "Anubis",
|
||||
"authorUrl": "https://github.com/AnubisNekhet"
|
||||
}
|
8549
.obsidian/themes/AnuPpuccin/theme.css
vendored
8549
.obsidian/themes/AnuPpuccin/theme.css
vendored
File diff suppressed because it is too large
Load diff
224
.obsidian/workspace.json
vendored
224
.obsidian/workspace.json
vendored
|
@ -1,224 +0,0 @@
|
|||
{
|
||||
"main": {
|
||||
"id": "9a5ca1e17e8e3895",
|
||||
"type": "split",
|
||||
"children": [
|
||||
{
|
||||
"id": "01bc8d20221acddd",
|
||||
"type": "tabs",
|
||||
"children": [
|
||||
{
|
||||
"id": "d8b2d491d5dde0b3",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "markdown",
|
||||
"state": {
|
||||
"file": "Python/Argument Passing.md",
|
||||
"mode": "preview",
|
||||
"backlinks": true,
|
||||
"source": false
|
||||
},
|
||||
"icon": "lucide-file",
|
||||
"title": "Argument Passing"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "5e5fd1622dcd9b85",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "markdown",
|
||||
"state": {
|
||||
"file": "Python/README.md.md",
|
||||
"mode": "source",
|
||||
"backlinks": true,
|
||||
"source": false
|
||||
},
|
||||
"icon": "lucide-file",
|
||||
"title": "README.md"
|
||||
}
|
||||
}
|
||||
],
|
||||
"currentTab": 1
|
||||
}
|
||||
],
|
||||
"direction": "vertical"
|
||||
},
|
||||
"left": {
|
||||
"id": "85b8d641c4d6242d",
|
||||
"type": "split",
|
||||
"children": [
|
||||
{
|
||||
"id": "82f0407a18103432",
|
||||
"type": "tabs",
|
||||
"children": [
|
||||
{
|
||||
"id": "de52c1adc6aa0124",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "file-explorer",
|
||||
"state": {
|
||||
"sortOrder": "alphabetical"
|
||||
},
|
||||
"icon": "lucide-folder-closed",
|
||||
"title": "Files"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "38f12b90c8bcd3e6",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "search",
|
||||
"state": {
|
||||
"query": "",
|
||||
"matchingCase": false,
|
||||
"explainSearch": false,
|
||||
"collapseAll": false,
|
||||
"extraContext": false,
|
||||
"sortOrder": "alphabetical"
|
||||
},
|
||||
"icon": "lucide-search",
|
||||
"title": "Search"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"direction": "horizontal",
|
||||
"width": 254
|
||||
},
|
||||
"right": {
|
||||
"id": "a9cd509ca1eca3c4",
|
||||
"type": "split",
|
||||
"children": [
|
||||
{
|
||||
"id": "958737111c7ee21b",
|
||||
"type": "tabs",
|
||||
"children": [
|
||||
{
|
||||
"id": "3af91911204ef141",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "backlink",
|
||||
"state": {
|
||||
"file": "Support - L2/L2 Fundamentals.md",
|
||||
"collapseAll": false,
|
||||
"extraContext": false,
|
||||
"sortOrder": "alphabetical",
|
||||
"showSearch": false,
|
||||
"searchQuery": "",
|
||||
"backlinkCollapsed": false,
|
||||
"unlinkedCollapsed": true
|
||||
},
|
||||
"icon": "links-coming-in",
|
||||
"title": "Backlinks for L2 Fundamentals"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "35838e13297ecef1",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "outgoing-link",
|
||||
"state": {
|
||||
"file": "Support - L2/L2 Fundamentals.md",
|
||||
"linksCollapsed": false,
|
||||
"unlinkedCollapsed": true
|
||||
},
|
||||
"icon": "links-going-out",
|
||||
"title": "Outgoing links from L2 Fundamentals"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "1632de8f17d6e4ad",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "tag",
|
||||
"state": {
|
||||
"sortOrder": "frequency",
|
||||
"useHierarchy": true
|
||||
},
|
||||
"icon": "lucide-tags",
|
||||
"title": "Tags"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "72bf1c83f4775541",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "all-properties",
|
||||
"state": {
|
||||
"sortOrder": "frequency",
|
||||
"showSearch": false,
|
||||
"searchQuery": ""
|
||||
},
|
||||
"icon": "lucide-archive",
|
||||
"title": "All properties"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "638e54066aa2ef85",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "side-panel-control-view",
|
||||
"state": {},
|
||||
"icon": "viewIcon",
|
||||
"title": "Markdown-Autocomplete"
|
||||
}
|
||||
}
|
||||
],
|
||||
"currentTab": 4
|
||||
}
|
||||
],
|
||||
"direction": "horizontal",
|
||||
"width": 334
|
||||
},
|
||||
"left-ribbon": {
|
||||
"hiddenItems": {
|
||||
"templates:Insert template": false,
|
||||
"command-palette:Open command palette": false,
|
||||
"obsidian-markdown-formatting-assistant-plugin:Open Markdown Formatting Assistant": false,
|
||||
"obsidian-kanban:Create new board": false,
|
||||
"obsidian-textgenerator-plugin:Generate Text!": false,
|
||||
"obsidian-textgenerator-plugin:Text Generator: Templates Packages Manager": false
|
||||
}
|
||||
},
|
||||
"active": "5e5fd1622dcd9b85",
|
||||
"lastOpenFiles": [
|
||||
"Python/Argument Passing.md",
|
||||
"Python/README.md.md",
|
||||
"Python/Invoking the Interpreter.md",
|
||||
"02 Templates/Sub Concept.md",
|
||||
"Python/Interactive Mode.md",
|
||||
"02 Templates/Main Concept.md",
|
||||
"{{Subsection 3 Title}}.md",
|
||||
"02 Templates",
|
||||
"Python",
|
||||
"The Symbolism of Water as an Element.md",
|
||||
"03 Attachments",
|
||||
"Pasted image 20241124160009.png",
|
||||
"Docs",
|
||||
"Langauges/Python/Untitled.md",
|
||||
"Networking/HTTP Status Codes.md",
|
||||
"01 Glossary/A.md",
|
||||
"01 Glossary/B.md",
|
||||
"Langauges/Python/ThinkPython/1 Programming as a Way of Thinking.md",
|
||||
"01 Glossary/D.md",
|
||||
"01 Glossary/O.md",
|
||||
"01 Glossary/C.md",
|
||||
"01 Glossary/E.md",
|
||||
"01 Glossary/F.md",
|
||||
"01 Glossary/I.md",
|
||||
"A^Arithmetic Operator.md",
|
||||
"Langauges/Python/ThinkPython/Untitled 1.md",
|
||||
"Langauges/Python/ThinkPython",
|
||||
"Networking/Cloudflare/5XX Errors.md",
|
||||
"Networking/Cloudflare/10XXX Errors.md",
|
||||
"Networking/Cloudflare/1XXX Errors.md",
|
||||
"Networking/Cloudflare",
|
||||
"Networking",
|
||||
"Langauges",
|
||||
"Langauges/Python",
|
||||
"Untitled 2",
|
||||
"_Admin/Callouts.md",
|
||||
"Support - L2/L2 Fundamentals.md"
|
||||
]
|
||||
}
|
Loading…
Reference in a new issue